public final class ConfigurableValidationState extends ValidationState
An extension of ValidationState which can be configured to turn off checking for ID/IDREF errors and unparsed entity errors.
Constructor and Description |
---|
ConfigurableValidationState()
Creates a new ConfigurableValidationState.
|
Modifier and Type | Method and Description |
---|---|
void |
addId(String name)
Adds the ID, if ID/IDREF checking is enabled.
|
void |
addIdRef(String name)
Adds the IDREF, if ID/IDREF checking is enabled.
|
String |
checkIDRefID()
Checks if all IDREFs have a corresponding ID.
|
boolean |
isEntityDeclared(String name)
Checks if an entity is declared.
|
boolean |
isEntityUnparsed(String name)
Checks if an entity is unparsed.
|
boolean |
isIdDeclared(String name)
Checks if an ID has already been declared.
|
void |
setIdIdrefChecking(boolean setting)
Turns checking for ID/IDREF errors on and off.
|
void |
setUnparsedEntityChecking(boolean setting)
Turns checking for unparsed entity errors on and off.
|
getLocale, getSymbol, getURI, needExtraChecking, needFacetChecking, needToNormalize, reset, resetIDTables, setEntityState, setExtraChecking, setFacetChecking, setLocale, setNamespaceSupport, setNormalizationRequired, setSymbolTable, setUsingNamespaces, useNamespaces
public ConfigurableValidationState()
public void setIdIdrefChecking(boolean setting)
setting
- true to turn on error checking,
false to turn off error checkingpublic void setUnparsedEntityChecking(boolean setting)
setting
- true to turn on error checking,
false to turn off error checkingpublic String checkIDRefID()
checkIDRefID
in class ValidationState
public boolean isIdDeclared(String name)
isIdDeclared
in interface ValidationContext
isIdDeclared
in class ValidationState
public boolean isEntityDeclared(String name)
isEntityDeclared
in interface ValidationContext
isEntityDeclared
in class ValidationState
public boolean isEntityUnparsed(String name)
isEntityUnparsed
in interface ValidationContext
isEntityUnparsed
in class ValidationState
public void addId(String name)
addId
in interface ValidationContext
addId
in class ValidationState
name
- the ID to addpublic void addIdRef(String name)
addIdRef
in interface ValidationContext
addIdRef
in class ValidationState
name
- the IDREF to addCopyright © 2016 JBoss by Red Hat. All rights reserved.