|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.ocd.blx.XMLProperties
This class wraps a java.util.Map and enables Map contents to be retrieved and Converted to XML
This Class can only except Integers, String, Longs, Floats, Doubles, Dates, and Booleans
Field Summary | |
static java.lang.String |
BEAN_CLASS_ATTR_NAME
|
static java.lang.String |
BOOLEAN_ATTR_TYPE
|
static int |
BOOLEAN_TYPE
|
static java.lang.String |
DATE_ATTR_TYPE
|
static int |
DATE_TYPE
|
static java.lang.String |
DOUBLE_ATTR_TYPE
|
static int |
DOUBLE_TYPE
|
static java.lang.String |
FLOAT_ATTR_TYPE
|
static int |
FLOAT_TYPE
|
static java.lang.String |
INT_ATTR_TYPE
|
static int |
INT_TYPE
|
static java.lang.String |
LONG_ATTR_TYPE
|
static int |
LONG_TYPE
|
static java.lang.String |
NAME_ATTR_NAME
|
static java.lang.String |
NULL_ATTR_TYPE
|
static int |
NULL_TYPE
|
static java.lang.String |
PROPERTIES_NODE_NAME
|
static java.lang.String |
PROPERTY_NODE_NAME
|
static java.lang.String |
STRING_ATTR_TYPE
|
static int |
STRING_TYPE
|
static java.lang.String |
TYPE_ATTR_NAME
|
static java.lang.String |
VALUE_ATTR_NAME
|
Constructor Summary | |
XMLProperties()
Create a new Properties Object |
|
XMLProperties(java.lang.Object pBean,
java.lang.String[] propNames)
Create a new Properties Object. |
Method Summary | |
java.lang.Object |
getBean()
Get the Bean this Property Object is listening on. |
java.lang.Object |
getProperty(java.lang.String pName)
Get Property |
boolean |
getPropertyBoolean(java.lang.String pName)
Get Property as boolean |
java.util.Date |
getPropertyDate(java.lang.String pName)
Get Property as Date |
double |
getPropertyDouble(java.lang.String pName)
Get Property as double |
float |
getPropertyFloat(java.lang.String pName)
Get Property as float |
int |
getPropertyInt(java.lang.String pName)
get Property as int |
long |
getPropertyLong(java.lang.String pName)
Get Property as long |
java.lang.String |
getPropertyString(java.lang.String pName)
Get Property as String |
int |
getPropertyType(java.lang.String pName)
Get the Type of the Property |
org.w3c.dom.Element |
getXMLElement()
Get the Data Node for this Component |
void |
setBean(java.lang.Object pBean,
java.lang.String[] pPropNames)
Set the Bean this Property Object is listening on. |
void |
setProperty(java.lang.String pName,
java.lang.Object pValue)
Set Property |
void |
setPropertyBoolean(java.lang.String pName,
boolean pValue)
Set Boolean Property |
void |
setPropertyDate(java.lang.String pName,
java.util.Date pValue)
Set Date Property |
void |
setPropertyDouble(java.lang.String pName,
double pValue)
Set double Property |
void |
setPropertyFloat(java.lang.String pName,
float pValue)
Set float Property |
void |
setPropertyInt(java.lang.String pName,
int pValue)
Set int Property |
void |
setPropertyLong(java.lang.String pName,
long pValue)
Set long Property |
void |
setPropertyString(java.lang.String pName,
java.lang.String pValue)
Set String Property |
void |
setXMLElement(org.w3c.dom.Element pElement)
Set the Node on this Component |
boolean |
xmlHasChanged()
Return true if this components state has changed in a way that Requires a new XML Node to be fetched |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int STRING_TYPE
public static final int INT_TYPE
public static final int LONG_TYPE
public static final int FLOAT_TYPE
public static final int DOUBLE_TYPE
public static final int DATE_TYPE
public static final int BOOLEAN_TYPE
public static final int NULL_TYPE
public static final java.lang.String STRING_ATTR_TYPE
public static final java.lang.String INT_ATTR_TYPE
public static final java.lang.String LONG_ATTR_TYPE
public static final java.lang.String FLOAT_ATTR_TYPE
public static final java.lang.String DOUBLE_ATTR_TYPE
public static final java.lang.String DATE_ATTR_TYPE
public static final java.lang.String BOOLEAN_ATTR_TYPE
public static final java.lang.String NULL_ATTR_TYPE
public static final java.lang.String PROPERTIES_NODE_NAME
public static final java.lang.String BEAN_CLASS_ATTR_NAME
public static final java.lang.String PROPERTY_NODE_NAME
public static final java.lang.String TYPE_ATTR_NAME
public static final java.lang.String NAME_ATTR_NAME
public static final java.lang.String VALUE_ATTR_NAME
Constructor Detail |
public XMLProperties()
public XMLProperties(java.lang.Object pBean, java.lang.String[] propNames)
pBean
- to store properties forpropNames
- names of Properties to store for this BeanMethod Detail |
public int getPropertyType(java.lang.String pName)
pName
- Name of Propertypublic java.lang.String getPropertyString(java.lang.String pName)
- public int getPropertyInt(java.lang.String pName)
public long getPropertyLong(java.lang.String pName)
public float getPropertyFloat(java.lang.String pName)
public double getPropertyDouble(java.lang.String pName)
public java.util.Date getPropertyDate(java.lang.String pName)
public boolean getPropertyBoolean(java.lang.String pName)
public java.lang.Object getProperty(java.lang.String pName)
public void setProperty(java.lang.String pName, java.lang.Object pValue)
public void setPropertyInt(java.lang.String pName, int pValue)
public void setPropertyLong(java.lang.String pName, long pValue)
public void setPropertyFloat(java.lang.String pName, float pValue)
public void setPropertyDouble(java.lang.String pName, double pValue)
public void setPropertyDate(java.lang.String pName, java.util.Date pValue)
public void setPropertyBoolean(java.lang.String pName, boolean pValue)
public void setPropertyString(java.lang.String pName, java.lang.String pValue)
public boolean xmlHasChanged()
public void setXMLElement(org.w3c.dom.Element pElement)
Node
- that contains this components settingspublic void setBean(java.lang.Object pBean, java.lang.String[] pPropNames)
pBean
- to listen for property changes or null to not listen for property changes on a BeanpPropNames
- names of Properties we should listen on or null for all propertiespublic java.lang.Object getBean()
public org.w3c.dom.Element getXMLElement()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |