Subversion Repositories SmartDukaan

Rev

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

Rev 20025 Rev 21844
Line 28... Line 28...
28
  private static final org.apache.thrift.protocol.TField REGISTERED_ADDRESS_FIELD_DESC = new org.apache.thrift.protocol.TField("registeredAddress", org.apache.thrift.protocol.TType.STRING, (short)3);
28
  private static final org.apache.thrift.protocol.TField REGISTERED_ADDRESS_FIELD_DESC = new org.apache.thrift.protocol.TField("registeredAddress", org.apache.thrift.protocol.TType.STRING, (short)3);
29
  private static final org.apache.thrift.protocol.TField REG_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("regId", org.apache.thrift.protocol.TType.STRING, (short)4);
29
  private static final org.apache.thrift.protocol.TField REG_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("regId", org.apache.thrift.protocol.TType.STRING, (short)4);
30
  private static final org.apache.thrift.protocol.TField CIN_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("cinNumber", org.apache.thrift.protocol.TType.STRING, (short)5);
30
  private static final org.apache.thrift.protocol.TField CIN_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("cinNumber", org.apache.thrift.protocol.TType.STRING, (short)5);
31
  private static final org.apache.thrift.protocol.TField TIN_FIELD_DESC = new org.apache.thrift.protocol.TField("tin", org.apache.thrift.protocol.TType.STRING, (short)6);
31
  private static final org.apache.thrift.protocol.TField TIN_FIELD_DESC = new org.apache.thrift.protocol.TField("tin", org.apache.thrift.protocol.TType.STRING, (short)6);
32
  private static final org.apache.thrift.protocol.TField STATE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("stateId", org.apache.thrift.protocol.TType.I64, (short)7);
32
  private static final org.apache.thrift.protocol.TField STATE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("stateId", org.apache.thrift.protocol.TType.I64, (short)7);
-
 
33
  private static final org.apache.thrift.protocol.TField GSTIN_FIELD_DESC = new org.apache.thrift.protocol.TField("gstin", org.apache.thrift.protocol.TType.STRING, (short)8);
33
 
34
 
34
  private long sellerId; // required
35
  private long sellerId; // required
35
  private String organisationName; // required
36
  private String organisationName; // required
36
  private String registeredAddress; // required
37
  private String registeredAddress; // required
37
  private String regId; // required
38
  private String regId; // required
38
  private String cinNumber; // required
39
  private String cinNumber; // required
39
  private String tin; // required
40
  private String tin; // required
40
  private long stateId; // required
41
  private long stateId; // required
-
 
42
  private String gstin; // required
41
 
43
 
42
  /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
44
  /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
43
  public enum _Fields implements org.apache.thrift.TFieldIdEnum {
45
  public enum _Fields implements org.apache.thrift.TFieldIdEnum {
44
    SELLER_ID((short)1, "sellerId"),
46
    SELLER_ID((short)1, "sellerId"),
45
    ORGANISATION_NAME((short)2, "organisationName"),
47
    ORGANISATION_NAME((short)2, "organisationName"),
46
    REGISTERED_ADDRESS((short)3, "registeredAddress"),
48
    REGISTERED_ADDRESS((short)3, "registeredAddress"),
47
    REG_ID((short)4, "regId"),
49
    REG_ID((short)4, "regId"),
48
    CIN_NUMBER((short)5, "cinNumber"),
50
    CIN_NUMBER((short)5, "cinNumber"),
49
    TIN((short)6, "tin"),
51
    TIN((short)6, "tin"),
50
    STATE_ID((short)7, "stateId");
52
    STATE_ID((short)7, "stateId"),
-
 
53
    GSTIN((short)8, "gstin");
51
 
54
 
52
    private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
55
    private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
53
 
56
 
54
    static {
57
    static {
55
      for (_Fields field : EnumSet.allOf(_Fields.class)) {
58
      for (_Fields field : EnumSet.allOf(_Fields.class)) {
Line 74... Line 77...
74
          return CIN_NUMBER;
77
          return CIN_NUMBER;
75
        case 6: // TIN
78
        case 6: // TIN
76
          return TIN;
79
          return TIN;
77
        case 7: // STATE_ID
80
        case 7: // STATE_ID
78
          return STATE_ID;
81
          return STATE_ID;
-
 
82
        case 8: // GSTIN
-
 
83
          return GSTIN;
79
        default:
84
        default:
80
          return null;
85
          return null;
81
      }
86
      }
82
    }
87
    }
83
 
88
 
Line 135... Line 140...
135
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
140
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
136
    tmpMap.put(_Fields.TIN, new org.apache.thrift.meta_data.FieldMetaData("tin", org.apache.thrift.TFieldRequirementType.DEFAULT, 
141
    tmpMap.put(_Fields.TIN, new org.apache.thrift.meta_data.FieldMetaData("tin", org.apache.thrift.TFieldRequirementType.DEFAULT, 
137
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
142
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
138
    tmpMap.put(_Fields.STATE_ID, new org.apache.thrift.meta_data.FieldMetaData("stateId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
143
    tmpMap.put(_Fields.STATE_ID, new org.apache.thrift.meta_data.FieldMetaData("stateId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
139
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
144
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
-
 
145
    tmpMap.put(_Fields.GSTIN, new org.apache.thrift.meta_data.FieldMetaData("gstin", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
146
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
140
    metaDataMap = Collections.unmodifiableMap(tmpMap);
147
    metaDataMap = Collections.unmodifiableMap(tmpMap);
141
    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(SellerInfo.class, metaDataMap);
148
    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(SellerInfo.class, metaDataMap);
142
  }
149
  }
143
 
150
 
144
  public SellerInfo() {
151
  public SellerInfo() {
Line 149... Line 156...
149
    String organisationName,
156
    String organisationName,
150
    String registeredAddress,
157
    String registeredAddress,
151
    String regId,
158
    String regId,
152
    String cinNumber,
159
    String cinNumber,
153
    String tin,
160
    String tin,
154
    long stateId)
161
    long stateId,
-
 
162
    String gstin)
155
  {
163
  {
156
    this();
164
    this();
157
    this.sellerId = sellerId;
165
    this.sellerId = sellerId;
158
    setSellerIdIsSet(true);
166
    setSellerIdIsSet(true);
159
    this.organisationName = organisationName;
167
    this.organisationName = organisationName;
Line 161... Line 169...
161
    this.regId = regId;
169
    this.regId = regId;
162
    this.cinNumber = cinNumber;
170
    this.cinNumber = cinNumber;
163
    this.tin = tin;
171
    this.tin = tin;
164
    this.stateId = stateId;
172
    this.stateId = stateId;
165
    setStateIdIsSet(true);
173
    setStateIdIsSet(true);
-
 
174
    this.gstin = gstin;
166
  }
175
  }
167
 
176
 
168
  /**
177
  /**
169
   * Performs a deep copy on <i>other</i>.
178
   * Performs a deep copy on <i>other</i>.
170
   */
179
   */
Line 186... Line 195...
186
    }
195
    }
187
    if (other.isSetTin()) {
196
    if (other.isSetTin()) {
188
      this.tin = other.tin;
197
      this.tin = other.tin;
189
    }
198
    }
190
    this.stateId = other.stateId;
199
    this.stateId = other.stateId;
-
 
200
    if (other.isSetGstin()) {
-
 
201
      this.gstin = other.gstin;
-
 
202
    }
191
  }
203
  }
192
 
204
 
193
  public SellerInfo deepCopy() {
205
  public SellerInfo deepCopy() {
194
    return new SellerInfo(this);
206
    return new SellerInfo(this);
195
  }
207
  }
Line 203... Line 215...
203
    this.regId = null;
215
    this.regId = null;
204
    this.cinNumber = null;
216
    this.cinNumber = null;
205
    this.tin = null;
217
    this.tin = null;
206
    setStateIdIsSet(false);
218
    setStateIdIsSet(false);
207
    this.stateId = 0;
219
    this.stateId = 0;
-
 
220
    this.gstin = null;
208
  }
221
  }
209
 
222
 
210
  public long getSellerId() {
223
  public long getSellerId() {
211
    return this.sellerId;
224
    return this.sellerId;
212
  }
225
  }
Line 364... Line 377...
364
 
377
 
365
  public void setStateIdIsSet(boolean value) {
378
  public void setStateIdIsSet(boolean value) {
366
    __isset_bit_vector.set(__STATEID_ISSET_ID, value);
379
    __isset_bit_vector.set(__STATEID_ISSET_ID, value);
367
  }
380
  }
368
 
381
 
-
 
382
  public String getGstin() {
-
 
383
    return this.gstin;
-
 
384
  }
-
 
385
 
-
 
386
  public void setGstin(String gstin) {
-
 
387
    this.gstin = gstin;
-
 
388
  }
-
 
389
 
-
 
390
  public void unsetGstin() {
-
 
391
    this.gstin = null;
-
 
392
  }
-
 
393
 
-
 
394
  /** Returns true if field gstin is set (has been assigned a value) and false otherwise */
-
 
395
  public boolean isSetGstin() {
-
 
396
    return this.gstin != null;
-
 
397
  }
-
 
398
 
-
 
399
  public void setGstinIsSet(boolean value) {
-
 
400
    if (!value) {
-
 
401
      this.gstin = null;
-
 
402
    }
-
 
403
  }
-
 
404
 
369
  public void setFieldValue(_Fields field, Object value) {
405
  public void setFieldValue(_Fields field, Object value) {
370
    switch (field) {
406
    switch (field) {
371
    case SELLER_ID:
407
    case SELLER_ID:
372
      if (value == null) {
408
      if (value == null) {
373
        unsetSellerId();
409
        unsetSellerId();
Line 422... Line 458...
422
      } else {
458
      } else {
423
        setStateId((Long)value);
459
        setStateId((Long)value);
424
      }
460
      }
425
      break;
461
      break;
426
 
462
 
-
 
463
    case GSTIN:
-
 
464
      if (value == null) {
-
 
465
        unsetGstin();
-
 
466
      } else {
-
 
467
        setGstin((String)value);
-
 
468
      }
-
 
469
      break;
-
 
470
 
427
    }
471
    }
428
  }
472
  }
429
 
473
 
430
  public Object getFieldValue(_Fields field) {
474
  public Object getFieldValue(_Fields field) {
431
    switch (field) {
475
    switch (field) {
Line 448... Line 492...
448
      return getTin();
492
      return getTin();
449
 
493
 
450
    case STATE_ID:
494
    case STATE_ID:
451
      return Long.valueOf(getStateId());
495
      return Long.valueOf(getStateId());
452
 
496
 
-
 
497
    case GSTIN:
-
 
498
      return getGstin();
-
 
499
 
453
    }
500
    }
454
    throw new IllegalStateException();
501
    throw new IllegalStateException();
455
  }
502
  }
456
 
503
 
457
  /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
504
  /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
Line 473... Line 520...
473
      return isSetCinNumber();
520
      return isSetCinNumber();
474
    case TIN:
521
    case TIN:
475
      return isSetTin();
522
      return isSetTin();
476
    case STATE_ID:
523
    case STATE_ID:
477
      return isSetStateId();
524
      return isSetStateId();
-
 
525
    case GSTIN:
-
 
526
      return isSetGstin();
478
    }
527
    }
479
    throw new IllegalStateException();
528
    throw new IllegalStateException();
480
  }
529
  }
481
 
530
 
482
  @Override
531
  @Override
Line 553... Line 602...
553
        return false;
602
        return false;
554
      if (this.stateId != that.stateId)
603
      if (this.stateId != that.stateId)
555
        return false;
604
        return false;
556
    }
605
    }
557
 
606
 
-
 
607
    boolean this_present_gstin = true && this.isSetGstin();
-
 
608
    boolean that_present_gstin = true && that.isSetGstin();
-
 
609
    if (this_present_gstin || that_present_gstin) {
-
 
610
      if (!(this_present_gstin && that_present_gstin))
-
 
611
        return false;
-
 
612
      if (!this.gstin.equals(that.gstin))
-
 
613
        return false;
-
 
614
    }
-
 
615
 
558
    return true;
616
    return true;
559
  }
617
  }
560
 
618
 
561
  @Override
619
  @Override
562
  public int hashCode() {
620
  public int hashCode() {
Line 639... Line 697...
639
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.stateId, typedOther.stateId);
697
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.stateId, typedOther.stateId);
640
      if (lastComparison != 0) {
698
      if (lastComparison != 0) {
641
        return lastComparison;
699
        return lastComparison;
642
      }
700
      }
643
    }
701
    }
-
 
702
    lastComparison = Boolean.valueOf(isSetGstin()).compareTo(typedOther.isSetGstin());
-
 
703
    if (lastComparison != 0) {
-
 
704
      return lastComparison;
-
 
705
    }
-
 
706
    if (isSetGstin()) {
-
 
707
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gstin, typedOther.gstin);
-
 
708
      if (lastComparison != 0) {
-
 
709
        return lastComparison;
-
 
710
      }
-
 
711
    }
644
    return 0;
712
    return 0;
645
  }
713
  }
646
 
714
 
647
  public _Fields fieldForId(int fieldId) {
715
  public _Fields fieldForId(int fieldId) {
648
    return _Fields.findByThriftId(fieldId);
716
    return _Fields.findByThriftId(fieldId);
Line 707... Line 775...
707
            setStateIdIsSet(true);
775
            setStateIdIsSet(true);
708
          } else { 
776
          } else { 
709
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
777
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
710
          }
778
          }
711
          break;
779
          break;
-
 
780
        case 8: // GSTIN
-
 
781
          if (field.type == org.apache.thrift.protocol.TType.STRING) {
-
 
782
            this.gstin = iprot.readString();
-
 
783
          } else { 
-
 
784
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
785
          }
-
 
786
          break;
712
        default:
787
        default:
713
          org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
788
          org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
714
      }
789
      }
715
      iprot.readFieldEnd();
790
      iprot.readFieldEnd();
716
    }
791
    }
Line 751... Line 826...
751
      oprot.writeFieldEnd();
826
      oprot.writeFieldEnd();
752
    }
827
    }
753
    oprot.writeFieldBegin(STATE_ID_FIELD_DESC);
828
    oprot.writeFieldBegin(STATE_ID_FIELD_DESC);
754
    oprot.writeI64(this.stateId);
829
    oprot.writeI64(this.stateId);
755
    oprot.writeFieldEnd();
830
    oprot.writeFieldEnd();
-
 
831
    if (this.gstin != null) {
-
 
832
      oprot.writeFieldBegin(GSTIN_FIELD_DESC);
-
 
833
      oprot.writeString(this.gstin);
-
 
834
      oprot.writeFieldEnd();
-
 
835
    }
756
    oprot.writeFieldStop();
836
    oprot.writeFieldStop();
757
    oprot.writeStructEnd();
837
    oprot.writeStructEnd();
758
  }
838
  }
759
 
839
 
760
  @Override
840
  @Override
Line 807... Line 887...
807
    first = false;
887
    first = false;
808
    if (!first) sb.append(", ");
888
    if (!first) sb.append(", ");
809
    sb.append("stateId:");
889
    sb.append("stateId:");
810
    sb.append(this.stateId);
890
    sb.append(this.stateId);
811
    first = false;
891
    first = false;
-
 
892
    if (!first) sb.append(", ");
-
 
893
    sb.append("gstin:");
-
 
894
    if (this.gstin == null) {
-
 
895
      sb.append("null");
-
 
896
    } else {
-
 
897
      sb.append(this.gstin);
-
 
898
    }
-
 
899
    first = false;
812
    sb.append(")");
900
    sb.append(")");
813
    return sb.toString();
901
    return sb.toString();
814
  }
902
  }
815
 
903
 
816
  public void validate() throws org.apache.thrift.TException {
904
  public void validate() throws org.apache.thrift.TException {