public class BaseType extends Object implements Serializable
| Modifier and Type | Field and Description |
|---|---|
protected Factory |
factory |
protected SimpleDateFormat |
simpleDateFormat |
protected Attr |
xmlAttr |
protected Element |
xmlElement |
| Constructor and Description |
|---|
BaseType() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
getElementBooleanValue(String elementName) |
byte |
getElementByteValue(String elementName) |
Date |
getElementDateValue(String elementName)
Get the value for the input element
|
double |
getElementDoubleValue(String elementName) |
float |
getElementFloatValue(String elementName) |
int |
getElementIntegerValue(String elementName) |
long |
getElementLongValue(String elementName) |
String |
getElementName()
Return the node name for this element
|
short |
getElementShortValue(String elementName) |
String |
getElementValue()
Get the text value for this element
|
String |
getElementValue(String elementName)
Get the value for the input element
|
String |
getElementValue(String property,
int index)
Get the element with the specifed name and at the specified location
|
BaseType |
getElementValue(String property,
String className)
Get the value for the input element
|
Object |
getElementValue(String property,
String className,
int index)
Get the value for the input element
|
Attr |
getXMLAttribute()
Return the XML attribute that corresponds to this bean
|
Element |
getXMLElement()
Return the XML element that corresponds to this bean
|
boolean |
removeElement(String elementName)
Remove the element with the input elementName from the current node
|
void |
setElementValue(String elementName,
BaseType baseType)
Create an element and set it to the specified value
|
void |
setElementValue(String elementName,
boolean value)
Create an element and set it to the specified value
|
void |
setElementValue(String elementName,
byte value)
Create an element and set it to the specified value
|
void |
setElementValue(String elementName,
Date value)
Create an element and set it to the specified value.
|
void |
setElementValue(String elementName,
double value)
Create an element and set it to the specified value
|
void |
setElementValue(String elementName,
float value)
Create an element and set it to the specified value
|
void |
setElementValue(String elementName,
int value)
Create an element and set it to the specified value
|
void |
setElementValue(String elementName,
long value)
Create an element and set it to the specified value
|
void |
setElementValue(String elementName,
short value)
Create an element and set it to the specified value
|
void |
setElementValue(String elementName,
String elementValue)
Create the element and the text node if it does not exist.
|
protected void |
setFactory(Factory factory)
Remember the factory that creates this XML element or attribute
|
protected void |
setXMLAttribute(Attr xmlAttr)
Remember the XML attribute that corresponds to this bean
|
protected void |
setXMLElement(Element element)
Remember the XML element that corresponds to this bean
|
int |
sizeOfElement(String name)
Return the number of children with this name
|
void |
updateElementValue(boolean value) |
void |
updateElementValue(byte value) |
void |
updateElementValue(Date value) |
void |
updateElementValue(double value) |
void |
updateElementValue(float value) |
void |
updateElementValue(int value) |
void |
updateElementValue(long value) |
void |
updateElementValue(short value) |
void |
updateElementValue(String value)
Update the text node for this element
|
protected Factory factory
protected Element xmlElement
protected Attr xmlAttr
protected SimpleDateFormat simpleDateFormat
protected void setFactory(Factory factory)
protected void setXMLElement(Element element)
public Element getXMLElement()
protected void setXMLAttribute(Attr xmlAttr)
public Attr getXMLAttribute()
public void setElementValue(String elementName, String elementValue)
elementName - - the name of the elementelementValue - - the value of the elementpublic void setElementValue(String elementName, boolean value)
public void setElementValue(String elementName, int value)
public void setElementValue(String elementName, float value)
public void setElementValue(String elementName, double value)
public void setElementValue(String elementName, long value)
public void setElementValue(String elementName, short value)
public void setElementValue(String elementName, byte value)
public void setElementValue(String elementName, Date value)
public void setElementValue(String elementName, BaseType baseType)
public String getElementValue()
public String getElementValue(String property, int index)
public String getElementValue(String elementName)
elementName - The name of the elementpublic boolean getElementBooleanValue(String elementName)
public int getElementIntegerValue(String elementName)
public float getElementFloatValue(String elementName)
public double getElementDoubleValue(String elementName)
public long getElementLongValue(String elementName)
public short getElementShortValue(String elementName)
public byte getElementByteValue(String elementName)
public Date getElementDateValue(String elementName)
elementName - The name of the elementpublic BaseType getElementValue(String property, String className)
className - - the name of the class corresponding to this element
Could be an inner class.public Object getElementValue(String property, String className, int index)
property - - the name of the elementclassName - - the name of the class corresponding to this element
Could be an inner classindex - - an index for collectionpublic void updateElementValue(String value)
public void updateElementValue(boolean value)
public void updateElementValue(int value)
public void updateElementValue(float value)
public void updateElementValue(double value)
public void updateElementValue(long value)
public void updateElementValue(short value)
public void updateElementValue(byte value)
public void updateElementValue(Date value)
public boolean removeElement(String elementName)
public int sizeOfElement(String name)
public String getElementName()
Copyright © 2017–2019 Eclipse Foundation. All rights reserved.