|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.ojb.broker.metadata.DescriptorBase
class DescriptorBase
base class for all Descriptors. It is used to implement the AttributeContainer interface which provides mechanics for user defined attributes.
Field Summary | |
---|---|
private Map |
attributeMap
holds user defined attributes |
(package private) static long |
serialVersionUID
|
Constructor Summary | |
---|---|
DescriptorBase()
Constructor for DescriptorBase. |
Method Summary | |
---|---|
void |
addAttribute(String attributeName,
String attributeValue)
Store the specified attribute and it's value. |
String |
getAttribute(String attributeName)
Get the value of an attribute |
String |
getAttribute(String attributeName,
String defaultValue)
Get the value of an attribute |
String[] |
getAttributeNames()
Returns an array of the names of all atributes of this descriptor. |
Map |
getAttributes()
Returns the attribute map (name, value) of this descriptor. |
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
static final long serialVersionUID
private Map attributeMap
Constructor Detail |
---|
public DescriptorBase()
Method Detail |
---|
public void addAttribute(String attributeName, String attributeValue)
AttributeContainer
addAttribute
in interface AttributeContainer
attributeName
- the name of the attribute to retrieveattributeValue
- the attribute's valueAttributeContainer.addAttribute(String, String)
public String getAttribute(String attributeName, String defaultValue)
AttributeContainer
getAttribute
in interface AttributeContainer
attributeName
- the attribute to retrievedefaultValue
- the value to return if the attribute is not present
AttributeContainer.getAttribute(String, String)
public String getAttribute(String attributeName)
AttributeContainer
getAttribute
in interface AttributeContainer
attributeName
- the attribute to retrieve
AttributeContainer.getAttribute(String)
public Map getAttributes()
public String[] getAttributeNames()
null
)public String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |