com.ibm.di.config.base
Class BaseConfigurationImpl

java.lang.Object
  extended by com.ibm.di.config.base.BaseConfigurationImpl
All Implemented Interfaces:
BaseConfiguration, MetamergeConfigChangeListener, Serializable
Direct Known Subclasses:
AssemblyLineConfigImpl, AttributeMapConfigImpl, AttributeMapItemImpl, BranchConditionImpl, CallConfigImpl, CallParamConfigImpl, CheckpointConfigImpl, ConnectorConfigImpl, ConnectorSchemaConfigImpl, ConnectorSchemaItemConfigImpl, ContainerConfigImpl, DeltaConfigImpl, EventHandlerActionConfigImpl, EventHandlerActionItemConfigImpl, EventHandlerConditionConfigImpl, EventHandlerConfigImpl, ExposedPropertyImpl, ExternalFile, ExternalPropertiesDelegator, ExternalPropertiesImpl, FormConfigImpl, FormItemConfigImpl, HookConfigImpl, InheritConfigImpl, InstanceConfigImpl, LibraryConfigImpl, LinkCriteriaConfigImpl, LinkCriteriaItemImpl, LogConfigImpl, LogConfigItemImpl, MetamergeConfigImpl, MetamergeFolderImpl, NamespaceConfigImpl, OperationConfigImpl, ParserConfigImpl, PoolDefConfigImpl, PoolInstanceConfigImpl, PropertyConfigImpl, PropertyManagerImpl, PropertyStoreConfigImpl, RawConnectorConfigImpl, ReconnectConfigImpl, SandboxConfigImpl, SchemaConfigImpl, SchemaItemConfigImpl, ScriptConfigImpl, TombstonesConfigImpl

public class BaseConfigurationImpl
extends Object
implements BaseConfiguration, MetamergeConfigChangeListener

See Also:
Serialized Form

Field Summary
static String NAME
           
 
Fields inherited from interface com.ibm.di.config.interfaces.BaseConfiguration
DISABLE_EXTPROPS, DISABLE_INHERITANCE, INHERIT_NONE, INHERIT_PARENT, ONE_LEVEL, RECURSIVE, RECURSIVE_ONELEVEL, RECURSIVE_SUBTREE, SEARCH_EXACTCASE, SEARCH_ONELEVEL, SEARCH_PARAMNAME, SEARCH_PARAMNAME_RE, SEARCH_PROPERTY, SEARCH_REGEX, SUBTREE
 
Constructor Summary
BaseConfigurationImpl()
          Empty constructor
BaseConfigurationImpl(Object data)
          Constructor providing a TreeMap of attribute/value pairs
 
Method Summary
 void addListener(MetamergeConfigChangeListener listener)
          Registers an object to be notified of change events in this object.
 void configurationChanged(MetamergeConfigChange mcc)
           
 TreeMap deepClone(TreeMap inputMap)
          Clones the local data structure
 Object expandPropertyValue(Object name, Object value)
          Substitutes the parameter value with a user property value.
 Object expandPropertyValue(Object name, Object value, List cref)
           
 boolean flatten(List excludedNS)
          flatten - combines all values from this object and its inherited objects into one single config object.
 void fromEntry(Object entry)
          This method should populate this object with data from a com.ibm.di.entry.Entry object.
 boolean getBooleanParameter(Object key, boolean defval)
          Converts value from getParameter call to a boolean
 BaseConfiguration getChild(Object name)
          Named children support
 BaseConfiguration getChildForPath(String path)
          This method traverses the child hierarchy (from the top) and returns the configuration object associated with the path.
 List getChildNames()
          Returns a list of names for all child configuration object
 Object getClone()
          Returns a cloned version of this object.
 TreeMap getData()
          Returns the internal data structure for this object.
 Iterator getDataIterator()
          Returns an Iterator for all keys in this object.
 boolean getDebug()
          Common methods
 boolean getDebug(boolean defval)
          Returns the debug flag for the object.
 boolean getDebugBreak(boolean defval)
          Gets the debugBreak attribute of the BaseConfiguration object
 boolean getEnabled()
          Gets the enabled attribute of the BaseConfiguration object
 int getFlags()
          Returns flags
 BaseConfiguration getInheritsFrom()
          Returns the configuration we inherit from.
 String getInheritsFromRef()
          Returns the explictly inherited object name
 int getIntegerParameter(Object key, int defval)
          Converts value from getParameter call to an int
 List getKeys(int level)
          Returns a list of keys in this object.
 boolean getLogEnabled()
          Gets the log enabled attribute of the BaseConfiguration object
 MetamergeConfig getMetamergeConfig()
          Gets the metamergeConfig objects to which this object belongs.
 boolean getModified()
          Returns the modified state of this object.
 Name getName()
          Returns the name of this object
 Object getNamespace()
          Gets the namespace attribute of the BaseConfiguration object
 String getNullBehavior()
          Gets the nullBehavior attribute of the BaseConfiguration object
 String getNullBehaviorValue()
          Gets the nullBehaviorValue attribute of the BaseConfiguration object
 String getNullDefinition()
          Gets the nullDefinition attribute of the BaseConfiguration object
 String getNullDefinitionValue()
          Gets the nullDefinitionValue attribute of the BaseConfiguration object
 Object getParameter(Object name)
          Returns the value for a given config item.
 Object getParameter(Object name, Object createValue)
          Gets the parameter attribute of the BaseConfiguration object.
 Object getParameter(Object name, Object createValue, List cref)
          Returns the value for a given config item.
 String getParameterPropertySource(Object name)
          Returns the property name source for a given parameter name.
 String getParameterPropertySourceFromValue(Object value)
           
 Object getParameterRaw(Object name)
          Returns the value for a given config item without expanding the property value.
 BaseConfiguration getParent()
          Returns the parent configuration object
 String getParentName()
          Returns a string giving the complete name of the parent, followed by a dot If no parent, return empty string
 String getPath()
          This method returns the path to this object.
 List getReferences(List list)
          Returns a list of all references to other object from which this object or its children inherit from.
static ResourceHash getResHash()
           
 String getScript()
          Gets the script attribute of the BaseConfiguration object
 String getScriptEngine()
          Gets the ScriptEngine attribute of the BaseConfiguration object
 String getShortName()
          Gets the shortName attribute of the BaseConfiguration object.
 String getStringParameter(Object name)
          Converts value from getParameter call to a string
 Map getSubstitutionMap()
          Returns the Map object containing available objects for param substitution
 boolean getUseListeners()
           
 String getUserComment()
          Returns the user defined comment string
 boolean hasParameter(Object name)
          Returns true if parameter name is local to this object.
 void init()
          init - method called after internal data structure is set
 boolean isParameterLocal(Object name)
          Returns true if either the parameter is local or false if the parameter does not exist either in this object or in any inherited object.
 String nameForChild(BaseConfiguration config)
          Returns the name for a configuration object
 void notifyChange(Object source, Object key, int operation)
          Signal a change event to listeners.
 void notifyChange(Object source, Object key, int operation, Object userObject)
          Signal a change event to listeners.
protected  void performNotifyChange(MetamergeConfigChange mcc)
           
 void removeListener(MetamergeConfigChangeListener listener)
          Removes a listener from the notification list.
 void removeParameter(Object name)
          Get/Set parameter variants.
 List search(String text, int options, int sizelimit)
          Searches a configuration object and optionally its children for a specific key or value.
 List search(String text, int options, int sizelimit, List results)
          Searches a configuration object and optionally its children for a specific key or value.
 void setBooleanParameter(Object name, boolean value)
          Calls setParameter converting value to a Boolean object
 void setChild(Object name, BaseConfiguration config)
          Associates a configuration object with a name in this configuration
 void setData(TreeMap obj)
          Sets the internal data structure for this object.
 void setDebug(boolean debug)
          Common method - Sets the debug flag for the object
 void setDebugBreak(boolean debug)
          Sets the debugBreak attribute of the BaseConfiguration object
 void setEnabled(boolean autoStart)
          Gets the enabled attribute of the BaseConfiguration object
 void setFlags(int flags)
          Set flags ( like ignore inheritance )
 void setInheritsFrom(BaseConfiguration inherit)
          Sets the configuration we inherit from.
 void setInheritsFromRef(String ref)
          Sets the name of the object from which this object should inherit its values.
 void setIntegerParameter(Object name, int value)
          Calls setParameter converting value to an Integer object
 void setLogEnabled(boolean enabled)
          Sets the log enabled attribute of the BaseConfiguration object
 void setMetamergeConfig(MetamergeConfig mc)
          Sets the Metamergeconfig object to which this object belongs.
 void setModified(boolean modified)
          Sets the modified state of this object.
 void setName(Name name)
          Sets the name of this object
 void setName(String name)
          Sets the name attribute of the BaseConfiguration object
 void setNullBehavior(String nb)
          Sets the nullBehavior attribute of the BaseConfiguration object
 void setNullBehaviorValue(String nbv)
          Sets the nullBehaviorValue attribute of the BaseConfiguration object
 void setNullDefinition(String nb)
          Sets the nullDefinition attribute of the BaseConfiguration object
 void setNullDefinitionValue(String nbv)
          Sets the nullDefinitionValue attribute of the BaseConfiguration object
 void setParameter(Object name, Object value)
          Sets the value for a given config item
 void setParameter(Object name, Object value, boolean notify)
          Sets the value for a given config item, optionally notifying the change.
 void setParameterPropertySource(Object name, String propertySource)
          Associates a parameter name with a user property.
 void setParent(BaseConfiguration parent)
          Sets the parent object.
 void setProtectedParameter(Object name, Object value)
          Stores the parameter value in the default password store if one is configured.
 void setScript(String script)
          Sets the script attribute of the BaseConfiguration object
 void setScriptEngine(String engine)
          Sets the ScriptEngine attribute of the BaseConfiguration object
 void setStringParameter(Object name, String value)
          Calls setParameter
 void setSubstitutionMap(Map map)
          Sets the substutition map for this configuration object
 void setupInheritanceChain()
          Established the inheritance chain for this object.
 void setUseListeners(boolean value)
          Event listener methods.
 void setUserComment(String comment)
          v Sets the user defined comment string
 int size()
          Returns the total number of keys in this configuration object.
 Object toEntry()
          Object/State using Entry object.
 String toString()
           
 void updateInheritsFrom(String ref)
          Sets the name of the object from which this object should inherit its values and calls the setupInheritanceChain to activate the change.
 boolean willExpandProps()
           
 boolean willFlatten(List excludedNS)
          willFlatten - returns true if this object will attempt flattening given the provided excluded namespaces
 boolean willUseInherited()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

NAME

public static final String NAME
See Also:
Constant Field Values
Constructor Detail

BaseConfigurationImpl

public BaseConfigurationImpl()
Empty constructor


BaseConfigurationImpl

public BaseConfigurationImpl(Object data)
Constructor providing a TreeMap of attribute/value pairs

Method Detail

getResHash

public static ResourceHash getResHash()

setupInheritanceChain

public void setupInheritanceChain()
                           throws Exception
Established the inheritance chain for this object.

Specified by:
setupInheritanceChain in interface BaseConfiguration
Throws:
Exception - if the operation does not succeed

getInheritsFrom

public BaseConfiguration getInheritsFrom()
Returns the configuration we inherit from.

Specified by:
getInheritsFrom in interface BaseConfiguration
Returns:
The inherited object

getInheritsFromRef

public String getInheritsFromRef()
Returns the explictly inherited object name

Specified by:
getInheritsFromRef in interface BaseConfiguration
Returns:
The name of the inherited object

setInheritsFrom

public void setInheritsFrom(BaseConfiguration inherit)
Sets the configuration we inherit from.

Specified by:
setInheritsFrom in interface BaseConfiguration
Parameters:
inherit - The new inheritsFrom value

updateInheritsFrom

public void updateInheritsFrom(String ref)
                        throws Exception
Description copied from interface: BaseConfiguration
Sets the name of the object from which this object should inherit its values and calls the setupInheritanceChain to activate the change.

Specified by:
updateInheritsFrom in interface BaseConfiguration
Parameters:
ref - The new inheritsFromRef value
Throws:
Exception

setInheritsFromRef

public void setInheritsFromRef(String ref)
Description copied from interface: BaseConfiguration
Sets the name of the object from which this object should inherit its values.

Specified by:
setInheritsFromRef in interface BaseConfiguration
Parameters:
ref - The new inheritsFromRef value

getModified

public boolean getModified()
Returns the modified state of this object.

Specified by:
getModified in interface BaseConfiguration
Returns:
The modified value

setModified

public void setModified(boolean modified)
Sets the modified state of this object.

Specified by:
setModified in interface BaseConfiguration
Parameters:
modified - The new modified value

setUseListeners

public void setUseListeners(boolean value)
Event listener methods.

Specified by:
setUseListeners in interface BaseConfiguration

getUseListeners

public boolean getUseListeners()
Specified by:
getUseListeners in interface BaseConfiguration

addListener

public void addListener(MetamergeConfigChangeListener listener)
Description copied from interface: BaseConfiguration
Registers an object to be notified of change events in this object.

Specified by:
addListener in interface BaseConfiguration
Parameters:
listener - The listener object to notify.

removeListener

public void removeListener(MetamergeConfigChangeListener listener)
Description copied from interface: BaseConfiguration
Removes a listener from the notification list.

Specified by:
removeListener in interface BaseConfiguration
Parameters:
listener - The listener object to remove

configurationChanged

public void configurationChanged(MetamergeConfigChange mcc)
Specified by:
configurationChanged in interface MetamergeConfigChangeListener

notifyChange

public void notifyChange(Object source,
                         Object key,
                         int operation)
Description copied from interface: BaseConfiguration
Signal a change event to listeners. This method is typically called by setParameter but not user code.

Specified by:
notifyChange in interface BaseConfiguration
Parameters:
source - The caller initiating the change event
key - The key that changed
operation - The operation performed on key

notifyChange

public void notifyChange(Object source,
                         Object key,
                         int operation,
                         Object userObject)
Description copied from interface: BaseConfiguration
Signal a change event to listeners. This method is typically called by setParameter but not user code.

Specified by:
notifyChange in interface BaseConfiguration
Parameters:
source - The caller initiating the change event
key - The key that changed
operation - The operation performed on key
userObject - Arbitrary object provided by caller

performNotifyChange

protected void performNotifyChange(MetamergeConfigChange mcc)

size

public int size()
Returns the total number of keys in this configuration object.

Specified by:
size in interface BaseConfiguration
Returns:
A count of local items in this object

getName

public Name getName()
Returns the name of this object

Specified by:
getName in interface BaseConfiguration
Returns:
The name value

getShortName

public String getShortName()
Description copied from interface: BaseConfiguration
Gets the shortName attribute of the BaseConfiguration object. The short name is the last component in a multi component name. E.g.: AssemblyLines/MyName --> "MyName"

Specified by:
getShortName in interface BaseConfiguration
Returns:
The shortName value

getNamespace

public Object getNamespace()
Description copied from interface: BaseConfiguration
Gets the namespace attribute of the BaseConfiguration object

Specified by:
getNamespace in interface BaseConfiguration
Returns:
The namespace value

setName

public void setName(Name name)
Sets the name of this object

Specified by:
setName in interface BaseConfiguration
Parameters:
name - The new name value

setName

public void setName(String name)
             throws Exception
Description copied from interface: BaseConfiguration
Sets the name attribute of the BaseConfiguration object

Specified by:
setName in interface BaseConfiguration
Parameters:
name - The new name value
Throws:
Exception - if the operation does not succeed

getData

public TreeMap getData()
Returns the internal data structure for this object.

Specified by:
getData in interface BaseConfiguration
Returns:
The treemap

deepClone

public TreeMap deepClone(TreeMap inputMap)
Clones the local data structure


setData

public void setData(TreeMap obj)
Sets the internal data structure for this object.

Specified by:
setData in interface BaseConfiguration
Parameters:
obj - The new data value

init

public void init()
          throws Exception
init - method called after internal data structure is set

Specified by:
init in interface BaseConfiguration
Throws:
Exception - if the initialization fails

getDataIterator

public Iterator getDataIterator()
Returns an Iterator for all keys in this object.

Specified by:
getDataIterator in interface BaseConfiguration
Returns:
The dataIterator value

getKeys

public List getKeys(int level)
Returns a list of keys in this object. If level is ONE_LEVEL only simple key/value items are returned. If SUBTREE is specified then all keys are returned regardless of whether they are complex (TreeMap) or simple (String, Boolean, Integer, Vector ). If RECURSIVE is anded in then inherited keys are returned as well.

Specified by:
getKeys in interface BaseConfiguration
Parameters:
level - The level of keys returned.
Returns:
The list of keys

getParent

public BaseConfiguration getParent()
Returns the parent configuration object

Specified by:
getParent in interface BaseConfiguration
Returns:
The parent value

getParentName

public String getParentName()
Returns a string giving the complete name of the parent, followed by a dot If no parent, return empty string


setParent

public void setParent(BaseConfiguration parent)
Sets the parent object.

Specified by:
setParent in interface BaseConfiguration
Parameters:
parent - The new parent value

setFlags

public void setFlags(int flags)
Set flags ( like ignore inheritance )

Specified by:
setFlags in interface BaseConfiguration

getFlags

public int getFlags()
Returns flags

Specified by:
getFlags in interface BaseConfiguration

removeParameter

public void removeParameter(Object name)
Get/Set parameter variants.

Specified by:
removeParameter in interface BaseConfiguration
Parameters:
name - Parameter name

isParameterLocal

public boolean isParameterLocal(Object name)
Description copied from interface: BaseConfiguration
Returns true if either the parameter is local or false if the parameter does not exist either in this object or in any inherited object.

Specified by:
isParameterLocal in interface BaseConfiguration
Parameters:
name - Parameter name
Returns:
True if name is local

hasParameter

public boolean hasParameter(Object name)
Description copied from interface: BaseConfiguration
Returns true if parameter name is local to this object.

Specified by:
hasParameter in interface BaseConfiguration
Parameters:
name - Parameter name
Returns:
true if name is local

getParameterRaw

public Object getParameterRaw(Object name)
Description copied from interface: BaseConfiguration
Returns the value for a given config item without expanding the property value.

Specified by:
getParameterRaw in interface BaseConfiguration
Parameters:
name - The parameter name
Returns:
The parameter value

getParameter

public Object getParameter(Object name)
Description copied from interface: BaseConfiguration
Returns the value for a given config item. This method will call inherited object's getParameter if this object does not contain the named value. In case of returning an inherited value, the value from the inherited object will be cloned. It is up to the user to create a key/value local to this object by calling one of the setParameter methods.

Specified by:
getParameter in interface BaseConfiguration
Parameters:
name - The parameter name
Returns:
The parameter value

getParameter

public Object getParameter(Object name,
                           Object createValue)
Description copied from interface: BaseConfiguration
Gets the parameter attribute of the BaseConfiguration object. If the parameter is not present a default value is assigned to the parameter using createValue.

Specified by:
getParameter in interface BaseConfiguration
Parameters:
name - The parameter name
createValue - The value added to this object in case the parameter does not exist
Returns:
The parameter value

getParameter

public Object getParameter(Object name,
                           Object createValue,
                           List cref)
Description copied from interface: BaseConfiguration
Returns the value for a given config item. This method will call inherited object's getParameter if this object does not contain the named value. In case of returning an inherited value, the value from the inherited object will be cloned. It is up to the user to create a key/value local to this object by calling one of the setParameter methods. This method also conveys the List object to ParameterSubstitution calls to resolve circular references. If the parameter is not present even after calling inherited object's getParameter, a default value is assigned to the parameter using createValue.

Specified by:
getParameter in interface BaseConfiguration
Parameters:
name - The parameter name
createValue - The value added to this object in case the parameter does not exist "@param cref The circular references list
Returns:
The parameter value

getStringParameter

public String getStringParameter(Object name)
Description copied from interface: BaseConfiguration
Converts value from getParameter call to a string

Specified by:
getStringParameter in interface BaseConfiguration
Parameters:
name - The parameter name
Returns:
The stringParameter value

getBooleanParameter

public boolean getBooleanParameter(Object key,
                                   boolean defval)
Description copied from interface: BaseConfiguration
Converts value from getParameter call to a boolean

Specified by:
getBooleanParameter in interface BaseConfiguration
Parameters:
key - The parameter name
defval - The default value if parameter does not exist
Returns:
The boolean value

getIntegerParameter

public int getIntegerParameter(Object key,
                               int defval)
Description copied from interface: BaseConfiguration
Converts value from getParameter call to an int

Specified by:
getIntegerParameter in interface BaseConfiguration
Parameters:
key - The parameter name
defval - The default value if parameter does not exist
Returns:
The integerParameter value

setParameter

public void setParameter(Object name,
                         Object value)
Description copied from interface: BaseConfiguration
Sets the value for a given config item

Specified by:
setParameter in interface BaseConfiguration
Parameters:
name - Parameter name
value - Parameter value

setParameter

public void setParameter(Object name,
                         Object value,
                         boolean notify)
Description copied from interface: BaseConfiguration
Sets the value for a given config item, optionally notifying the change. If notify is true, the behavior is identical to setParameter( name, value ).

Specified by:
setParameter in interface BaseConfiguration
Parameters:
name - Parameter name
value - Parameter value
notify - If true, notify of the change

setProtectedParameter

public void setProtectedParameter(Object name,
                                  Object value)
                           throws Exception
Description copied from interface: BaseConfiguration
Stores the parameter value in the default password store if one is configured. Retrieval of the parameter is done through the standard getParameter methods.

Specified by:
setProtectedParameter in interface BaseConfiguration
Parameters:
name - Parameter name
value - Parameter value
Throws:
Exception

setBooleanParameter

public void setBooleanParameter(Object name,
                                boolean value)
Description copied from interface: BaseConfiguration
Calls setParameter converting value to a Boolean object

Specified by:
setBooleanParameter in interface BaseConfiguration
Parameters:
name - Parameter name
value - Parameter value

setIntegerParameter

public void setIntegerParameter(Object name,
                                int value)
Description copied from interface: BaseConfiguration
Calls setParameter converting value to an Integer object

Specified by:
setIntegerParameter in interface BaseConfiguration
Parameters:
name - Parameter name
value - Parameter value

setStringParameter

public void setStringParameter(Object name,
                               String value)
Description copied from interface: BaseConfiguration
Calls setParameter

Specified by:
setStringParameter in interface BaseConfiguration
Parameters:
name - Parameter name
value - Parameter value

getParameterPropertySource

public String getParameterPropertySource(Object name)
Returns the property name source for a given parameter name. If the parameter name is not associated with a user property then null is returned.

Specified by:
getParameterPropertySource in interface BaseConfiguration
Parameters:
name - Parameter name
Returns:
The user property source value

getParameterPropertySourceFromValue

public String getParameterPropertySourceFromValue(Object value)

setParameterPropertySource

public void setParameterPropertySource(Object name,
                                       String propertySource)
Associates a parameter name with a user property.

Specified by:
setParameterPropertySource in interface BaseConfiguration
Parameters:
name - Parameter name
propertySource - User property name

expandPropertyValue

public Object expandPropertyValue(Object name,
                                  Object value)
Substitutes the parameter value with a user property value.


expandPropertyValue

public Object expandPropertyValue(Object name,
                                  Object value,
                                  List cref)

toEntry

public Object toEntry()
               throws Exception
Object/State using Entry object. Default implementation simply copies every attribute to/from entry using String values.

Specified by:
toEntry in interface BaseConfiguration
Returns:
The entry representing
Throws:
Exception - Any exception thrown by the implementing class

fromEntry

public void fromEntry(Object entry)
               throws Exception
Description copied from interface: BaseConfiguration
This method should populate this object with data from a com.ibm.di.entry.Entry object.

Specified by:
fromEntry in interface BaseConfiguration
Parameters:
entry - The entry containing data
Throws:
Exception - Any exception thrown by the implementing class

toString

public String toString()
Overrides:
toString in class Object

setMetamergeConfig

public void setMetamergeConfig(MetamergeConfig mc)
Description copied from interface: BaseConfiguration
Sets the Metamergeconfig object to which this object belongs.

Specified by:
setMetamergeConfig in interface BaseConfiguration
Parameters:
mc - The new metamergeConfig object

getMetamergeConfig

public MetamergeConfig getMetamergeConfig()
Description copied from interface: BaseConfiguration
Gets the metamergeConfig objects to which this object belongs.

Specified by:
getMetamergeConfig in interface BaseConfiguration
Returns:
The metamergeConfig object

getDebug

public boolean getDebug()
Common methods

Specified by:
getDebug in interface BaseConfiguration
Returns:
The debug value

getDebug

public boolean getDebug(boolean defval)
Description copied from interface: BaseConfiguration
Returns the debug flag for the object.

Specified by:
getDebug in interface BaseConfiguration
Parameters:
defval - The value to be returned, if the debug parameter cannot be found
Returns:
The debug value

setDebug

public void setDebug(boolean debug)
Description copied from interface: BaseConfiguration
Common method - Sets the debug flag for the object

Specified by:
setDebug in interface BaseConfiguration
Parameters:
debug - The new debug value

getDebugBreak

public boolean getDebugBreak(boolean defval)
Description copied from interface: BaseConfiguration
Gets the debugBreak attribute of the BaseConfiguration object

Specified by:
getDebugBreak in interface BaseConfiguration
Parameters:
defval - The value to be returned, if the debugBreak parameter cannot be found
Returns:
The debugBreak value

setDebugBreak

public void setDebugBreak(boolean debug)
Description copied from interface: BaseConfiguration
Sets the debugBreak attribute of the BaseConfiguration object

Specified by:
setDebugBreak in interface BaseConfiguration
Parameters:
debug - The new debugBreak value

getScript

public String getScript()
Description copied from interface: BaseConfiguration
Gets the script attribute of the BaseConfiguration object

Specified by:
getScript in interface BaseConfiguration
Returns:
The script value

setScript

public void setScript(String script)
Description copied from interface: BaseConfiguration
Sets the script attribute of the BaseConfiguration object

Specified by:
setScript in interface BaseConfiguration
Parameters:
script - The new script value

getScriptEngine

public String getScriptEngine()
Description copied from interface: BaseConfiguration
Gets the ScriptEngine attribute of the BaseConfiguration object

Specified by:
getScriptEngine in interface BaseConfiguration
Returns:
The ScriptEngine value

setScriptEngine

public void setScriptEngine(String engine)
Description copied from interface: BaseConfiguration
Sets the ScriptEngine attribute of the BaseConfiguration object

Specified by:
setScriptEngine in interface BaseConfiguration
Parameters:
engine - The new ScriptEngine value

getNullBehavior

public String getNullBehavior()
Description copied from interface: BaseConfiguration
Gets the nullBehavior attribute of the BaseConfiguration object

Specified by:
getNullBehavior in interface BaseConfiguration
Returns:
The nullBehavior value

getNullBehaviorValue

public String getNullBehaviorValue()
Description copied from interface: BaseConfiguration
Gets the nullBehaviorValue attribute of the BaseConfiguration object

Specified by:
getNullBehaviorValue in interface BaseConfiguration
Returns:
The nullBehaviorValue value

setNullBehavior

public void setNullBehavior(String nb)
Description copied from interface: BaseConfiguration
Sets the nullBehavior attribute of the BaseConfiguration object

Specified by:
setNullBehavior in interface BaseConfiguration
Parameters:
nb - The new nullBehavior value

setNullBehaviorValue

public void setNullBehaviorValue(String nbv)
Description copied from interface: BaseConfiguration
Sets the nullBehaviorValue attribute of the BaseConfiguration object

Specified by:
setNullBehaviorValue in interface BaseConfiguration
Parameters:
nbv - The new nullBehaviorValue value

getNullDefinition

public String getNullDefinition()
Gets the nullDefinition attribute of the BaseConfiguration object

Specified by:
getNullDefinition in interface BaseConfiguration
Returns:
The nullDefinition value

getNullDefinitionValue

public String getNullDefinitionValue()
Gets the nullDefinitionValue attribute of the BaseConfiguration object

Specified by:
getNullDefinitionValue in interface BaseConfiguration
Returns:
The nullDefinitionValue value

setNullDefinition

public void setNullDefinition(String nb)
Sets the nullDefinition attribute of the BaseConfiguration object

Specified by:
setNullDefinition in interface BaseConfiguration
Parameters:
nb - The new nullBehavior value

setNullDefinitionValue

public void setNullDefinitionValue(String nbv)
Sets the nullDefinitionValue attribute of the BaseConfiguration object

Specified by:
setNullDefinitionValue in interface BaseConfiguration
Parameters:
nbv - The new nullBehaviorValue value

getEnabled

public boolean getEnabled()
Description copied from interface: BaseConfiguration
Gets the enabled attribute of the BaseConfiguration object

Specified by:
getEnabled in interface BaseConfiguration
Returns:
The nullBehaviorValue value

setEnabled

public void setEnabled(boolean autoStart)
Description copied from interface: BaseConfiguration
Gets the enabled attribute of the BaseConfiguration object

Specified by:
setEnabled in interface BaseConfiguration

willExpandProps

public boolean willExpandProps()

willUseInherited

public boolean willUseInherited()

getClone

public Object getClone()
                throws Exception
Description copied from interface: BaseConfiguration
Returns a cloned version of this object.

Specified by:
getClone in interface BaseConfiguration
Throws:
Exception

getLogEnabled

public boolean getLogEnabled()
Description copied from interface: BaseConfiguration
Gets the log enabled attribute of the BaseConfiguration object

Specified by:
getLogEnabled in interface BaseConfiguration
Returns:
The nullBehaviorValue value

setLogEnabled

public void setLogEnabled(boolean enabled)
Description copied from interface: BaseConfiguration
Sets the log enabled attribute of the BaseConfiguration object

Specified by:
setLogEnabled in interface BaseConfiguration

setUserComment

public void setUserComment(String comment)
v Sets the user defined comment string

Specified by:
setUserComment in interface BaseConfiguration

getUserComment

public String getUserComment()
Returns the user defined comment string

Specified by:
getUserComment in interface BaseConfiguration

getSubstitutionMap

public Map getSubstitutionMap()
Returns the Map object containing available objects for param substitution

Specified by:
getSubstitutionMap in interface BaseConfiguration

setSubstitutionMap

public void setSubstitutionMap(Map map)
Sets the substutition map for this configuration object

Specified by:
setSubstitutionMap in interface BaseConfiguration

flatten

public boolean flatten(List excludedNS)
                throws Exception
flatten - combines all values from this object and its inherited objects into one single config object. After flattening, the object is a complete object with no inherited values except those from the excludedNS list.

Specified by:
flatten in interface BaseConfiguration
Parameters:
excludedNS - List of namespaces to exclude from flattening
Returns:
TRUE if object attempted flattening, FALSE is this object inherits from an excluded namespace or has no inheritance
Throws:
Exception

willFlatten

public boolean willFlatten(List excludedNS)
willFlatten - returns true if this object will attempt flattening given the provided excluded namespaces

Specified by:
willFlatten in interface BaseConfiguration

getReferences

public List getReferences(List list)
Description copied from interface: BaseConfiguration
Returns a list of all references to other object from which this object or its children inherit from.

Specified by:
getReferences in interface BaseConfiguration
Parameters:
list - If non-null, the object must use the provided list rather than creating its own

search

public List search(String text,
                   int options,
                   int sizelimit)
Description copied from interface: BaseConfiguration
Searches a configuration object and optionally its children for a specific key or value.

Specified by:
search in interface BaseConfiguration
Parameters:
text - The search text
options - Search options (oneLevel=1, exactCase=2, regExp=4, paramName=8)
sizelimit - Max number of hits returned

search

public List search(String text,
                   int options,
                   int sizelimit,
                   List results)
Description copied from interface: BaseConfiguration
Searches a configuration object and optionally its children for a specific key or value.

Specified by:
search in interface BaseConfiguration
Parameters:
text - The search text
options - Search options (oneLevel=1, exactCase=2, regExp=4, paramName=8)
sizelimit - Max number of hits returned
results - A list of results.

getChild

public BaseConfiguration getChild(Object name)
Named children support

Specified by:
getChild in interface BaseConfiguration
Parameters:
name - The name of the configuration object

setChild

public void setChild(Object name,
                     BaseConfiguration config)
Description copied from interface: BaseConfiguration
Associates a configuration object with a name in this configuration

Specified by:
setChild in interface BaseConfiguration
Parameters:
name - The name
config - The configuration object

getChildNames

public List getChildNames()
Description copied from interface: BaseConfiguration
Returns a list of names for all child configuration object

Specified by:
getChildNames in interface BaseConfiguration
Returns:
list of names

nameForChild

public String nameForChild(BaseConfiguration config)
Description copied from interface: BaseConfiguration
Returns the name for a configuration object

Specified by:
nameForChild in interface BaseConfiguration
Parameters:
config - The configuration object
Returns:
The name associated with config or null if not found

getChildForPath

public BaseConfiguration getChildForPath(String path)
                                  throws NameNotFoundException
Description copied from interface: BaseConfiguration
This method traverses the child hierarchy (from the top) and returns the configuration object associated with the path. This method will in effect split the path in its components and recursively call getChild() to drill down to the last object in the path.

Specified by:
getChildForPath in interface BaseConfiguration
Parameters:
path - The complete path to an object (as returned by getPath())
Returns:
The configuration object associated with the path
Throws:
NameNotFoundException

getPath

public String getPath()
This method returns the path to this object. The path can be used to traverse a hierarchy of configuration objects/configuration values. The preferred name is the parent's name for this configuration object since we use the getChild() method to map between names and config objets. We do this since the name of this object can be different than the parent's name for the object, which basically happens when the parent container has several objects with the same name.

Specified by:
getPath in interface BaseConfiguration
Returns:
The path to this configuration object