org.freecompany.infoset.sax

Class SaxInfosetFactory

public class SaxInfosetFactory extends Object implements InfosetFactory<XMLReader>

Field Summary
protected SAXParserFactoryfactory
Constructor Summary
protected SaxInfosetFactory()
Method Summary
<V> Infoset<V>adaptTo(Class<V> clazz, Infoset<XMLReader> infoset)
Infoset<XMLReader>create(URL url)
Creates an infoset that will, when accessed, parse the content from the provided URL.
Infoset<XMLReader>create(ReadableByteChannel channel)
Creates an infoset that will, when accessed, parse the content from the provided URL.
Infoset<XMLReader>create(InputStream input)
Creates an infoset that will, when accessed, parse the content from the provided InputStream.
static SaxInfosetFactorynewInstance()

Field Detail

factory

protected final SAXParserFactory factory

Constructor Detail

SaxInfosetFactory

protected SaxInfosetFactory()

Method Detail

adaptTo

public <V> Infoset<V> adaptTo(Class<V> clazz, Infoset<XMLReader> infoset)

create

public Infoset<XMLReader> create(URL url)
Creates an infoset that will, when accessed, parse the content from the provided URL. Once parsed, the content will be cached, so anything that wishes to modify the resulting Document must clone it first.

create

public Infoset<XMLReader> create(ReadableByteChannel channel)
Creates an infoset that will, when accessed, parse the content from the provided URL. Once parsed, the content will be cached, so anything that wishes to modify the resulting Document must clone it first.

create

public Infoset<XMLReader> create(InputStream input)
Creates an infoset that will, when accessed, parse the content from the provided InputStream. Once parsed, the content will be cached, so anything that wishes to modify the resulting Document must clone it first.

newInstance

public static SaxInfosetFactory newInstance()