Class JsoupAttributes
- java.lang.Object
-
- com.itextpdf.styledxmlparser.node.impl.jsoup.node.JsoupAttributes
-
- All Implemented Interfaces:
IAttributes,java.lang.Iterable<IAttribute>
public class JsoupAttributes extends java.lang.Object implements IAttributes
Implementation of theIAttributesinterface; wrapper for the JSoupAttributesclass.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private static classJsoupAttributes.AttributeIteratorIterator to loop overIAttributeelements.
-
Field Summary
Fields Modifier and Type Field Description private AttributesattributesThe JSoupAttributesinstance.
-
Constructor Summary
Constructors Constructor Description JsoupAttributes(Attributes attributes)Creates a newJsoupAttributesinstance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetAttribute(java.lang.String key)Gets the value of an attribute, given a key.java.util.Iterator<IAttribute>iterator()voidsetAttribute(java.lang.String key, java.lang.String value)Adds a key and a value of an attributes.intsize()Returns the number of attributes.
-
-
-
Field Detail
-
attributes
private Attributes attributes
The JSoupAttributesinstance.
-
-
Constructor Detail
-
JsoupAttributes
public JsoupAttributes(Attributes attributes)
Creates a newJsoupAttributesinstance.- Parameters:
attributes- the attributes
-
-
Method Detail
-
getAttribute
public java.lang.String getAttribute(java.lang.String key)
Description copied from interface:IAttributesGets the value of an attribute, given a key.- Specified by:
getAttributein interfaceIAttributes- Parameters:
key- the key- Returns:
- the attribute
-
setAttribute
public void setAttribute(java.lang.String key, java.lang.String value)Description copied from interface:IAttributesAdds a key and a value of an attributes.- Specified by:
setAttributein interfaceIAttributes- Parameters:
key- the keyvalue- the value
-
size
public int size()
Description copied from interface:IAttributesReturns the number of attributes.- Specified by:
sizein interfaceIAttributes- Returns:
- the number of attributes
-
iterator
public java.util.Iterator<IAttribute> iterator()
- Specified by:
iteratorin interfacejava.lang.Iterable<IAttribute>
-
-