public Buffer Reply(PeerAddress sender, Buffer requestBuffer, bool complete) { int i = requestBuffer.BackingBuffer.ReadInt(); Console.WriteLine("Got {0}.", i); var buffer = AlternativeCompositeByteBuf.CompBuffer().WriteInt(i); return(new Buffer(buffer)); }
public Buffer Reply(PeerAddress sender, Buffer requestBuffer, bool complete) { Console.WriteLine("{0}.", ++_counter); Console.WriteLine("Request from {0}.", sender); Console.WriteLine("Buffer Size : {0}", Convenient.ToHumanReadable(requestBuffer.Length)); // server returns just OK if same buffer is returned return requestBuffer; }
public Buffer Reply(PeerAddress sender, Buffer requestBuffer, bool complete) { Console.WriteLine("{0}.", ++_counter); Console.WriteLine("Request from {0}.", sender); Console.WriteLine("Buffer Size : {0}", Convenient.ToHumanReadable(requestBuffer.Length)); // server returns just OK if same buffer is returned return(requestBuffer); }
public Buffer Reply(PeerAddress sender, Buffer requestBuffer, bool complete) { return(CreateTestBuffer()); }
public Buffer Reply(PeerAddress sender, Buffer requestBuffer, bool complete) { int i = requestBuffer.BackingBuffer.ReadInt(); Console.WriteLine("Got {0}.", i); var buffer = AlternativeCompositeByteBuf.CompBuffer().WriteInt(i); return new Buffer(buffer); }
public Buffer Reply(PeerAddress sender, Buffer requestBuffer, bool complete) { return CreateTestBuffer(); }
public SendDirectBuilder SetBuffer(Buffer buffer) { Buffer = buffer; return(this); }