Class DOMDocumentFactoryBean

java.lang.Object
net.shibboleth.shared.spring.factory.DOMDocumentFactoryBean
All Implemented Interfaces:
FactoryBean<Document>

public class DOMDocumentFactoryBean extends Object implements FactoryBean<Document>
Spring bean factory for producing a Document from a resource.
  • Field Details

    • resource

      @Nullable private Resource resource
      Resource to load the document from.
    • parserPool

      @Nullable private ParserPool parserPool
      Parser pool to use when parsing the document.
    • document

      @Nullable private Document document
      Resulting Document.
  • Constructor Details

    • DOMDocumentFactoryBean

      public DOMDocumentFactoryBean()
  • Method Details

    • setResource

      public void setResource(@Nonnull Resource domResource)
      Sets the resource containing the document to be parsed.
      Parameters:
      domResource - resource, never null
    • setParserPool

      public void setParserPool(@Nonnull ParserPool pool)
      Sets the parser pool to be used to parse the file.
      Parameters:
      pool - parser pool, never null.
    • getObject

      @Nonnull public Document getObject() throws Exception
      Specified by:
      getObject in interface FactoryBean<Document>
      Throws:
      Exception
    • getObjectType

      @Nonnull public Class<?> getObjectType()
      Specified by:
      getObjectType in interface FactoryBean<Document>
    • isSingleton

      public boolean isSingleton()
      Specified by:
      isSingleton in interface FactoryBean<Document>