Class CompactSyntax
java.lang.Object
com.sun.tools.rngom.parse.compact.CompactSyntax
- All Implemented Interfaces:
ValidationContext
,CompactSyntaxConstants
,Context
-
Field Summary
Modifier and TypeFieldDescriptionNext token.Current token.Generated Token Manager.Fields inherited from interface com.sun.tools.rngom.parse.compact.CompactSyntaxConstants
AFTER_DOCUMENTATION, AFTER_SINGLE_LINE_COMMENT, BASE_CHAR, COMBINING_CHAR, DEFAULT, DIGIT, DOCUMENTATION, DOCUMENTATION_AFTER_SINGLE_LINE_COMMENT, DOCUMENTATION_CONTINUE, EOF, ESCAPED_IDENTIFIER, EXTENDER, FANNOTATE, IDENTIFIER, IDEOGRAPHIC, ILLEGAL_CHAR, LETTER, LITERAL, NCNAME, NEWLINE, NMCHAR, NMSTART, NOT_NEWLINE, PREFIX_STAR, PREFIXED_NAME, SINGLE_LINE_COMMENT, SINGLE_LINE_COMMENT_CONTINUE, tokenImage, WS
-
Constructor Summary
ConstructorDescriptionCompactSyntax
(CompactParseable parseable, Reader r, String sourceUri, SchemaBuilder sb, ErrorHandler eh, String inheritedNs) Constructor with generated Token Manager.CompactSyntax
(InputStream stream) Constructor with InputStream.CompactSyntax
(InputStream stream, String encoding) Constructor with InputStream and supplied encodingCompactSyntax
(Reader stream) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionfinal ParsedNameClass
final ParsedPattern
AnnotatedPrimaryExpr
(boolean topLevel, Scope scope, Token[] except) final void
final ParsedElementAnnotation
AnnotationElement
(boolean nested) final void
final void
final ParsedElementAnnotation
final Annotations
final ParsedNameClass
AnyNameExceptClass
(int context, Annotations a, Annotations[] pa) final GrammarSection.Combine
AssignOp()
final ParsedPattern
AttributeExpr
(Scope scope, Annotations a) final ParsedNameClass
BasicNameClass
(int context) copy()
Returns the immutable snapshot of this .final ParsedPattern
DataExpr
(boolean topLevel, Scope scope, Annotations a, Token[] except) final Token
final void
final void
Define
(GrammarSection section, Scope scope, Annotations a) final void
Definition
(GrammarSection section, Scope scope, Annotations a) final void
Disable tracing.final void
Div
(GrammarSection section, Scope scope, Annotations a) final ParsedElementAnnotation
final ParsedPattern
ElementExpr
(Scope scope, Annotations a) final ParsedPattern
final void
Enable tracing.final ParsedPattern
final ParsedNameClass
ExceptNameClass
(int context) final ParsedPattern
Expr
(boolean topLevel, Scope scope, Token t, Annotations a) final ParsedPattern
ExternalRefExpr
(Scope scope, Annotations a) Generate ParseException.Returns the base URI of the context.final Token
Get the next Token.final Token
getToken
(int index) Get the specific Token.final Annotations
GrammarBody
(GrammarSection section, Scope scope, Annotations a) final void
GrammarComponent
(GrammarSection section, Scope scope) final ParsedPattern
GrammarExpr
(Scope scope, Annotations a) final com.sun.tools.rngom.parse.compact.CompactSyntax.LocatedString
final ParsedElementAnnotation
final ParsedPattern
IdentifierExpr
(Scope scope, Annotations a) final void
Include
(GrammarSection section, Scope scope, Annotations a) final Annotations
IncludeBody
(GrammarSection section, Scope scope, Annotations a) final void
IncludeComponent
(GrammarSection section, Scope scope) final ParsedPattern
final void
IncludeDiv
(GrammarSection section, Scope scope, Annotations a) final String
Inherit()
final ParsedPattern
boolean
isNotation
(String notationName) Checks if a notation is declared with the specified name.boolean
isUnparsedEntity
(String entityName) Checks if an unparsed entity is declared with the specified name.final Token
Keyword()
final ParsedPattern
ListExpr
(Scope scope, Annotations a) final String
Literal()
final com.sun.tools.rngom.parse.compact.CompactSyntax.LocatedString
final void
final void
final void
final void
final ParsedPattern
MixedExpr
(Scope scope, Annotations a) final ParsedNameClass
NameClass
(int context, Annotations[] pa) final ParsedNameClass
NameClassAlternatives
(int context, ParsedNameClass nc, Annotations[] pa) final void
final String
final ParsedPattern
final com.sun.tools.rngom.parse.compact.CompactSyntax.LocatedString
NsName()
final ParsedNameClass
NsNameExceptClass
(int context, Annotations a, Annotations[] pa) final ParsedNameClass
OpenNameClass
(int context, Annotations a) final void
Param
(DataPatternBuilder dpb) final void
Params
(DataPatternBuilder dpb) final ParsedPattern
ParenExpr
(boolean topLevel, Scope scope, Annotations a) final ParsedNameClass
ParenNameClass
(int context, Annotations a) final ParsedPattern
ParentExpr
(Scope scope, Annotations a) final void
Preamble()
final String
Prefix()
final void
PrefixedAnnotationAttribute
(Annotations a, boolean nested) final ParsedElementAnnotation
PrefixedAnnotationElement
(boolean nested) final ParsedNameClass
prefixes()
Enumerates the prefixes bound to namespaces.final ParsedPattern
PrimaryExpr
(boolean topLevel, Scope scope, Annotations a, Token[] except) final ParsedNameClass
PrimaryNameClass
(int context, Annotations a) void
Reinitialise.void
ReInit
(InputStream stream) Reinitialise.void
ReInit
(InputStream stream, String encoding) Reinitialise.void
Reinitialise.resolveNamespacePrefix
(String prefix) Resolves a namespace prefix to the corresponding namespace URI.final void
Start
(GrammarSection section, Scope scope, Annotations a) final ParsedPattern
final ParsedPattern
TopLevelGrammar
(Scope scope) final void
final ParsedPattern
final void
final ParsedElementAnnotation
final com.sun.tools.rngom.parse.compact.CompactSyntax.LocatedString
final ParsedNameClass
UnprefixedNameClass
(int context, Annotations a) final ParsedPattern
ValueExpr
(boolean topLevel, Annotations a)
-
Field Details
-
token_source
Generated Token Manager. -
token
Current token. -
jj_nt
Next token.
-
-
Constructor Details
-
CompactSyntax
public CompactSyntax(CompactParseable parseable, Reader r, String sourceUri, SchemaBuilder sb, ErrorHandler eh, String inheritedNs) -
CompactSyntax
Constructor with InputStream. -
CompactSyntax
Constructor with InputStream and supplied encoding -
CompactSyntax
Constructor. -
CompactSyntax
Constructor with generated Token Manager.
-
-
Method Details
-
resolveNamespacePrefix
Description copied from interface:ValidationContext
Resolves a namespace prefix to the corresponding namespace URI. This method is used for validating the QName type, for example.If the prefix is "" (empty string), it indicates an unprefixed value. The callee should resolve it as for an unprefixed element, rather than for an unprefixed attribute.
If the prefix is "xml", then the callee must resolve this prefix into "http://www.w3.org/XML/1998/namespace", as defined in the XML Namespaces Recommendation.
- Specified by:
resolveNamespacePrefix
in interfaceValidationContext
- Returns:
- namespace URI of this prefix. If the specified prefix is not declared, the implementation must return null.
-
prefixes
Description copied from interface:Context
Enumerates the prefixes bound to namespaces. -
getBaseUri
Description copied from interface:ValidationContext
Returns the base URI of the context. The null string may be returned if no base URI is known.- Specified by:
getBaseUri
in interfaceValidationContext
-
isUnparsedEntity
Description copied from interface:ValidationContext
Checks if an unparsed entity is declared with the specified name.- Specified by:
isUnparsedEntity
in interfaceValidationContext
- Returns:
- true if the DTD has an unparsed entity declaration for the specified name. false otherwise.
-
isNotation
Description copied from interface:ValidationContext
Checks if a notation is declared with the specified name.- Specified by:
isNotation
in interfaceValidationContext
- Returns:
- true if the DTD has a notation declaration for the specified name. false otherwise.
-
copy
Description copied from interface:Context
Returns the immutable snapshot of this . -
Input
- Throws:
ParseException
-
TopLevelLookahead
- Throws:
ParseException
-
LookaheadAfterAnnotations
- Throws:
ParseException
-
LookaheadGrammarKeyword
- Throws:
ParseException
-
LookaheadDocumentation
- Throws:
ParseException
-
LookaheadBody
- Throws:
ParseException
-
IncludedGrammar
- Throws:
ParseException
-
TopLevelGrammar
- Throws:
ParseException
-
Preamble
- Throws:
ParseException
-
NamespaceDecl
- Throws:
ParseException
-
NamespaceName
- Throws:
ParseException
-
DatatypesDecl
- Throws:
ParseException
-
AnnotatedPrimaryExpr
public final ParsedPattern AnnotatedPrimaryExpr(boolean topLevel, Scope scope, Token[] except) throws ParseException - Throws:
ParseException
-
PrimaryExpr
public final ParsedPattern PrimaryExpr(boolean topLevel, Scope scope, Annotations a, Token[] except) throws ParseException - Throws:
ParseException
-
EmptyExpr
- Throws:
ParseException
-
TextExpr
- Throws:
ParseException
-
NotAllowedExpr
- Throws:
ParseException
-
Expr
public final ParsedPattern Expr(boolean topLevel, Scope scope, Token t, Annotations a) throws ParseException - Throws:
ParseException
-
UnaryExpr
public final ParsedPattern UnaryExpr(boolean topLevel, Scope scope, boolean[] hadOccur, Token[] except) throws ParseException - Throws:
ParseException
-
ElementExpr
- Throws:
ParseException
-
AttributeExpr
- Throws:
ParseException
-
NameClass
- Throws:
ParseException
-
AnnotateAfter
- Throws:
ParseException
-
NameClassAlternatives
public final ParsedNameClass NameClassAlternatives(int context, ParsedNameClass nc, Annotations[] pa) throws ParseException - Throws:
ParseException
-
BasicNameClass
- Throws:
ParseException
-
PrimaryNameClass
- Throws:
ParseException
-
OpenNameClass
- Throws:
ParseException
-
UnprefixedNameClass
- Throws:
ParseException
-
PrefixedNameClass
- Throws:
ParseException
-
NsNameExceptClass
public final ParsedNameClass NsNameExceptClass(int context, Annotations a, Annotations[] pa) throws ParseException - Throws:
ParseException
-
NsName
public final com.sun.tools.rngom.parse.compact.CompactSyntax.LocatedString NsName() throws ParseException- Throws:
ParseException
-
AnyNameExceptClass
public final ParsedNameClass AnyNameExceptClass(int context, Annotations a, Annotations[] pa) throws ParseException - Throws:
ParseException
-
ParenNameClass
- Throws:
ParseException
-
ExceptNameClass
- Throws:
ParseException
-
ListExpr
- Throws:
ParseException
-
MixedExpr
- Throws:
ParseException
-
GrammarExpr
- Throws:
ParseException
-
ParenExpr
public final ParsedPattern ParenExpr(boolean topLevel, Scope scope, Annotations a) throws ParseException - Throws:
ParseException
-
GrammarBody
public final Annotations GrammarBody(GrammarSection section, Scope scope, Annotations a) throws ParseException - Throws:
ParseException
-
GrammarComponent
- Throws:
ParseException
-
Definition
public final void Definition(GrammarSection section, Scope scope, Annotations a) throws ParseException - Throws:
ParseException
-
Start
- Throws:
ParseException
-
Define
- Throws:
ParseException
-
AssignOp
- Throws:
ParseException
-
Include
- Throws:
ParseException
-
IncludeBody
public final Annotations IncludeBody(GrammarSection section, Scope scope, Annotations a) throws ParseException - Throws:
ParseException
-
IncludeComponent
- Throws:
ParseException
-
Div
- Throws:
ParseException
-
IncludeDiv
public final void IncludeDiv(GrammarSection section, Scope scope, Annotations a) throws ParseException - Throws:
ParseException
-
ExternalRefExpr
- Throws:
ParseException
-
Inherit
- Throws:
ParseException
-
ParentExpr
- Throws:
ParseException
-
IdentifierExpr
- Throws:
ParseException
-
ValueExpr
- Throws:
ParseException
-
DataExpr
public final ParsedPattern DataExpr(boolean topLevel, Scope scope, Annotations a, Token[] except) throws ParseException - Throws:
ParseException
-
DatatypeName
- Throws:
ParseException
-
Identifier
public final com.sun.tools.rngom.parse.compact.CompactSyntax.LocatedString Identifier() throws ParseException- Throws:
ParseException
-
Prefix
- Throws:
ParseException
-
UnprefixedName
public final com.sun.tools.rngom.parse.compact.CompactSyntax.LocatedString UnprefixedName() throws ParseException- Throws:
ParseException
-
Params
- Throws:
ParseException
-
Param
- Throws:
ParseException
-
Except
- Throws:
ParseException
-
Documentation
- Throws:
ParseException
-
Annotations
- Throws:
ParseException
-
AnnotationAttribute
- Throws:
ParseException
-
PrefixedAnnotationAttribute
- Throws:
ParseException
-
UnprefixedAnnotationAttribute
- Throws:
ParseException
-
AnnotationElement
- Throws:
ParseException
-
AnnotationElementNotKeyword
- Throws:
ParseException
-
PrefixedAnnotationElement
public final ParsedElementAnnotation PrefixedAnnotationElement(boolean nested) throws ParseException - Throws:
ParseException
-
UnprefixedAnnotationElement
- Throws:
ParseException
-
IdentifierAnnotationElement
- Throws:
ParseException
-
AnnotationElementContent
- Throws:
ParseException
-
AnnotationElementLiteral
- Throws:
ParseException
-
Literal
- Throws:
ParseException
-
LocatedLiteral
public final com.sun.tools.rngom.parse.compact.CompactSyntax.LocatedString LocatedLiteral() throws ParseException- Throws:
ParseException
-
Keyword
- Throws:
ParseException
-
ReInit
Reinitialise. -
ReInit
Reinitialise. -
ReInit
Reinitialise. -
ReInit
Reinitialise. -
getNextToken
Get the next Token. -
getToken
Get the specific Token. -
generateParseException
Generate ParseException. -
enable_tracing
public final void enable_tracing()Enable tracing. -
disable_tracing
public final void disable_tracing()Disable tracing.
-