org.apache.jackrabbit.server.io
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 Summary
 void addIOHandler(IOHandler ioHandler)
          Adds the specified handler to the list of handlers.
 boolean exportContent(ExportContext context, boolean isCollection)
          Passes the specified information to the IOHandlers present on this manager.
 boolean exportContent(ExportContext context, DavResource resource)
          Passes the specified information to the IOHandlers present on this manager.
 org.apache.tika.detect.Detector getDetector()
          Return the configured type detector.
 IOHandler[] getIOHandlers()
          Returns all handlers that have been added to this manager.
 boolean importContent(ImportContext context, boolean isCollection)
          Passes the specified context and boolean value to the IOHandlers present on this manager.
 boolean importContent(ImportContext context, DavResource resource)
          Passes the specified information to the IOHandlers present on this manager.
 void setDetector(org.apache.tika.detect.Detector detector)
          Sets the configured type detector.
 

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 incidates 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 incidates 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 incidates 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 incidates 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)


Copyright © 2004-2010 The Apache Software Foundation. All Rights Reserved.