protected override void Trasmit(PMSMessage message) { byte[] ByteArray = message.ToByteArray(); GetTransport().DiscardInBuffer(); GetTransport().Write(ByteArray, 0, ByteArray.Length); logger.Debug(Encoding.ASCII.GetString(ByteArray)); }
public PMSRoomStatusResponse Inquiry(PMSRoomStatus Status) { _data.Import(Status); PMSRoomStatusResponse Response = new PMSRoomStatusResponse(); try { PMSMessage messageToTransmit = BuildInquiry(); Trasmit(messageToTransmit); ReceiveInquiry(); // Provide a Cach of this room number and foilos // for quick look up when rooms are charged. Response = _data.ExportPMSRoomStatusResponse(_cache); } catch (System.TimeoutException ex) { logger.Error("MicrosServer : No Reply :" + ex.Message); Response.ErrorResponse = ex.Message; } catch (System.Exception ex) { logger.Error("\rMicrosServer : " + ex.Message); Response.ErrorResponse = ex.Message; } return(Response); }
protected override void Trasmit(PMSMessage message) { byte[] ByteArray = message.ToByteArray(); logger.Info(Encoding.ASCII.GetString(ByteArray)); }
protected override void Trasmit(PMSMessage message) { throw new Exception("The method or operation is not implemented."); }
abstract protected void Trasmit(PMSMessage message);