Class AbstractX4OReaderSession<T>
java.lang.Object
org.x4o.xml.io.AbstractX4OConnectionDebug
org.x4o.xml.io.AbstractX4OConnection
org.x4o.xml.io.AbstractX4OReaderSession<T>
- Type Parameters:
T- The root element object type.
- All Implemented Interfaces:
X4OConnection, X4OReader<T>, X4OReaderSession<T>
- Direct Known Subclasses:
AbstractX4OReader
public abstract class AbstractX4OReaderSession<T>
extends AbstractX4OConnection
implements X4OReaderSession<T>
AbstractX4OReaderSession
- Version:
- 1.0 Apr 6, 2013
- Author:
- Willem Cazander
-
Field Summary
Fields inherited from class AbstractX4OConnection
phaseSkip, phaseStopFields inherited from class AbstractX4OConnectionDebug
ABSTRACT_DEBUG_OUTPUT_HANDLER, ABSTRACT_DEBUG_OUTPUT_STREAM, ABSTRACT_DEBUG_OUTPUT_STREAM_CLOSE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionreadFileSession(File file) Reads the file and reads it as an InputStream.readFileSession(String fileName) Reads the file fileName and reads it as an InputStream.readResourceSession(String resourceName) reads an resource locaction.readStringSession(String xmlString) Converts a String to a InputStream to is can me read by SAX.readUrlSession(URL url) Fetched the data direct from remote url to a InputStream to is can me readd by SAX.Methods inherited from class AbstractX4OConnection
addPhaseSkip, getLanguage, getProperty, getPropertyKeys, setPhaseStop, setPropertyMethods inherited from class AbstractX4OConnectionDebug
debugException, debugStart, debugStopMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface X4OConnection
addPhaseSkip, getProperty, getPropertyKeys, setPhaseStop, setPropertyMethods inherited from interface X4OReader
addELBeanInstance, read, readFile, readFile, readResource, readString, readUrlMethods inherited from interface X4OReaderSession
readSession, releaseSession
-
Constructor Details
-
AbstractX4OReaderSession
-
-
Method Details
-
readFileSession
public X4OLanguageSession readFileSession(String fileName) throws X4OConnectionException, SAXException, IOException, FileNotFoundException Reads the file fileName and reads it as an InputStream.- Specified by:
readFileSessionin interfaceX4OReaderSession<T>- Parameters:
fileName- The file name to read.- Throws:
FileNotFoundException- Is thrown is file is not found.X4OConnectionException- Is thrown after x4o exception.SAXException- Is thrown after sax xml exception.IOException- Is thrown after io exception.- See Also:
-
readFileSession
public X4OLanguageSession readFileSession(File file) throws X4OConnectionException, SAXException, IOException, FileNotFoundException Reads the file and reads it as an InputStream.- Specified by:
readFileSessionin interfaceX4OReaderSession<T>- Parameters:
file- The file to read.- Throws:
FileNotFoundException- Is thrown is file is not found.X4OConnectionException- Is thrown after x4o exception.SAXException- Is thrown after sax xml exception.IOException- Is thrown after io exception.- See Also:
-
readResourceSession
public X4OLanguageSession readResourceSession(String resourceName) throws X4OConnectionException, SAXException, IOException reads an resource locaction.- Specified by:
readResourceSessionin interfaceX4OReaderSession<T>- Parameters:
resourceName- The resource to readr.- Throws:
X4OConnectionException- Is thrown after x4o exception.SAXException- Is thrown after sax xml exception.IOException- Is thrown after io exception.- See Also:
-
readStringSession
public X4OLanguageSession readStringSession(String xmlString) throws X4OConnectionException, SAXException, IOException Converts a String to a InputStream to is can me read by SAX.- Specified by:
readStringSessionin interfaceX4OReaderSession<T>- Parameters:
xmlString- The xml as (UTF-8) String to read.- Throws:
X4OConnectionException- Is thrown after x4o exception.SAXException- Is thrown after sax xml exception.IOException- Is thrown after io exception.- See Also:
-
readUrlSession
public X4OLanguageSession readUrlSession(URL url) throws X4OConnectionException, SAXException, IOException Fetched the data direct from remote url to a InputStream to is can me readd by SAX.- Specified by:
readUrlSessionin interfaceX4OReaderSession<T>- Parameters:
url- The url to read.- Throws:
X4OConnectionException- Is thrown after x4o exception.SAXException- Is thrown after sax xml exception.IOException- Is thrown after io exception.- See Also:
-