com.ctc.wstx.stax
Class ValidatingInputFactory

java.lang.Object
  extended bycom.ctc.wstx.stax.MinimalInputFactory
      extended bycom.ctc.wstx.stax.ValidatingInputFactory
All Implemented Interfaces:
InputConfigFlags, ReaderCreator

public final class ValidatingInputFactory
extends MinimalInputFactory

Input factory that contains full set of cursor API functionality, including full DTD handling. It does not contain Event API, which means that this is a subset of full StAX specification; subset that is useful if event API is not needed. It builds on top of MinimalInputFactory, basically just adding the connecting code to use real DTD handling implementation.

See Also:
MinimalInputFactory

Field Summary
protected  SimpleCache mDTDCache
           
 
Fields inherited from class com.ctc.wstx.stax.MinimalInputFactory
mConfig, mIsMinimal
 
Fields inherited from interface com.ctc.wstx.cfg.InputConfigFlags
CFG_CACHE_DTDS, CFG_COALESCE_TEXT, CFG_INTERN_NS_URIS, CFG_LAZY_PARSING, CFG_NAMESPACE_AWARE, CFG_NORMALIZE_ATTR_VALUES, CFG_NORMALIZE_LFS, CFG_PRESERVE_LOCATION, CFG_REPLACE_ENTITY_REFS, CFG_REPORT_ALL_TEXT_AS_CHARACTERS, CFG_REPORT_PROLOG_WS, CFG_SUPPORT_DTD, CFG_SUPPORT_DTDPP, CFG_SUPPORT_EXTERNAL_ENTITIES, CFG_VALIDATE_AGAINST_DTD, CFG_VALIDATE_TEXT_CHARS, CONTENT_ALLOW_DTD_ANY, CONTENT_ALLOW_MIXED, CONTENT_ALLOW_NON_MIXED, CONTENT_ALLOW_NONE, CONTENT_ALLOW_UNDEFINED
 
Constructor Summary
ValidatingInputFactory()
           
 
Method Summary
 void addCachedDTD(DTDId id, DTDSubset extSubset)
           
protected  javax.xml.stream.XMLStreamReader doCreateSR(BranchingReaderSource input, ReaderConfig cfg, InputBootstrapper bs)
           
 DTDSubset findCachedDTD(DTDId id)
          Method readers created by this factory call, if DTD caching is enabled, to see if an external DTD (subset) has been parsed and cached earlier.
static void main(java.lang.String[] args)
           
static ValidatingInputFactory newValidatingInstance()
          Need to add this method, since we have no base class to do it...
 
Methods inherited from class com.ctc.wstx.stax.MinimalInputFactory
createXMLStreamReader, createXMLStreamReader, createXMLStreamReader, createXMLStreamReader, createXMLStreamReader, createXMLStreamReader, getConfig, getProperty, getXMLReporter, getXMLResolver, isPropertySupported, newMinimalInstance, setProperty, setXMLReporter, setXMLResolver, updateSymbolTable
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

mDTDCache

protected SimpleCache mDTDCache
Constructor Detail

ValidatingInputFactory

public ValidatingInputFactory()
Method Detail

newValidatingInstance

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


findCachedDTD

public DTDSubset findCachedDTD(DTDId id)
Method readers created by this factory call, if DTD caching is enabled, to see if an external DTD (subset) has been parsed and cached earlier.

Specified by:
findCachedDTD in interface ReaderCreator
Overrides:
findCachedDTD in class MinimalInputFactory

addCachedDTD

public void addCachedDTD(DTDId id,
                         DTDSubset extSubset)
Specified by:
addCachedDTD in interface ReaderCreator
Overrides:
addCachedDTD in class MinimalInputFactory

doCreateSR

protected javax.xml.stream.XMLStreamReader doCreateSR(BranchingReaderSource input,
                                                      ReaderConfig cfg,
                                                      InputBootstrapper bs)
                                               throws java.io.IOException,
                                                      javax.xml.stream.XMLStreamException
Overrides:
doCreateSR in class MinimalInputFactory
Throws:
java.io.IOException
javax.xml.stream.XMLStreamException

main

public static void main(java.lang.String[] args)
                 throws java.lang.Exception
Throws:
java.lang.Exception