public SL_SUPPLY(string supplyId, long newTicketId, long oldTicketId, long newPrice, long oldPrice, string ticketTypeId, string opeUserId, long opeTime, SL_ORDER slOrder, SL_USELESS_TICKET_INFO slUselessTicketInfo) : this() { this.SupplyId = supplyId; this.NewTicketId = newTicketId; this.OldTicketId = oldTicketId; this.NewPrice = newPrice; this.OldPrice = oldPrice; this.TicketTypeId = ticketTypeId; this.OpeUserId = opeUserId; this.OpeTime = opeTime; this.SlOrder = slOrder; this.SlUselessTicketInfo = slUselessTicketInfo; }
public void Read(TProtocol iprot) { iprot.IncrementRecursionDepth(); try { bool isset_supplyId = false; bool isset_newTicketId = false; bool isset_oldTicketId = false; bool isset_newPrice = false; bool isset_oldPrice = false; bool isset_ticketTypeId = false; bool isset_opeUserId = false; bool isset_opeTime = false; bool isset_slOrder = false; bool isset_slUselessTicketInfo = false; TField field; iprot.ReadStructBegin(); while (true) { field = iprot.ReadFieldBegin(); if (field.Type == TType.Stop) { break; } switch (field.ID) { case 1: if (field.Type == TType.String) { SupplyId = iprot.ReadString(); isset_supplyId = true; } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 2: if (field.Type == TType.I64) { NewTicketId = iprot.ReadI64(); isset_newTicketId = true; } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 3: if (field.Type == TType.I64) { OldTicketId = iprot.ReadI64(); isset_oldTicketId = true; } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 4: if (field.Type == TType.I64) { NewPrice = iprot.ReadI64(); isset_newPrice = true; } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 5: if (field.Type == TType.I64) { OldPrice = iprot.ReadI64(); isset_oldPrice = true; } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 6: if (field.Type == TType.String) { TicketTypeId = iprot.ReadString(); isset_ticketTypeId = true; } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 7: if (field.Type == TType.String) { OpeUserId = iprot.ReadString(); isset_opeUserId = true; } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 8: if (field.Type == TType.I64) { OpeTime = iprot.ReadI64(); isset_opeTime = true; } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 9: if (field.Type == TType.Struct) { SlOrder = new SL_ORDER(); SlOrder.Read(iprot); isset_slOrder = true; } else { TProtocolUtil.Skip(iprot, field.Type); } break; case 10: if (field.Type == TType.Struct) { SlUselessTicketInfo = new SL_USELESS_TICKET_INFO(); SlUselessTicketInfo.Read(iprot); isset_slUselessTicketInfo = true; } else { TProtocolUtil.Skip(iprot, field.Type); } break; default: TProtocolUtil.Skip(iprot, field.Type); break; } iprot.ReadFieldEnd(); } iprot.ReadStructEnd(); if (!isset_supplyId) { throw new TProtocolException(TProtocolException.INVALID_DATA); } if (!isset_newTicketId) { throw new TProtocolException(TProtocolException.INVALID_DATA); } if (!isset_oldTicketId) { throw new TProtocolException(TProtocolException.INVALID_DATA); } if (!isset_newPrice) { throw new TProtocolException(TProtocolException.INVALID_DATA); } if (!isset_oldPrice) { throw new TProtocolException(TProtocolException.INVALID_DATA); } if (!isset_ticketTypeId) { throw new TProtocolException(TProtocolException.INVALID_DATA); } if (!isset_opeUserId) { throw new TProtocolException(TProtocolException.INVALID_DATA); } if (!isset_opeTime) { throw new TProtocolException(TProtocolException.INVALID_DATA); } if (!isset_slOrder) { throw new TProtocolException(TProtocolException.INVALID_DATA); } if (!isset_slUselessTicketInfo) { throw new TProtocolException(TProtocolException.INVALID_DATA); } } finally { iprot.DecrementRecursionDepth(); } }