com.quiotix.html.parser
Class HtmlDocument.Attribute

java.lang.Object
  extended by com.quiotix.html.parser.HtmlDocument.Attribute
All Implemented Interfaces:
Sized
Enclosing class:
HtmlDocument

public static class HtmlDocument.Attribute
extends Object
implements Sized

A Tag Attribute.


Field Summary
 boolean hasValue
          Whether the Attribute has a value.
 String name
          The name of this Attribute.
 String value
          The value of this Attribute, including any surrounding quotes.
 
Constructor Summary
HtmlDocument.Attribute(String n)
          Constructor.
HtmlDocument.Attribute(String n, String v)
          Constructor.
 
Method Summary
 int getLength()
          Whether quotes are included is dependant upon the source document.
 String getValue()
           
 void setValue(String v)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

name

public String name
The name of this Attribute.


value

public String value
The value of this Attribute, including any surrounding quotes.


hasValue

public boolean hasValue
Whether the Attribute has a value.

Constructor Detail

HtmlDocument.Attribute

public HtmlDocument.Attribute(String n)
Constructor.


HtmlDocument.Attribute

public HtmlDocument.Attribute(String n,
                              String v)
Constructor.

Method Detail

getLength

public int getLength()
Whether quotes are included is dependant upon the source document.

Specified by:
getLength in interface Sized
Returns:
the number of characters
See Also:
Sized.getLength()

toString

public String toString()
Overrides:
toString in class Object

getValue

public String getValue()
Returns:
the value with quotes removed

setValue

public void setValue(String v)
Parameters:
v - the value to set, may be null


Copyright © 1999-2011 Quiotix. All Rights Reserved.