public ISAAC Copy() { ISAAC newCopy = new ISAAC(null); newCopy.SetInternalState(offset, a, b, c, mm, randRsl, ancestry); return(newCopy); }
private void SetInternalState(uint offset, uint a, uint b, uint c, uint[] mm, uint[] randRsl, System.Collections.Generic.Queue <ISAAC> ancestry) { SetInternalState(offset, a, b, c, mm, randRsl); var g = ancestry.ToArray(); var f = new ISAAC[g.Length]; Array.Copy(g, f, g.Length); this.ancestry = new System.Collections.Generic.Queue <ISAAC>(f); }
public CryptoSystem(byte[] seed) { if (seed == null) { throw new ArgumentNullException("seed can not be null"); } if (seed.Length != 4) { throw new ArgumentOutOfRangeException("seed length is wrong"); } Wheel = new ISAAC(seed); }