All Packages Class Hierarchy This Package Previous Next Index
Class xe.xe_ElementDeclParser
java.lang.Object
|
+----xe.xe_Parser
|
+----xe.xe_ElementDeclParser
- public class xe_ElementDeclParser
- extends xe_Parser
Class xe_ElementDeclParser - parser for an element declaration within the
DTD of an XML document, assuming the beginning ('
or
or - mixed
or - elements
-
xe_ElementDeclParser()
-
-
parse()
- Parse the body of an element declaration.
-
parseElementContent(xg_ElementDecl, xe_Token, xe_Token)
- Parse the declaration of an 'elements' element, assuming that its name,
opening parenthesis and the first token of the first Entry have already been
parsed.
-
parseElementsEntry(xg_ElementDecl, xe_Token)
- Parse an entry in the list of an 'elements' element, assuming that its first
token has already been parsed.
-
parseElementsList(xg_ElementDecl, xe_Token, xe_Token)
- Parse an entry in the list of an 'elements' element, assuming that its
opening parenthesis and the token after it have already been parsed.
-
parseMixedContent(xg_ElementDecl, xe_Token, xe_Token)
- Parse the declaration of a mixed element, assuming that its name, opening
parenthesis and the '#' of #PCDATA have already been parsed (and the '#' is
in the InputStartToken).
-
parseMixedNameList(xg_ElementDecl, xe_Token)
- Parse the declaration of a mixed element which has a list of names, assuming
that it has been parsed up to the '#PCDATA |'.
-
parseOccurrencesChar(xg_ElementDecl)
- Parse the occurrences character ('?', '*', '+' - or it may be omitted
altogether) which occurs at the end of an elements list.
xe_ElementDeclParser
public xe_ElementDeclParser()
parse
public xg_Node parse() throws IOException
- Parse the body of an element declaration.
- Returns:
- The parsed ElementDecl
- Overrides:
- parse in class xe_Parser
parseMixedContent
public xe_Token parseMixedContent(xg_ElementDecl InputElementDecl,
xe_Token InputOpenParenToken,
xe_Token InputFirstToken) throws IOException
- Parse the declaration of a mixed element, assuming that its name, opening
parenthesis and the '#' of #PCDATA have already been parsed (and the '#' is
in the InputStartToken). It should have the rough form:
Name (#PCDATA )
Name (#PCDATA | Name; | Name; | ...)*
======>
- Parameters:
- InputElementDecl - The element declaration currently being parsed
- InputOpenParenToken - The opening parenthesis token
- InputFirstToken - The first token after the open parenthesis
parseMixedNameList
public void parseMixedNameList(xg_ElementDecl InputElementDecl,
xe_Token InputOpeningOrToken) throws IOException
- Parse the declaration of a mixed element which has a list of names, assuming
that it has been parsed up to the '#PCDATA |'. This initial '|' is assumed
to have already been parsed (and be in the InputStartToken), although we
still need to check it actually is '|'. It should have the rough form:
Name (#PCDATA | Name; | Name; | ...)*
==============>
- Parameters:
- InputElementDecl - The ElementDecl currently being parsed
- InputOpeningOrToken - The opening or token
parseElementContent
public xe_Token parseElementContent(xg_ElementDecl InputElementDecl,
xe_Token InputOpenParenToken,
xe_Token InputFirstToken) throws IOException
- Parse the declaration of an 'elements' element, assuming that its name,
opening parenthesis and the first token of the first Entry have already been
parsed. It should have the rough form:
Name ( Entry | Entry | ... )?|*|+ - choice
Name ( Entry , Entry , ... )?|*|+ - seq
========>
where Entry is either a 'choice' or 'seq'.
- Parameters:
- InputElementDecl - The ElementDecl currently being parsed
- InputOpenParenToken - The opening parenthesis token
- InputFirstToken - The first token after the open parenthesis
parseElementsList
public xe_Token parseElementsList(xg_ElementDecl InputElementDecl,
xe_Token InputOpenParenToken,
xe_Token InputFirstToken) throws IOException
- Parse an entry in the list of an 'elements' element, assuming that its
opening parenthesis and the token after it have already been parsed. It
should have the rough form:
( Entry | Entry | ... ) - choice
or ( Entry , Entry , ... ) - seq
===>
where Entry is either a Name, 'choice' or 'seq'.
- Parameters:
- InputElementDecl - The element declaration currently being parsed
- InputOpenParenToken - The opening parenthesis token
- InputFirstToken - The first token after the opening parenthesis
parseElementsEntry
public xe_Token parseElementsEntry(xg_ElementDecl InputElementDecl,
xe_Token InputFirstToken) throws IOException
- Parse an entry in the list of an 'elements' element, assuming that its first
token has already been parsed. It should have the rough form:
Name
or ( Entry | Entry | ... ) - choice
or ( Entry , Entry , ... ) - seq
where Entry is either a Name, 'choice' or 'seq'.
- Parameters:
- InputElementDecl - The ElementDecl currently being parsed
- InputFirstToken - The first token
- Returns:
- The token which follows the entry
parseOccurrencesChar
public xe_Token parseOccurrencesChar(xg_ElementDecl InputElementDecl) throws IOException
- Parse the occurrences character ('?', '*', '+' - or it may be omitted
altogether) which occurs at the end of an elements list.
- Parameters:
- InputElementDecl - The ElementDecl currently being parsed
- Returns:
- The token which follows the occurrences character
All Packages Class Hierarchy This Package Previous Next Index