|
IBM Branch Transformation Toolkit Javadoc | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.ibm.btt.base.types.DSEType
This class provides an implementation of the Type interface that defines the type of the business object or business process. Associated PropertyDescriptors configure this definition. There are PropertyDescriptors that describe the structure of the type and a single PropertyDescriptor that defines the default business rules for business objects of the Type.
Field Summary | |
---|---|
static java.lang.String |
errorMsgsDynaInfoEndDelim
The end delimiter for dynamic error Messages |
static java.lang.String |
errorMsgsDynaInfoStartDelim
The start delimiter for dynamic error messages |
static DSETypeExternalizer |
externalizer
|
(package private) static java.lang.Object |
RESOURCE_BUNDLE_NOT_DEFINED
Empty object which is put in the cache where no locale .properties file is available |
static java.util.Hashtable |
resTypesCache
Cache of locales ResourcesBundles for types_locale.prperties |
static java.util.Hashtable |
resTypesExtCache
Cache of locales ResourcesBundles for typesext_locale.properties |
static java.lang.Boolean |
shareDescriptors
The Boolean to store the shareDataDescriptor flag defined in the dse.ini |
Fields inherited from interface com.ibm.btt.base.types.TypeConstants |
---|
amended, CONV_TYPE_DEFAULT, CONV_TYPE_HOST, CONV_TYPE_OUTPUT, CONV_TYPE_SER, CONV_TYPE_XML, disabled, hidden, isAmended, isDisabled, isHidden, isMandatory, isOmitted, isReadOnly, mandatory, omitted, readOnly, TYPE_DEFAULT, TYPE_REGISTRY_INIT_SIZE |
Constructor Summary | |
---|---|
DSEType(java.lang.String name,
java.lang.String implClassName)
This constructor creates a DSEType with the name and implementing class passed as argument. |
Method Summary | |
---|---|
PropertyDescription |
addPropertyDescriptor(PropertyDescription descriptor)
Adds the PropertyDescriptor passed as argument to the list of contained descriptors and, if successful, returns the added PropertyDescriptor. |
PropertyDescription |
addSharedDescriptor(PropertyDescription descriptor,
java.lang.String newDescriptorName)
Adds the existing PropertyDescriptor with the newDescriptorname to the list of contained descriptors and, if successful, returns the added PropertyDescriptor. |
java.lang.Object |
createInstance()
Returns a business object populated with the default data specified for this Type. |
java.lang.Object |
createInstance(PropertyDescription descriptor)
Returns a business object populated with the default data specified for this Type. |
java.lang.Object |
createInstance(PropertyDescription descriptor,
Hashtable parameters)
Returns a business object populated with the default data specified for this Type. |
java.lang.Object |
createInstanceSharingDescriptors(PropertyDescription descriptor,
Hashtable parameters,
java.lang.String newDescriptorName)
Returns a business object populated with the default data specified for this Type. |
java.lang.Object |
createInstanceSharingDescriptors(PropertyDescription descriptor,
java.lang.String newDescriptorName)
Returns a business object populated with the default data specified for this Type. |
PropertyDescription |
getDefaultDescriptorForType()
Returns the PropertyDescriptor associated with this Type, which defines its business rules. |
static java.lang.String |
getErrorMsgsDynaInfoEndDelim()
Gets the errorMsgsDynaInfoEndDelim. |
static java.lang.String |
getErrorMsgsDynaInfoStartDelim()
Gets the errorMsgsDynaInfoStartDelim. |
static DSETypeExternalizer |
getExternalizer()
Gets the externalizer. |
java.lang.Class |
getImplClass()
Returns the class that implements the business behavior described by this Type. |
Key |
getKey(TypedData businessObject)
Returns a Key object which can, if the Type has unique Keys, be used to identify the business object passed as argument. |
KeyBuilder |
getKeyBuilder()
Returns the KeyBuilder responsible for building Keys for this Type. |
static java.lang.String |
getMessageFromLocale(java.lang.String code,
java.util.Locale locale)
Returns the message associated with this locale. |
java.lang.String |
getName()
Returns the name of this Type. |
PropertyDescription |
getPropertyDescriptor(int index)
Returns the PropertyDescriptor at the index position. |
PropertyDescription |
getPropertyDescriptor(java.lang.String name)
Returns the PropertyDescriptor with the name passed, or null if no descriptor of that name exists. |
java.util.Enumeration |
getPropertyDescriptors()
Returns an Enumeration of all PropertyDescriptors contained within this Type. |
static java.util.ResourceBundle |
getResTypes()
Returns the resTypes. |
static java.util.ResourceBundle |
getResTypesExt()
Returns the resTypesExt. |
static boolean |
getShareDescriptors()
Gets the shareDataDescriptors flag. |
protected void |
initializeBusinessObjectState(ElementState iniState,
Hashtable parameters)
Initializes the ElementStae passed based on the attributes defined in the parameters Hashtable. |
boolean |
isCompound()
Returns a flag indicating whether this Type is Compound or not. |
static java.lang.Object |
readObject(java.lang.String name)
Instantiates a Typed Data Element named: name, from the definition file. |
void |
reset()
Resets this type. |
void |
reset(Type newType)
Resets this type with a new Type instance. |
void |
setDefaultDescriptorForType(PropertyDescription defaultDescriptor)
Sets the default PropertyDescriptor that defines this Type's business rules. |
static void |
setErrorMsgsDynaInfoEndDelim(java.lang.String errorMsgDynaInfoEndDelimToSet)
Sets the errorMsgsDynaInfoEndDelim property. |
static void |
setErrorMsgsDynaInfoStartDelim(java.lang.String errorMsgDynStartDelimToSet)
Sets the errorMsgsDynaInfoStartDelim property. |
static void |
setExternalizer(DSETypeExternalizer anExternalizer)
Sets the externalizer. |
void |
setKeyBuilder(KeyBuilder keyBuilder)
Sets the KeyBuilder that builds Keys for this Type. |
static void |
setResTypes(java.util.ResourceBundle resTypes)
Sets the resTypes. |
static void |
setResTypesExt(java.util.ResourceBundle resTypesExt)
Sets the resTypesExt. |
static void |
setShareDescriptors(boolean newShareDescriptors)
Sets the shareDescriptor property. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static java.util.Hashtable resTypesCache
public static java.util.Hashtable resTypesExtCache
static java.lang.Object RESOURCE_BUNDLE_NOT_DEFINED
public static DSETypeExternalizer externalizer
public static java.lang.Boolean shareDescriptors
public static java.lang.String errorMsgsDynaInfoStartDelim
public static java.lang.String errorMsgsDynaInfoEndDelim
Constructor Detail |
public DSEType(java.lang.String name, java.lang.String implClassName) throws DSETypeException
name
- StringimplClassName
- StringMethod Detail |
public PropertyDescription addPropertyDescriptor(PropertyDescription descriptor) throws DSETypeException
addPropertyDescriptor
in interface Type
descriptor
- PropertyDescription
DSETypeException
- - Name of PropertyDescriptor to add is either null or a duplicatepublic PropertyDescription addSharedDescriptor(PropertyDescription descriptor, java.lang.String newDescriptorName) throws DSETypeException
DSETypeException
- - Name of PropertyDescriptor to add is either null or a duplicatepublic java.lang.Object createInstance() throws DSETypeException
createInstance
in interface Type
DSETypeException
- - Object creation is unsuccessfulpublic java.lang.Object createInstance(PropertyDescription descriptor) throws DSETypeException
createInstance
in interface Type
descriptor
- PropertyDescription
DSETypeException
- - Object creation is unsuccessfulpublic java.lang.Object createInstance(PropertyDescription descriptor, Hashtable parameters) throws DSETypeException
DSETypeException
- - Object creation is unsuccessfulpublic java.lang.Object createInstanceSharingDescriptors(PropertyDescription descriptor, Hashtable parameters, java.lang.String newDescriptorName) throws DSETypeException
createInstanceSharingDescriptors
in interface Type
DSETypeException
- - Object creation is unsuccessfulpublic java.lang.Object createInstanceSharingDescriptors(PropertyDescription descriptor, java.lang.String newDescriptorName) throws DSETypeException
createInstanceSharingDescriptors
in interface Type
DSETypeException
- - Object creation is unsuccessfulpublic PropertyDescription getDefaultDescriptorForType()
getDefaultDescriptorForType
in interface Type
public static java.lang.String getErrorMsgsDynaInfoEndDelim()
public static java.lang.String getErrorMsgsDynaInfoStartDelim()
public static DSETypeExternalizer getExternalizer() throws DSETypeException
DSETypeException
public java.lang.Class getImplClass()
getImplClass
in interface Type
public Key getKey(TypedData businessObject) throws DSETypeException
This behavior may be delegated to a utility object since Types are to be employed, not subclassed. Returns a Key with a value of zero for all Types, including Simple Types, which do not have unique Keys.
getKey
in interface Type
businessObject
- TypedData
DSETypeException
- - If the building of the key for the businessObject given failspublic KeyBuilder getKeyBuilder()
getKeyBuilder
in interface Type
public static java.lang.String getMessageFromLocale(java.lang.String code, java.util.Locale locale)
code
- java.lang.Stringlocale
- java.util.Locale
public java.lang.String getName()
getName
in interface Type
public PropertyDescription getPropertyDescriptor(int index)
getPropertyDescriptor
in interface Type
index
- int
public PropertyDescription getPropertyDescriptor(java.lang.String name)
getPropertyDescriptor
in interface Type
name
- String
public java.util.Enumeration getPropertyDescriptors()
getPropertyDescriptors
in interface Type
public static boolean getShareDescriptors()
protected void initializeBusinessObjectState(ElementState iniState, Hashtable parameters)
public boolean isCompound()
isCompound
in interface Type
public static java.lang.Object readObject(java.lang.String name) throws DSETypeException
DSETypeException
public void reset() throws DSETypeException
reset
in interface Type
DSETypeException
- - If the type cannot be resetpublic void reset(Type newType) throws DSETypeException
reset
in interface Type
newType
- com.ibm.btt.base.types.DSEType
DSETypeException
- - If the type cannot be resetpublic void setDefaultDescriptorForType(PropertyDescription defaultDescriptor)
setDefaultDescriptorForType
in interface Type
defaultDescriptor
- PropertyDescriptionpublic static void setErrorMsgsDynaInfoEndDelim(java.lang.String errorMsgDynaInfoEndDelimToSet)
public static void setErrorMsgsDynaInfoStartDelim(java.lang.String errorMsgDynStartDelimToSet)
public static void setExternalizer(DSETypeExternalizer anExternalizer)
anExternalizer
- DSETypeExternalizerpublic void setKeyBuilder(KeyBuilder keyBuilder)
setKeyBuilder
in interface Type
keyBuilder
- KeyBuilderpublic static void setShareDescriptors(boolean newShareDescriptors)
public static java.util.ResourceBundle getResTypes()
public static void setResTypes(java.util.ResourceBundle resTypes)
resTypes
- - The resTypes to setpublic static java.util.ResourceBundle getResTypesExt()
public static void setResTypesExt(java.util.ResourceBundle resTypesExt)
resTypesExt
- - The resTypesExt to set
|
IBM Branch Transformation Toolkit Javadoc | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |