com.pcbsys.nirvana.nAdminAPI.nConfigEntry Class Reference

This class contains all the information about a configuration parameter, including the name, the current value, a description of it and a warning or constrant string. More...

Inherits Observable, and SortedObject.

Public Member Functions

boolean equals (long aLong)
 Compares this object with the passed object. More...
 
String getDescription ()
 Returns a string which contains the description for this parameter and typically what it is used for. More...
 
long getMax ()
 Retrieves the maximum range value of the configuration parameter. More...
 
long getMin ()
 Retrieves the minimum range value of the configuration parameter. More...
 
String getName ()
 Retrieves the name of the configuration parameter. More...
 
fConfigObject getParent ()
 
int getType ()
 Retrieves the type of the configuration parameter. More...
 
String getValue ()
 Retrieves the current value of this parameter. More...
 
String getWarning ()
 Returns a String which contains information about the limits/bounds of this parameter and what would be nominal values. More...
 
boolean isMatch (Object item)
 Compares this object with the passed object. More...
 
boolean isReadOnly ()
 Returns whether the specific entry is read only and therefore cannot be modifed. More...
 
boolean lessThan (long aLong)
 Compares this object with the passed object. More...
 
boolean lessThan (Object item)
 Compares this object with the passed object. More...
 
void setValue (String value) throws nAdminIllegalArgumentException, nConfigurationException
 Sets the parameters value to the new value passed. More...
 
void validateNewValue (String value) throws nAdminIllegalArgumentException
 Validates a proposed new value for the config entry. More...
 

Detailed Description

This class contains all the information about a configuration parameter, including the name, the current value, a description of it and a warning or constrant string.

This class extends java.util.Observable since the value can be changed asynchronously from the realm. When this happens any observer is notified of the changed value, passed as a String

Member Function Documentation

boolean com.pcbsys.nirvana.nAdminAPI.nConfigEntry.equals ( long  aLong)

Compares this object with the passed object.

For internal use only

Parameters
aLonglong to compare against
Returns
True if this object is equal to the passed long
String com.pcbsys.nirvana.nAdminAPI.nConfigEntry.getDescription ( )

Returns a string which contains the description for this parameter and typically what it is used for.

Returns
a description for this config entry as a String
long com.pcbsys.nirvana.nAdminAPI.nConfigEntry.getMax ( )

Retrieves the maximum range value of the configuration parameter.

Returns
maximum range value of config object
long com.pcbsys.nirvana.nAdminAPI.nConfigEntry.getMin ( )

Retrieves the minimum range value of the configuration parameter.

Returns
minumum range value of config object
String com.pcbsys.nirvana.nAdminAPI.nConfigEntry.getName ( )

Retrieves the name of the configuration parameter.

Returns
the name of this configuration parameter as a String
fConfigObject com.pcbsys.nirvana.nAdminAPI.nConfigEntry.getParent ( )
Returns
The parent object that contains this entry;
int com.pcbsys.nirvana.nAdminAPI.nConfigEntry.getType ( )

Retrieves the type of the configuration parameter.

Returns
type of config object
String com.pcbsys.nirvana.nAdminAPI.nConfigEntry.getValue ( )

Retrieves the current value of this parameter.

The parameter is always a string though it could represent longs/ints/booleans etc

Returns
the current value of this configuration parameter as a String
String com.pcbsys.nirvana.nAdminAPI.nConfigEntry.getWarning ( )

Returns a String which contains information about the limits/bounds of this parameter and what would be nominal values.

Returns
a warning for this config entry as a String
boolean com.pcbsys.nirvana.nAdminAPI.nConfigEntry.isMatch ( Object  item)

Compares this object with the passed object.

For internal use only

Parameters
itemObject to compare against
Returns
True if this object is equal to the passed object
boolean com.pcbsys.nirvana.nAdminAPI.nConfigEntry.isReadOnly ( )

Returns whether the specific entry is read only and therefore cannot be modifed.

Returns
if the entry is read only
boolean com.pcbsys.nirvana.nAdminAPI.nConfigEntry.lessThan ( long  aLong)

Compares this object with the passed object.

For internal use only

Parameters
aLonglong to compare against
Returns
True if this object is less than the passed long
boolean com.pcbsys.nirvana.nAdminAPI.nConfigEntry.lessThan ( Object  item)

Compares this object with the passed object.

For internal use only

Parameters
itemObject to compare against
Returns
True if this object is less than the passed object
void com.pcbsys.nirvana.nAdminAPI.nConfigEntry.setValue ( String  value) throws nAdminIllegalArgumentException, nConfigurationException

Sets the parameters value to the new value passed.

This value is nit committed to the realm until the nRealmNode.commitConfig(nConfigGroup) is called.

Parameters
valueThe new value to set this parameter to as a String
Exceptions
nAdminIllegalArgumentExceptionthrown if value is null, not the correct type, or not within a specific range
See Also
nRealmNode
nConfigGroup
void com.pcbsys.nirvana.nAdminAPI.nConfigEntry.validateNewValue ( String  value) throws nAdminIllegalArgumentException

Validates a proposed new value for the config entry.

Parameters
valuea string object specifying the value to be validated
Exceptions
nAdminIllegalArgumentExceptionthrown if not the correct type, or not within a specific range