Class AbstractDocumentComparator

    • Constructor Detail

      • AbstractDocumentComparator

        public AbstractDocumentComparator()
    • Method Detail

      • compare

        public final void compare​(String sid,
                                  File original,
                                  File modified,
                                  File target)
                           throws IOException
        Description copied from interface: DocumentComparator
        Performs the comparison
        Specified by:
        compare in interface DocumentComparator
        Parameters:
        sid - identifier of the session
        original - The original file
        modified - The modified file
        target - The comparison output as PDF file
        Throws:
        IOException - error writing the temporary files or in the comparation
      • compare

        public final void compare​(String sid,
                                  com.logicaldoc.core.document.Version originalVersion,
                                  com.logicaldoc.core.document.Version modifiedVersion,
                                  File dest)
                           throws IOException,
                                  com.logicaldoc.core.PersistenceException
        Description copied from interface: DocumentComparator
        Performs the comparison
        Specified by:
        compare in interface DocumentComparator
        Parameters:
        sid - The actual Session ID
        originalVersion - The original version
        modifiedVersion - The modified version
        dest - The comparison output as PDF file
        Throws:
        IOException - error writing the temporary files or in the comparation
        com.logicaldoc.core.PersistenceException
      • setEnabled

        public void setEnabled​(boolean enabled)
        Description copied from interface: DocumentComparator
        Enables or disables the comparator
        Specified by:
        setEnabled in interface DocumentComparator
        Parameters:
        enabled - the new enabled status
      • getParameterNames

        public List<String> getParameterNames()
        Description copied from interface: DocumentComparator
        Implementations should return the list of the required parameters. A parameter is stored in the context as comparator.SimpleClassName.parameter = value
        Specified by:
        getParameterNames in interface DocumentComparator
        Returns:
        the list of configuration parameters
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object