|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface BaseConfiguration
Field Summary | |
---|---|
static int |
DISABLE_EXTPROPS
Flag to disable expansion of external properties (getParameter) |
static int |
DISABLE_INHERITANCE
Flag to disable inherited access (getParameter) |
static String |
INHERIT_NONE
Explicitly disregars inheritance |
static String |
INHERIT_PARENT
Inherit from parent |
static int |
ONE_LEVEL
Return keys of this object |
static int |
RECURSIVE
Flag that determines if getKeys() should recurse to inherited object |
static int |
RECURSIVE_ONELEVEL
Convenience for RECURSIVE + ONE_LEVEL |
static int |
RECURSIVE_SUBTREE
Convenience for RECURSIVE + SUBTREE |
static int |
SEARCH_EXACTCASE
|
static int |
SEARCH_ONELEVEL
|
static int |
SEARCH_PARAMNAME
|
static int |
SEARCH_PARAMNAME_RE
|
static int |
SEARCH_PROPERTY
|
static int |
SEARCH_REGEX
|
static int |
SUBTREE
Return child entries's keys of this object |
Method Summary | |
---|---|
void |
addListener(MetamergeConfigChangeListener listener)
Registers an object to be notified of change events in this object. |
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 name,
boolean defval)
Converts value from getParameter call to a boolean |
BaseConfiguration |
getChild(Object name)
Returns the configuration object named name. |
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 a TreeMap with key/value pairs for all local parameters. |
Iterator |
getDataIterator()
Returns an Iterator for the keys in the data object |
boolean |
getDebug()
Returns the debug flag for the object. |
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 the flags how the getParameter behaves in terms of inheritance and external properties. |
BaseConfiguration |
getInheritsFrom()
Returns the object from which this object inherits data. |
String |
getInheritsFromRef()
Gets the name of the object this object should inherit its values. |
int |
getIntegerParameter(Object name,
int defval)
Converts value from getParameter call to an int |
List |
getKeys(int level)
Gets the keys attribute of the BaseConfiguration 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()
Modified state |
Name |
getName()
The object's full name |
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 user property name for a parameter |
Object |
getParameterRaw(Object name)
Returns the value for a given config item without expanding the property value. |
BaseConfiguration |
getParent()
Returns the parent object to which this object belongs. |
String |
getPath()
Returns the complete 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. |
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()
Called to initialize to object. |
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. |
void |
removeListener(MetamergeConfigChangeListener listener)
Removes a listener from the notification list. |
void |
removeParameter(Object name)
Removes a local parameter from this object. |
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 data)
Sets the data to be used by this object by passing a TreeMap of key/value pairs. |
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 enabled)
Gets the enabled attribute of the BaseConfiguration object |
void |
setFlags(int flags)
Controls how the getParameter behaves in terms of inheritance and external properties. |
void |
setInheritsFrom(BaseConfiguration inherit)
Sets the object from which this object inherits data. |
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 attribute of the BaseConfiguration object |
void |
setName(Name name)
Sets the name attribute of the BaseConfiguration 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)
Sets the user property name to use for an attribute |
void |
setParent(BaseConfiguration parent)
Sets the parent object to which this object belongs. |
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()
Called to initialize the inheritance chain for this object. |
void |
setUseListeners(boolean value)
|
void |
setUserComment(String comment)
Sets the user defined comment string |
int |
size()
Number of key/value pairs. |
Object |
toEntry()
Object/State using Entry object. |
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 |
willFlatten(List excludedNS)
willFlatten - returns true if this object will attempt flattening given the provided excluded namespaces |
Field Detail |
---|
static final String INHERIT_NONE
static final String INHERIT_PARENT
static final int ONE_LEVEL
static final int SUBTREE
static final int RECURSIVE
static final int RECURSIVE_SUBTREE
static final int RECURSIVE_ONELEVEL
static final int DISABLE_INHERITANCE
static final int DISABLE_EXTPROPS
static final int SEARCH_ONELEVEL
static final int SEARCH_EXACTCASE
static final int SEARCH_REGEX
static final int SEARCH_PARAMNAME
static final int SEARCH_PROPERTY
static final int SEARCH_PARAMNAME_RE
Method Detail |
---|
Name getName()
String getShortName()
void setName(Name name)
name
- The new name valuevoid setName(String name) throws Exception
name
- The new name value
Exception
- if the operation does not succeedObject getNamespace()
boolean getModified()
void setModified(boolean modified)
modified
- The new modified valuevoid setFlags(int flags)
int getFlags()
Object getParameterRaw(Object name)
name
- The parameter name
Object getParameter(Object name)
name
- The parameter name
Object getParameter(Object name, Object createValue)
name
- The parameter namecreateValue
- The value added to this object in case the parameter does not exist
Object getParameter(Object name, Object createValue, List cref)
name
- The parameter namecreateValue
- The value added to this object in case the parameter does not exist
"@param cref The circular references list
String getStringParameter(Object name)
name
- The parameter name
boolean getBooleanParameter(Object name, boolean defval)
name
- The parameter namedefval
- The default value if parameter does not exist
int getIntegerParameter(Object name, int defval)
name
- The parameter namedefval
- The default value if parameter does not exist
void setParameter(Object name, Object value)
name
- Parameter namevalue
- Parameter valuevoid setProtectedParameter(Object name, Object value) throws Exception
name
- Parameter namevalue
- Parameter value
Exception
void setBooleanParameter(Object name, boolean value)
name
- Parameter namevalue
- Parameter valuevoid setIntegerParameter(Object name, int value)
name
- Parameter namevalue
- Parameter valuevoid setStringParameter(Object name, String value)
name
- Parameter namevalue
- Parameter valuevoid setParameter(Object name, Object value, boolean notify)
name
- Parameter namevalue
- Parameter valuenotify
- If true, notify of the changevoid removeParameter(Object name)
name
- Parameter nameboolean hasParameter(Object name)
name
- Parameter name
boolean isParameterLocal(Object name)
name
- Parameter name
String getParameterPropertySource(Object name)
name
- Parameter name
void setParameterPropertySource(Object name, String propertySource)
name
- Parameter namepropertySource
- User property nameint size()
TreeMap getData()
void setData(TreeMap data)
data
- The new data valuevoid init() throws Exception
Exception
- if the initialization failsIterator getDataIterator()
List getKeys(int level)
level
- The level of keys returned.
boolean getUseListeners()
void setUseListeners(boolean value)
void addListener(MetamergeConfigChangeListener listener)
listener
- The listener object to notify.void removeListener(MetamergeConfigChangeListener listener)
listener
- The listener object to removevoid notifyChange(Object source, Object key, int operation)
source
- The caller initiating the change eventkey
- The key that changedoperation
- The operation performed on keyvoid notifyChange(Object source, Object key, int operation, Object userObject)
source
- The caller initiating the change eventkey
- The key that changedoperation
- The operation performed on keyuserObject
- Arbitrary object provided by callerObject toEntry() throws Exception
Exception
- Any exception thrown by the implementing classvoid fromEntry(Object entry) throws Exception
entry
- The entry containing data
Exception
- Any exception thrown by the implementing classvoid setParent(BaseConfiguration parent)
parent
- The new parent valueBaseConfiguration getParent()
void setMetamergeConfig(MetamergeConfig mc)
mc
- The new metamergeConfig objectMetamergeConfig getMetamergeConfig()
void setupInheritanceChain() throws Exception
Exception
- if the operation does not succeedBaseConfiguration getInheritsFrom()
String getInheritsFromRef()
void setInheritsFromRef(String ref)
ref
- The new inheritsFromRef valuevoid updateInheritsFrom(String ref) throws Exception
ref
- The new inheritsFromRef value
Exception
void setInheritsFrom(BaseConfiguration inherit)
inherit
- The new inheritsFrom valueboolean getDebug()
boolean getDebug(boolean defval)
defval
- The value to be returned, if the debug parameter cannot be found
void setDebug(boolean debug)
debug
- The new debug valueboolean getDebugBreak(boolean defval)
defval
- The value to be returned, if the debugBreak parameter cannot be found
void setDebugBreak(boolean debug)
debug
- The new debugBreak valueString getScript()
void setScript(String script)
script
- The new script valueString getScriptEngine()
void setScriptEngine(String engine)
engine
- The new ScriptEngine valueString getNullBehavior()
String getNullBehaviorValue()
void setNullBehavior(String nb)
nb
- The new nullBehavior valuevoid setNullBehaviorValue(String nbv)
nbv
- The new nullBehaviorValue valueString getNullDefinition()
String getNullDefinitionValue()
void setNullDefinition(String nb)
nb
- The new nullBehavior valuevoid setNullDefinitionValue(String nbv)
nbv
- The new nullBehaviorValue valueboolean getEnabled()
void setEnabled(boolean enabled)
Object getClone() throws Exception
Exception
boolean getLogEnabled()
void setLogEnabled(boolean enabled)
void setUserComment(String comment)
String getUserComment()
Map getSubstitutionMap()
void setSubstitutionMap(Map map)
boolean willFlatten(List excludedNS)
boolean flatten(List excludedNS) throws Exception
excludedNS
- List of namespaces to exclude from flattening
Exception
List getReferences(List list)
list
- If non-null, the object must use the provided list rather than creating its ownList search(String text, int options, int sizelimit)
text
- The search textoptions
- Search options (oneLevel=1, exactCase=2, regExp=4, paramName=8)sizelimit
- Max number of hits returnedList search(String text, int options, int sizelimit, List results)
text
- The search textoptions
- Search options (oneLevel=1, exactCase=2, regExp=4, paramName=8)sizelimit
- Max number of hits returnedresults
- A list of results.BaseConfiguration getChild(Object name)
name
- The name of the configuration objectvoid setChild(Object name, BaseConfiguration config)
name
- The nameconfig
- The configuration objectString nameForChild(BaseConfiguration config)
config
- The configuration object
List getChildNames()
String getPath()
BaseConfiguration getChildForPath(String path) throws NameNotFoundException
path
- The complete path to an object (as returned by getPath())
Exception
- NameNotFoundException
NameNotFoundException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |