public abstract class HtmlElement extends Object implements Element, Comparable<HtmlElement>
HTMLElementFactory.| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(HtmlElement o)
Compares this object with the specified object for order.
|
boolean |
equals(Object obj) |
String |
getAttribute(String name)
Gets value of attribute by name
|
Attributes |
getAttributes()
Gets the list of attributes of the element
|
BigInteger |
getId()
Gets the id of the element (not the attribute id but the id as assigned by pasrser)
|
String |
getName()
Gets the name of the element (not the attribute name but the name of the tag)
|
HtmlElement |
getParent()
Gets the parent of the element
|
Position |
getPosition()
Gets the position of the element
|
String |
getSource()
Gets the source of the element
|
String |
getTextContent()
Gets the text content of the element
|
int |
hashCode() |
void |
setPosition(Position position)
Sets the position of the element
|
void |
setSource(String source)
Sets the source of the element
|
void |
setTextContent(String textContent)
Sets the text content of the element
|
String |
toString() |
public BigInteger getId()
public String getName()
public HtmlElement getParent()
public Attributes getAttributes()
public String getAttribute(String name)
name - attribute which value should be returnedpublic void setSource(String source)
source - source of the elementpublic String getSource()
public void setPosition(Position position)
position - position of the elementpublic Position getPosition()
public String getTextContent()
public void setTextContent(String textContent)
textContent - text content of the elementpublic int compareTo(HtmlElement o)
compareTo in interface Comparable<HtmlElement>o - HtmlElement to compare this withCopyright © 2012. All Rights Reserved.