private class XmlObjectParser.Parser extends DefaultHandler
| Modifier and Type | Field and Description |
|---|---|
private StringBuilder |
characters |
private Stack<Object> |
current |
private Locator |
locator |
| Modifier | Constructor and Description |
|---|---|
private |
Parser() |
| Modifier and Type | Method and Description |
|---|---|
void |
characters(char[] ch,
int start,
int length) |
void |
endElement(String ns,
String lname,
String qname) |
void |
error(SAXParseException e) |
void |
fatalError(SAXParseException e) |
private Object |
getValueForClass(Class<?> klass,
String value) |
private boolean |
parseBoolean(String s) |
private void |
report() |
void |
setDocumentLocator(Locator locator) |
private void |
setValue(XmlObjectParser.Entry entry,
String fieldName,
String value) |
void |
startElement(String ns,
String lname,
String qname,
Attributes a) |
protected void |
throwException(Exception e) |
endDocument, endPrefixMapping, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, skippedEntity, startDocument, startPrefixMapping, unparsedEntityDecl, warningprivate StringBuilder characters
private Parser()
public void setDocumentLocator(Locator locator)
setDocumentLocator in interface ContentHandlersetDocumentLocator in class DefaultHandlerprotected void throwException(Exception e) throws XmlParsingException
XmlParsingExceptionpublic void startElement(String ns, String lname, String qname, Attributes a) throws SAXException
startElement in interface ContentHandlerstartElement in class DefaultHandlerSAXExceptionpublic void endElement(String ns, String lname, String qname) throws SAXException
endElement in interface ContentHandlerendElement in class DefaultHandlerSAXExceptionpublic void characters(char[] ch, int start, int length)
characters in interface ContentHandlercharacters in class DefaultHandlerprivate void report()
private Object getValueForClass(Class<?> klass, String value)
private void setValue(XmlObjectParser.Entry entry, String fieldName, String value) throws SAXException
SAXExceptionprivate boolean parseBoolean(String s)
public void error(SAXParseException e) throws SAXException
error in interface ErrorHandlererror in class DefaultHandlerSAXExceptionpublic void fatalError(SAXParseException e) throws SAXException
fatalError in interface ErrorHandlerfatalError in class DefaultHandlerSAXException