|
Java EE 5 SDK | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface PropertiesAccess
All MBeans that have Properties must extend this interface.
Properties are always Strings. Property names are required to be unique.
To specify properties when creating any type of AMXConfig
which
(the AMXConfig must extend PropertiesAccess), add them to the optional
Map when creating it:
final Map
optional = new HashMap (); optional.put( PropertiesAccess.PROPERTY_PREFIX + "prop1", prop1Value ); optional.put( PropertiesAccess.PROPERTY_PREFIX + "prop2", prop2Value ); ...
Field Summary | |
---|---|
static String |
PROPERTY_PREFIX
When a key is required for a property in a Map, its name must consist of this prefix plus the actual name. |
Method Summary | |
---|---|
void |
createProperty(String propertyName,
String propertyValue)
Create a new property. |
boolean |
existsProperty(String propertyName)
Return true if any properties exist with the specified name. |
Map<String,String> |
getProperties()
|
String[] |
getPropertyNames()
Get the names of all properties. |
String |
getPropertyValue(String propertyName)
Get the value of a property. |
void |
removeProperty(String propertyName)
Remove a property with the specified name. |
void |
setPropertyValue(String propertyName,
String propertyValue)
Set the value of a property. |
Field Detail |
---|
static final String PROPERTY_PREFIX
Method Detail |
---|
String[] getPropertyNames()
Map<String,String> getProperties()
String getPropertyValue(String propertyName)
propertyName
- the name of the propertyvoid setPropertyValue(String propertyName, String propertyValue)
propertyName
- the name of the propertypropertyValue
- the value of the propertyboolean existsProperty(String propertyName)
propertyName
- the name of the propertyvoid createProperty(String propertyName, String propertyValue)
propertyName
- the name of the propertypropertyValue
- the value of the propertyvoid removeProperty(String propertyName)
propertyName
- the name of the property
|
Java EE 5 SDK | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright 2006 Sun Microsystems, Inc. All rights reserved.