com.ctc.wstx.stax
Class MinimalOutputFactory

java.lang.Object
  extended by com.ctc.wstx.stax.MinimalOutputFactory
All Implemented Interfaces:
OutputConfigFlags

public final class MinimalOutputFactory
extends java.lang.Object
implements OutputConfigFlags

Minimalistic input factory, which implements the suggested J2ME subset of XMLOutputFactory API: basically just the cursor-based iteration, and classes it needs.

Unfortunately, the way StAX 1.0 is defined, this class can NOT be the base class of the full input factory, without getting references to most of StAX event classes. It does however have lots of shared (cut'n pasted code) with WstxOutputFactory. Hopefully in future this problem can be resolved.


Field Summary
protected  WriterConfig mConfig
           
protected  boolean mIsMinimal
          Flag used to distinguish "real" minimal implementations and extending non-minimal ones (currently there's such distinction for input factories, for minimal <= validating <= event-based, but not for ouput)
 
Fields inherited from interface com.ctc.wstx.cfg.OutputConfigFlags
CFG_AUTOMATIC_EMPTY_ELEMS, CFG_AUTOMATIC_NS, CFG_COPY_DEFAULT_ATTRS, CFG_ENABLE_NS, CFG_ESCAPE_CR, CFG_FIX_CONTENT, CFG_OUTPUT_CDATA_AS_TEXT, CFG_VALIDATE_ATTR, CFG_VALIDATE_CONTENT, CFG_VALIDATE_NAMES, CFG_VALIDATE_STRUCTURE
 
Constructor Summary
protected MinimalOutputFactory(boolean isMinimal)
           
 
Method Summary
 javax.xml.stream.XMLStreamWriter createXMLStreamWriter(java.io.OutputStream out)
           
 javax.xml.stream.XMLStreamWriter createXMLStreamWriter(java.io.OutputStream out, java.lang.String enc)
           
 javax.xml.stream.XMLStreamWriter createXMLStreamWriter(javax.xml.transform.Result result)
           
 javax.xml.stream.XMLStreamWriter createXMLStreamWriter(java.io.Writer w)
           
 javax.xml.stream.XMLStreamWriter createXMLStreamWriter(java.io.Writer w, java.lang.String enc)
           
 WriterConfig getConfig()
           
 java.lang.Object getProperty(java.lang.String name)
           
 boolean isPropertySupported(java.lang.String name)
           
static MinimalOutputFactory newMinimalInstance()
          Need to add this method, since we have no base class to do it...
 void setProperty(java.lang.String name, java.lang.Object value)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

mIsMinimal

protected final boolean mIsMinimal
Flag used to distinguish "real" minimal implementations and extending non-minimal ones (currently there's such distinction for input factories, for minimal <= validating <= event-based, but not for ouput)


mConfig

protected final WriterConfig mConfig
Constructor Detail

MinimalOutputFactory

protected MinimalOutputFactory(boolean isMinimal)
Method Detail

newMinimalInstance

public static MinimalOutputFactory newMinimalInstance()
Need to add this method, since we have no base class to do it...


createXMLStreamWriter

public javax.xml.stream.XMLStreamWriter createXMLStreamWriter(java.io.OutputStream out)
                                                       throws javax.xml.stream.XMLStreamException
Throws:
javax.xml.stream.XMLStreamException

createXMLStreamWriter

public javax.xml.stream.XMLStreamWriter createXMLStreamWriter(java.io.OutputStream out,
                                                              java.lang.String enc)
                                                       throws javax.xml.stream.XMLStreamException
Throws:
javax.xml.stream.XMLStreamException

createXMLStreamWriter

public javax.xml.stream.XMLStreamWriter createXMLStreamWriter(javax.xml.transform.Result result)
                                                       throws javax.xml.stream.XMLStreamException
Throws:
javax.xml.stream.XMLStreamException

createXMLStreamWriter

public javax.xml.stream.XMLStreamWriter createXMLStreamWriter(java.io.Writer w)
                                                       throws javax.xml.stream.XMLStreamException
Throws:
javax.xml.stream.XMLStreamException

createXMLStreamWriter

public javax.xml.stream.XMLStreamWriter createXMLStreamWriter(java.io.Writer w,
                                                              java.lang.String enc)
                                                       throws javax.xml.stream.XMLStreamException
Throws:
javax.xml.stream.XMLStreamException

getProperty

public java.lang.Object getProperty(java.lang.String name)

isPropertySupported

public boolean isPropertySupported(java.lang.String name)

setProperty

public void setProperty(java.lang.String name,
                        java.lang.Object value)

getConfig

public WriterConfig getConfig()