protected void updateDevice(ServicePacket <T> p) { OnUpdateDevice((IUpdateDevice)p); }
protected virtual void OnCommandReceived(byte code, ServicePacket <T> command) { CommandReceived.Raise(this, new CommandReceivedEventArgs <T, ServicePacket <T> >(code, command)); }
protected void AutoSend <T1>(ServicePacket <T> p) where T1 : UserRequest <T>, new() { // TODO: autosend cached requests (as they are simple and not configurable) toSend.Enqueue(new T1()); }