public AgentMessage Reply(PerformativeType performative) { AgentMessage reply = this.MemberwiseClone() as AgentMessage; reply.Performative = performative; reply.Sender = this.RealReceiver; reply.Receiver = this.Sender; reply.RealReceiver = this.Sender; reply.InReplyTo = this.ReplyWith; return(reply); }
public async Task Given_a_frame_body_byte_array_with_a_performative_When_creating_a_frame_body_Then_performative_equals_byte_array_performative (string performative, PerformativeType expectedType) { var frameBodyBytes = ConvertToByteArray (performative); var result = await FrameBodyFactory.GetFrameBodyFromBytes (frameBodyBytes); result.Performative.Should ().Be (expectedType); }
public FrameBody (PerformativeType performative, byte[] payloadBytes) { Performative = performative; Payload = payloadBytes; }
public AgentMessage(PerformativeType performative) { this.Performative = performative; }
Performative (string name, PerformativeType type) { Name = name; Type = type; }