java.lang.Object | |
↳ | org.jsoup.nodes.Attribute |
A single key + value attribute. Keys are trimmed and normalised to lower-case.
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Create a new attribute from unencoded (raw) key and value.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Create a new Attribute from an unencoded key and a HMTL attribute encoded value.
| |||||||||||
Get the attribute key.
| |||||||||||
Get the attribute value.
| |||||||||||
Get the HTML representation of this attribute; e.g.
| |||||||||||
Set the attribute key.
| |||||||||||
Set the attribute value.
| |||||||||||
Get the string representation of this attribute, implemented as
html() . |
Protected Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
| |||||||||||
From interface
java.util.Map.Entry
|
Create a new attribute from unencoded (raw) key and value.
key | attribute key |
---|---|
value | attribute value |
Create a new Attribute from an unencoded key and a HMTL attribute encoded value.
unencodedKey | assumes the key is not encoded, as can be only run of simple \w chars. |
---|---|
encodedValue | HTML attribute encoded value |
Get the HTML representation of this attribute; e.g. href="index.html"
.
Set the attribute key. Gets normalised as per the constructor method.
key | the new key; must not be null |
---|
Set the attribute value.
value | the new attribute value; must not be null |
---|
Get the string representation of this attribute, implemented as html()
.