|
jPOS 1.6.1 API Documentation | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.jpos.core.SubConfiguration
public class SubConfiguration
SubConfiguration objects lets childs objects access attributes in its parent object with a given prefix, for example "child.". Child objects can access properties with their prefix removed.
| Constructor Summary | |
|---|---|
SubConfiguration()
Creates a new empty SubConfiguration object |
|
SubConfiguration(Configuration cfg,
java.lang.String prefix)
Creates a new SubConfiguration from its parent's Configuration and the a given prefix. |
|
| Method Summary | |
|---|---|
java.lang.String |
get(java.lang.String propertyName)
|
java.lang.String |
get(java.lang.String propertyName,
java.lang.String defaultValue)
|
java.lang.String[] |
getAll(java.lang.String propertyName)
|
boolean |
getBoolean(java.lang.String propertyName)
|
boolean |
getBoolean(java.lang.String propertyName,
boolean defaultValue)
|
boolean[] |
getBooleans(java.lang.String propertyName)
|
double |
getDouble(java.lang.String propertyName)
|
double |
getDouble(java.lang.String propertyName,
double defaultValue)
|
double[] |
getDoubles(java.lang.String propertyName)
|
int |
getInt(java.lang.String propertyName)
|
int |
getInt(java.lang.String propertyName,
int defaultValue)
|
int[] |
getInts(java.lang.String propertyName)
|
long |
getLong(java.lang.String propertyName)
|
long |
getLong(java.lang.String propertyName,
long defaultValue)
|
long[] |
getLongs(java.lang.String propertyName)
|
java.lang.Object |
getObject(java.lang.String propertyName)
Creates a new object, it takes the class from the value of the property propertyName |
void |
put(java.lang.String name,
java.lang.Object value)
|
void |
setConfiguration(Configuration newCfg)
Sets the container configuration. |
void |
setPrefix(java.lang.String newPrefix)
Sets the prefix that identifies the parameters of the child object inside the parent configuration. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SubConfiguration()
public SubConfiguration(Configuration cfg,
java.lang.String prefix)
prefix.
cfg - Parent's Configurationprefix - prefix identifying child parameters.| Method Detail |
|---|
public void setConfiguration(Configuration newCfg)
newCfg - New container configuration.public void setPrefix(java.lang.String newPrefix)
newPrefix - New prefixpublic java.lang.String get(java.lang.String propertyName)
get in interface Configurationpublic java.lang.String[] getAll(java.lang.String propertyName)
getAll in interface ConfigurationpropertyName - ditto
public int[] getInts(java.lang.String propertyName)
getInts in interface Configurationpublic long[] getLongs(java.lang.String propertyName)
getLongs in interface Configurationpublic double[] getDoubles(java.lang.String propertyName)
getDoubles in interface Configurationpublic boolean[] getBooleans(java.lang.String propertyName)
getBooleans in interface Configuration
public java.lang.String get(java.lang.String propertyName,
java.lang.String defaultValue)
get in interface Configurationpublic boolean getBoolean(java.lang.String propertyName)
getBoolean in interface Configuration
public boolean getBoolean(java.lang.String propertyName,
boolean defaultValue)
getBoolean in interface Configurationpublic double getDouble(java.lang.String propertyName)
getDouble in interface Configuration
public double getDouble(java.lang.String propertyName,
double defaultValue)
getDouble in interface Configurationpublic long getLong(java.lang.String propertyName)
getLong in interface Configuration
public long getLong(java.lang.String propertyName,
long defaultValue)
getLong in interface Configurationpublic int getInt(java.lang.String propertyName)
getInt in interface Configuration
public int getInt(java.lang.String propertyName,
int defaultValue)
getInt in interface Configuration
public void put(java.lang.String name,
java.lang.Object value)
put in interface Configurationname - the Property namevalue - typically a String, but could be a String[] too
public java.lang.Object getObject(java.lang.String propertyName)
throws ConfigurationException
propertyName
propertyName - Property whose value is the class name of
the object being created.
ConfigurationException
|
jPOS.org | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||