| 11890 |
kshitij.so |
1 |
/**
|
|
|
2 |
* Autogenerated by Thrift Compiler (0.7.0)
|
|
|
3 |
*
|
|
|
4 |
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
|
|
|
5 |
*/
|
|
|
6 |
package in.shop2020.model.v1.user;
|
|
|
7 |
|
|
|
8 |
import java.util.List;
|
|
|
9 |
import java.util.ArrayList;
|
|
|
10 |
import java.util.Map;
|
|
|
11 |
import java.util.HashMap;
|
|
|
12 |
import java.util.EnumMap;
|
|
|
13 |
import java.util.Set;
|
|
|
14 |
import java.util.HashSet;
|
|
|
15 |
import java.util.EnumSet;
|
|
|
16 |
import java.util.Collections;
|
|
|
17 |
import java.util.BitSet;
|
|
|
18 |
import java.nio.ByteBuffer;
|
|
|
19 |
import java.util.Arrays;
|
|
|
20 |
import org.slf4j.Logger;
|
|
|
21 |
import org.slf4j.LoggerFactory;
|
|
|
22 |
|
|
|
23 |
public class PrivateDealUser implements org.apache.thrift.TBase<PrivateDealUser, PrivateDealUser._Fields>, java.io.Serializable, Cloneable {
|
|
|
24 |
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("PrivateDealUser");
|
|
|
25 |
|
|
|
26 |
private static final org.apache.thrift.protocol.TField USER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("userId", org.apache.thrift.protocol.TType.I64, (short)1);
|
|
|
27 |
private static final org.apache.thrift.protocol.TField ADDED_ON_FIELD_DESC = new org.apache.thrift.protocol.TField("addedOn", org.apache.thrift.protocol.TType.I64, (short)2);
|
|
|
28 |
private static final org.apache.thrift.protocol.TField IS_ACTIVE_FIELD_DESC = new org.apache.thrift.protocol.TField("isActive", org.apache.thrift.protocol.TType.BOOL, (short)3);
|
| 12696 |
amit.gupta |
29 |
private static final org.apache.thrift.protocol.TField COUNTER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("counterId", org.apache.thrift.protocol.TType.I64, (short)4);
|
|
|
30 |
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)5);
|
| 13146 |
manish.sha |
31 |
private static final org.apache.thrift.protocol.TField BULK_SHIPMENT_AMOUNT_LIMIT_FIELD_DESC = new org.apache.thrift.protocol.TField("bulkShipmentAmountLimit", org.apache.thrift.protocol.TType.DOUBLE, (short)6);
|
| 18590 |
manish.sha |
32 |
private static final org.apache.thrift.protocol.TField CREDITOR_ASSIGNED_FIELD_DESC = new org.apache.thrift.protocol.TField("creditorAssigned", org.apache.thrift.protocol.TType.BOOL, (short)7);
|
| 11890 |
kshitij.so |
33 |
|
|
|
34 |
private long userId; // required
|
|
|
35 |
private long addedOn; // required
|
|
|
36 |
private boolean isActive; // required
|
| 12696 |
amit.gupta |
37 |
private long counterId; // required
|
|
|
38 |
private String tin; // required
|
| 13146 |
manish.sha |
39 |
private double bulkShipmentAmountLimit; // required
|
| 18590 |
manish.sha |
40 |
private boolean creditorAssigned; // required
|
| 11890 |
kshitij.so |
41 |
|
|
|
42 |
/** 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 {
|
|
|
44 |
USER_ID((short)1, "userId"),
|
|
|
45 |
ADDED_ON((short)2, "addedOn"),
|
| 12696 |
amit.gupta |
46 |
IS_ACTIVE((short)3, "isActive"),
|
|
|
47 |
COUNTER_ID((short)4, "counterId"),
|
| 13146 |
manish.sha |
48 |
TIN((short)5, "tin"),
|
| 18590 |
manish.sha |
49 |
BULK_SHIPMENT_AMOUNT_LIMIT((short)6, "bulkShipmentAmountLimit"),
|
|
|
50 |
CREDITOR_ASSIGNED((short)7, "creditorAssigned");
|
| 11890 |
kshitij.so |
51 |
|
|
|
52 |
private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
|
|
|
53 |
|
|
|
54 |
static {
|
|
|
55 |
for (_Fields field : EnumSet.allOf(_Fields.class)) {
|
|
|
56 |
byName.put(field.getFieldName(), field);
|
|
|
57 |
}
|
|
|
58 |
}
|
|
|
59 |
|
|
|
60 |
/**
|
|
|
61 |
* Find the _Fields constant that matches fieldId, or null if its not found.
|
|
|
62 |
*/
|
|
|
63 |
public static _Fields findByThriftId(int fieldId) {
|
|
|
64 |
switch(fieldId) {
|
|
|
65 |
case 1: // USER_ID
|
|
|
66 |
return USER_ID;
|
|
|
67 |
case 2: // ADDED_ON
|
|
|
68 |
return ADDED_ON;
|
|
|
69 |
case 3: // IS_ACTIVE
|
|
|
70 |
return IS_ACTIVE;
|
| 12696 |
amit.gupta |
71 |
case 4: // COUNTER_ID
|
|
|
72 |
return COUNTER_ID;
|
|
|
73 |
case 5: // TIN
|
|
|
74 |
return TIN;
|
| 13146 |
manish.sha |
75 |
case 6: // BULK_SHIPMENT_AMOUNT_LIMIT
|
|
|
76 |
return BULK_SHIPMENT_AMOUNT_LIMIT;
|
| 18590 |
manish.sha |
77 |
case 7: // CREDITOR_ASSIGNED
|
|
|
78 |
return CREDITOR_ASSIGNED;
|
| 11890 |
kshitij.so |
79 |
default:
|
|
|
80 |
return null;
|
|
|
81 |
}
|
|
|
82 |
}
|
|
|
83 |
|
|
|
84 |
/**
|
|
|
85 |
* Find the _Fields constant that matches fieldId, throwing an exception
|
|
|
86 |
* if it is not found.
|
|
|
87 |
*/
|
|
|
88 |
public static _Fields findByThriftIdOrThrow(int fieldId) {
|
|
|
89 |
_Fields fields = findByThriftId(fieldId);
|
|
|
90 |
if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
|
|
|
91 |
return fields;
|
|
|
92 |
}
|
|
|
93 |
|
|
|
94 |
/**
|
|
|
95 |
* Find the _Fields constant that matches name, or null if its not found.
|
|
|
96 |
*/
|
|
|
97 |
public static _Fields findByName(String name) {
|
|
|
98 |
return byName.get(name);
|
|
|
99 |
}
|
|
|
100 |
|
|
|
101 |
private final short _thriftId;
|
|
|
102 |
private final String _fieldName;
|
|
|
103 |
|
|
|
104 |
_Fields(short thriftId, String fieldName) {
|
|
|
105 |
_thriftId = thriftId;
|
|
|
106 |
_fieldName = fieldName;
|
|
|
107 |
}
|
|
|
108 |
|
|
|
109 |
public short getThriftFieldId() {
|
|
|
110 |
return _thriftId;
|
|
|
111 |
}
|
|
|
112 |
|
|
|
113 |
public String getFieldName() {
|
|
|
114 |
return _fieldName;
|
|
|
115 |
}
|
|
|
116 |
}
|
|
|
117 |
|
|
|
118 |
// isset id assignments
|
|
|
119 |
private static final int __USERID_ISSET_ID = 0;
|
|
|
120 |
private static final int __ADDEDON_ISSET_ID = 1;
|
|
|
121 |
private static final int __ISACTIVE_ISSET_ID = 2;
|
| 12696 |
amit.gupta |
122 |
private static final int __COUNTERID_ISSET_ID = 3;
|
| 13146 |
manish.sha |
123 |
private static final int __BULKSHIPMENTAMOUNTLIMIT_ISSET_ID = 4;
|
| 18590 |
manish.sha |
124 |
private static final int __CREDITORASSIGNED_ISSET_ID = 5;
|
|
|
125 |
private BitSet __isset_bit_vector = new BitSet(6);
|
| 11890 |
kshitij.so |
126 |
|
|
|
127 |
public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
|
|
|
128 |
static {
|
|
|
129 |
Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
|
|
|
130 |
tmpMap.put(_Fields.USER_ID, new org.apache.thrift.meta_data.FieldMetaData("userId", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
131 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
|
|
|
132 |
tmpMap.put(_Fields.ADDED_ON, new org.apache.thrift.meta_data.FieldMetaData("addedOn", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
133 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
|
|
|
134 |
tmpMap.put(_Fields.IS_ACTIVE, new org.apache.thrift.meta_data.FieldMetaData("isActive", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
135 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
|
| 12696 |
amit.gupta |
136 |
tmpMap.put(_Fields.COUNTER_ID, new org.apache.thrift.meta_data.FieldMetaData("counterId", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
137 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
|
|
|
138 |
tmpMap.put(_Fields.TIN, new org.apache.thrift.meta_data.FieldMetaData("tin", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
139 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
|
| 13146 |
manish.sha |
140 |
tmpMap.put(_Fields.BULK_SHIPMENT_AMOUNT_LIMIT, new org.apache.thrift.meta_data.FieldMetaData("bulkShipmentAmountLimit", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
141 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
|
| 18590 |
manish.sha |
142 |
tmpMap.put(_Fields.CREDITOR_ASSIGNED, new org.apache.thrift.meta_data.FieldMetaData("creditorAssigned", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
143 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
|
| 11890 |
kshitij.so |
144 |
metaDataMap = Collections.unmodifiableMap(tmpMap);
|
|
|
145 |
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(PrivateDealUser.class, metaDataMap);
|
|
|
146 |
}
|
|
|
147 |
|
|
|
148 |
public PrivateDealUser() {
|
|
|
149 |
}
|
|
|
150 |
|
|
|
151 |
public PrivateDealUser(
|
|
|
152 |
long userId,
|
|
|
153 |
long addedOn,
|
| 12696 |
amit.gupta |
154 |
boolean isActive,
|
|
|
155 |
long counterId,
|
| 13146 |
manish.sha |
156 |
String tin,
|
| 18590 |
manish.sha |
157 |
double bulkShipmentAmountLimit,
|
|
|
158 |
boolean creditorAssigned)
|
| 11890 |
kshitij.so |
159 |
{
|
|
|
160 |
this();
|
|
|
161 |
this.userId = userId;
|
|
|
162 |
setUserIdIsSet(true);
|
|
|
163 |
this.addedOn = addedOn;
|
|
|
164 |
setAddedOnIsSet(true);
|
|
|
165 |
this.isActive = isActive;
|
|
|
166 |
setIsActiveIsSet(true);
|
| 12696 |
amit.gupta |
167 |
this.counterId = counterId;
|
|
|
168 |
setCounterIdIsSet(true);
|
|
|
169 |
this.tin = tin;
|
| 13146 |
manish.sha |
170 |
this.bulkShipmentAmountLimit = bulkShipmentAmountLimit;
|
|
|
171 |
setBulkShipmentAmountLimitIsSet(true);
|
| 18590 |
manish.sha |
172 |
this.creditorAssigned = creditorAssigned;
|
|
|
173 |
setCreditorAssignedIsSet(true);
|
| 11890 |
kshitij.so |
174 |
}
|
|
|
175 |
|
|
|
176 |
/**
|
|
|
177 |
* Performs a deep copy on <i>other</i>.
|
|
|
178 |
*/
|
|
|
179 |
public PrivateDealUser(PrivateDealUser other) {
|
|
|
180 |
__isset_bit_vector.clear();
|
|
|
181 |
__isset_bit_vector.or(other.__isset_bit_vector);
|
|
|
182 |
this.userId = other.userId;
|
|
|
183 |
this.addedOn = other.addedOn;
|
|
|
184 |
this.isActive = other.isActive;
|
| 12696 |
amit.gupta |
185 |
this.counterId = other.counterId;
|
|
|
186 |
if (other.isSetTin()) {
|
|
|
187 |
this.tin = other.tin;
|
|
|
188 |
}
|
| 13146 |
manish.sha |
189 |
this.bulkShipmentAmountLimit = other.bulkShipmentAmountLimit;
|
| 18590 |
manish.sha |
190 |
this.creditorAssigned = other.creditorAssigned;
|
| 11890 |
kshitij.so |
191 |
}
|
|
|
192 |
|
|
|
193 |
public PrivateDealUser deepCopy() {
|
|
|
194 |
return new PrivateDealUser(this);
|
|
|
195 |
}
|
|
|
196 |
|
|
|
197 |
@Override
|
|
|
198 |
public void clear() {
|
|
|
199 |
setUserIdIsSet(false);
|
|
|
200 |
this.userId = 0;
|
|
|
201 |
setAddedOnIsSet(false);
|
|
|
202 |
this.addedOn = 0;
|
|
|
203 |
setIsActiveIsSet(false);
|
|
|
204 |
this.isActive = false;
|
| 12696 |
amit.gupta |
205 |
setCounterIdIsSet(false);
|
|
|
206 |
this.counterId = 0;
|
|
|
207 |
this.tin = null;
|
| 13146 |
manish.sha |
208 |
setBulkShipmentAmountLimitIsSet(false);
|
|
|
209 |
this.bulkShipmentAmountLimit = 0.0;
|
| 18590 |
manish.sha |
210 |
setCreditorAssignedIsSet(false);
|
|
|
211 |
this.creditorAssigned = false;
|
| 11890 |
kshitij.so |
212 |
}
|
|
|
213 |
|
|
|
214 |
public long getUserId() {
|
|
|
215 |
return this.userId;
|
|
|
216 |
}
|
|
|
217 |
|
|
|
218 |
public void setUserId(long userId) {
|
|
|
219 |
this.userId = userId;
|
|
|
220 |
setUserIdIsSet(true);
|
|
|
221 |
}
|
|
|
222 |
|
|
|
223 |
public void unsetUserId() {
|
|
|
224 |
__isset_bit_vector.clear(__USERID_ISSET_ID);
|
|
|
225 |
}
|
|
|
226 |
|
|
|
227 |
/** Returns true if field userId is set (has been assigned a value) and false otherwise */
|
|
|
228 |
public boolean isSetUserId() {
|
|
|
229 |
return __isset_bit_vector.get(__USERID_ISSET_ID);
|
|
|
230 |
}
|
|
|
231 |
|
|
|
232 |
public void setUserIdIsSet(boolean value) {
|
|
|
233 |
__isset_bit_vector.set(__USERID_ISSET_ID, value);
|
|
|
234 |
}
|
|
|
235 |
|
|
|
236 |
public long getAddedOn() {
|
|
|
237 |
return this.addedOn;
|
|
|
238 |
}
|
|
|
239 |
|
|
|
240 |
public void setAddedOn(long addedOn) {
|
|
|
241 |
this.addedOn = addedOn;
|
|
|
242 |
setAddedOnIsSet(true);
|
|
|
243 |
}
|
|
|
244 |
|
|
|
245 |
public void unsetAddedOn() {
|
|
|
246 |
__isset_bit_vector.clear(__ADDEDON_ISSET_ID);
|
|
|
247 |
}
|
|
|
248 |
|
|
|
249 |
/** Returns true if field addedOn is set (has been assigned a value) and false otherwise */
|
|
|
250 |
public boolean isSetAddedOn() {
|
|
|
251 |
return __isset_bit_vector.get(__ADDEDON_ISSET_ID);
|
|
|
252 |
}
|
|
|
253 |
|
|
|
254 |
public void setAddedOnIsSet(boolean value) {
|
|
|
255 |
__isset_bit_vector.set(__ADDEDON_ISSET_ID, value);
|
|
|
256 |
}
|
|
|
257 |
|
|
|
258 |
public boolean isIsActive() {
|
|
|
259 |
return this.isActive;
|
|
|
260 |
}
|
|
|
261 |
|
|
|
262 |
public void setIsActive(boolean isActive) {
|
|
|
263 |
this.isActive = isActive;
|
|
|
264 |
setIsActiveIsSet(true);
|
|
|
265 |
}
|
|
|
266 |
|
|
|
267 |
public void unsetIsActive() {
|
|
|
268 |
__isset_bit_vector.clear(__ISACTIVE_ISSET_ID);
|
|
|
269 |
}
|
|
|
270 |
|
|
|
271 |
/** Returns true if field isActive is set (has been assigned a value) and false otherwise */
|
|
|
272 |
public boolean isSetIsActive() {
|
|
|
273 |
return __isset_bit_vector.get(__ISACTIVE_ISSET_ID);
|
|
|
274 |
}
|
|
|
275 |
|
|
|
276 |
public void setIsActiveIsSet(boolean value) {
|
|
|
277 |
__isset_bit_vector.set(__ISACTIVE_ISSET_ID, value);
|
|
|
278 |
}
|
|
|
279 |
|
| 12696 |
amit.gupta |
280 |
public long getCounterId() {
|
|
|
281 |
return this.counterId;
|
|
|
282 |
}
|
|
|
283 |
|
|
|
284 |
public void setCounterId(long counterId) {
|
|
|
285 |
this.counterId = counterId;
|
|
|
286 |
setCounterIdIsSet(true);
|
|
|
287 |
}
|
|
|
288 |
|
|
|
289 |
public void unsetCounterId() {
|
|
|
290 |
__isset_bit_vector.clear(__COUNTERID_ISSET_ID);
|
|
|
291 |
}
|
|
|
292 |
|
|
|
293 |
/** Returns true if field counterId is set (has been assigned a value) and false otherwise */
|
|
|
294 |
public boolean isSetCounterId() {
|
|
|
295 |
return __isset_bit_vector.get(__COUNTERID_ISSET_ID);
|
|
|
296 |
}
|
|
|
297 |
|
|
|
298 |
public void setCounterIdIsSet(boolean value) {
|
|
|
299 |
__isset_bit_vector.set(__COUNTERID_ISSET_ID, value);
|
|
|
300 |
}
|
|
|
301 |
|
|
|
302 |
public String getTin() {
|
|
|
303 |
return this.tin;
|
|
|
304 |
}
|
|
|
305 |
|
|
|
306 |
public void setTin(String tin) {
|
|
|
307 |
this.tin = tin;
|
|
|
308 |
}
|
|
|
309 |
|
|
|
310 |
public void unsetTin() {
|
|
|
311 |
this.tin = null;
|
|
|
312 |
}
|
|
|
313 |
|
|
|
314 |
/** Returns true if field tin is set (has been assigned a value) and false otherwise */
|
|
|
315 |
public boolean isSetTin() {
|
|
|
316 |
return this.tin != null;
|
|
|
317 |
}
|
|
|
318 |
|
|
|
319 |
public void setTinIsSet(boolean value) {
|
|
|
320 |
if (!value) {
|
|
|
321 |
this.tin = null;
|
|
|
322 |
}
|
|
|
323 |
}
|
|
|
324 |
|
| 13146 |
manish.sha |
325 |
public double getBulkShipmentAmountLimit() {
|
|
|
326 |
return this.bulkShipmentAmountLimit;
|
|
|
327 |
}
|
|
|
328 |
|
|
|
329 |
public void setBulkShipmentAmountLimit(double bulkShipmentAmountLimit) {
|
|
|
330 |
this.bulkShipmentAmountLimit = bulkShipmentAmountLimit;
|
|
|
331 |
setBulkShipmentAmountLimitIsSet(true);
|
|
|
332 |
}
|
|
|
333 |
|
|
|
334 |
public void unsetBulkShipmentAmountLimit() {
|
|
|
335 |
__isset_bit_vector.clear(__BULKSHIPMENTAMOUNTLIMIT_ISSET_ID);
|
|
|
336 |
}
|
|
|
337 |
|
|
|
338 |
/** Returns true if field bulkShipmentAmountLimit is set (has been assigned a value) and false otherwise */
|
|
|
339 |
public boolean isSetBulkShipmentAmountLimit() {
|
|
|
340 |
return __isset_bit_vector.get(__BULKSHIPMENTAMOUNTLIMIT_ISSET_ID);
|
|
|
341 |
}
|
|
|
342 |
|
|
|
343 |
public void setBulkShipmentAmountLimitIsSet(boolean value) {
|
|
|
344 |
__isset_bit_vector.set(__BULKSHIPMENTAMOUNTLIMIT_ISSET_ID, value);
|
|
|
345 |
}
|
|
|
346 |
|
| 18590 |
manish.sha |
347 |
public boolean isCreditorAssigned() {
|
|
|
348 |
return this.creditorAssigned;
|
|
|
349 |
}
|
|
|
350 |
|
|
|
351 |
public void setCreditorAssigned(boolean creditorAssigned) {
|
|
|
352 |
this.creditorAssigned = creditorAssigned;
|
|
|
353 |
setCreditorAssignedIsSet(true);
|
|
|
354 |
}
|
|
|
355 |
|
|
|
356 |
public void unsetCreditorAssigned() {
|
|
|
357 |
__isset_bit_vector.clear(__CREDITORASSIGNED_ISSET_ID);
|
|
|
358 |
}
|
|
|
359 |
|
|
|
360 |
/** Returns true if field creditorAssigned is set (has been assigned a value) and false otherwise */
|
|
|
361 |
public boolean isSetCreditorAssigned() {
|
|
|
362 |
return __isset_bit_vector.get(__CREDITORASSIGNED_ISSET_ID);
|
|
|
363 |
}
|
|
|
364 |
|
|
|
365 |
public void setCreditorAssignedIsSet(boolean value) {
|
|
|
366 |
__isset_bit_vector.set(__CREDITORASSIGNED_ISSET_ID, value);
|
|
|
367 |
}
|
|
|
368 |
|
| 11890 |
kshitij.so |
369 |
public void setFieldValue(_Fields field, Object value) {
|
|
|
370 |
switch (field) {
|
|
|
371 |
case USER_ID:
|
|
|
372 |
if (value == null) {
|
|
|
373 |
unsetUserId();
|
|
|
374 |
} else {
|
|
|
375 |
setUserId((Long)value);
|
|
|
376 |
}
|
|
|
377 |
break;
|
|
|
378 |
|
|
|
379 |
case ADDED_ON:
|
|
|
380 |
if (value == null) {
|
|
|
381 |
unsetAddedOn();
|
|
|
382 |
} else {
|
|
|
383 |
setAddedOn((Long)value);
|
|
|
384 |
}
|
|
|
385 |
break;
|
|
|
386 |
|
|
|
387 |
case IS_ACTIVE:
|
|
|
388 |
if (value == null) {
|
|
|
389 |
unsetIsActive();
|
|
|
390 |
} else {
|
|
|
391 |
setIsActive((Boolean)value);
|
|
|
392 |
}
|
|
|
393 |
break;
|
|
|
394 |
|
| 12696 |
amit.gupta |
395 |
case COUNTER_ID:
|
|
|
396 |
if (value == null) {
|
|
|
397 |
unsetCounterId();
|
|
|
398 |
} else {
|
|
|
399 |
setCounterId((Long)value);
|
|
|
400 |
}
|
|
|
401 |
break;
|
|
|
402 |
|
|
|
403 |
case TIN:
|
|
|
404 |
if (value == null) {
|
|
|
405 |
unsetTin();
|
|
|
406 |
} else {
|
|
|
407 |
setTin((String)value);
|
|
|
408 |
}
|
|
|
409 |
break;
|
|
|
410 |
|
| 13146 |
manish.sha |
411 |
case BULK_SHIPMENT_AMOUNT_LIMIT:
|
|
|
412 |
if (value == null) {
|
|
|
413 |
unsetBulkShipmentAmountLimit();
|
|
|
414 |
} else {
|
|
|
415 |
setBulkShipmentAmountLimit((Double)value);
|
|
|
416 |
}
|
|
|
417 |
break;
|
|
|
418 |
|
| 18590 |
manish.sha |
419 |
case CREDITOR_ASSIGNED:
|
|
|
420 |
if (value == null) {
|
|
|
421 |
unsetCreditorAssigned();
|
|
|
422 |
} else {
|
|
|
423 |
setCreditorAssigned((Boolean)value);
|
|
|
424 |
}
|
|
|
425 |
break;
|
|
|
426 |
|
| 11890 |
kshitij.so |
427 |
}
|
|
|
428 |
}
|
|
|
429 |
|
|
|
430 |
public Object getFieldValue(_Fields field) {
|
|
|
431 |
switch (field) {
|
|
|
432 |
case USER_ID:
|
|
|
433 |
return Long.valueOf(getUserId());
|
|
|
434 |
|
|
|
435 |
case ADDED_ON:
|
|
|
436 |
return Long.valueOf(getAddedOn());
|
|
|
437 |
|
|
|
438 |
case IS_ACTIVE:
|
|
|
439 |
return Boolean.valueOf(isIsActive());
|
|
|
440 |
|
| 12696 |
amit.gupta |
441 |
case COUNTER_ID:
|
|
|
442 |
return Long.valueOf(getCounterId());
|
|
|
443 |
|
|
|
444 |
case TIN:
|
|
|
445 |
return getTin();
|
|
|
446 |
|
| 13146 |
manish.sha |
447 |
case BULK_SHIPMENT_AMOUNT_LIMIT:
|
|
|
448 |
return Double.valueOf(getBulkShipmentAmountLimit());
|
|
|
449 |
|
| 18590 |
manish.sha |
450 |
case CREDITOR_ASSIGNED:
|
|
|
451 |
return Boolean.valueOf(isCreditorAssigned());
|
|
|
452 |
|
| 11890 |
kshitij.so |
453 |
}
|
|
|
454 |
throw new IllegalStateException();
|
|
|
455 |
}
|
|
|
456 |
|
|
|
457 |
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
|
|
|
458 |
public boolean isSet(_Fields field) {
|
|
|
459 |
if (field == null) {
|
|
|
460 |
throw new IllegalArgumentException();
|
|
|
461 |
}
|
|
|
462 |
|
|
|
463 |
switch (field) {
|
|
|
464 |
case USER_ID:
|
|
|
465 |
return isSetUserId();
|
|
|
466 |
case ADDED_ON:
|
|
|
467 |
return isSetAddedOn();
|
|
|
468 |
case IS_ACTIVE:
|
|
|
469 |
return isSetIsActive();
|
| 12696 |
amit.gupta |
470 |
case COUNTER_ID:
|
|
|
471 |
return isSetCounterId();
|
|
|
472 |
case TIN:
|
|
|
473 |
return isSetTin();
|
| 13146 |
manish.sha |
474 |
case BULK_SHIPMENT_AMOUNT_LIMIT:
|
|
|
475 |
return isSetBulkShipmentAmountLimit();
|
| 18590 |
manish.sha |
476 |
case CREDITOR_ASSIGNED:
|
|
|
477 |
return isSetCreditorAssigned();
|
| 11890 |
kshitij.so |
478 |
}
|
|
|
479 |
throw new IllegalStateException();
|
|
|
480 |
}
|
|
|
481 |
|
|
|
482 |
@Override
|
|
|
483 |
public boolean equals(Object that) {
|
|
|
484 |
if (that == null)
|
|
|
485 |
return false;
|
|
|
486 |
if (that instanceof PrivateDealUser)
|
|
|
487 |
return this.equals((PrivateDealUser)that);
|
|
|
488 |
return false;
|
|
|
489 |
}
|
|
|
490 |
|
|
|
491 |
public boolean equals(PrivateDealUser that) {
|
|
|
492 |
if (that == null)
|
|
|
493 |
return false;
|
|
|
494 |
|
|
|
495 |
boolean this_present_userId = true;
|
|
|
496 |
boolean that_present_userId = true;
|
|
|
497 |
if (this_present_userId || that_present_userId) {
|
|
|
498 |
if (!(this_present_userId && that_present_userId))
|
|
|
499 |
return false;
|
|
|
500 |
if (this.userId != that.userId)
|
|
|
501 |
return false;
|
|
|
502 |
}
|
|
|
503 |
|
|
|
504 |
boolean this_present_addedOn = true;
|
|
|
505 |
boolean that_present_addedOn = true;
|
|
|
506 |
if (this_present_addedOn || that_present_addedOn) {
|
|
|
507 |
if (!(this_present_addedOn && that_present_addedOn))
|
|
|
508 |
return false;
|
|
|
509 |
if (this.addedOn != that.addedOn)
|
|
|
510 |
return false;
|
|
|
511 |
}
|
|
|
512 |
|
|
|
513 |
boolean this_present_isActive = true;
|
|
|
514 |
boolean that_present_isActive = true;
|
|
|
515 |
if (this_present_isActive || that_present_isActive) {
|
|
|
516 |
if (!(this_present_isActive && that_present_isActive))
|
|
|
517 |
return false;
|
|
|
518 |
if (this.isActive != that.isActive)
|
|
|
519 |
return false;
|
|
|
520 |
}
|
|
|
521 |
|
| 12696 |
amit.gupta |
522 |
boolean this_present_counterId = true;
|
|
|
523 |
boolean that_present_counterId = true;
|
|
|
524 |
if (this_present_counterId || that_present_counterId) {
|
|
|
525 |
if (!(this_present_counterId && that_present_counterId))
|
|
|
526 |
return false;
|
|
|
527 |
if (this.counterId != that.counterId)
|
|
|
528 |
return false;
|
|
|
529 |
}
|
|
|
530 |
|
|
|
531 |
boolean this_present_tin = true && this.isSetTin();
|
|
|
532 |
boolean that_present_tin = true && that.isSetTin();
|
|
|
533 |
if (this_present_tin || that_present_tin) {
|
|
|
534 |
if (!(this_present_tin && that_present_tin))
|
|
|
535 |
return false;
|
|
|
536 |
if (!this.tin.equals(that.tin))
|
|
|
537 |
return false;
|
|
|
538 |
}
|
|
|
539 |
|
| 13146 |
manish.sha |
540 |
boolean this_present_bulkShipmentAmountLimit = true;
|
|
|
541 |
boolean that_present_bulkShipmentAmountLimit = true;
|
|
|
542 |
if (this_present_bulkShipmentAmountLimit || that_present_bulkShipmentAmountLimit) {
|
|
|
543 |
if (!(this_present_bulkShipmentAmountLimit && that_present_bulkShipmentAmountLimit))
|
|
|
544 |
return false;
|
|
|
545 |
if (this.bulkShipmentAmountLimit != that.bulkShipmentAmountLimit)
|
|
|
546 |
return false;
|
|
|
547 |
}
|
|
|
548 |
|
| 18590 |
manish.sha |
549 |
boolean this_present_creditorAssigned = true;
|
|
|
550 |
boolean that_present_creditorAssigned = true;
|
|
|
551 |
if (this_present_creditorAssigned || that_present_creditorAssigned) {
|
|
|
552 |
if (!(this_present_creditorAssigned && that_present_creditorAssigned))
|
|
|
553 |
return false;
|
|
|
554 |
if (this.creditorAssigned != that.creditorAssigned)
|
|
|
555 |
return false;
|
|
|
556 |
}
|
|
|
557 |
|
| 11890 |
kshitij.so |
558 |
return true;
|
|
|
559 |
}
|
|
|
560 |
|
|
|
561 |
@Override
|
|
|
562 |
public int hashCode() {
|
|
|
563 |
return 0;
|
|
|
564 |
}
|
|
|
565 |
|
|
|
566 |
public int compareTo(PrivateDealUser other) {
|
|
|
567 |
if (!getClass().equals(other.getClass())) {
|
|
|
568 |
return getClass().getName().compareTo(other.getClass().getName());
|
|
|
569 |
}
|
|
|
570 |
|
|
|
571 |
int lastComparison = 0;
|
|
|
572 |
PrivateDealUser typedOther = (PrivateDealUser)other;
|
|
|
573 |
|
|
|
574 |
lastComparison = Boolean.valueOf(isSetUserId()).compareTo(typedOther.isSetUserId());
|
|
|
575 |
if (lastComparison != 0) {
|
|
|
576 |
return lastComparison;
|
|
|
577 |
}
|
|
|
578 |
if (isSetUserId()) {
|
|
|
579 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.userId, typedOther.userId);
|
|
|
580 |
if (lastComparison != 0) {
|
|
|
581 |
return lastComparison;
|
|
|
582 |
}
|
|
|
583 |
}
|
|
|
584 |
lastComparison = Boolean.valueOf(isSetAddedOn()).compareTo(typedOther.isSetAddedOn());
|
|
|
585 |
if (lastComparison != 0) {
|
|
|
586 |
return lastComparison;
|
|
|
587 |
}
|
|
|
588 |
if (isSetAddedOn()) {
|
|
|
589 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.addedOn, typedOther.addedOn);
|
|
|
590 |
if (lastComparison != 0) {
|
|
|
591 |
return lastComparison;
|
|
|
592 |
}
|
|
|
593 |
}
|
|
|
594 |
lastComparison = Boolean.valueOf(isSetIsActive()).compareTo(typedOther.isSetIsActive());
|
|
|
595 |
if (lastComparison != 0) {
|
|
|
596 |
return lastComparison;
|
|
|
597 |
}
|
|
|
598 |
if (isSetIsActive()) {
|
|
|
599 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isActive, typedOther.isActive);
|
|
|
600 |
if (lastComparison != 0) {
|
|
|
601 |
return lastComparison;
|
|
|
602 |
}
|
|
|
603 |
}
|
| 12696 |
amit.gupta |
604 |
lastComparison = Boolean.valueOf(isSetCounterId()).compareTo(typedOther.isSetCounterId());
|
|
|
605 |
if (lastComparison != 0) {
|
|
|
606 |
return lastComparison;
|
|
|
607 |
}
|
|
|
608 |
if (isSetCounterId()) {
|
|
|
609 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.counterId, typedOther.counterId);
|
|
|
610 |
if (lastComparison != 0) {
|
|
|
611 |
return lastComparison;
|
|
|
612 |
}
|
|
|
613 |
}
|
|
|
614 |
lastComparison = Boolean.valueOf(isSetTin()).compareTo(typedOther.isSetTin());
|
|
|
615 |
if (lastComparison != 0) {
|
|
|
616 |
return lastComparison;
|
|
|
617 |
}
|
|
|
618 |
if (isSetTin()) {
|
|
|
619 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.tin, typedOther.tin);
|
|
|
620 |
if (lastComparison != 0) {
|
|
|
621 |
return lastComparison;
|
|
|
622 |
}
|
|
|
623 |
}
|
| 13146 |
manish.sha |
624 |
lastComparison = Boolean.valueOf(isSetBulkShipmentAmountLimit()).compareTo(typedOther.isSetBulkShipmentAmountLimit());
|
|
|
625 |
if (lastComparison != 0) {
|
|
|
626 |
return lastComparison;
|
|
|
627 |
}
|
|
|
628 |
if (isSetBulkShipmentAmountLimit()) {
|
|
|
629 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.bulkShipmentAmountLimit, typedOther.bulkShipmentAmountLimit);
|
|
|
630 |
if (lastComparison != 0) {
|
|
|
631 |
return lastComparison;
|
|
|
632 |
}
|
|
|
633 |
}
|
| 18590 |
manish.sha |
634 |
lastComparison = Boolean.valueOf(isSetCreditorAssigned()).compareTo(typedOther.isSetCreditorAssigned());
|
|
|
635 |
if (lastComparison != 0) {
|
|
|
636 |
return lastComparison;
|
|
|
637 |
}
|
|
|
638 |
if (isSetCreditorAssigned()) {
|
|
|
639 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.creditorAssigned, typedOther.creditorAssigned);
|
|
|
640 |
if (lastComparison != 0) {
|
|
|
641 |
return lastComparison;
|
|
|
642 |
}
|
|
|
643 |
}
|
| 11890 |
kshitij.so |
644 |
return 0;
|
|
|
645 |
}
|
|
|
646 |
|
|
|
647 |
public _Fields fieldForId(int fieldId) {
|
|
|
648 |
return _Fields.findByThriftId(fieldId);
|
|
|
649 |
}
|
|
|
650 |
|
|
|
651 |
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
|
|
|
652 |
org.apache.thrift.protocol.TField field;
|
|
|
653 |
iprot.readStructBegin();
|
|
|
654 |
while (true)
|
|
|
655 |
{
|
|
|
656 |
field = iprot.readFieldBegin();
|
|
|
657 |
if (field.type == org.apache.thrift.protocol.TType.STOP) {
|
|
|
658 |
break;
|
|
|
659 |
}
|
|
|
660 |
switch (field.id) {
|
|
|
661 |
case 1: // USER_ID
|
|
|
662 |
if (field.type == org.apache.thrift.protocol.TType.I64) {
|
|
|
663 |
this.userId = iprot.readI64();
|
|
|
664 |
setUserIdIsSet(true);
|
|
|
665 |
} else {
|
|
|
666 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
667 |
}
|
|
|
668 |
break;
|
|
|
669 |
case 2: // ADDED_ON
|
|
|
670 |
if (field.type == org.apache.thrift.protocol.TType.I64) {
|
|
|
671 |
this.addedOn = iprot.readI64();
|
|
|
672 |
setAddedOnIsSet(true);
|
|
|
673 |
} else {
|
|
|
674 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
675 |
}
|
|
|
676 |
break;
|
|
|
677 |
case 3: // IS_ACTIVE
|
|
|
678 |
if (field.type == org.apache.thrift.protocol.TType.BOOL) {
|
|
|
679 |
this.isActive = iprot.readBool();
|
|
|
680 |
setIsActiveIsSet(true);
|
|
|
681 |
} else {
|
|
|
682 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
683 |
}
|
|
|
684 |
break;
|
| 12696 |
amit.gupta |
685 |
case 4: // COUNTER_ID
|
|
|
686 |
if (field.type == org.apache.thrift.protocol.TType.I64) {
|
|
|
687 |
this.counterId = iprot.readI64();
|
|
|
688 |
setCounterIdIsSet(true);
|
|
|
689 |
} else {
|
|
|
690 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
691 |
}
|
|
|
692 |
break;
|
|
|
693 |
case 5: // TIN
|
|
|
694 |
if (field.type == org.apache.thrift.protocol.TType.STRING) {
|
|
|
695 |
this.tin = iprot.readString();
|
|
|
696 |
} else {
|
|
|
697 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
698 |
}
|
|
|
699 |
break;
|
| 13146 |
manish.sha |
700 |
case 6: // BULK_SHIPMENT_AMOUNT_LIMIT
|
|
|
701 |
if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
|
|
|
702 |
this.bulkShipmentAmountLimit = iprot.readDouble();
|
|
|
703 |
setBulkShipmentAmountLimitIsSet(true);
|
|
|
704 |
} else {
|
|
|
705 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
706 |
}
|
|
|
707 |
break;
|
| 18590 |
manish.sha |
708 |
case 7: // CREDITOR_ASSIGNED
|
|
|
709 |
if (field.type == org.apache.thrift.protocol.TType.BOOL) {
|
|
|
710 |
this.creditorAssigned = iprot.readBool();
|
|
|
711 |
setCreditorAssignedIsSet(true);
|
|
|
712 |
} else {
|
|
|
713 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
714 |
}
|
|
|
715 |
break;
|
| 11890 |
kshitij.so |
716 |
default:
|
|
|
717 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
718 |
}
|
|
|
719 |
iprot.readFieldEnd();
|
|
|
720 |
}
|
|
|
721 |
iprot.readStructEnd();
|
|
|
722 |
validate();
|
|
|
723 |
}
|
|
|
724 |
|
|
|
725 |
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
|
|
|
726 |
validate();
|
|
|
727 |
|
|
|
728 |
oprot.writeStructBegin(STRUCT_DESC);
|
|
|
729 |
oprot.writeFieldBegin(USER_ID_FIELD_DESC);
|
|
|
730 |
oprot.writeI64(this.userId);
|
|
|
731 |
oprot.writeFieldEnd();
|
|
|
732 |
oprot.writeFieldBegin(ADDED_ON_FIELD_DESC);
|
|
|
733 |
oprot.writeI64(this.addedOn);
|
|
|
734 |
oprot.writeFieldEnd();
|
|
|
735 |
oprot.writeFieldBegin(IS_ACTIVE_FIELD_DESC);
|
|
|
736 |
oprot.writeBool(this.isActive);
|
|
|
737 |
oprot.writeFieldEnd();
|
| 12696 |
amit.gupta |
738 |
oprot.writeFieldBegin(COUNTER_ID_FIELD_DESC);
|
|
|
739 |
oprot.writeI64(this.counterId);
|
|
|
740 |
oprot.writeFieldEnd();
|
|
|
741 |
if (this.tin != null) {
|
|
|
742 |
oprot.writeFieldBegin(TIN_FIELD_DESC);
|
|
|
743 |
oprot.writeString(this.tin);
|
|
|
744 |
oprot.writeFieldEnd();
|
|
|
745 |
}
|
| 13146 |
manish.sha |
746 |
oprot.writeFieldBegin(BULK_SHIPMENT_AMOUNT_LIMIT_FIELD_DESC);
|
|
|
747 |
oprot.writeDouble(this.bulkShipmentAmountLimit);
|
|
|
748 |
oprot.writeFieldEnd();
|
| 18590 |
manish.sha |
749 |
oprot.writeFieldBegin(CREDITOR_ASSIGNED_FIELD_DESC);
|
|
|
750 |
oprot.writeBool(this.creditorAssigned);
|
|
|
751 |
oprot.writeFieldEnd();
|
| 11890 |
kshitij.so |
752 |
oprot.writeFieldStop();
|
|
|
753 |
oprot.writeStructEnd();
|
|
|
754 |
}
|
|
|
755 |
|
|
|
756 |
@Override
|
|
|
757 |
public String toString() {
|
|
|
758 |
StringBuilder sb = new StringBuilder("PrivateDealUser(");
|
|
|
759 |
boolean first = true;
|
|
|
760 |
|
|
|
761 |
sb.append("userId:");
|
|
|
762 |
sb.append(this.userId);
|
|
|
763 |
first = false;
|
|
|
764 |
if (!first) sb.append(", ");
|
|
|
765 |
sb.append("addedOn:");
|
|
|
766 |
sb.append(this.addedOn);
|
|
|
767 |
first = false;
|
|
|
768 |
if (!first) sb.append(", ");
|
|
|
769 |
sb.append("isActive:");
|
|
|
770 |
sb.append(this.isActive);
|
|
|
771 |
first = false;
|
| 12696 |
amit.gupta |
772 |
if (!first) sb.append(", ");
|
|
|
773 |
sb.append("counterId:");
|
|
|
774 |
sb.append(this.counterId);
|
|
|
775 |
first = false;
|
|
|
776 |
if (!first) sb.append(", ");
|
|
|
777 |
sb.append("tin:");
|
|
|
778 |
if (this.tin == null) {
|
|
|
779 |
sb.append("null");
|
|
|
780 |
} else {
|
|
|
781 |
sb.append(this.tin);
|
|
|
782 |
}
|
|
|
783 |
first = false;
|
| 13146 |
manish.sha |
784 |
if (!first) sb.append(", ");
|
|
|
785 |
sb.append("bulkShipmentAmountLimit:");
|
|
|
786 |
sb.append(this.bulkShipmentAmountLimit);
|
|
|
787 |
first = false;
|
| 18590 |
manish.sha |
788 |
if (!first) sb.append(", ");
|
|
|
789 |
sb.append("creditorAssigned:");
|
|
|
790 |
sb.append(this.creditorAssigned);
|
|
|
791 |
first = false;
|
| 11890 |
kshitij.so |
792 |
sb.append(")");
|
|
|
793 |
return sb.toString();
|
|
|
794 |
}
|
|
|
795 |
|
|
|
796 |
public void validate() throws org.apache.thrift.TException {
|
|
|
797 |
// check for required fields
|
|
|
798 |
}
|
|
|
799 |
|
|
|
800 |
private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
|
|
|
801 |
try {
|
|
|
802 |
write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
|
|
|
803 |
} catch (org.apache.thrift.TException te) {
|
|
|
804 |
throw new java.io.IOException(te);
|
|
|
805 |
}
|
|
|
806 |
}
|
|
|
807 |
|
|
|
808 |
private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
|
|
|
809 |
try {
|
|
|
810 |
// it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
|
|
|
811 |
__isset_bit_vector = new BitSet(1);
|
|
|
812 |
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
|
|
|
813 |
} catch (org.apache.thrift.TException te) {
|
|
|
814 |
throw new java.io.IOException(te);
|
|
|
815 |
}
|
|
|
816 |
}
|
|
|
817 |
|
|
|
818 |
}
|
|
|
819 |
|