|
eXchaNGeR | |||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
The interface that represents an XML element in the eXchaNGeR
application. Use the factory method creatElement()
to
create a new element.
Method Summary | |
void |
add(XElement child)
Adds a child element to this element. |
XDocument |
document()
Returns the document for this element. |
String |
getAttribute(String name)
Returns the value of the attribute with the name. |
String[][] |
getAttributes()
Returns a 2 dimensional array of attributes. |
XElement |
getElement(String name)
Returns the first element for the given name. |
XElement[] |
getElements()
Returns all the child elements of this element. |
XElement[] |
getElements(String name)
Returns all the child elements with a given name for this element. |
String |
getName()
Returns the (local)name for this element. |
XElementType |
getType()
Returns the type of this element. |
String |
getUniversalName()
Returns the universal name for this element. |
String |
getValue()
Gets the text value of this element. |
XUrl |
getXUrl()
Returns the eXchaNGeR url of this element, This url consists of the document URL and the unique XPath expression to this element. |
boolean |
isRoot()
A check wether this element is the root element. |
String |
namespace()
Returns the namespace for this element. |
XElement |
parent()
Returns the parent of this element. |
String |
path()
Returns an XPath result, uniquely identifying this element. |
void |
putAttribute(String name,
String value)
Adds an attribute to the list of attributes or overwrites the attribute if the attribute name already exists. |
void |
remove(XElement child)
Removes a child element from this element. |
void |
setValue(String value)
Sets the text value of this element. |
Method Detail |
public void putAttribute(String name, String value)
name
- the name of the attribute.value
- the value of the attribute.public String[][] getAttributes()
public String getAttribute(String name)
name
- the name of the attribute.public XElement getElement(String name)
name
- the name of the element.public XElement[] getElements()
public XElement[] getElements(String name)
name
- the name of the element.public String namespace()
public String getUniversalName()
public String getName()
public boolean isRoot()
public XElement parent()
public String getValue()
public void setValue(String value)
value
- the value of this element.public void add(XElement child)
child
- the child element.public void remove(XElement child)
child
- the child element.public String path()
public XDocument document()
public XElementType getType()
public XUrl getXUrl()
|
eXchaNGeR | |||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |