public class XmlElement extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
XmlElement.XmlTextElement |
| Modifier and Type | Field and Description |
|---|---|
Map<String,String> |
attributes |
List<XmlElement> |
children |
String |
name |
XmlElement |
parent |
| Constructor and Description |
|---|
XmlElement(XmlElement parent,
String name,
Map<String,String> attributes) |
XmlElement(XmlElement parent,
String name,
Map<String,String> attributes,
List<XmlElement> children) |
| Modifier and Type | Method and Description |
|---|---|
void |
appendChild(XmlElement child) |
XmlElement |
attribute(String name,
String value) |
XmlElement |
child(XmlElement child) |
static XmlElement |
element(String name) |
XmlElement |
findChildForName(String name,
XmlElement _default) |
static XmlElement |
findChildForName(XmlElement element,
String name,
XmlElement _default) |
String |
getText() |
boolean |
hasNonTextChildren() |
int |
numChildrenWithName(String name) |
XmlElement |
text(String text) |
public XmlElement parent
public String name
public List<XmlElement> children
public XmlElement(XmlElement parent, String name, Map<String,String> attributes)
public XmlElement(XmlElement parent, String name, Map<String,String> attributes, List<XmlElement> children)
public void appendChild(XmlElement child)
public XmlElement findChildForName(String name, XmlElement _default)
public static XmlElement findChildForName(XmlElement element, String name, XmlElement _default)
public int numChildrenWithName(String name)
public String getText()
public boolean hasNonTextChildren()
public static XmlElement element(String name)
public XmlElement child(XmlElement child)
public XmlElement attribute(String name, String value)
public XmlElement text(String text)
Copyright © 2019. All rights reserved.