Hashsig.create AsyncExperimental

Hashsig.create(buf, buflen, opts).then(function(hashsig) {
  // Use hashsig
});
Parameters Type  
buf String The input buffer.
buflen Number The input buffer size.
opts Number The signature computation options (see above).
Returns  
Hashsig The computed similarity signature.

Hashsig.createFromFile AsyncExperimental

Hashsig.createFromFile(path, opts).then(function(hashsig) {
  // Use hashsig
});
Parameters Type  
path String The path to the input file.
opts Number The signature computation options (see above).
Returns  
Hashsig The computed similarity signature.

Hashsig#compare SyncExperimental

var result = hashsig.compare(b);
Parameters Type  
b Hashsig The second similarity signature to compare.
Returns  
Number [0 to 100] on success as the similarity score, or error code.

Hashsig.OPTION ENUM

Flag Value
Hashsig.OPTION.NORMAL 0
Hashsig.OPTION.IGNORE_WHITESPACE 1
Hashsig.OPTION.SMART_WHITESPACE 2
Hashsig.OPTION.ALLOW_SMALL_FILES 4