net.sf.saxon.om

Class Name10Checker


public final class Name10Checker
extends NameChecker

The class checks names and characters against the rules of the XML 1.0 and XML Namespaces 1.0 specification

Field Summary

static Name10Checker
theInstance

Method Summary

static Name10Checker
getInstance()
Get the singular instance of this class
String
getXMLVersion()
Return the XML version supported by this NameChecker
boolean
isNCNameChar(int ch)
Test whether a character can appear in an NCName
boolean
isNCNameStartChar(int ch)
Test whether a character can appear at the start of an NCName
boolean
isValidChar(int ch)
Test whether a character is a valid XML character

Methods inherited from class net.sf.saxon.om.NameChecker

checkQNameParts, getPrefix, getQNameParts, getXMLVersion, isNCNameChar, isNCNameStartChar, isQName, isValidChar, isValidNCName, isValidNmtoken

Field Details

theInstance

public static final Name10Checker theInstance

Method Details

getInstance

public static Name10Checker getInstance()
Get the singular instance of this class
Returns:
the singular instance of this class

getXMLVersion

public String getXMLVersion()
Return the XML version supported by this NameChecker
Overrides:
getXMLVersion in interface NameChecker
Returns:
"1.0" as a string

isNCNameChar

public boolean isNCNameChar(int ch)
Test whether a character can appear in an NCName
Overrides:
isNCNameChar in interface NameChecker
Parameters:
ch - the character to be tested
Returns:
true if this is a valid character in an NCName the selected version of XML

isNCNameStartChar

public boolean isNCNameStartChar(int ch)
Test whether a character can appear at the start of an NCName
Overrides:
isNCNameStartChar in interface NameChecker
Parameters:
ch - the character to be tested
Returns:
true if this is a valid character at the start of an NCName the selected version of XML

isValidChar

public boolean isValidChar(int ch)
Test whether a character is a valid XML character
Overrides:
isValidChar in interface NameChecker
Parameters:
ch - the character to be tested
Returns:
true if this is a valid character in the selected version of XML