public abstract class XMLBaseGrammar extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
XMLBaseGrammar.Context |
| Modifier and Type | Field and Description |
|---|---|
static int |
BUFFERSIZE |
protected static String |
Char
[2] Char ::= [#x1-#xD7FF] | [#xE000-#xFFFD] | [#x10000-#x10FFFF]
|
protected boolean |
external |
protected Map<String,Object> |
generalReferences |
protected InputSource |
input |
protected org.vesalainen.parser.util.InputReader |
inputReader |
protected XMLLocator |
locator |
protected static String |
NameChar
[4a] NameChar ::= NameStartChar | "-" | "." | [0-9] | #xB7 | [#x0300-#x036F] | [#x203F-#x2040]
|
protected static String |
NameStartChar
[4] NameStartChar ::= ":" | [A-Z] | "_" | [a-z] | [#xC0-#xD6] | [#xD8-#xF6] | [#xF8-#x2FF] | [#x370-#x37D] | [#x37F-#x1FFF] | [#x200C-#x200D] | [#x2070-#x218F] | [#x2C00-#x2FEF] | [#x3001-#xD7FF] | [#xF900-#xFDCF] | [#xFDF0-#xFFFD] | [#x10000-#xEFFFF]
|
protected static String |
NCNameChar
[4a] NameChar ::= NameStartChar | "-" | "." | [0-9] | #xB7 | [#x0300-#x036F] | [#x203F-#x2040]
|
protected static String |
NCNameStartChar
[4] NCNameStartChar ::= [A-Z] | "_" | [a-z] | [#xC0-#xD6] | [#xD8-#xF6] | [#xF8-#x2FF] | [#x370-#x37D] | [#x37F-#x1FFF] | [#x200C-#x200D] | [#x2070-#x218F] | [#x2C00-#x2FEF] | [#x3001-#xD7FF] | [#xF900-#xFDCF] | [#xFDF0-#xFFFD] | [#x10000-#xEFFFF]
|
protected Map<String,Object> |
parameterReferences |
protected static String |
PubidChar
[13] PubidChar ::= #x20 | #xD | #xA | [a-zA-Z0-9] | [-'()+,./:=?;!*#@$_%]
|
protected static String |
PubidCharMinusApostrophe |
protected static String |
RestrictedChar
[2a] RestrictedChar ::= [#x1-#x8] | [#xB-#xC] | [#xE-#x1F] | [#x7F-#x84] | [#x86-#x9F]
|
protected static String |
S
[3] S ::= (#x20 | #x9 | #xD | #xA)+
|
| Constructor and Description |
|---|
XMLBaseGrammar() |
| Modifier and Type | Method and Description |
|---|---|
protected String |
aposAttValue() |
protected String |
aposAttValue(String str,
String value) |
protected String |
aposAttValueStart(org.vesalainen.parser.util.InputReader reader) |
protected String |
aposAttValueSub(String str) |
protected String |
aposEntityValue() |
protected String |
aposEntityValue(String str,
String value) |
protected String |
aposEntityValueStart(org.vesalainen.parser.util.InputReader reader) |
protected String |
aposEntityValueSub(String str) |
protected String |
attValue(String str) |
protected abstract void |
byteOrderMark() |
protected void |
cdSect(org.vesalainen.parser.util.InputReader r)
[20] CData ::= (Char* - (Char* ']]>' Char*))
|
protected void |
charData(org.vesalainen.parser.util.InputReader reader)
[14] CharData ::= [^<&]* - ([^<&]* ']]>' [^<&]*)
|
protected String |
charRef(int value)
[66] CharRef ::= '' [0-9]+ ';'
| '' [0-9a-fA-F]+ ';'
|
protected int |
charRefDecimal(String s) |
protected int |
charRefHex(String s) |
protected void |
comment(org.vesalainen.parser.util.InputReader reader)
[15] Comment ::= ''
|
protected abstract int |
digit(int value) |
protected abstract void |
document()
[1] document ::= ( prolog element Misc* ) - ( Char* RestrictedChar Char* )
|
protected String |
emptyQuote() |
protected abstract String |
encName(String name)
[81] EncName ::= [A-Za-z] ([A-Za-z0-9._] | '-')*
|
protected void |
encodingDecl(String charset)
[80] EncodingDecl ::= S 'encoding' Eq ('"' EncName '"' | "'" EncName "'" )
|
protected abstract void |
entityDecl()
[70] EntityDecl ::= GEDecl | PEDecl
|
protected void |
entityDef(String entityValue)
[73] EntityDef ::= EntityValue | (ExternalID NDataDecl?)
|
protected void |
entityDef(String[] externalID) |
protected String |
entityRef(String name)
[68] EntityRef ::= '&' Name ';'
|
protected String |
entityValue(String str) |
protected char[] |
eol() |
protected abstract void |
eq()
[25] Eq ::= S? '=' S?
|
protected QName |
eTagName(String s) |
protected String[] |
externalID(String systemLiteral) |
protected String[] |
externalID(String pubidLiteral,
String systemLiteral) |
protected void |
geDecl(String name)
[71] GEDecl ::= ''
|
String |
getEncoding() |
String |
getPublicId() |
String |
getSystemId() |
String |
getXmlVersion() |
protected int |
hex(String value) |
protected abstract void |
misc()
[27] Misc ::= Comment | PI | S
|
protected abstract String |
name(String name)
[5] Name ::= NameStartChar (NameChar)*
|
protected List<String> |
names(List<String> names,
String name) |
protected List<String> |
names(String name)
[6] Names ::= Name (#x20 Name)*
|
protected void |
nDataDecl(String name)
[76] NDataDecl ::= S 'NDATA' S Name
|
protected abstract String |
nmtoken(String nmtoken)
[7] Nmtoken ::= (NameChar)+
|
protected List<String> |
nmtokens(List<String> nmtokens,
String nmtoken) |
protected List<String> |
nmtokens(String nmtoken)
[8] Nmtokens ::= Nmtoken (#x20 Nmtoken)*
|
protected abstract String |
notApos(String value) |
protected abstract String |
notAposValue(String value) |
protected void |
notationDecl(String name,
String publicID) |
protected void |
notationDecl(String name,
String[] externalID)
[82] NotationDecl ::= ''
|
protected abstract String |
notQuot(String value) |
protected abstract String |
notQuotValue(String value) |
protected String |
nsAttName(String s)
[1] NSAttName ::= PrefixedAttName
| DefaultAttName
|
protected String[] |
optExternalID()
(S ExternalID)?
|
protected String[] |
optExternalID(String[] externalID) |
protected abstract String |
parseAposAttValue(org.vesalainen.parser.util.InputReader reader) |
protected abstract String |
parseAposEntityValue(org.vesalainen.parser.util.InputReader reader) |
protected abstract void |
parseDocument(org.vesalainen.parser.util.InputReader reader) |
protected abstract void |
parseExtSubset(org.vesalainen.parser.util.InputReader reader) |
protected abstract String |
parseQuotAttValue(org.vesalainen.parser.util.InputReader reader) |
protected abstract String |
parseQuotEntityValue(org.vesalainen.parser.util.InputReader reader) |
protected void |
peDecl(String name,
Object value)
[72] PEDecl ::= ''
|
protected Object |
peDef(String entityValue)
[74] PEDef ::= EntityValue | ExternalID
|
protected Object |
peDef(String[] externalID) |
protected String |
peReference(String name,
org.vesalainen.parser.util.InputReader reader)
[69] PEReference ::= '%' Name ';'
|
protected void |
pi()
[16] PI ::= '' PITarget (S (Char* - (Char* '?>' Char*)))? '?>'
|
protected abstract String |
pubidLiteral(String literal)
[12] PubidLiteral ::= '"' PubidChar* '"' | "'" (PubidChar - "'")* "'"
|
protected String |
pubidLiteralMinusApostrophe(String value) |
protected String |
pubidLiteralWithApostrophe(String value) |
protected abstract String |
publicID(String id)
[83] PublicID ::= 'PUBLIC' S PubidLiteral
|
protected QName |
qName(String s) |
protected String |
quotAttValue() |
protected String |
quotAttValue(String str,
String value) |
protected String |
quotAttValueStart(org.vesalainen.parser.util.InputReader reader)
[10] AttValue ::= '"' ([^<&"] | Reference)* '"'
| "'" ([^<&'] | Reference)* "'"
|
protected String |
quotAttValueSub(String str) |
protected String |
quotEntityValue() |
protected String |
quotEntityValue(String str,
String value) |
protected String |
quotEntityValueStart(org.vesalainen.parser.util.InputReader reader)
[9] EntityValue ::= '"' ([^%&"] | PEReference | Reference)* '"'
| "'" ([^%&'] | PEReference | Reference)* "'"
|
protected String |
quotEntityValueSub(String str) |
protected abstract String |
reference(String value)
[67] Reference ::= EntityRef | CharRef
|
protected abstract void |
s() |
protected void |
sdDecl(boolean opt)
[32] SDDecl ::= S 'standalone' Eq (("'" ('yes' | 'no') "'") | ('"' ('yes' | 'no') '"'))
|
void |
setExternal(boolean external) |
void |
setPublicId(String publicId) |
void |
setSystemId(String systemId) |
void |
setXmlVersion(String xmlVersion) |
protected abstract void |
singleApostrophe() |
protected abstract void |
singleQuot() |
protected QName |
sTagName(String s)
[4] NCName ::= NCNameStartChar NCNameChar*
|
protected String |
systemLiteral(String literal)
[11] SystemLiteral ::= ('"' [^"]* '"') | ("'" [^']* "'")
|
protected void |
utf16BE() |
protected void |
utf16BEPrefix() |
protected void |
utf16LE() |
protected void |
utf16LEPrefix() |
protected void |
utf32BE() |
protected void |
utf32BEPrefix() |
protected void |
utf32LE() |
protected void |
utf32LEPrefix() |
protected void |
utf8() |
protected abstract void |
utf8Prefix() |
protected String |
version(String version) |
protected void |
versionInfo(String version)
[24] VersionInfo ::= S 'version' Eq ("'" VersionNum "'" | '"' VersionNum '"')
|
protected abstract String |
versionNum(String version)
[26] VersionNum ::= '1.1'
|
protected abstract void |
xmlDecl()
[23] XMLDecl ::= ''
|
protected abstract void |
xmlPrefix() |
protected boolean |
yesNo(String opt) |
public static final int BUFFERSIZE
protected static final String Char
protected static final String RestrictedChar
protected static final String S
protected static final String NameStartChar
protected static final String NameChar
protected static final String PubidChar
protected static final String PubidCharMinusApostrophe
protected static final String NCNameStartChar
protected static final String NCNameChar
protected org.vesalainen.parser.util.InputReader inputReader
protected InputSource input
protected XMLLocator locator
protected boolean external
protected abstract void parseExtSubset(org.vesalainen.parser.util.InputReader reader)
reader - protected abstract void parseDocument(org.vesalainen.parser.util.InputReader reader)
reader - protected abstract String parseQuotAttValue(org.vesalainen.parser.util.InputReader reader)
reader - protected abstract String parseAposAttValue(org.vesalainen.parser.util.InputReader reader)
reader - protected abstract String parseQuotEntityValue(org.vesalainen.parser.util.InputReader reader)
reader - protected abstract String parseAposEntityValue(org.vesalainen.parser.util.InputReader reader)
reader - protected abstract void document()
throws SAXException
SAXExceptionprotected abstract String name(String name)
name - protected String quotEntityValueStart(org.vesalainen.parser.util.InputReader reader) throws IOException
IOExceptionprotected String aposEntityValueStart(org.vesalainen.parser.util.InputReader reader) throws IOException
IOExceptionprotected String entityValue(String str) throws IOException
IOExceptionprotected String quotEntityValue()
protected String aposEntityValue()
protected String quotAttValueStart(org.vesalainen.parser.util.InputReader reader) throws IOException
IOExceptionprotected String aposAttValueStart(org.vesalainen.parser.util.InputReader reader) throws IOException
IOExceptionprotected String attValue(String str) throws IOException
IOExceptionprotected abstract void singleQuot()
protected abstract void singleApostrophe()
protected String quotAttValue()
protected String aposAttValue()
protected String emptyQuote()
protected String systemLiteral(String literal)
protected abstract String pubidLiteral(String literal)
protected void charData(org.vesalainen.parser.util.InputReader reader)
throws SAXException
SAXExceptionprotected void comment(org.vesalainen.parser.util.InputReader reader)
throws SAXException
SAXExceptionprotected abstract void s()
protected void pi()
protected void cdSect(org.vesalainen.parser.util.InputReader r)
throws SAXException
SAXExceptionprotected abstract int digit(int value)
protected int hex(String value)
protected abstract void xmlDecl()
protected abstract void byteOrderMark()
protected void utf32BE()
throws SAXParseException
SAXParseExceptionprotected void utf32LE()
throws SAXParseException
SAXParseExceptionprotected void utf16BE()
throws SAXParseException
SAXParseExceptionprotected void utf16LE()
throws SAXParseException
SAXParseExceptionprotected void utf8()
throws SAXParseException
SAXParseExceptionprotected abstract void xmlPrefix()
protected void utf32BEPrefix()
throws SAXParseException
SAXParseExceptionprotected void utf32LEPrefix()
throws SAXParseException
SAXParseExceptionprotected void utf16BEPrefix()
throws SAXParseException
SAXParseExceptionprotected void utf16LEPrefix()
throws SAXParseException
SAXParseExceptionprotected abstract void utf8Prefix()
protected void versionInfo(String version) throws SAXParseException
SAXParseExceptionprotected abstract void eq()
protected abstract void misc()
protected void sdDecl(boolean opt)
protected boolean yesNo(String opt)
protected String charRef(int value)
value - protected int charRefDecimal(String s)
protected int charRefHex(String s)
protected abstract String reference(String value)
value - protected String entityRef(String name) throws SAXParseException
name - SAXParseExceptionprotected String peReference(String name, org.vesalainen.parser.util.InputReader reader) throws SAXParseException, IOException
name - SAXParseExceptionIOExceptionprotected abstract void entityDecl()
protected void geDecl(String name)
name - protected void peDecl(String name, Object value) throws SAXException
name - SAXExceptionprotected void entityDef(String entityValue)
value - protected void entityDef(String[] externalID)
protected Object peDef(String entityValue)
value - protected Object peDef(String[] externalID) throws SAXException, IOException
SAXExceptionIOExceptionprotected String[] optExternalID()
protected void nDataDecl(String name)
name - protected void encodingDecl(String charset)
encName - protected abstract String encName(String name)
name - protected void notationDecl(String name, String[] externalID) throws SAXException
name - id - SAXExceptionprotected void notationDecl(String name, String publicID) throws SAXException
SAXExceptionprotected abstract String publicID(String id)
id - protected String nsAttName(String s) throws IOException
IOExceptionprotected QName sTagName(String s) throws IOException
name - IOExceptionprotected QName eTagName(String s) throws IOException
IOExceptionprotected QName qName(String s) throws IOException
IOExceptionprotected char[] eol()
throws IOException
IOExceptionpublic String getEncoding()
public String getPublicId()
public void setPublicId(String publicId)
public String getSystemId()
public void setSystemId(String systemId) throws URISyntaxException
URISyntaxExceptionpublic String getXmlVersion()
public void setXmlVersion(String xmlVersion)
public void setExternal(boolean external)
Copyright © 2014. All rights reserved.