public override EventArgs Create(Messages.Message message, EventContext context) { var eventArgsAttr = message.GetType().GetTypeInfo().GetCustomAttribute <EventArgsAttribute>(); if (eventArgsAttr != null) { return(eventArgsAttr.Create()); } else { return(new SimpleEventArgs(message, context)); } }
public void Tranceive(Messages.Message message) { Tracer.WriteLineInfo("Sending {0}", message.GetType().Name); message.Send(PortStream); message.Receive(PortStream); }