Interface IOManager

  • All Known Implementing Classes:
    DefaultIOManager, IOManagerImpl

    public interface IOManager
    IOManager interface provides the means to define a list of IOHandlers that should be asked to perform an import or export.
    • Method Detail

      • addIOHandler

        void addIOHandler​(IOHandler ioHandler)
        Adds the specified handler to the list of handlers.
        Parameters:
        ioHandler - to be added
      • getIOHandlers

        IOHandler[] getIOHandlers()
        Returns all handlers that have been added to this manager.
        Returns:
        Array of all handlers
      • getDetector

        org.apache.tika.detect.Detector getDetector()
        Return the configured type detector.
        Returns:
        content type detector
      • setDetector

        void setDetector​(org.apache.tika.detect.Detector detector)
        Sets the configured type detector.
        Parameters:
        detector - content type detector.
      • importContent

        boolean importContent​(ImportContext context,
                              boolean isCollection)
                       throws IOException
        Passes the specified context and boolean value to the IOHandlers present on this manager. As soon as the first handler indicates success the import should be considered completed. If none of the handlers can deal with the given information this method must return false.
        Parameters:
        context -
        isCollection -
        Returns:
        true if any of the handlers import the given context. False otherwise.
        Throws:
        IOException
        See Also:
        IOHandler.importContent(ImportContext, boolean)
      • importContent

        boolean importContent​(ImportContext context,
                              DavResource resource)
                       throws IOException
        Passes the specified information to the IOHandlers present on this manager. As soon as the first handler indicates success the import should be considered completed. If none of the handlers can deal with the given information this method must return false.
        Parameters:
        context -
        resource -
        Returns:
        true if any of the handlers import the information present on the specified context.
        Throws:
        IOException
        See Also:
        IOHandler.importContent(ImportContext, DavResource)
      • exportContent

        boolean exportContent​(ExportContext context,
                              boolean isCollection)
                       throws IOException
        Passes the specified information to the IOHandlers present on this manager. As soon as the first handler indicates success the export should be considered completed. If none of the handlers can deal with the given information this method must return false.
        Parameters:
        context -
        isCollection -
        Returns:
        true if any of the handlers could run the export successfully, false otherwise.
        Throws:
        IOException
        See Also:
        IOHandler.exportContent(ExportContext, boolean)
      • exportContent

        boolean exportContent​(ExportContext context,
                              DavResource resource)
                       throws IOException
        Passes the specified information to the IOHandlers present on this manager. As soon as the first handler indicates success the export should be considered completed. If none of the handlers can deal with the given information this method must return false.
        Parameters:
        context -
        resource -
        Returns:
        true if any of the handlers could run the export successfully, false otherwise.
        Throws:
        IOException
        See Also:
        IOHandler.exportContent(ExportContext, DavResource)