/// <summary> /// Compare this object instance with another /// </summary> /// /// <param name="Obj">Object to compare</param> /// /// <returns>True if equal, otherwise false</returns> public override bool Equals(Object Obj) { if (this == Obj) { return(true); } if (Obj == null) { return(false); } NTRUParameters other = (NTRUParameters)Obj; if (N != other.N) { return(false); } if (BufferLenBits != other.BufferLenBits) { return(false); } if (_bufferLenTrits != other._bufferLenTrits) { return(false); } if (CBits != other.CBits) { return(false); } if (Db != other.Db) { return(false); } if (DF != other.DF) { return(false); } if (DF1 != other.DF1) { return(false); } if (DF2 != other.DF2) { return(false); } if (DF3 != other.DF3) { return(false); } if (Dg != other.Dg) { return(false); } if (Dm0 != other.Dm0) { return(false); } if (MaxM1 != other.MaxM1) { return(false); } if (DR != other.DR) { return(false); } if (DR1 != other.DR1) { return(false); } if (DR2 != other.DR2) { return(false); } if (DR3 != other.DR3) { return(false); } if (FastFp != other.FastFp) { return(false); } if (!Digest.Equals(other.Digest)) { return(false); } if (!RandomEngine.Equals(other.RandomEngine)) { return(false); } if (HashSeed != other.HashSeed) { return(false); } if (Length != other.Length) { return(false); } if (MessageMax != other.MessageMax) { return(false); } if (MinMGFHashCalls != other.MinMGFHashCalls) { return(false); } if (MinIGFHashCalls != other.MinIGFHashCalls) { return(false); } if (!Compare.AreEqual(OId, other.OId)) { return(false); } if (PkLen != other.PkLen) { return(false); } if (!PolyType.Equals(other.PolyType)) { return(false); } if (Q != other.Q) { return(false); } if (Sparse != other.Sparse) { return(false); } return(true); }