|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectedu.harvard.hul.ois.jhove.module.html.HtmlAttributeDesc
public class HtmlAttributeDesc
Class representing an abstract attribute of an HTML element.
| Field Summary | |
|---|---|
static int |
CONREF
Permitted values for _kind |
static int |
CURRENT
Permitted values for _kind |
static int |
IMPLIED
Permitted values for _kind |
static int |
OTHER
Permitted values for _kind |
static int |
REQUIRED
Permitted values for _kind |
| Constructor Summary | |
|---|---|
HtmlAttributeDesc(java.lang.String name)
Constructor for an attribute that can take any value, with kind defaulting to IMPLIED. |
|
HtmlAttributeDesc(java.lang.String name,
java.lang.String[] permittedValues,
int kind)
Constructor. |
|
| Method Summary | |
|---|---|
java.lang.String |
getName()
Returns the attribute's name. |
boolean |
isRequired()
Return true if the attribute is required. |
boolean |
nameMatches(java.lang.String name)
Returns true if this tag's name
matches the parameter. |
boolean |
valueOK(java.lang.String name,
java.lang.String value)
Returns true if the parameter is a permissible
value for the attribute. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int REQUIRED
public static final int CURRENT
public static final int CONREF
public static final int IMPLIED
public static final int OTHER
| Constructor Detail |
|---|
public HtmlAttributeDesc(java.lang.String name,
java.lang.String[] permittedValues,
int kind)
name - The name of the attribute. Must be lower case.permittedValues - Specific values allowed for the parameter. If
null, then any CDATA value is allowed.kind - The kind of parameter. Must be REQUIRED, CURRENT,
CONREF, or IMPLIED.public HtmlAttributeDesc(java.lang.String name)
| Method Detail |
|---|
public java.lang.String getName()
public boolean nameMatches(java.lang.String name)
true if this tag's name
matches the parameter.
public boolean valueOK(java.lang.String name,
java.lang.String value)
true if the parameter is a permissible
value for the attribute.
public boolean isRequired()
true if the attribute is required.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||