XMLBoolRef is a type converter for boolean data with write access. More...

Public Member Functions | |
| XMLBoolRef (XMLNode node, final String attrName) | |
| XMLBoolRef (XMLNode node, final String attrName, boolean def) | |
| boolean | boolValue () |
| void | assign (boolean value) |
| Set boolean value in referenced node. | |
Protected Attributes | |
| final XMLNode | _node |
| final String | _attrName |
XMLBoolRef is a type converter for boolean data with write access.
Definition at line 45 of file XMLBoolRef.java.
| de.mfuchs.xmlstorage.XMLBoolRef.XMLBoolRef | ( | XMLNode | node, |
| final String | attrName | ||
| ) |
Definition at line 47 of file XMLBoolRef.java.
{
this(node, attrName, false);
}
| de.mfuchs.xmlstorage.XMLBoolRef.XMLBoolRef | ( | XMLNode | node, |
| final String | attrName, | ||
| boolean | def | ||
| ) |
Definition at line 52 of file XMLBoolRef.java.
References de.mfuchs.xmlstorage.XMLBoolRef._attrName, de.mfuchs.xmlstorage.XMLBoolRef._node, de.mfuchs.xmlstorage.XMLBoolRef.assign(), and de.mfuchs.xmlstorage.XMLNode.get().
{
_node = node;
_attrName = attrName;
if (node != null)
if (node.get(attrName).length() == 0)
assign(def);
}

| void de.mfuchs.xmlstorage.XMLBoolRef.assign | ( | boolean | value ) |
Set boolean value in referenced node.
| value |
Definition at line 77 of file XMLBoolRef.java.
References de.mfuchs.xmlstorage.XMLBoolRef._attrName, de.mfuchs.xmlstorage.XMLBoolRef._node, and de.mfuchs.xmlstorage.XMLNode.put().
Referenced by de.mfuchs.xmlstorage.XMLBoolRef.XMLBoolRef().

| boolean de.mfuchs.xmlstorage.XMLBoolRef.boolValue | ( | ) |
Definition at line 65 of file XMLBoolRef.java.
References de.mfuchs.xmlstorage.XMLBoolRef._attrName, de.mfuchs.xmlstorage.XMLBoolRef._node, and de.mfuchs.xmlstorage.XMLNode.get().
{
if (_node != null)
return Boolean.valueOf(_node.get(_attrName)).booleanValue();
else
return false;
}

final String de.mfuchs.xmlstorage.XMLBoolRef._attrName [protected] |
Definition at line 84 of file XMLBoolRef.java.
Referenced by de.mfuchs.xmlstorage.XMLBoolRef.assign(), de.mfuchs.xmlstorage.XMLBoolRef.boolValue(), and de.mfuchs.xmlstorage.XMLBoolRef.XMLBoolRef().
final XMLNode de.mfuchs.xmlstorage.XMLBoolRef._node [protected] |
Definition at line 83 of file XMLBoolRef.java.
Referenced by de.mfuchs.xmlstorage.XMLBoolRef.assign(), de.mfuchs.xmlstorage.XMLBoolRef.boolValue(), and de.mfuchs.xmlstorage.XMLBoolRef.XMLBoolRef().
1.7.2