|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Object org.attoparser.markup.DocumentRestrictions
public final class DocumentRestrictions
Models a series of restrictions that can be applied during document parsing
by subclasses of AbstractDetailedMarkupAttoHandler
.
A fixed set of these restrictions can be used for checking the well-formedness (from an XML/XHTML standpoint) of a document:
Besides these well-formedness related restrictions, there is also a requireNoProlog restriction that ensures no XML Declaration or DOCTYPE clause appears in the parsed document.
Method Summary | |
---|---|
boolean |
getRequireBalancedElements()
|
boolean |
getRequireNoProlog()
|
boolean |
getRequireUniqueAttributesInElement()
|
boolean |
getRequireUniqueRootElement()
|
boolean |
getRequireWellFormedAttributeValues()
|
boolean |
getRequireWellFormedProlog()
|
static DocumentRestrictions |
none()
Creates a DocumentRestrictions instance enforcing no restrictions at all. |
void |
setRequireBalancedElements(boolean requireBalancedElements)
|
void |
setRequireNoProlog(boolean requireNoProlog)
|
void |
setRequireUniqueAttributesInElement(boolean requireUniqueAttributesInElement)
|
void |
setRequireUniqueRootElement(boolean requireUniqueRootElement)
|
void |
setRequireWellFormedAttributeValues(boolean requireWellFormedAttributeValues)
|
void |
setRequireWellFormedProlog(boolean requireWellFormedProlog)
|
static DocumentRestrictions |
wellFormed()
Creates a DocumentRestrictions instance enforcing the set of restrictions
that check the well-formedness (from an XML/XHTML standpoint):
requireBalancedElements, requireWellFormedProlog,
requireUniqueRootElement, requireWellFormedAttributeValues
and requireUniqueAttributesInElement. |
Methods inherited from class Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static DocumentRestrictions none()
Creates a DocumentRestrictions
instance enforcing no restrictions at all.
public static DocumentRestrictions wellFormed()
Creates a DocumentRestrictions
instance enforcing the set of restrictions
that check the well-formedness (from an XML/XHTML standpoint):
requireBalancedElements, requireWellFormedProlog,
requireUniqueRootElement, requireWellFormedAttributeValues
and requireUniqueAttributesInElement.
public boolean getRequireBalancedElements()
public void setRequireBalancedElements(boolean requireBalancedElements)
public boolean getRequireWellFormedProlog()
public void setRequireWellFormedProlog(boolean requireWellFormedProlog)
public boolean getRequireWellFormedAttributeValues()
public void setRequireWellFormedAttributeValues(boolean requireWellFormedAttributeValues)
public boolean getRequireUniqueAttributesInElement()
public void setRequireUniqueAttributesInElement(boolean requireUniqueAttributesInElement)
public boolean getRequireUniqueRootElement()
public void setRequireUniqueRootElement(boolean requireUniqueRootElement)
public boolean getRequireNoProlog()
public void setRequireNoProlog(boolean requireNoProlog)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |