All Packages Class Hierarchy This Package Previous Next Index

Class org.jfouffa.parser.html.AttributeList

java.lang.Object
   |
   +----org.jfouffa.parser.html.AttributeList

public class AttributeList
extends Object
This class represents a list of attributes.

Typical usage :

  for (int i = 0; i < myAttributeList.size(); i++) {
    Attribute attr = myAttributeList.getAttribute(i);
    System.out.println(attr);
  }
 


Constructor index

 o AttributeList()
Create a new AttributeList

Method index

 o getAttribute(int)
Gets the attribute at item index.
 o getAttribute(String, boolean)
Gets the attribute with a specified name
 o size()
Returns the number of attributes
 o toString()
Returns a string representation of the object.

Constructors

 o AttributeList
 public AttributeList()
Create a new AttributeList

Methods

 o size
 public int size()
Returns the number of attributes

 o getAttribute
 public Attribute getAttribute(int item)
Gets the attribute at item index.

Parameters:
item - the index of the atribute
 o getAttribute
 public Attribute getAttribute(String name,
                               boolean sensitive)
Gets the attribute with a specified name

Parameters:
name - the name of the attribute
sensitive - is the attribute is case-sensitive or not ?
Returns:
the attribute or null
 o toString
 public String toString()
Returns a string representation of the object.

Overrides:
toString in class Object