public RabinKarpHashEnumerator(string s, int blockSize, IHashCoefficientTable hasher) { _input = s; _blockSize = blockSize; _hasher = hasher; if (s.Length < _blockSize) { throw new ArgumentException("Block size cannot be smaller than input string length.", "blockSize"); } Reset(); }
public RabinKarpHash(int blockSize, IHashCoefficientTable hasher) { int b2n = 1; _n = blockSize; _hasher = hasher; for (int i = 0; i < _n; i++) { b2n *= _b; } _b2n = b2n; }
public RabinKarpHashEnumerable(string s, int blockSize, IHashCoefficientTable hasher) { _input = s; _blockSize = blockSize; _hasher = hasher; }