Class InputSourceFactory


  • public final class InputSourceFactory
    extends Object
    Factory class that creates instances of WstxInputSource to allow reading input from various sources.
    • Constructor Detail

      • InputSourceFactory

        public InputSourceFactory()
    • Method Detail

      • constructEntitySource

        public static ReaderSource constructEntitySource​(ReaderConfig cfg,
                                                         WstxInputSource parent,
                                                         String entityName,
                                                         InputBootstrapper bs,
                                                         String pubId,
                                                         SystemId sysId,
                                                         int xmlVersion,
                                                         Reader r)
        Parameters:
        parent -
        entityName - Name of the entity expanded to create this input source: null when source created for the (main level) external DTD subset entity.
        xmlVersion - Optional xml version identifier of the main parsed document. Currently only relevant for checking that XML 1.0 document does not include XML 1.1 external parsed entities. If unknown, no checks will be done.
      • constructCharArraySource

        public static WstxInputSource constructCharArraySource​(WstxInputSource parent,
                                                               String fromEntity,
                                                               char[] text,
                                                               int offset,
                                                               int len,
                                                               Location loc,
                                                               URL src)
        Factory method usually used to expand internal parsed entities; in which case context remains mostly the same.