public int Hash(string input) { if (_isDisposed) { throw new ObjectDisposedException("HashServiceImpl disposed"); } return(MurmurHash.StringHash(input)); }
public static int HashFor(Address node) { // cluster node identifier is the host and port of the address; protocol and system is assumed to be the same if (!string.IsNullOrEmpty(node.Host) && node.Port.HasValue) { return(MurmurHash.StringHash(node.Host + ":" + node.Port.Value.ToString())); } else { throw new IllegalStateException("Unexpected address without host/port: " + node); } }
public ReplicatorActor(string replicaId, ReplicatorSettings settings) : this(MurmurHash.StringHash(replicaId), settings) { }
private ORSetKey <EntryId> Key(EntryId entityId) { var i = Math.Abs(MurmurHash.StringHash(entityId)) % NrOfKeys; return(_stateKeys[i]); }
public int GetPersistenceHash(string aggregateId) { return(MurmurHash.StringHash(aggregateId)); }
public int Murmur_string_hash() { return(MurmurHash.StringHash(testString)); }
public override int GetHashCode() => MurmurHash.StringHash(StreamId) ^ MurmurHash.StringHash(ReplicaId);