Class AbstractDocumentChecksummer<T extends BaseChecksummerConfig>
java.lang.Object
com.norconex.crawler.core.doc.operations.checksum.AbstractDocumentChecksummer<T>
- Type Parameters:
T- configurable type
- All Implemented Interfaces:
Configurable<T>,DocumentChecksummer
- Direct Known Subclasses:
Md5DocumentChecksummer
public abstract class AbstractDocumentChecksummer<T extends BaseChecksummerConfig>
extends Object
implements DocumentChecksummer, Configurable<T>
Abstract implementation of DocumentChecksummer giving the option
to keep the generated checksum in a metadata field.
The checksum can be stored
in a target field name specified. If no target field name is specified,
it stores it under the
metadata field name CrawlerDocMetaConstants.CHECKSUM_DOC.
Implementors do not need to store the checksum themselves, this abstract class does it.
toField is ignored unless the keep
attribute is set to true.
-
Field Summary
Fields inherited from interface com.norconex.commons.lang.config.Configurable
PROPERTY -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.norconex.commons.lang.config.Configurable
getConfiguration
-
Constructor Details
-
AbstractDocumentChecksummer
public AbstractDocumentChecksummer()
-
-
Method Details
-
createDocumentChecksum
Description copied from interface:DocumentChecksummerCreates a document checksum.- Specified by:
createDocumentChecksumin interfaceDocumentChecksummer- Parameters:
document- an HTTP document- Returns:
- a checksum value
-
doCreateDocumentChecksum
-
equals
-
canEqual
-
hashCode
public int hashCode() -
toString
-