Overview | Package | Class | Tree | Deprecated | Index | Help
| bea Systems, Inc.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## theory.smart.foundation
Class BelongingHome

    java.lang.Object
      |
      +--theory.smart.foundation.BelongingHome

public class BelongingHome
extends java.lang.Object
implements SmartHome

This is a Belonging home/bean factory.

See Also:
  `theory.smart.util.Helper#initFromTheoryProperties`

Field Summary
`static java.lang.String` | `BELONGING_BEAN_CLASS_NAME`
`static java.lang.String` | `CUSTOM_HOME_NAME`
`static java.lang.String` | `DEFAULT_BELONGING_IMPL_SUFFIX`

Constructor Summary
`BelongingHome()`

Method Summary
`static Belonging` | `create(java.lang.String belongingInterface)` Given a bean interface, use the factory pattern to create an instance.
`static SmartHome` | `getCustomHome(java.lang.String belongingInterface)` Given a bean interface, use the factory pattern to get its custom home.
`static void` | `init(java.util.Properties properties)` The init method must be called before any Belongings are created.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### CUSTOM_HOME_NAME

    public static final java.lang.String CUSTOM_HOME_NAME

### BELONGING_BEAN_CLASS_NAME

    public static final java.lang.String BELONGING_BEAN_CLASS_NAME

### DEFAULT_BELONGING_IMPL_SUFFIX

    public static final java.lang.String DEFAULT_BELONGING_IMPL_SUFFIX

Constructor Detail

### BelongingHome

    public BelongingHome()

Method Detail

### init

    public static void init(java.util.Properties properties)

  The init method must be called before any Belongings are created. This method is called from Helper.initFromTheoryProperties().
  See Also:
    `theory.smart.util.Helper#initFromTheoryProperties`

### getCustomHome

    public static SmartHome getCustomHome(java.lang.String belongingInterface)

  Given a bean interface, use the factory pattern to get its custom home. If a bean's custom home is not defined in the theory.properties file, then this method returns null. This is an example of specifying a custom home name in the properties file.

        theory.smart.axiom.contact.Address.CustomHomeName = com.acme.util.AddressHome
        theory.smart.axiom.contact.Phone.CustomHomeName = com.acme.contact.PhoneHome

### create

    public static Belonging create(java.lang.String belongingInterface)

  Given a bean interface, use the factory pattern to create an instance. The bean instance can be obtained from the theory.properties file. If it is not there, then we will use the default Impl where is the name of the bean interface. This is an example of specifying a different Impl class in the properties file.

       theory.smart.axiom.contact.Address.BelongingBeanClassName = com.acme.util.AddressBean
       theory.smart.axiom.contact.Phone.BelongingBeanClassName = com.acme.contact.PhoneBean

Overview | Package | Class | Tree | Deprecated | Index | Help
| bea Systems, Inc.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

© Copyright 2000 bea Systems, Inc. All rights reserved.