|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface XMLFactory
Interface that provides access to classes that facilitate the processing of XML related operations.
Nested Class Summary | |
---|---|
static class |
XMLFactory.XSLT_PROCESSOR
Specification of the kind of XSLT processor to be used |
Field Summary | |
---|---|
static java.lang.String |
ATTR_CLASS
name of the class attribute used for instantiation |
static java.lang.String |
DEFAULT_EXTENSION_ID
ID of the XLM Factory default extension |
static java.lang.String |
EXTENSION_POINT_ID
ID of the XLM Factory extension point |
Method Summary | |
---|---|
org.xml.sax.ContentHandler |
createContentHandler(XMLStreamHandler handler)
Create a ContentHandler that dispatches to an
XMLStreamHandler |
DefaultContentHandler |
createDefaultContentHandler()
Creates a default content handler that can be attached with different target ContentHandler implementations |
DefaultContentHandler |
createDefaultContentHandler(org.xml.sax.ContentHandler aHandler)
Creates a default content handler that can be attached with different target ContentHandler implementations and automatically
associates it with a handler |
DefaultContentHandler |
createDefaultContentHandler(ResettableContentHandler aHandler)
Creates a default content handler that can be attached with different target ContentHandler implementations. |
DocumentTypeDefinition |
createDocumentTypeDefinition(java.lang.String publicID,
java.lang.String systemID)
Parses the specified DTD into a DocumentTypeDefinition structure |
org.xml.sax.ContentHandler |
createHeadContentHandler(javax.portlet.RenderResponse response)
Constructs a ContentHandler that creates head contributions for a
portlet. |
org.xml.sax.XMLReader |
createHTMLReader()
Constructs an XMLReader that parses HTML content and converts it
into XHTML SAX events |
org.xml.sax.XMLReader |
createHTMLReader(org.xml.sax.ContentHandler handler)
Constructs an XMLReader that parses HTML content and converts it
into XHTML SAX events |
javax.xml.transform.sax.SAXTransformerFactory |
createSAXTransformerFactory(java.lang.Boolean bForceXSLTC)
Creates a new transformer factory based on the XSLTC flag |
javax.xml.transform.Source |
createSource(XMLProducer aProducer)
Constructs a Source object on top of a XMLProducer . |
StreamContentHandler |
createStreamContentHandler()
Constructs a new StreamContentHandler |
StreamContentHandler |
createStreamContentHandler(boolean bAllowCDATASections)
Constructs a new StreamContentHandler |
StreamContentHandler |
createStreamContentHandler(java.io.OutputStream out)
Constructs a new StreamContentHandler |
StreamContentHandler |
createStreamContentHandler(java.io.OutputStream out,
boolean bAllowCDATASections)
Constructs a new StreamContentHandler |
StreamContentHandler |
createStreamContentHandler(java.io.Writer out)
Constructs a new StreamContentHandler |
StreamContentHandler |
createStreamContentHandler(java.io.Writer out,
boolean bAllowCDATASections)
Constructs a new StreamContentHandler |
javax.xml.transform.Templates |
createTemplates()
Creates a template for the identitiy transformation |
javax.xml.transform.Templates |
createTemplates(java.lang.Boolean bForceXSLTC)
Deprecated. use createTemplates(XSLT_PROCESSOR) |
javax.xml.transform.Templates |
createTemplates(javax.xml.transform.Source src)
Creates an XSLTC template using the default processor |
javax.xml.transform.Templates |
createTemplates(javax.xml.transform.Source src,
java.lang.Boolean bForceXSLTC)
Deprecated. use createTemplates(Source, XSLT_PROCESSOR) instead |
javax.xml.transform.Templates |
createTemplates(javax.xml.transform.Source src,
XMLFactory.XSLT_PROCESSOR type)
Creates an XSLTC template |
javax.xml.transform.Templates |
createTemplates(XMLFactory.XSLT_PROCESSOR type)
Creates a template for the identitiy transformation |
javax.xml.transform.TransformerFactory |
createTransformerFactory()
Creates a new transformer factory using the default processor |
javax.xml.transform.TransformerFactory |
createTransformerFactory(java.lang.Boolean bForceXSLTC)
Deprecated. use createTransformerFactory(XSLT_PROCESSOR) instead |
javax.xml.transform.TransformerFactory |
createTransformerFactory(XMLFactory.XSLT_PROCESSOR type)
Creates a new transformer factory based on the processor tyoe |
javax.xml.transform.sax.TransformerHandler |
createTransformerHandler(javax.xml.transform.Source aTemplates,
java.lang.Boolean bForceXSLTC)
Constructs a handler that transforms SAX events via an XSLT |
javax.xml.transform.sax.TransformerHandler |
createTransformerHandler(javax.xml.transform.Templates aTemplates,
java.lang.Boolean bForceXSLTC)
Constructs a handler that transforms SAX events via an XSLT |
ResolverContentHandler |
createXMLBaseContentHandler()
Creates a content handler that listens to the xml:base attributes and that is able to resolve URLs in the context of these base tags. |
ResolverContentHandler |
createXMLBaseContentHandler(org.xml.sax.ContentHandler aDelegate)
Creates a content handler that listens to the xml:base attributes and that is able to resolve URLs in the context of these base tags. |
ResolverContentHandler |
createXMLBaseContentHandler(ResettableContentHandler aHandler)
Creates an ContentHandler that keeps track of "xml:base"
attributes to compute absolute URLs from relative URLs. |
ResolverXMLFilter |
createXMLBaseFilter()
Creates an XMLFilter that keeps track of "xml:base"
attributes to compute absolute URLs from relative URLs. |
ResolverXMLFilter |
createXMLBaseFilter(org.xml.sax.XMLReader parent)
Creates an XMLFilter that keeps track of "xml:base"
attributes to compute absolute URLs from relative URLs. |
XMLOutputStream |
createXMLOutputStream()
Creates an XMLOutputStream that can be used to convert a byte
stream into ContentHandler callbacks. |
XMLOutputStream |
createXMLOutputStream(org.xml.sax.ContentHandler handler)
Creates an XMLOutputStream that can be used to convert a byte
stream into ContentHandler callbacks. |
XMLProducer |
createXMLProducer(javax.xml.transform.Source aSource)
Construct wrapper that represents a Source as a
XMLProducer . |
org.xml.sax.XMLReader |
createXMLReader()
Creates an XMLReader object based on the standard SAX factories. |
org.xml.sax.XMLReader |
createXMLReader(XMLOutputStream aStream)
Creates an XMLReader object that wraps an XMLOutputStream |
XMLRecorder |
createXMLRecorder()
Creates an object that can record SAX callbacks and that can then playback this sequence to another handler at a later point in tisme. |
XMLRecorder |
createXMLRecorder(int bufferSize)
Creates an object that can record SAX callbacks and that can then playback this sequence to another handler at a later point in time. |
XMLStreamHandler |
createXMLStreamHandler(java.io.Writer aOut,
java.lang.String aMethod)
Constructs a serializer that can produce XML, XHTML or HTML markup |
XMLWriter |
createXMLWriter()
Creates an XMLWriter that can be used to convert a character
stream into ContentHandler callbacks. |
XMLWriter |
createXMLWriter(org.xml.sax.ContentHandler handler)
Creates an XMLWriter that can be used to convert a character
stream into ContentHandler callbacks. |
org.xml.sax.EntityResolver |
getEntityResolver()
Returns an entity resolver that supports entities for HTML XHTML SVG MATHML |
javax.xml.transform.URIResolver |
getURIResolver()
Returns a default URI resolver |
Field Detail |
---|
static final java.lang.String ATTR_CLASS
static final java.lang.String DEFAULT_EXTENSION_ID
static final java.lang.String EXTENSION_POINT_ID
Method Detail |
---|
org.xml.sax.ContentHandler createContentHandler(XMLStreamHandler handler) throws org.xml.sax.SAXException, java.io.IOException
ContentHandler
that dispatches to an
XMLStreamHandler
handler
- target handler, not null
org.xml.sax.SAXException
java.io.IOException
DefaultContentHandler createDefaultContentHandler() throws org.xml.sax.SAXException
ContentHandler
implementations
org.xml.sax.SAXException
- - if the handler could not be constructedDefaultContentHandler createDefaultContentHandler(org.xml.sax.ContentHandler aHandler) throws org.xml.sax.SAXException
ContentHandler
implementations and automatically
associates it with a handler
aHandler
- handler that will directly be connected
org.xml.sax.SAXException
- - if the handler could not be constructedDefaultContentHandler createDefaultContentHandler(ResettableContentHandler aHandler) throws org.xml.sax.SAXException
ContentHandler
implementations. This handler will be part
of the chain defined by the aHandler parameter
aHandler
- handler that will directly be connected
org.xml.sax.SAXException
- - if the handler could not be constructedDocumentTypeDefinition createDocumentTypeDefinition(java.lang.String publicID, java.lang.String systemID) throws org.xml.sax.SAXException, java.io.IOException
DocumentTypeDefinition
structure
publicID
- the publicIDsystemID
- the systemID
org.xml.sax.SAXException
java.io.IOException
org.xml.sax.ContentHandler createHeadContentHandler(javax.portlet.RenderResponse response)
ContentHandler
that creates head contributions for a
portlet. The class is meant to be used in the
PortletRequest.RENDER_HEADERS
phase of the portlet. We assume
that the content starts with a Constants#ELEMENT_HEAD
element,
this element will be ignored. All valid children of the head element will
be added to the response.
response
- the response during the header phase
org.xml.sax.XMLReader createHTMLReader()
XMLReader
that parses HTML content and converts it
into XHTML SAX events
null
org.xml.sax.XMLReader createHTMLReader(org.xml.sax.ContentHandler handler)
XMLReader
that parses HTML content and converts it
into XHTML SAX events
handler
- handler to assign to the reader
null
javax.xml.transform.sax.SAXTransformerFactory createSAXTransformerFactory(java.lang.Boolean bForceXSLTC) throws javax.xml.transform.TransformerFactoryConfigurationError
bForceXSLTC
- the method tries to create the XSLTC version of the
transformer template, if set to false it uses the system
default. If null it uses the most efficient version that is
available in the system automatically
ErrorListener
is registered with the TransformerFactory,
in which case an exception error sends an error message to the
ErrorListener and returns null).
javax.xml.transform.TransformerFactoryConfigurationError
- if the implmentation is not available or cannot be
instantiated.javax.xml.transform.Source createSource(XMLProducer aProducer)
Source
object on top of a XMLProducer
.
aProducer
- the producer, not null
StreamContentHandler createStreamContentHandler() throws org.xml.sax.SAXException
StreamContentHandler
org.xml.sax.SAXException
StreamContentHandler createStreamContentHandler(boolean bAllowCDATASections) throws org.xml.sax.SAXException
StreamContentHandler
bAllowCDATASections
- flag to indicate if the serialized can produce CDATA sections
to escape markup or if it should rather use entity references
org.xml.sax.SAXException
StreamContentHandler createStreamContentHandler(java.io.OutputStream out) throws org.xml.sax.SAXException
StreamContentHandler
org.xml.sax.SAXException
StreamContentHandler createStreamContentHandler(java.io.OutputStream out, boolean bAllowCDATASections) throws org.xml.sax.SAXException
StreamContentHandler
out
- the writer to serialize tobAllowCDATASections
- flag to indicate if the serialized can produce CDATA sections
to escape markup or if it should rather use entity references
org.xml.sax.SAXException
StreamContentHandler createStreamContentHandler(java.io.Writer out) throws org.xml.sax.SAXException
StreamContentHandler
org.xml.sax.SAXException
StreamContentHandler createStreamContentHandler(java.io.Writer out, boolean bAllowCDATASections) throws org.xml.sax.SAXException
StreamContentHandler
out
- the stream to serialize tobAllowCDATASections
- flag to indicate if the serialized can produce CDATA sections
to escape markup or if it should rather use entity references
org.xml.sax.SAXException
javax.xml.transform.Templates createTemplates() throws javax.xml.transform.TransformerConfigurationException
javax.xml.transform.TransformerConfigurationException
@Deprecated javax.xml.transform.Templates createTemplates(java.lang.Boolean bForceXSLTC) throws javax.xml.transform.TransformerConfigurationException
createTemplates(XSLT_PROCESSOR)
bForceXSLTC
- the method tries to create the XSLTC version of the
transformer template, if set to false it uses the system
default. If null it uses the most efficient version that is
available in the system automatically
javax.xml.transform.TransformerConfigurationException
javax.xml.transform.Templates createTemplates(javax.xml.transform.Source src) throws javax.xml.transform.TransformerConfigurationException
src
- source for the templates
javax.xml.transform.TransformerConfigurationException
@Deprecated javax.xml.transform.Templates createTemplates(javax.xml.transform.Source src, java.lang.Boolean bForceXSLTC) throws javax.xml.transform.TransformerConfigurationException
createTemplates(Source, XSLT_PROCESSOR)
instead
src
- source for the templatesbForceXSLTC
- the method tries to create the XSLTC version of the
transformer template, if set to false it uses the system
default. If null it uses the most efficient version that is
available in the system automatically
javax.xml.transform.TransformerConfigurationException
javax.xml.transform.Templates createTemplates(javax.xml.transform.Source src, XMLFactory.XSLT_PROCESSOR type) throws javax.xml.transform.TransformerConfigurationException
src
- source for the templatestype
- type of the processor to be used
javax.xml.transform.TransformerConfigurationException
javax.xml.transform.Templates createTemplates(XMLFactory.XSLT_PROCESSOR type) throws javax.xml.transform.TransformerConfigurationException
type
- type of the processor to be used
javax.xml.transform.TransformerConfigurationException
javax.xml.transform.TransformerFactory createTransformerFactory() throws javax.xml.transform.TransformerFactoryConfigurationError
ErrorListener
is registered with the TransformerFactory,
in which case an exception error sends an error message to the
ErrorListener and returns null).
javax.xml.transform.TransformerFactoryConfigurationError
- if the implmentation is not available or cannot be
instantiated.@Deprecated javax.xml.transform.TransformerFactory createTransformerFactory(java.lang.Boolean bForceXSLTC) throws javax.xml.transform.TransformerFactoryConfigurationError
createTransformerFactory(XSLT_PROCESSOR)
instead
bForceXSLTC
- the method tries to create the XSLTC version of the
transformer template, if set to false it uses the system
default. If null it uses the most efficient version that is
available in the system automatically
ErrorListener
is registered with the TransformerFactory,
in which case an exception error sends an error message to the
ErrorListener and returns null).
javax.xml.transform.TransformerFactoryConfigurationError
- if the implmentation is not available or cannot be
instantiated.javax.xml.transform.TransformerFactory createTransformerFactory(XMLFactory.XSLT_PROCESSOR type) throws javax.xml.transform.TransformerFactoryConfigurationError
type
- type of the processor to be used
ErrorListener
is registered with the TransformerFactory,
in which case an exception error sends an error message to the
ErrorListener and returns null).
javax.xml.transform.TransformerFactoryConfigurationError
- if the implmentation is not available or cannot be
instantiated.javax.xml.transform.sax.TransformerHandler createTransformerHandler(javax.xml.transform.Source aTemplates, java.lang.Boolean bForceXSLTC) throws javax.xml.transform.TransformerConfigurationException
aTemplates
- the source for the templatesbForceXSLTC
- the method tries to create the XSLTC version of the
transformer template, if set to false it uses the system
default. If null it uses the most efficient version that is
available in the system automatically
javax.xml.transform.TransformerConfigurationException
javax.xml.transform.sax.TransformerHandler createTransformerHandler(javax.xml.transform.Templates aTemplates, java.lang.Boolean bForceXSLTC) throws javax.xml.transform.TransformerConfigurationException
aTemplates
- the templatesbForceXSLTC
- the method tries to create the XSLTC version of the
transformer template, if set to false it uses the system
default. If null it uses the most efficient version that is
available in the system automatically
javax.xml.transform.TransformerConfigurationException
ResolverContentHandler createXMLBaseContentHandler() throws org.xml.sax.SAXException
org.xml.sax.SAXException
- - if the handler could not be constructedResolverContentHandler createXMLBaseContentHandler(org.xml.sax.ContentHandler aDelegate) throws org.xml.sax.SAXException
aDelegate
- handler to dispatch to
org.xml.sax.SAXException
- - if the handler could not be constructedResolverContentHandler createXMLBaseContentHandler(ResettableContentHandler aHandler) throws org.xml.sax.SAXException
ContentHandler
that keeps track of "xml:base"
attributes to compute absolute URLs from relative URLs.
aHandler
- next element in the handler chain. This next element will
receive all SAX events that were initially thrown on the
handler
ResettableContentHandler
as the next element in the
handler chain
org.xml.sax.SAXException
- - if the handler could not be constructedResolverXMLFilter createXMLBaseFilter() throws org.xml.sax.SAXException
XMLFilter
that keeps track of "xml:base"
attributes to compute absolute URLs from relative URLs.
ResolverXMLFilter
that is associated
with a default XMLReader
.
org.xml.sax.SAXException
- - if the filter could not be constructedResolverXMLFilter createXMLBaseFilter(org.xml.sax.XMLReader parent) throws org.xml.sax.SAXException
XMLFilter
that keeps track of "xml:base"
attributes to compute absolute URLs from relative URLs.
parent
- the XMLReader
instance that is used as the basis for
the SAX events
ResolverXMLFilter
that is associated
with the specified XMLReader
.
org.xml.sax.SAXException
- - if the filter could not be constructedXMLOutputStream createXMLOutputStream() throws org.xml.sax.SAXException
XMLOutputStream
that can be used to convert a byte
stream into ContentHandler
callbacks. The stream returned by this
call is NOT initialized, make sure to assign a content handler via
XMLOutputStream#setContentHandler(ContentHandler)
and to
initialize the stream for parsing by calling
XMLOutputStream#reset()
.
XMLOutputStream
org.xml.sax.SAXException
- - if the filter could not be constructedXMLOutputStream createXMLOutputStream(org.xml.sax.ContentHandler handler) throws org.xml.sax.SAXException, java.io.IOException
XMLOutputStream
that can be used to convert a byte
stream into ContentHandler
callbacks. The stream is initialized
with the given content handler and also ready for parsing.
handler
- content handler to throw the SAX events to
XMLOutputStream
org.xml.sax.SAXException
- - if the filter could not be constructed
java.io.IOException
XMLProducer createXMLProducer(javax.xml.transform.Source aSource) throws org.xml.sax.SAXException, java.io.IOException
Source
as a
XMLProducer
.
aSource
- the source, not null
org.xml.sax.SAXException
java.io.IOException
org.xml.sax.XMLReader createXMLReader() throws org.xml.sax.SAXException
XMLReader
object based on the standard SAX factories.
The resulting reader is configured for secure xml processing
XMLConstants.FEATURE_SECURE_PROCESSING
.
org.xml.sax.SAXException
org.xml.sax.XMLReader createXMLReader(XMLOutputStream aStream) throws org.xml.sax.SAXException
XMLReader
object that wraps an XMLOutputStream
org.xml.sax.SAXException
XMLRecorder createXMLRecorder() throws java.io.IOException
java.io.IOException
XMLRecorder createXMLRecorder(int bufferSize) throws java.io.IOException
bufferSize
- size of the string buffer used for xml characters
java.io.IOException
XMLStreamHandler createXMLStreamHandler(java.io.Writer aOut, java.lang.String aMethod) throws java.io.IOException
aOut
- target writer, not null
aMethod
- the output method, default is "XML"
null
java.io.IOException
XMLWriter createXMLWriter() throws org.xml.sax.SAXException
XMLWriter
that can be used to convert a character
stream into ContentHandler
callbacks. The stream returned by this
call is NOT initialized, make sure to assign a content handler via
XMLOutputStream#setContentHandler(ContentHandler)
and to
initialize the stream for parsing by calling
XMLOutputStream#reset()
.
XMLWriter
org.xml.sax.SAXException
- - if the filter could not be constructedXMLWriter createXMLWriter(org.xml.sax.ContentHandler handler) throws org.xml.sax.SAXException, java.io.IOException
XMLWriter
that can be used to convert a character
stream into ContentHandler
callbacks. The stream is initialized
with the given content handler and also ready for parsing.
handler
- content handler to throw the SAX events to
XMLWriter
org.xml.sax.SAXException
- - if the filter could not be constructed
java.io.IOException
org.xml.sax.EntityResolver getEntityResolver()
null
http://www.w3.org/QA/2002/04/valid-dtd-list.html
javax.xml.transform.URIResolver getURIResolver()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |