com.badlogic.gdx.utils
Class Xml.Element
java.lang.Object
com.badlogic.gdx.utils.Xml.Element
- Enclosing class:
- Xml
public static class Xml.Element
- extends java.lang.Object
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Xml.Element
public Xml.Element(java.lang.String name)
getName
public java.lang.String getName()
getAttribute
public java.lang.String getAttribute(java.lang.String name)
setAttribute
public void setAttribute(java.lang.String name,
java.lang.String value)
getChildCount
public int getChildCount()
getChild
public Xml.Element getChild(int i)
addChild
public void addChild(Xml.Element element)
getText
public java.lang.String getText()
setText
public void setText(java.lang.String text)
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object
toString
public java.lang.String toString(java.lang.String indent)
getChildByName
public Xml.Element getChildByName(java.lang.String name)
- Parameters:
name
- the name of the child Xml.Element
- Returns:
- the first child having the given name or null, does not recurse
getChildByNameRecursive
public Xml.Element getChildByNameRecursive(java.lang.String name)
- Parameters:
name
- the name of the child Xml.Element
- Returns:
- the first child having the given name or null, recurses
getChildrenByName
public Array<Xml.Element> getChildrenByName(java.lang.String name)
- Parameters:
name
- the name of the children
- Returns:
- the children with the given name or an empty
Array
getFloatAttribute
public float getFloatAttribute(java.lang.String name)
- Returns the attribute as a float.
- Parameters:
name
- the name of the attribute
- Returns:
- the attribute
getIntAttribute
public int getIntAttribute(java.lang.String name)
- Returns the attribute as an int.
- Parameters:
name
- the name of the attribute
- Returns:
- the attribute
getBooleanAttribute
public boolean getBooleanAttribute(java.lang.String name)
- Returns the attribute as a boolean.
- Parameters:
name
- the name of the attribute
- Returns:
- the attribute
Copyright 2010 Mario Zechner (contact@badlogicgames.com), Nathan Sweet (admin@esotericsoftware.com)