Subversion Repositories SmartDukaan

Rev

Rev 3430 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 3430 Rev 3546
Line 37... Line 37...
37
  private static final org.apache.thrift.protocol.TField AIRWAY_BILL_NO_FIELD_DESC = new org.apache.thrift.protocol.TField("airwayBillNo", org.apache.thrift.protocol.TType.STRING, (short)12);
37
  private static final org.apache.thrift.protocol.TField AIRWAY_BILL_NO_FIELD_DESC = new org.apache.thrift.protocol.TField("airwayBillNo", org.apache.thrift.protocol.TType.STRING, (short)12);
38
  private static final org.apache.thrift.protocol.TField PRODUCT_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("productName", org.apache.thrift.protocol.TType.STRING, (short)13);
38
  private static final org.apache.thrift.protocol.TField PRODUCT_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("productName", org.apache.thrift.protocol.TType.STRING, (short)13);
39
  private static final org.apache.thrift.protocol.TField CUSTOMER_MOBILE_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("customerMobileNumber", org.apache.thrift.protocol.TType.STRING, (short)14);
39
  private static final org.apache.thrift.protocol.TField CUSTOMER_MOBILE_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("customerMobileNumber", org.apache.thrift.protocol.TType.STRING, (short)14);
40
  private static final org.apache.thrift.protocol.TField CUSTOMER_EMAIL_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("customerEmailId", org.apache.thrift.protocol.TType.STRING, (short)15);
40
  private static final org.apache.thrift.protocol.TField CUSTOMER_EMAIL_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("customerEmailId", org.apache.thrift.protocol.TType.STRING, (short)15);
41
  private static final org.apache.thrift.protocol.TField CUSTOMER_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("customerName", org.apache.thrift.protocol.TType.STRING, (short)16);
41
  private static final org.apache.thrift.protocol.TField CUSTOMER_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("customerName", org.apache.thrift.protocol.TType.STRING, (short)16);
42
  private static final org.apache.thrift.protocol.TField ASSIGNEE_FIELD_DESC = new org.apache.thrift.protocol.TField("assignee", org.apache.thrift.protocol.TType.STRUCT, (short)17);
-
 
43
  private static final org.apache.thrift.protocol.TField CREATOR_FIELD_DESC = new org.apache.thrift.protocol.TField("creator", org.apache.thrift.protocol.TType.STRUCT, (short)18);
-
 
44
 
42
 
45
  private long id; // required
43
  private long id; // required
46
  private long customerId; // required
44
  private long customerId; // required
47
  private long openDate; // required
45
  private long openDate; // required
48
  private long closeDate; // required
46
  private long closeDate; // required
Line 56... Line 54...
56
  private String airwayBillNo; // required
54
  private String airwayBillNo; // required
57
  private String productName; // required
55
  private String productName; // required
58
  private String customerMobileNumber; // required
56
  private String customerMobileNumber; // required
59
  private String customerEmailId; // required
57
  private String customerEmailId; // required
60
  private String customerName; // required
58
  private String customerName; // required
61
  private Agent assignee; // required
-
 
62
  private Agent creator; // required
-
 
63
 
59
 
64
  /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
60
  /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
65
  public enum _Fields implements org.apache.thrift.TFieldIdEnum {
61
  public enum _Fields implements org.apache.thrift.TFieldIdEnum {
66
    ID((short)1, "id"),
62
    ID((short)1, "id"),
67
    CUSTOMER_ID((short)2, "customerId"),
63
    CUSTOMER_ID((short)2, "customerId"),
Line 88... Line 84...
88
    ORDER_ID((short)11, "orderId"),
84
    ORDER_ID((short)11, "orderId"),
89
    AIRWAY_BILL_NO((short)12, "airwayBillNo"),
85
    AIRWAY_BILL_NO((short)12, "airwayBillNo"),
90
    PRODUCT_NAME((short)13, "productName"),
86
    PRODUCT_NAME((short)13, "productName"),
91
    CUSTOMER_MOBILE_NUMBER((short)14, "customerMobileNumber"),
87
    CUSTOMER_MOBILE_NUMBER((short)14, "customerMobileNumber"),
92
    CUSTOMER_EMAIL_ID((short)15, "customerEmailId"),
88
    CUSTOMER_EMAIL_ID((short)15, "customerEmailId"),
93
    CUSTOMER_NAME((short)16, "customerName"),
89
    CUSTOMER_NAME((short)16, "customerName");
94
    ASSIGNEE((short)17, "assignee"),
-
 
95
    CREATOR((short)18, "creator");
-
 
96
 
90
 
97
    private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
91
    private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
98
 
92
 
99
    static {
93
    static {
100
      for (_Fields field : EnumSet.allOf(_Fields.class)) {
94
      for (_Fields field : EnumSet.allOf(_Fields.class)) {
Line 137... Line 131...
137
          return CUSTOMER_MOBILE_NUMBER;
131
          return CUSTOMER_MOBILE_NUMBER;
138
        case 15: // CUSTOMER_EMAIL_ID
132
        case 15: // CUSTOMER_EMAIL_ID
139
          return CUSTOMER_EMAIL_ID;
133
          return CUSTOMER_EMAIL_ID;
140
        case 16: // CUSTOMER_NAME
134
        case 16: // CUSTOMER_NAME
141
          return CUSTOMER_NAME;
135
          return CUSTOMER_NAME;
142
        case 17: // ASSIGNEE
-
 
143
          return ASSIGNEE;
-
 
144
        case 18: // CREATOR
-
 
145
          return CREATOR;
-
 
146
        default:
136
        default:
147
          return null;
137
          return null;
148
      }
138
      }
149
    }
139
    }
150
 
140
 
Line 225... Line 215...
225
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
215
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
226
    tmpMap.put(_Fields.CUSTOMER_EMAIL_ID, new org.apache.thrift.meta_data.FieldMetaData("customerEmailId", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
216
    tmpMap.put(_Fields.CUSTOMER_EMAIL_ID, new org.apache.thrift.meta_data.FieldMetaData("customerEmailId", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
227
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
217
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
228
    tmpMap.put(_Fields.CUSTOMER_NAME, new org.apache.thrift.meta_data.FieldMetaData("customerName", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
218
    tmpMap.put(_Fields.CUSTOMER_NAME, new org.apache.thrift.meta_data.FieldMetaData("customerName", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
229
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
219
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
230
    tmpMap.put(_Fields.ASSIGNEE, new org.apache.thrift.meta_data.FieldMetaData("assignee", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
-
 
231
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Agent.class)));
-
 
232
    tmpMap.put(_Fields.CREATOR, new org.apache.thrift.meta_data.FieldMetaData("creator", org.apache.thrift.TFieldRequirementType.OPTIONAL, 
-
 
233
        new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Agent.class)));
-
 
234
    metaDataMap = Collections.unmodifiableMap(tmpMap);
220
    metaDataMap = Collections.unmodifiableMap(tmpMap);
235
    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(Ticket.class, metaDataMap);
221
    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(Ticket.class, metaDataMap);
236
  }
222
  }
237
 
223
 
238
  public Ticket() {
224
  public Ticket() {
Line 296... Line 282...
296
      this.customerEmailId = other.customerEmailId;
282
      this.customerEmailId = other.customerEmailId;
297
    }
283
    }
298
    if (other.isSetCustomerName()) {
284
    if (other.isSetCustomerName()) {
299
      this.customerName = other.customerName;
285
      this.customerName = other.customerName;
300
    }
286
    }
301
    if (other.isSetAssignee()) {
-
 
302
      this.assignee = new Agent(other.assignee);
-
 
303
    }
-
 
304
    if (other.isSetCreator()) {
-
 
305
      this.creator = new Agent(other.creator);
-
 
306
    }
-
 
307
  }
287
  }
308
 
288
 
309
  public Ticket deepCopy() {
289
  public Ticket deepCopy() {
310
    return new Ticket(this);
290
    return new Ticket(this);
311
  }
291
  }
Line 333... Line 313...
333
    this.airwayBillNo = null;
313
    this.airwayBillNo = null;
334
    this.productName = null;
314
    this.productName = null;
335
    this.customerMobileNumber = null;
315
    this.customerMobileNumber = null;
336
    this.customerEmailId = null;
316
    this.customerEmailId = null;
337
    this.customerName = null;
317
    this.customerName = null;
338
    this.assignee = null;
-
 
339
    this.creator = null;
-
 
340
  }
318
  }
341
 
319
 
342
  public long getId() {
320
  public long getId() {
343
    return this.id;
321
    return this.id;
344
  }
322
  }
Line 722... Line 700...
722
    if (!value) {
700
    if (!value) {
723
      this.customerName = null;
701
      this.customerName = null;
724
    }
702
    }
725
  }
703
  }
726
 
704
 
727
  public Agent getAssignee() {
-
 
728
    return this.assignee;
-
 
729
  }
-
 
730
 
-
 
731
  public void setAssignee(Agent assignee) {
-
 
732
    this.assignee = assignee;
-
 
733
  }
-
 
734
 
-
 
735
  public void unsetAssignee() {
-
 
736
    this.assignee = null;
-
 
737
  }
-
 
738
 
-
 
739
  /** Returns true if field assignee is set (has been assigned a value) and false otherwise */
-
 
740
  public boolean isSetAssignee() {
-
 
741
    return this.assignee != null;
-
 
742
  }
-
 
743
 
-
 
744
  public void setAssigneeIsSet(boolean value) {
-
 
745
    if (!value) {
-
 
746
      this.assignee = null;
-
 
747
    }
-
 
748
  }
-
 
749
 
-
 
750
  public Agent getCreator() {
-
 
751
    return this.creator;
-
 
752
  }
-
 
753
 
-
 
754
  public void setCreator(Agent creator) {
-
 
755
    this.creator = creator;
-
 
756
  }
-
 
757
 
-
 
758
  public void unsetCreator() {
-
 
759
    this.creator = null;
-
 
760
  }
-
 
761
 
-
 
762
  /** Returns true if field creator is set (has been assigned a value) and false otherwise */
-
 
763
  public boolean isSetCreator() {
-
 
764
    return this.creator != null;
-
 
765
  }
-
 
766
 
-
 
767
  public void setCreatorIsSet(boolean value) {
-
 
768
    if (!value) {
-
 
769
      this.creator = null;
-
 
770
    }
-
 
771
  }
-
 
772
 
-
 
773
  public void setFieldValue(_Fields field, Object value) {
705
  public void setFieldValue(_Fields field, Object value) {
774
    switch (field) {
706
    switch (field) {
775
    case ID:
707
    case ID:
776
      if (value == null) {
708
      if (value == null) {
777
        unsetId();
709
        unsetId();
Line 898... Line 830...
898
      } else {
830
      } else {
899
        setCustomerName((String)value);
831
        setCustomerName((String)value);
900
      }
832
      }
901
      break;
833
      break;
902
 
834
 
903
    case ASSIGNEE:
-
 
904
      if (value == null) {
-
 
905
        unsetAssignee();
-
 
906
      } else {
-
 
907
        setAssignee((Agent)value);
-
 
908
      }
-
 
909
      break;
-
 
910
 
-
 
911
    case CREATOR:
-
 
912
      if (value == null) {
-
 
913
        unsetCreator();
-
 
914
      } else {
-
 
915
        setCreator((Agent)value);
-
 
916
      }
-
 
917
      break;
-
 
918
 
-
 
919
    }
835
    }
920
  }
836
  }
921
 
837
 
922
  public Object getFieldValue(_Fields field) {
838
  public Object getFieldValue(_Fields field) {
923
    switch (field) {
839
    switch (field) {
Line 967... Line 883...
967
      return getCustomerEmailId();
883
      return getCustomerEmailId();
968
 
884
 
969
    case CUSTOMER_NAME:
885
    case CUSTOMER_NAME:
970
      return getCustomerName();
886
      return getCustomerName();
971
 
887
 
972
    case ASSIGNEE:
-
 
973
      return getAssignee();
-
 
974
 
-
 
975
    case CREATOR:
-
 
976
      return getCreator();
-
 
977
 
-
 
978
    }
888
    }
979
    throw new IllegalStateException();
889
    throw new IllegalStateException();
980
  }
890
  }
981
 
891
 
982
  /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
892
  /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
Line 1016... Line 926...
1016
      return isSetCustomerMobileNumber();
926
      return isSetCustomerMobileNumber();
1017
    case CUSTOMER_EMAIL_ID:
927
    case CUSTOMER_EMAIL_ID:
1018
      return isSetCustomerEmailId();
928
      return isSetCustomerEmailId();
1019
    case CUSTOMER_NAME:
929
    case CUSTOMER_NAME:
1020
      return isSetCustomerName();
930
      return isSetCustomerName();
1021
    case ASSIGNEE:
-
 
1022
      return isSetAssignee();
-
 
1023
    case CREATOR:
-
 
1024
      return isSetCreator();
-
 
1025
    }
931
    }
1026
    throw new IllegalStateException();
932
    throw new IllegalStateException();
1027
  }
933
  }
1028
 
934
 
1029
  @Override
935
  @Override
Line 1181... Line 1087...
1181
        return false;
1087
        return false;
1182
      if (!this.customerName.equals(that.customerName))
1088
      if (!this.customerName.equals(that.customerName))
1183
        return false;
1089
        return false;
1184
    }
1090
    }
1185
 
1091
 
1186
    boolean this_present_assignee = true && this.isSetAssignee();
-
 
1187
    boolean that_present_assignee = true && that.isSetAssignee();
-
 
1188
    if (this_present_assignee || that_present_assignee) {
-
 
1189
      if (!(this_present_assignee && that_present_assignee))
-
 
1190
        return false;
-
 
1191
      if (!this.assignee.equals(that.assignee))
-
 
1192
        return false;
-
 
1193
    }
-
 
1194
 
-
 
1195
    boolean this_present_creator = true && this.isSetCreator();
-
 
1196
    boolean that_present_creator = true && that.isSetCreator();
-
 
1197
    if (this_present_creator || that_present_creator) {
-
 
1198
      if (!(this_present_creator && that_present_creator))
-
 
1199
        return false;
-
 
1200
      if (!this.creator.equals(that.creator))
-
 
1201
        return false;
-
 
1202
    }
-
 
1203
 
-
 
1204
    return true;
1092
    return true;
1205
  }
1093
  }
1206
 
1094
 
1207
  @Override
1095
  @Override
1208
  public int hashCode() {
1096
  public int hashCode() {
Line 1375... Line 1263...
1375
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.customerName, typedOther.customerName);
1263
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.customerName, typedOther.customerName);
1376
      if (lastComparison != 0) {
1264
      if (lastComparison != 0) {
1377
        return lastComparison;
1265
        return lastComparison;
1378
      }
1266
      }
1379
    }
1267
    }
1380
    lastComparison = Boolean.valueOf(isSetAssignee()).compareTo(typedOther.isSetAssignee());
-
 
1381
    if (lastComparison != 0) {
-
 
1382
      return lastComparison;
-
 
1383
    }
-
 
1384
    if (isSetAssignee()) {
-
 
1385
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.assignee, typedOther.assignee);
-
 
1386
      if (lastComparison != 0) {
-
 
1387
        return lastComparison;
-
 
1388
      }
-
 
1389
    }
-
 
1390
    lastComparison = Boolean.valueOf(isSetCreator()).compareTo(typedOther.isSetCreator());
-
 
1391
    if (lastComparison != 0) {
-
 
1392
      return lastComparison;
-
 
1393
    }
-
 
1394
    if (isSetCreator()) {
-
 
1395
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.creator, typedOther.creator);
-
 
1396
      if (lastComparison != 0) {
-
 
1397
        return lastComparison;
-
 
1398
      }
-
 
1399
    }
-
 
1400
    return 0;
1268
    return 0;
1401
  }
1269
  }
1402
 
1270
 
1403
  public _Fields fieldForId(int fieldId) {
1271
  public _Fields fieldForId(int fieldId) {
1404
    return _Fields.findByThriftId(fieldId);
1272
    return _Fields.findByThriftId(fieldId);
Line 1531... Line 1399...
1531
            this.customerName = iprot.readString();
1399
            this.customerName = iprot.readString();
1532
          } else { 
1400
          } else { 
1533
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1401
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1534
          }
1402
          }
1535
          break;
1403
          break;
1536
        case 17: // ASSIGNEE
-
 
1537
          if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
-
 
1538
            this.assignee = new Agent();
-
 
1539
            this.assignee.read(iprot);
-
 
1540
          } else { 
-
 
1541
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
1542
          }
-
 
1543
          break;
-
 
1544
        case 18: // CREATOR
-
 
1545
          if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
-
 
1546
            this.creator = new Agent();
-
 
1547
            this.creator.read(iprot);
-
 
1548
          } else { 
-
 
1549
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
1550
          }
-
 
1551
          break;
-
 
1552
        default:
1404
        default:
1553
          org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1405
          org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1554
      }
1406
      }
1555
      iprot.readFieldEnd();
1407
      iprot.readFieldEnd();
1556
    }
1408
    }
Line 1646... Line 1498...
1646
        oprot.writeFieldBegin(CUSTOMER_NAME_FIELD_DESC);
1498
        oprot.writeFieldBegin(CUSTOMER_NAME_FIELD_DESC);
1647
        oprot.writeString(this.customerName);
1499
        oprot.writeString(this.customerName);
1648
        oprot.writeFieldEnd();
1500
        oprot.writeFieldEnd();
1649
      }
1501
      }
1650
    }
1502
    }
1651
    if (this.assignee != null) {
-
 
1652
      if (isSetAssignee()) {
-
 
1653
        oprot.writeFieldBegin(ASSIGNEE_FIELD_DESC);
-
 
1654
        this.assignee.write(oprot);
-
 
1655
        oprot.writeFieldEnd();
-
 
1656
      }
-
 
1657
    }
-
 
1658
    if (this.creator != null) {
-
 
1659
      if (isSetCreator()) {
-
 
1660
        oprot.writeFieldBegin(CREATOR_FIELD_DESC);
-
 
1661
        this.creator.write(oprot);
-
 
1662
        oprot.writeFieldEnd();
-
 
1663
      }
-
 
1664
    }
-
 
1665
    oprot.writeFieldStop();
1503
    oprot.writeFieldStop();
1666
    oprot.writeStructEnd();
1504
    oprot.writeStructEnd();
1667
  }
1505
  }
1668
 
1506
 
1669
  @Override
1507
  @Override
Line 1788... Line 1626...
1788
      } else {
1626
      } else {
1789
        sb.append(this.customerName);
1627
        sb.append(this.customerName);
1790
      }
1628
      }
1791
      first = false;
1629
      first = false;
1792
    }
1630
    }
1793
    if (isSetAssignee()) {
-
 
1794
      if (!first) sb.append(", ");
-
 
1795
      sb.append("assignee:");
-
 
1796
      if (this.assignee == null) {
-
 
1797
        sb.append("null");
-
 
1798
      } else {
-
 
1799
        sb.append(this.assignee);
-
 
1800
      }
-
 
1801
      first = false;
-
 
1802
    }
-
 
1803
    if (isSetCreator()) {
-
 
1804
      if (!first) sb.append(", ");
-
 
1805
      sb.append("creator:");
-
 
1806
      if (this.creator == null) {
-
 
1807
        sb.append("null");
-
 
1808
      } else {
-
 
1809
        sb.append(this.creator);
-
 
1810
      }
-
 
1811
      first = false;
-
 
1812
    }
-
 
1813
    sb.append(")");
1631
    sb.append(")");
1814
    return sb.toString();
1632
    return sb.toString();
1815
  }
1633
  }
1816
 
1634
 
1817
  public void validate() throws org.apache.thrift.TException {
1635
  public void validate() throws org.apache.thrift.TException {