Beispiel #1
0
        public override bool Equals(object o)
        {
            if (this == o)
            {
                return(true);
            }
            if (o == null || this.GetType() != o.GetType())
            {
                return(false);
            }
            BaseProtocolRequest that = ( BaseProtocolRequest )o;

            return(Objects.Equals(_protocolName, that._protocolName) && Objects.Equals(_versions, that._versions));
        }
Beispiel #2
0
 internal virtual void EncodeProtocolRequest <U>(BaseProtocolRequest <U> protocolRequest, System.Action <ByteBuf, U> writer) where U : IComparable <U>
 {
     StringMarshal.marshal(Out, protocolRequest.ProtocolName());
     Out.writeInt(protocolRequest.Versions().Count);
     protocolRequest.Versions().forEach(version => writer(Out, version));
 }