Interface I_CmsIndexWriter

    • Method Detail

      • close

        void close()
            throws java.io.IOException
        Close this IndexWriter.

        Throws:
        java.io.IOException - thrown if the close action fails.
      • commit

        void commit()
             throws java.io.IOException
        Commit all previous operations.

        Throws:
        java.io.IOException - thrown if the commit action fails.
      • deleteDocument

        void deleteDocument​(CmsPublishedResource resource)
                     throws java.io.IOException
        Delete a document from the index.

        Parameters:
        resource - the resource to delete
        Throws:
        java.io.IOException - in case something goes wrong
      • optimize

        void optimize()
               throws java.io.IOException
        Optimizes the index.

        Please note that as of Lucene 3.5, the direct use of optimize is discouraged as Lucene apparently is now able to manage the file structure so efficiently that frequent optimizations are not longer required.

        Throws:
        java.io.IOException - thrown if the optimization fails.
      • updateDocument

        void updateDocument​(java.lang.String rootPath,
                            I_CmsSearchDocument document)
                     throws java.io.IOException
        Update a document in the index.

        Parameters:
        rootPath - the root path of the document to update
        document - the document to update
        Throws:
        java.io.IOException - in case something goes wrong