org.apache.xmlrpc.parser

Class TypeParserImpl

Implemented Interfaces:
ContentHandler, TypeParser
Known Direct Subclasses:
AtomicParser, ByteArrayParser, RecursiveTypeParserImpl

public abstract class TypeParserImpl
extends java.lang.Object
implements TypeParser

Abstract base implementation of a TypeParser, for derivation of subclasses.

Method Summary

void
characters(char[] pChars, int pOffset, int pLength)
void
endDocument()
void
endPrefixMapping(String pPrefix)
Locator
getDocumentLocator()
Returns the document locator.
Object
getResult()
Returns the parsed object.
void
ignorableWhitespace(char[] pChars, int pOffset, int pLength)
protected static boolean
isEmpty(char[] pChars, int pStart, int pLength)
void
processingInstruction(String pTarget, String pData)
PI's are by default ignored.
void
setDocumentLocator(Locator pLocator)
void
setResult(Object pResult)
Sets the result object.
void
skippedEntity(String pName)
Skipped entities raise an exception by default.
void
startDocument()
void
startPrefixMapping(String pPrefix, String pURI)

Method Details

characters

public void characters(char[] pChars,
                       int pOffset,
                       int pLength)
            throws SAXException

endDocument

public void endDocument()
            throws SAXException

endPrefixMapping

public void endPrefixMapping(String pPrefix)
            throws SAXException

getDocumentLocator

public Locator getDocumentLocator()
Returns the document locator.
Returns:
Locator object describing the current location within the document.

getResult

public Object getResult()
            throws XmlRpcException
Returns the parsed object.
Specified by:
getResult in interface TypeParser
Returns:
The parameter or result object.
Throws:
XmlRpcException - Creating the result object failed.

ignorableWhitespace

public void ignorableWhitespace(char[] pChars,
                                int pOffset,
                                int pLength)
            throws SAXException

isEmpty

protected static boolean isEmpty(char[] pChars,
                                 int pStart,
                                 int pLength)

processingInstruction

public void processingInstruction(String pTarget,
                                  String pData)
            throws SAXException
PI's are by default ignored.

setDocumentLocator

public void setDocumentLocator(Locator pLocator)

setResult

public void setResult(Object pResult)
Sets the result object.
Parameters:
pResult - The result object.

skippedEntity

public void skippedEntity(String pName)
            throws SAXException
Skipped entities raise an exception by default.

startDocument

public void startDocument()
            throws SAXException

startPrefixMapping

public void startPrefixMapping(String pPrefix,
                               String pURI)
            throws SAXException

Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved.