public abstract class XMLDocumentParser extends XMLDTDBaseGrammar implements XMLReader, SAX2Constants, org.vesalainen.parser.ParserInfo
XMLBaseGrammar.ContextBUFFERSIZE, Char, external, generalReferences, input, inputReader, locator, NameChar, NameStartChar, NCNameChar, NCNameStartChar, parameterReferences, PubidChar, PubidCharMinusApostrophe, RestrictedChar, SFEATURE_ATTRIBUTES2, FEATURE_ENTITY_RESOLVER2, FEATURE_IS_STANDALONE, FEATURE_LOCATOR2, FEATURE_NAMES_SPACE, FEATURE_NAMES_SPACE_PREFIXES, FEATURE_VALIDATION, FEATURE_XML_1_1, FEATURES, PROPERTIES, PROPERTY_DECLARATION_HANDLER, PROPERTY_DOCUMENT_XML_VERSION, PROPERTY_LEXICAL_HANDLER| Constructor and Description |
|---|
XMLDocumentParser() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
attDef(QName name)
[53] AttDef ::= S Name S AttType S DefaultDecl
[21] AttDef ::= S (QName | NSAttName) S AttType S DefaultDecl
|
protected void |
attDef(String name) |
protected void |
attlistDecl(QName name)
[52] AttlistDecl ::= ''
[20] AttlistDecl ::= ''
|
protected void |
attribute(QName name,
String value)
[41] Attribute ::= Name Eq AttValue
[15] Attribute ::= NSAttName Eq AttValue
| QName Eq AttValue
|
protected void |
attribute(String name,
String uri) |
protected abstract void |
attributes() |
protected abstract boolean |
attributesSub(boolean hasContent) |
protected abstract void |
attType()
[54] AttType ::= StringType | TokenizedType | EnumeratedType
|
protected void |
charData(org.vesalainen.parser.util.InputReader reader)
[14] CharData ::= [^<&]* - ([^<&]* ']]>' [^<&]*)
|
protected abstract void |
children()
[47] children ::= (choice | seq) ('?' | '*' | '+')?
|
protected abstract void |
choice()
[49] choice ::= '(' S? cp ( S? '|' S? cp )+ S? ')'
|
protected void |
comment(org.vesalainen.parser.util.InputReader reader)
[15] Comment ::= ''
|
protected abstract void |
content()
[43] content ::= CharData? ((element | Reference | CDSect | PI | Comment) CharData?)*
|
protected void |
content(String charData) |
protected abstract void |
contentspec()
[46] contentspec ::= 'EMPTY' | 'ANY' | Mixed | children
|
protected boolean |
contentTag() |
protected abstract void |
cp() |
protected void |
cp(QName name)
[48] cp ::= (Name | choice | seq) ('?' | '*' | '+')?
[18] cp ::= (QName | choice | seq) ('?' | '*' | '+')?
|
protected abstract void |
defaultDecl()
[60] DefaultDecl ::= '#REQUIRED' | '#IMPLIED'
| (('#FIXED' S)? AttValue)
|
protected void |
defaultDecl(String value) |
protected void |
doctypedeclEnd() |
protected void |
doctypedeclStart(QName name,
String[] externalID) |
protected void |
document()
[1] document ::= ( prolog element Misc* ) - ( Char* RestrictedChar Char* )
|
protected abstract void |
element()
[39] element ::= EmptyElemTag
| STag content ETag
|
protected abstract void |
elementContent() |
protected void |
elementdecl(QName name)
[45] elementdecl ::= ''
[17] elementdecl ::= ''
|
protected boolean |
emptyTag() |
protected void |
endTag() |
protected abstract void |
enumeratedType()
[57] EnumeratedType ::= NotationType | Enumeration
|
protected void |
enumeration(String name)
[59] Enumeration ::= '(' S? Nmtoken (S? '|' S? Nmtoken)* S? ')'
|
protected abstract void |
enumerationNMTokens() |
protected void |
enumerationNMTokens(String name) |
protected void |
eTag(String s)
[42] ETag ::= '' Name S? '>'
[13] ETag ::= '' QName S? '>'
|
ContentHandler |
getContentHandler() |
DeclHandler |
getDeclHandler() |
DTDHandler |
getDTDHandler() |
EntityResolver |
getEntityResolver() |
ErrorHandler |
getErrorHandler() |
static XMLDocumentParser |
getInstance() |
LexicalHandler |
getLexicalHandler() |
Object |
getProperty(String name) |
static void |
main(String[] args) |
protected abstract void |
mixed()
[51] Mixed ::= '(' S? '#PCDATA' (S? '|' S? Name)* S? ')*'
| '(' S? '#PCDATA' S? ')'
[19] Mixed ::= '(' S? '#PCDATA' (S? '|' S? QName)* S? ')*'
| '(' S? '#PCDATA' S? ')'
|
protected abstract void |
mixedNames() |
protected void |
mixedNames(QName name) |
protected void |
notationDecl(String name,
String publicID) |
protected void |
notationDecl(String name,
String[] externalID)
[82] NotationDecl ::= ''
|
protected void |
notationType(String name)
[58] NotationType ::= 'NOTATION' S '(' S? Name (S? '|' S? Name)* S? ')'
|
protected abstract void |
notationTypeNames() |
protected void |
notationTypeNames(String name) |
void |
parse(InputSource input) |
void |
parse(String systemId) |
protected abstract boolean |
parseAttributes(org.vesalainen.parser.util.InputReader reader) |
protected abstract void |
parseContent(org.vesalainen.parser.util.InputReader reader) |
void |
parseText(String text) |
protected void |
peDecl(String name,
Object value)
[72] PEDecl ::= ''
|
protected Object |
peDef(String[] externalID) |
protected abstract void |
seq()
[50] seq ::= '(' S? cp ( S? ',' S? cp )* S? ')'
|
void |
setContentHandler(ContentHandler contentHandler) |
void |
setDeclHandler(DeclHandler declHandler) |
void |
setDTDHandler(DTDHandler dtdHandler) |
void |
setEntityResolver(EntityResolver entityResolver) |
void |
setErrorHandler(ErrorHandler errorHandler) |
void |
setLexicalHandler(LexicalHandler lexicalHandler) |
void |
setProperty(String name,
Object value) |
protected void |
sTag(QName name,
org.vesalainen.parser.util.InputReader reader)
[40] STag ::= '<' Name (S Attribute)* S? '>'
[12] STag ::= '<' QName (S Attribute)* S? '>'
[44] EmptyElemTag ::= '<' Name (S Attribute)* S? '/>'
EmptyElemTag ::= '<' QName (S Attribute)* S? '/>'
|
protected abstract void |
stringType()
[55] StringType ::= 'CDATA'
|
protected boolean |
tagType(boolean hasContent) |
protected abstract void |
tokenizedType()
[56] TokenizedType ::= 'ID'
| 'IDREF'
| 'IDREFS'
| 'ENTITY'
| 'ENTITIES'
| 'NMTOKEN'
| 'NMTOKENS'
|
protected void |
trace(int ord,
int ctx,
org.vesalainen.parser.util.InputReader reader,
int token,
int laToken,
int curtok,
int[] stack,
int sp,
int[] typeStack,
Object[] valueStack) |
conditionalSect, doctypedecl, doctypedeclContent, extParsedEntity, extSubset, extSubsetDecl, ignore, ignoreEnd, ignoreSect, ignoreSectContents, ignoreStart, includeSect, intSubset, markupdecl, prolog, textDeclaposAttValue, aposAttValue, aposAttValueStart, aposAttValueSub, aposEntityValue, aposEntityValue, aposEntityValueStart, aposEntityValueSub, attValue, byteOrderMark, cdSect, charRef, charRefDecimal, charRefHex, digit, emptyQuote, encName, encodingDecl, entityDecl, entityDef, entityDef, entityRef, entityValue, eol, eq, eTagName, externalID, externalID, geDecl, getEncoding, getPublicId, getSystemId, getXmlVersion, hex, misc, name, names, names, nDataDecl, nmtoken, nmtokens, nmtokens, notApos, notAposValue, notQuot, notQuotValue, nsAttName, optExternalID, optExternalID, parseAposAttValue, parseAposEntityValue, parseDocument, parseExtSubset, parseQuotAttValue, parseQuotEntityValue, peDef, peReference, pi, pubidLiteral, pubidLiteralMinusApostrophe, pubidLiteralWithApostrophe, publicID, qName, quotAttValue, quotAttValue, quotAttValueStart, quotAttValueSub, quotEntityValue, quotEntityValue, quotEntityValueStart, quotEntityValueSub, reference, s, sdDecl, setExternal, setPublicId, setSystemId, setXmlVersion, singleApostrophe, singleQuot, sTagName, systemLiteral, utf16BE, utf16BEPrefix, utf16LE, utf16LEPrefix, utf32BE, utf32BEPrefix, utf32LE, utf32LEPrefix, utf8, utf8Prefix, version, versionInfo, versionNum, xmlDecl, xmlPrefix, yesNoclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetFeature, setFeaturepublic static XMLDocumentParser getInstance() throws IOException
IOExceptionpublic void parse(InputSource input) throws IOException, SAXException
parse in interface XMLReaderIOExceptionSAXExceptionpublic void parseText(String text) throws IOException, SAXException
IOExceptionSAXExceptionpublic void parse(String systemId) throws IOException, SAXException
parse in interface XMLReaderIOExceptionSAXExceptionprotected void document()
throws SAXException
document in class XMLBaseGrammarSAXExceptionprotected abstract void element()
protected abstract void elementContent()
protected abstract void parseContent(org.vesalainen.parser.util.InputReader reader)
reader - protected void sTag(QName name, org.vesalainen.parser.util.InputReader reader) throws SAXException
SAXExceptionprotected void endTag()
protected boolean contentTag()
protected boolean emptyTag()
protected boolean tagType(boolean hasContent)
protected abstract boolean parseAttributes(org.vesalainen.parser.util.InputReader reader)
reader - protected abstract boolean attributesSub(boolean hasContent)
protected abstract void attributes()
protected void attribute(QName name, String value)
protected void attribute(String name, String uri) throws SAXException
SAXExceptionprotected void eTag(String s) throws SAXException
SAXExceptionprotected abstract void content()
protected void content(String charData)
protected Object peDef(String[] externalID) throws SAXException, IOException
peDef in class XMLBaseGrammarSAXExceptionIOExceptionprotected void charData(org.vesalainen.parser.util.InputReader reader)
throws SAXException
charData in class XMLBaseGrammarSAXExceptionprotected void comment(org.vesalainen.parser.util.InputReader reader)
throws SAXException
comment in class XMLBaseGrammarSAXExceptionprotected void doctypedeclStart(QName name, String[] externalID) throws SAXException, IOException
doctypedeclStart in class XMLDTDBaseGrammarSAXExceptionIOExceptionprotected void doctypedeclEnd()
throws SAXException
doctypedeclEnd in class XMLDTDBaseGrammarSAXExceptionprotected void peDecl(String name, Object value) throws SAXException
peDecl in class XMLBaseGrammarname - SAXExceptionprotected void notationDecl(String name, String[] externalID) throws SAXException
notationDecl in class XMLBaseGrammarname - id - SAXExceptionprotected void notationDecl(String name, String publicID) throws SAXException
notationDecl in class XMLBaseGrammarSAXExceptionpublic ContentHandler getContentHandler()
getContentHandler in interface XMLReaderpublic void setContentHandler(ContentHandler contentHandler)
setContentHandler in interface XMLReaderpublic DeclHandler getDeclHandler()
public void setDeclHandler(DeclHandler declHandler)
public DTDHandler getDTDHandler()
getDTDHandler in interface XMLReaderpublic void setDTDHandler(DTDHandler dtdHandler)
setDTDHandler in interface XMLReaderpublic EntityResolver getEntityResolver()
getEntityResolver in interface XMLReaderpublic void setEntityResolver(EntityResolver entityResolver)
setEntityResolver in interface XMLReaderpublic ErrorHandler getErrorHandler()
getErrorHandler in interface XMLReaderpublic void setErrorHandler(ErrorHandler errorHandler)
setErrorHandler in interface XMLReaderpublic LexicalHandler getLexicalHandler()
public void setLexicalHandler(LexicalHandler lexicalHandler)
public Object getProperty(String name) throws SAXNotRecognizedException, SAXNotSupportedException
getProperty in interface XMLReaderSAXNotRecognizedExceptionSAXNotSupportedExceptionpublic void setProperty(String name, Object value) throws SAXNotRecognizedException, SAXNotSupportedException
setProperty in interface XMLReaderSAXNotRecognizedExceptionSAXNotSupportedExceptionprotected void trace(int ord,
int ctx,
org.vesalainen.parser.util.InputReader reader,
int token,
int laToken,
int curtok,
int[] stack,
int sp,
int[] typeStack,
Object[] valueStack)
protected void elementdecl(QName name)
protected abstract void contentspec()
protected abstract void children()
protected void cp(QName name)
protected abstract void cp()
protected abstract void choice()
protected abstract void seq()
protected abstract void mixed()
protected abstract void mixedNames()
protected void mixedNames(QName name)
protected void attlistDecl(QName name)
name - protected void attDef(QName name)
name - protected void attDef(String name)
protected abstract void attType()
protected abstract void stringType()
protected abstract void tokenizedType()
protected abstract void enumeratedType()
protected void notationType(String name)
name - protected abstract void notationTypeNames()
protected void notationTypeNames(String name)
protected void enumeration(String name)
name - protected abstract void enumerationNMTokens()
protected void enumerationNMTokens(String name)
protected abstract void defaultDecl()
protected void defaultDecl(String value)
public static void main(String[] args)
args - the command line argumentsCopyright © 2014. All rights reserved.