|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.gcapmedia.dab.epg.binary.Element
public class Element
Element binary encoding
Constructor Summary | |
---|---|
Element(ElementTag tag)
|
Method Summary | |
---|---|
void |
addAttribute(Attribute attribute)
Add an attribute to this element |
void |
addChild(Element child)
Add a child to this element |
boolean |
equals(java.lang.Object obj)
|
static Element |
fromBytes(byte[] bytes)
Parse an object from its byte array representation |
static Element |
fromBytes(byte[] bytes,
TokenTable tokens)
Parse an object from its byte array representation |
Attribute |
getAttribute(AttributeTag tag)
Returns a specific attribute |
java.util.Collection<Attribute> |
getAttributes()
|
byte[] |
getBytes()
|
CData |
getCData()
|
java.util.Collection<Element> |
getChildren()
|
java.util.Collection<Element> |
getChildren(ElementTag tag)
Returns child elements of the specified type |
int |
getLength()
|
ElementTag |
getTag()
|
boolean |
hasAttribute(AttributeTag tag)
Returns whether a specific attribute is defined for this element |
boolean |
hasChildren(ElementTag tag)
Returns whether any elements of the specified type are children to this element |
void |
setCData(CData cdata)
Set this elements CDATA |
void |
setTokenTable(TokenTable tokens)
|
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Element(ElementTag tag)
tag
- Method Detail |
---|
public ElementTag getTag()
public void setTokenTable(TokenTable tokens)
public void addAttribute(Attribute attribute)
attribute
- Attribute to addpublic java.util.Collection<Attribute> getAttributes()
public Attribute getAttribute(AttributeTag tag)
tag
- Tag of attribute to retrieve
public boolean hasAttribute(AttributeTag tag)
tag
- Tag of attribute to test for
public void addChild(Element child)
child
- Child to addpublic java.util.Collection<Element> getChildren()
public java.util.Collection<Element> getChildren(ElementTag tag)
tag
- Element tag to return
public boolean hasChildren(ElementTag tag)
tag
- Element tag to test for
public void setCData(CData cdata)
cdata
- CDATA to setpublic CData getCData()
public byte[] getBytes()
getBytes
in interface Encodable
Encodable.getBytes()
public int getLength()
getLength
in interface Encodable
Encodable.getLength()
public static Element fromBytes(byte[] bytes)
bytes
- Byte array representationpublic static Element fromBytes(byte[] bytes, TokenTable tokens)
bytes
- Byte array representationpublic boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
Object.equals(java.lang.Object)
public java.lang.String toString()
toString
in class java.lang.Object
Object.toString()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |