public TicketCancelAckDTO(ITicketCancelAck ticket) { _ticketId = ticket.TicketId; _ticketCancelStatus = MtsTicketHelper.Convert(ticket.TicketCancelStatus); _code = ticket.Code; _message = ticket.Message; _timestampUtc = MtsTicketHelper.Convert(ticket.Timestamp); _version = ticket.Version; _sender = new Sender(ticket.BookmakerId); }
public static void Compare(ITicketCancelAck ticket, TicketCancelAckDTO dto) { Assert.IsTrue(ticket != null); Assert.IsTrue(dto != null); Assert.AreEqual(ticket.TicketId, dto.TicketId); Assert.AreEqual(MtsTicketHelper.Convert(ticket.Timestamp), dto.TimestampUtc); Assert.AreEqual(ticket.Version, dto.Version); Assert.AreEqual(ticket.BookmakerId, dto.Sender.BookmakerId); Assert.AreEqual(ticket.Code, dto.Code); Assert.AreEqual(ticket.Message, dto.Message); Assert.AreEqual(MtsTicketHelper.Convert(ticket.TicketCancelStatus), dto.TicketCancelStatus); Assert.IsFalse(string.IsNullOrEmpty(ticket.CorrelationId)); }
public static TicketCancelAckDTO Map(ITicketCancelAck source) { return(new TicketCancelAckDTO(source)); }