public abstract class HtmlDocDesc extends Object
Modifier and Type | Field and Description |
---|---|
protected HtmlTagDesc |
bodyElement
A representation of the BODY element.
|
protected static HashMap |
commonTags
Generic list of supported tags.
|
protected HtmlTagDesc |
framesetElement
A representation of the FRAMESET element.
|
protected HtmlTagDesc |
headElement
A representation of the HEAD element.
|
protected static String[] |
headings
Header tags, which are invariant for all HTML versions.
|
protected HtmlTagDesc |
htmlElement
A representation of the HTML element.
|
protected Map |
supportedElements
List of supported tags for this version of HTML.
|
Constructor and Description |
---|
HtmlDocDesc()
Consructor.
|
Modifier and Type | Method and Description |
---|---|
protected static void |
addRequiredAttribute(List atts,
String name)
Adds an attribute to a List, with unrestricted values and
type REQUIRED.
|
protected static void |
addSelfAttribute(List atts,
String name)
Adds an attribute to a List, with the only permitted value being
the name of the attribute.
|
protected static void |
addSimpleAttribute(List atts,
String name)
Adds an attribute to a List, with unrestricted values and
type IMPLIED.
|
protected static void |
addStringsToList(String[] names,
List lst)
Adds all the Strings in an array to the end of a List.
|
HtmlMetadata |
getMetadata()
Returns the metadata for this document.
|
protected void |
init()
Initialization called by subclass constructors after supportedElements
has been assigned.
|
protected void |
pushElementStack(JHOpenTag tag)
Pushes an element onto the element stack.
|
protected static void |
removeStringsFromList(List lst,
String[] strs)
Removes excluded strings from a List.
|
boolean |
validate(List elements,
RepInfo info)
Validates the document and puts interesting properties into the
RepInfo.
|
protected static HashMap commonTags
protected Map supportedElements
protected HtmlTagDesc htmlElement
protected HtmlTagDesc headElement
protected HtmlTagDesc bodyElement
protected HtmlTagDesc framesetElement
protected static String[] headings
public boolean validate(List elements, RepInfo info)
elements
- The element list constructed by the parserinfo
- The RepInfo object which will be populated
with propertiespublic HtmlMetadata getMetadata()
protected void init()
protected static void addStringsToList(String[] names, List lst)
protected static void addSimpleAttribute(List atts, String name)
protected static void addRequiredAttribute(List atts, String name)
protected static void addSelfAttribute(List atts, String name)
protected static void removeStringsFromList(List lst, String[] strs)
protected void pushElementStack(JHOpenTag tag)
Copyright © 2008–2017 The Open Preservation Foundation. All rights reserved.