BEA Systems, Inc.

WebLogic Server 8.1 API Reference

weblogic.xml.stream
Class XMLInputStreamFactory

java.lang.Object
  |
  +--weblogic.xml.stream.XMLInputStreamFactory

public abstract class XMLInputStreamFactory
extends java.lang.Object

Defines an abstract implementation of a factory for getting streams

Author:
Copyright © 2002 BEA Systems, Inc. All Rights Reserved.
See Also:
XMLInputStream, ElementFilter

Constructor Summary
XMLInputStreamFactory()
           
 
Method Summary
abstract  BufferedXMLInputStream newBufferedInputStream(XMLInputStream inputStream)
          Create a buffered XMLInputStream from an XMLInputStream
abstract  XMLInputStream newCanonicalInputStream(XMLInputStream inputStream)
          Wrap a canonical stream around an XMLInputStream
abstract  XMLInputStream newDTDAwareInputStream(java.io.InputStream inputStream)
          Create a stream that reads and understands a DTD, can be used to canoncalize an XML source
abstract  XMLInputStream newDTDAwareInputStream(java.io.Reader reader)
          Create a stream that reads and understands a DTD, can be used to canoncalize an XML source
abstract  XMLInputStream newFragmentInputStream(java.io.InputStream inputStream, java.util.Map namespaces)
          Create a stream can parse fragments
abstract  XMLInputStream newFragmentInputStream(java.io.Reader reader, java.util.Map namespaces)
          Create a stream can parse fragments
abstract  XMLInputStream newInputStream(org.w3c.dom.Document doc)
          Create an XMLInputStream that reads from a DOM document
abstract  XMLInputStream newInputStream(org.w3c.dom.Document document, ElementFilter filter)
          Create a filtered XMLInputStream that reads from a DOM document
abstract  XMLInputStream newInputStream(java.io.File file)
          Create a new XMLInputStream from a file
abstract  XMLInputStream newInputStream(java.io.File file, ElementFilter filter)
          Create a filtered XMLInputStream from a file
abstract  XMLInputStream newInputStream(java.io.InputStream stream)
          Create a new XMLInputStream from a stream
abstract  XMLInputStream newInputStream(java.io.InputStream stream, ElementFilter filter)
          Create a filtered XMLInputStream from a stream
abstract  XMLInputStream newInputStream(org.w3c.dom.Node node)
          Create an XMLInputStream that reads from a DOM node
abstract  XMLInputStream newInputStream(org.w3c.dom.Node node, ElementFilter filter)
          Create a filtered XMLInputStream that reads from a DOM node
abstract  XMLInputStream newInputStream(java.io.Reader reader)
          Create a new XMLInputStream from a reader
abstract  XMLInputStream newInputStream(java.io.Reader reader, ElementFilter filter)
          Create a filtered XMLInputStream from a reader
abstract  XMLInputStream newInputStream(XMLInputStream inputStream, ElementFilter filter)
          Create a filtered XMLInputStream from an XMLInputStream
abstract  XMLInputStream newInputStream(XMLPullReader reader, org.xml.sax.InputSource input)
          Create a new XMLInputStream from an InputSource
abstract  XMLInputStream newInputStream(XMLPullReader reader, org.xml.sax.InputSource input, ElementFilter filter)
          Create a filtered XMLInputStream from an InputSource read by the XMLPullReader
static XMLInputStreamFactory newInstance()
          Create a new instance of the factory.
abstract  void setFilter(ElementFilter filter)
          Allows you to set a default filter for the factory that will wrap all streams created from this factory
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XMLInputStreamFactory

public XMLInputStreamFactory()
Method Detail

newInstance

public static XMLInputStreamFactory newInstance()
Create a new instance of the factory.

newInputStream

public abstract XMLInputStream newInputStream(java.io.File file)
                                       throws XMLStreamException
Create a new XMLInputStream from a file

Parameters:
file - the XML file to read from

newInputStream

public abstract XMLInputStream newInputStream(java.io.InputStream stream)
                                       throws XMLStreamException
Create a new XMLInputStream from a stream

Parameters:
stream - the XML stream to read from

newInputStream

public abstract XMLInputStream newInputStream(java.io.Reader reader)
                                       throws XMLStreamException
Create a new XMLInputStream from a reader

Parameters:
reader - the XML reader to read from

newInputStream

public abstract XMLInputStream newInputStream(XMLPullReader reader,
                                              org.xml.sax.InputSource input)
                                       throws XMLStreamException
Create a new XMLInputStream from an InputSource

Parameters:
reader - the XMLPullReader that reads the inputsource
input - the InputSource that the XMLReader reads from

newInputStream

public abstract XMLInputStream newInputStream(org.w3c.dom.Document doc)
                                       throws XMLStreamException
Create an XMLInputStream that reads from a DOM document

Parameters:
document - the DOM document to read from

newInputStream

public abstract XMLInputStream newInputStream(org.w3c.dom.Node node)
                                       throws XMLStreamException
Create an XMLInputStream that reads from a DOM node

Parameters:
node - the DOM node to read from

newInputStream

public abstract XMLInputStream newInputStream(XMLPullReader reader,
                                              org.xml.sax.InputSource input,
                                              ElementFilter filter)
                                       throws XMLStreamException
Create a filtered XMLInputStream from an InputSource read by the XMLPullReader

Parameters:
reader - the XMLPullReader that reads the inputsource
input - the InputSource that the XMLReader reads from
filter - the ElementFilter to apply to the stream

newInputStream

public abstract XMLInputStream newInputStream(org.w3c.dom.Document document,
                                              ElementFilter filter)
                                       throws XMLStreamException
Create a filtered XMLInputStream that reads from a DOM document

Parameters:
document - the DOM document to read from
filter - the ElementFilter to apply to the stream

newInputStream

public abstract XMLInputStream newInputStream(org.w3c.dom.Node node,
                                              ElementFilter filter)
                                       throws XMLStreamException
Create a filtered XMLInputStream that reads from a DOM node

Parameters:
node - the DOM node to read from
filter - the ElementFilter to apply to the stream

newInputStream

public abstract XMLInputStream newInputStream(java.io.File file,
                                              ElementFilter filter)
                                       throws XMLStreamException
Create a filtered XMLInputStream from a file

Parameters:
file - the XML file to read from
filter - the ElementFilter to apply to the stream

newInputStream

public abstract XMLInputStream newInputStream(java.io.InputStream stream,
                                              ElementFilter filter)
                                       throws XMLStreamException
Create a filtered XMLInputStream from a stream

Parameters:
stream - the XML stream to read from
filter - the ElementFilter to apply to the stream

newInputStream

public abstract XMLInputStream newInputStream(java.io.Reader reader,
                                              ElementFilter filter)
                                       throws XMLStreamException
Create a filtered XMLInputStream from a reader

Parameters:
reader - the reader to read from
filter - the ElementFilter to apply to the stream

newInputStream

public abstract XMLInputStream newInputStream(XMLInputStream inputStream,
                                              ElementFilter filter)
                                       throws XMLStreamException
Create a filtered XMLInputStream from an XMLInputStream

Parameters:
inputStream - the stream to wrap
filter - the ElementFilter to apply to the stream

newBufferedInputStream

public abstract BufferedXMLInputStream newBufferedInputStream(XMLInputStream inputStream)
                                                       throws XMLStreamException
Create a buffered XMLInputStream from an XMLInputStream

Parameters:
inputStream - the stream to buffer

newCanonicalInputStream

public abstract XMLInputStream newCanonicalInputStream(XMLInputStream inputStream)
                                                throws XMLStreamException
Wrap a canonical stream around an XMLInputStream

Parameters:
inputStream - the stream to buffer

newDTDAwareInputStream

public abstract XMLInputStream newDTDAwareInputStream(java.io.InputStream inputStream)
                                               throws XMLStreamException
Create a stream that reads and understands a DTD, can be used to canoncalize an XML source

Parameters:
inputStream - the stream to buffer

newDTDAwareInputStream

public abstract XMLInputStream newDTDAwareInputStream(java.io.Reader reader)
                                               throws XMLStreamException
Create a stream that reads and understands a DTD, can be used to canoncalize an XML source

Parameters:
reader - the reader to read from

newFragmentInputStream

public abstract XMLInputStream newFragmentInputStream(java.io.InputStream inputStream,
                                                      java.util.Map namespaces)
                                               throws XMLStreamException
Create a stream can parse fragments

Parameters:
inputStream - the stream to buffer

newFragmentInputStream

public abstract XMLInputStream newFragmentInputStream(java.io.Reader reader,
                                                      java.util.Map namespaces)
                                               throws XMLStreamException
Create a stream can parse fragments

Parameters:
reader - the reader to read from

setFilter

public abstract void setFilter(ElementFilter filter)
                        throws XMLStreamException
Allows you to set a default filter for the factory that will wrap all streams created from this factory

Parameters:
filter - the default filter

Documentation is available at
http://download.oracle.com/docs/cd/E13222_01/wls/docs81b