void ProcessStoreMessage() { RequestStoreMessage request = RequestStoreMessage.Deserialize(ProtocolParser.ReadBytes(input)); ReplyStoreMessage reply = new ReplyStoreMessage(); localRepo.StoreMessage(request.Prefix, ChunkHash.FromHashBytes(request.ChunkHash)); ProtocolParser.WriteBytes(output, ReplyStoreMessage.SerializeToBytes(reply)); }
public override void StoreMessage(string prefix, ChunkHash chunkHash) { RequestStoreMessage msg = new RequestStoreMessage(); msg.Prefix = prefix; msg.ChunkHash = chunkHash.bytes; SendMessage(msg); ReplyStoreMessage.Deserialize(ProtocolParser.ReadBytes(input)); }
void ProcessStoreMessage() { RequestStoreMessage request = RequestStoreMessage.Deserialize (ProtocolParser.ReadBytes (input)); ReplyStoreMessage reply = new ReplyStoreMessage (); localRepo.StoreMessage (request.Prefix, ChunkHash.FromHashBytes (request.ChunkHash)); ProtocolParser.WriteBytes (output, ReplyStoreMessage.SerializeToBytes (reply)); }