Package com.sun.msv.grammar
package com.sun.msv.grammar
abstract grammar model(AGM): common part.
ID/IDREF support
Support for 'ID' and 'IDREF' types are implemented in this package, due to the restriction of the implementation.
The implementation in this package works as follows:
-
When verify method of IDType is called, it only checks the conformance as a NMTOKEN and uniqueness, then stores it as ID.
-
When verify method of IDREFType is called, it only checks the conformance as a NMTOKEN and stores it as IDREF.
-
When the entire document is parsed, ID list and IDREF list are cross-checked. IDREF without the corresponding ID is detected in this stage.
This implementation implies very severe limitations. For example, consider the following TREX pattern.
<element name="foo">
<choice>
<attribute name="bar" type="ID" />
<attribute name="bar" type="string" />
</choice>
<element name="child">
<attribute name="id" type="ID" />
</element>
</element>
And the following XML fragment.
<foo bar="xyz"> <child id="xyz" /> </foo>
This implementation cannot validate the above fragment, because "xyz" is registered as an ID when "bar" attribute is tested against "ID" type. IDREF type also has similar problems.
Note that RELAX prohibits these "abuse" of ID/IDREF in the way that this implementation works.
-
ClassDescriptiona NameClass that matches any name.Attribute declaration.Base implementation for those expression which has two child expressions.A|B.Union of two NameClasses.<concur> pattern of TREX.Expression that matchs characters of the particular
Datatype
.<difference> name class.Element declaration.Primitive of the tree regular expression.clones an expression.Creates a new Expression by combining existing expressions.expression cache by closed hash.Visitor interface for Expression and its derived types.ExpressionVisitor that returns boolean.ExpressionVisitor that returns Expression object.ExpressionVisitor that returns void.base interface of the "grammar".Deprecated.ValidationContextProvider that supports limited ID/IDREF implementation.<interleave> pattern of TREX, or <all> particle of XML Schema.<list> of RELAX NG.<mixed> of RELAX.validator of (namespaceURI,localPart) pair.common interface of AttributeExp and ElementExp.Visitor interface for NameClass.NameClass that matchs any names in a particular namespace.NameClass that acts a not operator.A+.Base class for application-specific AGM annotation.Container of ReferenceExp.Reference to the other expression.A,B.a NameClass that accepts only one fixed name.Base implementation for those expression who has one child expresison.Expression that matchs a particular value of aDatatype
.
IDContextProvider2
.