com.bluecast.xml

Class XMLInputReader

public abstract class XMLInputReader extends Reader

A Reader for XML documents the proper character set to use based on Byte Order Marks and XML declarations.

Version: $Revision: 1.3 $

Author: Yuval Oren, yuval@bluecast.com

Method Summary
StringgetXMLDeclaredEncoding()
Gets the declared encoding from the XML declaration, or null if no value was found.
StringgetXMLVersion()
Gets the version string from the XML declaration, or null.
booleanisXMLStandalone()
Returns the Standalone value from the XML declaration.
booleanisXMLStandaloneDeclared()
Returns true if an XML "standalone" declaration was found.
protected intparseXMLDeclaration(char[] cbuf, int offset, int length)
Call this to parse the XML declaration.
protected voidresetInput()

Method Detail

getXMLDeclaredEncoding

public String getXMLDeclaredEncoding()
Gets the declared encoding from the XML declaration, or null if no value was found.

getXMLVersion

public String getXMLVersion()
Gets the version string from the XML declaration, or null.

isXMLStandalone

public boolean isXMLStandalone()
Returns the Standalone value from the XML declaration. Defaults to false if no value was declared.

isXMLStandaloneDeclared

public boolean isXMLStandaloneDeclared()
Returns true if an XML "standalone" declaration was found.

parseXMLDeclaration

protected int parseXMLDeclaration(char[] cbuf, int offset, int length)
Call this to parse the XML declaration. Returns the number of characters used by the declaration, or zero if no declaration was found.

resetInput

protected void resetInput()