public ReliableBroadcast( ReliableBroadcastId broadcastId, IPublicConsensusKeySet wallet, IConsensusBroadcaster broadcaster) : base(wallet, broadcastId, broadcaster) { _broadcastId = broadcastId; _echoMessages = new ECHOMessage?[N]; _readyMessages = new ReadyMessage?[N]; _sentValMessage = new bool[N]; _requested = ResultStatus.NotRequested; _merkleTreeSize = N; while ((_merkleTreeSize & (_merkleTreeSize - 1)) != 0) { _merkleTreeSize++; // increment while not power of two } }
protected bool Equals(ReliableBroadcastId other) { return(SenderId == other.SenderId && Era == other.Era); }