public override bool Equals(object obj) { AllowedFastMessage msg = obj as AllowedFastMessage; if (msg == null) { return(false); } return(this.pieceIndex == msg.pieceIndex); }
protected virtual void HandleAllowedFastMessage(PeerId id, AllowedFastMessage message) { if (!Manager.Bitfield[message.PieceIndex]) id.IsAllowedFastPieces.Add(message.PieceIndex); }
protected override void HandleAllowedFastMessage(PeerId id, AllowedFastMessage message) { // Disregard these when in metadata mode as we can't request regular pieces anyway }