Interface ReplicationContentFactory


  • public interface ReplicationContentFactory
    Implements a factory that creates replication content.
    • Method Detail

      • create

        ReplicationContent create​(String mimeType,
                                  File file,
                                  boolean isTemp)
                           throws IOException
        Creates binary replication content for the given file. note we cannot use the last modified of the file, since it's low precision.
        Parameters:
        mimeType - the mime type of the content
        file - the file containing the data
        isTemp - if true file is temporary file and will be removed after this call.
        Returns:
        the replication content
        Throws:
        IOException - if an error occurs
      • create

        ReplicationContent create​(String mimeType,
                                  File file,
                                  long lastModified,
                                  boolean isTemp)
                           throws IOException
        Creates binary replication content for the given file. note we cannot use the last modified of the file, since it's low precision.
        Parameters:
        mimeType - the mime type of the content
        file - the file containing the data
        lastModified - the last modified time in ms.
        isTemp - if true file is temporary file and will be removed after this call.
        Returns:
        the replication content
        Throws:
        IOException - if an error occurs
      • close

        void close()
        Closes this factory and releases all allocated resources.
        Since:
        5.4