Nebula
Interest

RegionSubscription

The shared arithmetic of the region-subscription protocol: a set's fingerprint.

generated from the sources
public static class RegionSubscription

The shared arithmetic of the region-subscription protocol: a set's fingerprint. The hash is a XOR of a strong per-region mix, so it does not depend on the order regions were added in — which is the point, since one end keeps a hash set and the other rebuilds it from deltas.

Methods

Mix

public static ulong Mix(ulong region);

SplitMix64 finalizer: spreads the packed grid coordinate, whose low bits move in lock-step.

Hash

public static ulong Hash(IEnumerable<ulong> regions);

Fingerprint of a whole set, for an audit or a test.

On this page