| 11531 |
vikram.rag |
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.catalog;
|
|
|
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 PrivateDeal implements org.apache.thrift.TBase<PrivateDeal, PrivateDeal._Fields>, java.io.Serializable, Cloneable {
|
|
|
24 |
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("PrivateDeal");
|
|
|
25 |
|
|
|
26 |
private static final org.apache.thrift.protocol.TField ITEM_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("item_id", org.apache.thrift.protocol.TType.I64, (short)1);
|
|
|
27 |
private static final org.apache.thrift.protocol.TField DEAL_PRICE_FIELD_DESC = new org.apache.thrift.protocol.TField("dealPrice", org.apache.thrift.protocol.TType.DOUBLE, (short)2);
|
|
|
28 |
private static final org.apache.thrift.protocol.TField DEAL_FREEBIE_ITEM_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("dealFreebieItemId", org.apache.thrift.protocol.TType.I64, (short)3);
|
|
|
29 |
private static final org.apache.thrift.protocol.TField START_DATE_FIELD_DESC = new org.apache.thrift.protocol.TField("startDate", org.apache.thrift.protocol.TType.I64, (short)4);
|
|
|
30 |
private static final org.apache.thrift.protocol.TField END_DATE_FIELD_DESC = new org.apache.thrift.protocol.TField("endDate", org.apache.thrift.protocol.TType.I64, (short)5);
|
| 11580 |
vikram.rag |
31 |
private static final org.apache.thrift.protocol.TField DEAL_TEXT_OPTION_FIELD_DESC = new org.apache.thrift.protocol.TField("dealTextOption", org.apache.thrift.protocol.TType.I64, (short)6);
|
| 11531 |
vikram.rag |
32 |
private static final org.apache.thrift.protocol.TField DEAL_TEXT_FIELD_DESC = new org.apache.thrift.protocol.TField("dealText", org.apache.thrift.protocol.TType.STRING, (short)7);
|
|
|
33 |
private static final org.apache.thrift.protocol.TField IS_COD_FIELD_DESC = new org.apache.thrift.protocol.TField("isCod", org.apache.thrift.protocol.TType.BOOL, (short)8);
|
|
|
34 |
private static final org.apache.thrift.protocol.TField RANK_FIELD_DESC = new org.apache.thrift.protocol.TField("rank", org.apache.thrift.protocol.TType.I64, (short)9);
|
| 11580 |
vikram.rag |
35 |
private static final org.apache.thrift.protocol.TField DEAL_FREEBIE_OPTION_FIELD_DESC = new org.apache.thrift.protocol.TField("dealFreebieOption", org.apache.thrift.protocol.TType.I64, (short)10);
|
| 11531 |
vikram.rag |
36 |
|
|
|
37 |
private long item_id; // required
|
|
|
38 |
private double dealPrice; // required
|
|
|
39 |
private long dealFreebieItemId; // required
|
|
|
40 |
private long startDate; // required
|
|
|
41 |
private long endDate; // required
|
| 11580 |
vikram.rag |
42 |
private long dealTextOption; // required
|
| 11531 |
vikram.rag |
43 |
private String dealText; // required
|
|
|
44 |
private boolean isCod; // required
|
|
|
45 |
private long rank; // required
|
| 11580 |
vikram.rag |
46 |
private long dealFreebieOption; // required
|
| 11531 |
vikram.rag |
47 |
|
|
|
48 |
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
|
|
|
49 |
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
|
|
|
50 |
ITEM_ID((short)1, "item_id"),
|
|
|
51 |
DEAL_PRICE((short)2, "dealPrice"),
|
|
|
52 |
DEAL_FREEBIE_ITEM_ID((short)3, "dealFreebieItemId"),
|
|
|
53 |
START_DATE((short)4, "startDate"),
|
|
|
54 |
END_DATE((short)5, "endDate"),
|
| 11580 |
vikram.rag |
55 |
DEAL_TEXT_OPTION((short)6, "dealTextOption"),
|
| 11531 |
vikram.rag |
56 |
DEAL_TEXT((short)7, "dealText"),
|
|
|
57 |
IS_COD((short)8, "isCod"),
|
| 11580 |
vikram.rag |
58 |
RANK((short)9, "rank"),
|
|
|
59 |
DEAL_FREEBIE_OPTION((short)10, "dealFreebieOption");
|
| 11531 |
vikram.rag |
60 |
|
|
|
61 |
private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
|
|
|
62 |
|
|
|
63 |
static {
|
|
|
64 |
for (_Fields field : EnumSet.allOf(_Fields.class)) {
|
|
|
65 |
byName.put(field.getFieldName(), field);
|
|
|
66 |
}
|
|
|
67 |
}
|
|
|
68 |
|
|
|
69 |
/**
|
|
|
70 |
* Find the _Fields constant that matches fieldId, or null if its not found.
|
|
|
71 |
*/
|
|
|
72 |
public static _Fields findByThriftId(int fieldId) {
|
|
|
73 |
switch(fieldId) {
|
|
|
74 |
case 1: // ITEM_ID
|
|
|
75 |
return ITEM_ID;
|
|
|
76 |
case 2: // DEAL_PRICE
|
|
|
77 |
return DEAL_PRICE;
|
|
|
78 |
case 3: // DEAL_FREEBIE_ITEM_ID
|
|
|
79 |
return DEAL_FREEBIE_ITEM_ID;
|
|
|
80 |
case 4: // START_DATE
|
|
|
81 |
return START_DATE;
|
|
|
82 |
case 5: // END_DATE
|
|
|
83 |
return END_DATE;
|
| 11580 |
vikram.rag |
84 |
case 6: // DEAL_TEXT_OPTION
|
|
|
85 |
return DEAL_TEXT_OPTION;
|
| 11531 |
vikram.rag |
86 |
case 7: // DEAL_TEXT
|
|
|
87 |
return DEAL_TEXT;
|
|
|
88 |
case 8: // IS_COD
|
|
|
89 |
return IS_COD;
|
|
|
90 |
case 9: // RANK
|
|
|
91 |
return RANK;
|
| 11580 |
vikram.rag |
92 |
case 10: // DEAL_FREEBIE_OPTION
|
|
|
93 |
return DEAL_FREEBIE_OPTION;
|
| 11531 |
vikram.rag |
94 |
default:
|
|
|
95 |
return null;
|
|
|
96 |
}
|
|
|
97 |
}
|
|
|
98 |
|
|
|
99 |
/**
|
|
|
100 |
* Find the _Fields constant that matches fieldId, throwing an exception
|
|
|
101 |
* if it is not found.
|
|
|
102 |
*/
|
|
|
103 |
public static _Fields findByThriftIdOrThrow(int fieldId) {
|
|
|
104 |
_Fields fields = findByThriftId(fieldId);
|
|
|
105 |
if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
|
|
|
106 |
return fields;
|
|
|
107 |
}
|
|
|
108 |
|
|
|
109 |
/**
|
|
|
110 |
* Find the _Fields constant that matches name, or null if its not found.
|
|
|
111 |
*/
|
|
|
112 |
public static _Fields findByName(String name) {
|
|
|
113 |
return byName.get(name);
|
|
|
114 |
}
|
|
|
115 |
|
|
|
116 |
private final short _thriftId;
|
|
|
117 |
private final String _fieldName;
|
|
|
118 |
|
|
|
119 |
_Fields(short thriftId, String fieldName) {
|
|
|
120 |
_thriftId = thriftId;
|
|
|
121 |
_fieldName = fieldName;
|
|
|
122 |
}
|
|
|
123 |
|
|
|
124 |
public short getThriftFieldId() {
|
|
|
125 |
return _thriftId;
|
|
|
126 |
}
|
|
|
127 |
|
|
|
128 |
public String getFieldName() {
|
|
|
129 |
return _fieldName;
|
|
|
130 |
}
|
|
|
131 |
}
|
|
|
132 |
|
|
|
133 |
// isset id assignments
|
|
|
134 |
private static final int __ITEM_ID_ISSET_ID = 0;
|
|
|
135 |
private static final int __DEALPRICE_ISSET_ID = 1;
|
|
|
136 |
private static final int __DEALFREEBIEITEMID_ISSET_ID = 2;
|
|
|
137 |
private static final int __STARTDATE_ISSET_ID = 3;
|
|
|
138 |
private static final int __ENDDATE_ISSET_ID = 4;
|
| 11580 |
vikram.rag |
139 |
private static final int __DEALTEXTOPTION_ISSET_ID = 5;
|
| 11531 |
vikram.rag |
140 |
private static final int __ISCOD_ISSET_ID = 6;
|
|
|
141 |
private static final int __RANK_ISSET_ID = 7;
|
| 11580 |
vikram.rag |
142 |
private static final int __DEALFREEBIEOPTION_ISSET_ID = 8;
|
|
|
143 |
private BitSet __isset_bit_vector = new BitSet(9);
|
| 11531 |
vikram.rag |
144 |
|
|
|
145 |
public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
|
|
|
146 |
static {
|
|
|
147 |
Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
|
|
|
148 |
tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("item_id", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
149 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
|
|
|
150 |
tmpMap.put(_Fields.DEAL_PRICE, new org.apache.thrift.meta_data.FieldMetaData("dealPrice", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
151 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
|
|
|
152 |
tmpMap.put(_Fields.DEAL_FREEBIE_ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("dealFreebieItemId", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
153 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
|
|
|
154 |
tmpMap.put(_Fields.START_DATE, new org.apache.thrift.meta_data.FieldMetaData("startDate", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
155 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
|
|
|
156 |
tmpMap.put(_Fields.END_DATE, new org.apache.thrift.meta_data.FieldMetaData("endDate", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
157 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
|
| 11580 |
vikram.rag |
158 |
tmpMap.put(_Fields.DEAL_TEXT_OPTION, new org.apache.thrift.meta_data.FieldMetaData("dealTextOption", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
159 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
|
| 11531 |
vikram.rag |
160 |
tmpMap.put(_Fields.DEAL_TEXT, new org.apache.thrift.meta_data.FieldMetaData("dealText", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
161 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
|
|
|
162 |
tmpMap.put(_Fields.IS_COD, new org.apache.thrift.meta_data.FieldMetaData("isCod", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
163 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
|
|
|
164 |
tmpMap.put(_Fields.RANK, new org.apache.thrift.meta_data.FieldMetaData("rank", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
165 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
|
| 11580 |
vikram.rag |
166 |
tmpMap.put(_Fields.DEAL_FREEBIE_OPTION, new org.apache.thrift.meta_data.FieldMetaData("dealFreebieOption", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
167 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
|
| 11531 |
vikram.rag |
168 |
metaDataMap = Collections.unmodifiableMap(tmpMap);
|
|
|
169 |
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(PrivateDeal.class, metaDataMap);
|
|
|
170 |
}
|
|
|
171 |
|
|
|
172 |
public PrivateDeal() {
|
|
|
173 |
}
|
|
|
174 |
|
|
|
175 |
public PrivateDeal(
|
|
|
176 |
long item_id,
|
|
|
177 |
double dealPrice,
|
|
|
178 |
long dealFreebieItemId,
|
|
|
179 |
long startDate,
|
|
|
180 |
long endDate,
|
| 11580 |
vikram.rag |
181 |
long dealTextOption,
|
| 11531 |
vikram.rag |
182 |
String dealText,
|
|
|
183 |
boolean isCod,
|
| 11580 |
vikram.rag |
184 |
long rank,
|
|
|
185 |
long dealFreebieOption)
|
| 11531 |
vikram.rag |
186 |
{
|
|
|
187 |
this();
|
|
|
188 |
this.item_id = item_id;
|
|
|
189 |
setItem_idIsSet(true);
|
|
|
190 |
this.dealPrice = dealPrice;
|
|
|
191 |
setDealPriceIsSet(true);
|
|
|
192 |
this.dealFreebieItemId = dealFreebieItemId;
|
|
|
193 |
setDealFreebieItemIdIsSet(true);
|
|
|
194 |
this.startDate = startDate;
|
|
|
195 |
setStartDateIsSet(true);
|
|
|
196 |
this.endDate = endDate;
|
|
|
197 |
setEndDateIsSet(true);
|
| 11580 |
vikram.rag |
198 |
this.dealTextOption = dealTextOption;
|
|
|
199 |
setDealTextOptionIsSet(true);
|
| 11531 |
vikram.rag |
200 |
this.dealText = dealText;
|
|
|
201 |
this.isCod = isCod;
|
|
|
202 |
setIsCodIsSet(true);
|
|
|
203 |
this.rank = rank;
|
|
|
204 |
setRankIsSet(true);
|
| 11580 |
vikram.rag |
205 |
this.dealFreebieOption = dealFreebieOption;
|
|
|
206 |
setDealFreebieOptionIsSet(true);
|
| 11531 |
vikram.rag |
207 |
}
|
|
|
208 |
|
|
|
209 |
/**
|
|
|
210 |
* Performs a deep copy on <i>other</i>.
|
|
|
211 |
*/
|
|
|
212 |
public PrivateDeal(PrivateDeal other) {
|
|
|
213 |
__isset_bit_vector.clear();
|
|
|
214 |
__isset_bit_vector.or(other.__isset_bit_vector);
|
|
|
215 |
this.item_id = other.item_id;
|
|
|
216 |
this.dealPrice = other.dealPrice;
|
|
|
217 |
this.dealFreebieItemId = other.dealFreebieItemId;
|
|
|
218 |
this.startDate = other.startDate;
|
|
|
219 |
this.endDate = other.endDate;
|
| 11580 |
vikram.rag |
220 |
this.dealTextOption = other.dealTextOption;
|
| 11531 |
vikram.rag |
221 |
if (other.isSetDealText()) {
|
|
|
222 |
this.dealText = other.dealText;
|
|
|
223 |
}
|
|
|
224 |
this.isCod = other.isCod;
|
|
|
225 |
this.rank = other.rank;
|
| 11580 |
vikram.rag |
226 |
this.dealFreebieOption = other.dealFreebieOption;
|
| 11531 |
vikram.rag |
227 |
}
|
|
|
228 |
|
|
|
229 |
public PrivateDeal deepCopy() {
|
|
|
230 |
return new PrivateDeal(this);
|
|
|
231 |
}
|
|
|
232 |
|
|
|
233 |
@Override
|
|
|
234 |
public void clear() {
|
|
|
235 |
setItem_idIsSet(false);
|
|
|
236 |
this.item_id = 0;
|
|
|
237 |
setDealPriceIsSet(false);
|
|
|
238 |
this.dealPrice = 0.0;
|
|
|
239 |
setDealFreebieItemIdIsSet(false);
|
|
|
240 |
this.dealFreebieItemId = 0;
|
|
|
241 |
setStartDateIsSet(false);
|
|
|
242 |
this.startDate = 0;
|
|
|
243 |
setEndDateIsSet(false);
|
|
|
244 |
this.endDate = 0;
|
| 11580 |
vikram.rag |
245 |
setDealTextOptionIsSet(false);
|
|
|
246 |
this.dealTextOption = 0;
|
| 11531 |
vikram.rag |
247 |
this.dealText = null;
|
|
|
248 |
setIsCodIsSet(false);
|
|
|
249 |
this.isCod = false;
|
|
|
250 |
setRankIsSet(false);
|
|
|
251 |
this.rank = 0;
|
| 11580 |
vikram.rag |
252 |
setDealFreebieOptionIsSet(false);
|
|
|
253 |
this.dealFreebieOption = 0;
|
| 11531 |
vikram.rag |
254 |
}
|
|
|
255 |
|
|
|
256 |
public long getItem_id() {
|
|
|
257 |
return this.item_id;
|
|
|
258 |
}
|
|
|
259 |
|
|
|
260 |
public void setItem_id(long item_id) {
|
|
|
261 |
this.item_id = item_id;
|
|
|
262 |
setItem_idIsSet(true);
|
|
|
263 |
}
|
|
|
264 |
|
|
|
265 |
public void unsetItem_id() {
|
|
|
266 |
__isset_bit_vector.clear(__ITEM_ID_ISSET_ID);
|
|
|
267 |
}
|
|
|
268 |
|
|
|
269 |
/** Returns true if field item_id is set (has been assigned a value) and false otherwise */
|
|
|
270 |
public boolean isSetItem_id() {
|
|
|
271 |
return __isset_bit_vector.get(__ITEM_ID_ISSET_ID);
|
|
|
272 |
}
|
|
|
273 |
|
|
|
274 |
public void setItem_idIsSet(boolean value) {
|
|
|
275 |
__isset_bit_vector.set(__ITEM_ID_ISSET_ID, value);
|
|
|
276 |
}
|
|
|
277 |
|
|
|
278 |
public double getDealPrice() {
|
|
|
279 |
return this.dealPrice;
|
|
|
280 |
}
|
|
|
281 |
|
|
|
282 |
public void setDealPrice(double dealPrice) {
|
|
|
283 |
this.dealPrice = dealPrice;
|
|
|
284 |
setDealPriceIsSet(true);
|
|
|
285 |
}
|
|
|
286 |
|
|
|
287 |
public void unsetDealPrice() {
|
|
|
288 |
__isset_bit_vector.clear(__DEALPRICE_ISSET_ID);
|
|
|
289 |
}
|
|
|
290 |
|
|
|
291 |
/** Returns true if field dealPrice is set (has been assigned a value) and false otherwise */
|
|
|
292 |
public boolean isSetDealPrice() {
|
|
|
293 |
return __isset_bit_vector.get(__DEALPRICE_ISSET_ID);
|
|
|
294 |
}
|
|
|
295 |
|
|
|
296 |
public void setDealPriceIsSet(boolean value) {
|
|
|
297 |
__isset_bit_vector.set(__DEALPRICE_ISSET_ID, value);
|
|
|
298 |
}
|
|
|
299 |
|
|
|
300 |
public long getDealFreebieItemId() {
|
|
|
301 |
return this.dealFreebieItemId;
|
|
|
302 |
}
|
|
|
303 |
|
|
|
304 |
public void setDealFreebieItemId(long dealFreebieItemId) {
|
|
|
305 |
this.dealFreebieItemId = dealFreebieItemId;
|
|
|
306 |
setDealFreebieItemIdIsSet(true);
|
|
|
307 |
}
|
|
|
308 |
|
|
|
309 |
public void unsetDealFreebieItemId() {
|
|
|
310 |
__isset_bit_vector.clear(__DEALFREEBIEITEMID_ISSET_ID);
|
|
|
311 |
}
|
|
|
312 |
|
|
|
313 |
/** Returns true if field dealFreebieItemId is set (has been assigned a value) and false otherwise */
|
|
|
314 |
public boolean isSetDealFreebieItemId() {
|
|
|
315 |
return __isset_bit_vector.get(__DEALFREEBIEITEMID_ISSET_ID);
|
|
|
316 |
}
|
|
|
317 |
|
|
|
318 |
public void setDealFreebieItemIdIsSet(boolean value) {
|
|
|
319 |
__isset_bit_vector.set(__DEALFREEBIEITEMID_ISSET_ID, value);
|
|
|
320 |
}
|
|
|
321 |
|
|
|
322 |
public long getStartDate() {
|
|
|
323 |
return this.startDate;
|
|
|
324 |
}
|
|
|
325 |
|
|
|
326 |
public void setStartDate(long startDate) {
|
|
|
327 |
this.startDate = startDate;
|
|
|
328 |
setStartDateIsSet(true);
|
|
|
329 |
}
|
|
|
330 |
|
|
|
331 |
public void unsetStartDate() {
|
|
|
332 |
__isset_bit_vector.clear(__STARTDATE_ISSET_ID);
|
|
|
333 |
}
|
|
|
334 |
|
|
|
335 |
/** Returns true if field startDate is set (has been assigned a value) and false otherwise */
|
|
|
336 |
public boolean isSetStartDate() {
|
|
|
337 |
return __isset_bit_vector.get(__STARTDATE_ISSET_ID);
|
|
|
338 |
}
|
|
|
339 |
|
|
|
340 |
public void setStartDateIsSet(boolean value) {
|
|
|
341 |
__isset_bit_vector.set(__STARTDATE_ISSET_ID, value);
|
|
|
342 |
}
|
|
|
343 |
|
|
|
344 |
public long getEndDate() {
|
|
|
345 |
return this.endDate;
|
|
|
346 |
}
|
|
|
347 |
|
|
|
348 |
public void setEndDate(long endDate) {
|
|
|
349 |
this.endDate = endDate;
|
|
|
350 |
setEndDateIsSet(true);
|
|
|
351 |
}
|
|
|
352 |
|
|
|
353 |
public void unsetEndDate() {
|
|
|
354 |
__isset_bit_vector.clear(__ENDDATE_ISSET_ID);
|
|
|
355 |
}
|
|
|
356 |
|
|
|
357 |
/** Returns true if field endDate is set (has been assigned a value) and false otherwise */
|
|
|
358 |
public boolean isSetEndDate() {
|
|
|
359 |
return __isset_bit_vector.get(__ENDDATE_ISSET_ID);
|
|
|
360 |
}
|
|
|
361 |
|
|
|
362 |
public void setEndDateIsSet(boolean value) {
|
|
|
363 |
__isset_bit_vector.set(__ENDDATE_ISSET_ID, value);
|
|
|
364 |
}
|
|
|
365 |
|
| 11580 |
vikram.rag |
366 |
public long getDealTextOption() {
|
|
|
367 |
return this.dealTextOption;
|
| 11531 |
vikram.rag |
368 |
}
|
|
|
369 |
|
| 11580 |
vikram.rag |
370 |
public void setDealTextOption(long dealTextOption) {
|
|
|
371 |
this.dealTextOption = dealTextOption;
|
|
|
372 |
setDealTextOptionIsSet(true);
|
| 11531 |
vikram.rag |
373 |
}
|
|
|
374 |
|
| 11580 |
vikram.rag |
375 |
public void unsetDealTextOption() {
|
|
|
376 |
__isset_bit_vector.clear(__DEALTEXTOPTION_ISSET_ID);
|
| 11531 |
vikram.rag |
377 |
}
|
|
|
378 |
|
| 11580 |
vikram.rag |
379 |
/** Returns true if field dealTextOption is set (has been assigned a value) and false otherwise */
|
|
|
380 |
public boolean isSetDealTextOption() {
|
|
|
381 |
return __isset_bit_vector.get(__DEALTEXTOPTION_ISSET_ID);
|
| 11531 |
vikram.rag |
382 |
}
|
|
|
383 |
|
| 11580 |
vikram.rag |
384 |
public void setDealTextOptionIsSet(boolean value) {
|
|
|
385 |
__isset_bit_vector.set(__DEALTEXTOPTION_ISSET_ID, value);
|
| 11531 |
vikram.rag |
386 |
}
|
|
|
387 |
|
|
|
388 |
public String getDealText() {
|
|
|
389 |
return this.dealText;
|
|
|
390 |
}
|
|
|
391 |
|
|
|
392 |
public void setDealText(String dealText) {
|
|
|
393 |
this.dealText = dealText;
|
|
|
394 |
}
|
|
|
395 |
|
|
|
396 |
public void unsetDealText() {
|
|
|
397 |
this.dealText = null;
|
|
|
398 |
}
|
|
|
399 |
|
|
|
400 |
/** Returns true if field dealText is set (has been assigned a value) and false otherwise */
|
|
|
401 |
public boolean isSetDealText() {
|
|
|
402 |
return this.dealText != null;
|
|
|
403 |
}
|
|
|
404 |
|
|
|
405 |
public void setDealTextIsSet(boolean value) {
|
|
|
406 |
if (!value) {
|
|
|
407 |
this.dealText = null;
|
|
|
408 |
}
|
|
|
409 |
}
|
|
|
410 |
|
|
|
411 |
public boolean isIsCod() {
|
|
|
412 |
return this.isCod;
|
|
|
413 |
}
|
|
|
414 |
|
|
|
415 |
public void setIsCod(boolean isCod) {
|
|
|
416 |
this.isCod = isCod;
|
|
|
417 |
setIsCodIsSet(true);
|
|
|
418 |
}
|
|
|
419 |
|
|
|
420 |
public void unsetIsCod() {
|
|
|
421 |
__isset_bit_vector.clear(__ISCOD_ISSET_ID);
|
|
|
422 |
}
|
|
|
423 |
|
|
|
424 |
/** Returns true if field isCod is set (has been assigned a value) and false otherwise */
|
|
|
425 |
public boolean isSetIsCod() {
|
|
|
426 |
return __isset_bit_vector.get(__ISCOD_ISSET_ID);
|
|
|
427 |
}
|
|
|
428 |
|
|
|
429 |
public void setIsCodIsSet(boolean value) {
|
|
|
430 |
__isset_bit_vector.set(__ISCOD_ISSET_ID, value);
|
|
|
431 |
}
|
|
|
432 |
|
|
|
433 |
public long getRank() {
|
|
|
434 |
return this.rank;
|
|
|
435 |
}
|
|
|
436 |
|
|
|
437 |
public void setRank(long rank) {
|
|
|
438 |
this.rank = rank;
|
|
|
439 |
setRankIsSet(true);
|
|
|
440 |
}
|
|
|
441 |
|
|
|
442 |
public void unsetRank() {
|
|
|
443 |
__isset_bit_vector.clear(__RANK_ISSET_ID);
|
|
|
444 |
}
|
|
|
445 |
|
|
|
446 |
/** Returns true if field rank is set (has been assigned a value) and false otherwise */
|
|
|
447 |
public boolean isSetRank() {
|
|
|
448 |
return __isset_bit_vector.get(__RANK_ISSET_ID);
|
|
|
449 |
}
|
|
|
450 |
|
|
|
451 |
public void setRankIsSet(boolean value) {
|
|
|
452 |
__isset_bit_vector.set(__RANK_ISSET_ID, value);
|
|
|
453 |
}
|
|
|
454 |
|
| 11580 |
vikram.rag |
455 |
public long getDealFreebieOption() {
|
|
|
456 |
return this.dealFreebieOption;
|
|
|
457 |
}
|
|
|
458 |
|
|
|
459 |
public void setDealFreebieOption(long dealFreebieOption) {
|
|
|
460 |
this.dealFreebieOption = dealFreebieOption;
|
|
|
461 |
setDealFreebieOptionIsSet(true);
|
|
|
462 |
}
|
|
|
463 |
|
|
|
464 |
public void unsetDealFreebieOption() {
|
|
|
465 |
__isset_bit_vector.clear(__DEALFREEBIEOPTION_ISSET_ID);
|
|
|
466 |
}
|
|
|
467 |
|
|
|
468 |
/** Returns true if field dealFreebieOption is set (has been assigned a value) and false otherwise */
|
|
|
469 |
public boolean isSetDealFreebieOption() {
|
|
|
470 |
return __isset_bit_vector.get(__DEALFREEBIEOPTION_ISSET_ID);
|
|
|
471 |
}
|
|
|
472 |
|
|
|
473 |
public void setDealFreebieOptionIsSet(boolean value) {
|
|
|
474 |
__isset_bit_vector.set(__DEALFREEBIEOPTION_ISSET_ID, value);
|
|
|
475 |
}
|
|
|
476 |
|
| 11531 |
vikram.rag |
477 |
public void setFieldValue(_Fields field, Object value) {
|
|
|
478 |
switch (field) {
|
|
|
479 |
case ITEM_ID:
|
|
|
480 |
if (value == null) {
|
|
|
481 |
unsetItem_id();
|
|
|
482 |
} else {
|
|
|
483 |
setItem_id((Long)value);
|
|
|
484 |
}
|
|
|
485 |
break;
|
|
|
486 |
|
|
|
487 |
case DEAL_PRICE:
|
|
|
488 |
if (value == null) {
|
|
|
489 |
unsetDealPrice();
|
|
|
490 |
} else {
|
|
|
491 |
setDealPrice((Double)value);
|
|
|
492 |
}
|
|
|
493 |
break;
|
|
|
494 |
|
|
|
495 |
case DEAL_FREEBIE_ITEM_ID:
|
|
|
496 |
if (value == null) {
|
|
|
497 |
unsetDealFreebieItemId();
|
|
|
498 |
} else {
|
|
|
499 |
setDealFreebieItemId((Long)value);
|
|
|
500 |
}
|
|
|
501 |
break;
|
|
|
502 |
|
|
|
503 |
case START_DATE:
|
|
|
504 |
if (value == null) {
|
|
|
505 |
unsetStartDate();
|
|
|
506 |
} else {
|
|
|
507 |
setStartDate((Long)value);
|
|
|
508 |
}
|
|
|
509 |
break;
|
|
|
510 |
|
|
|
511 |
case END_DATE:
|
|
|
512 |
if (value == null) {
|
|
|
513 |
unsetEndDate();
|
|
|
514 |
} else {
|
|
|
515 |
setEndDate((Long)value);
|
|
|
516 |
}
|
|
|
517 |
break;
|
|
|
518 |
|
| 11580 |
vikram.rag |
519 |
case DEAL_TEXT_OPTION:
|
| 11531 |
vikram.rag |
520 |
if (value == null) {
|
| 11580 |
vikram.rag |
521 |
unsetDealTextOption();
|
| 11531 |
vikram.rag |
522 |
} else {
|
| 11580 |
vikram.rag |
523 |
setDealTextOption((Long)value);
|
| 11531 |
vikram.rag |
524 |
}
|
|
|
525 |
break;
|
|
|
526 |
|
|
|
527 |
case DEAL_TEXT:
|
|
|
528 |
if (value == null) {
|
|
|
529 |
unsetDealText();
|
|
|
530 |
} else {
|
|
|
531 |
setDealText((String)value);
|
|
|
532 |
}
|
|
|
533 |
break;
|
|
|
534 |
|
|
|
535 |
case IS_COD:
|
|
|
536 |
if (value == null) {
|
|
|
537 |
unsetIsCod();
|
|
|
538 |
} else {
|
|
|
539 |
setIsCod((Boolean)value);
|
|
|
540 |
}
|
|
|
541 |
break;
|
|
|
542 |
|
|
|
543 |
case RANK:
|
|
|
544 |
if (value == null) {
|
|
|
545 |
unsetRank();
|
|
|
546 |
} else {
|
|
|
547 |
setRank((Long)value);
|
|
|
548 |
}
|
|
|
549 |
break;
|
|
|
550 |
|
| 11580 |
vikram.rag |
551 |
case DEAL_FREEBIE_OPTION:
|
|
|
552 |
if (value == null) {
|
|
|
553 |
unsetDealFreebieOption();
|
|
|
554 |
} else {
|
|
|
555 |
setDealFreebieOption((Long)value);
|
|
|
556 |
}
|
|
|
557 |
break;
|
|
|
558 |
|
| 11531 |
vikram.rag |
559 |
}
|
|
|
560 |
}
|
|
|
561 |
|
|
|
562 |
public Object getFieldValue(_Fields field) {
|
|
|
563 |
switch (field) {
|
|
|
564 |
case ITEM_ID:
|
|
|
565 |
return Long.valueOf(getItem_id());
|
|
|
566 |
|
|
|
567 |
case DEAL_PRICE:
|
|
|
568 |
return Double.valueOf(getDealPrice());
|
|
|
569 |
|
|
|
570 |
case DEAL_FREEBIE_ITEM_ID:
|
|
|
571 |
return Long.valueOf(getDealFreebieItemId());
|
|
|
572 |
|
|
|
573 |
case START_DATE:
|
|
|
574 |
return Long.valueOf(getStartDate());
|
|
|
575 |
|
|
|
576 |
case END_DATE:
|
|
|
577 |
return Long.valueOf(getEndDate());
|
|
|
578 |
|
| 11580 |
vikram.rag |
579 |
case DEAL_TEXT_OPTION:
|
|
|
580 |
return Long.valueOf(getDealTextOption());
|
| 11531 |
vikram.rag |
581 |
|
|
|
582 |
case DEAL_TEXT:
|
|
|
583 |
return getDealText();
|
|
|
584 |
|
|
|
585 |
case IS_COD:
|
|
|
586 |
return Boolean.valueOf(isIsCod());
|
|
|
587 |
|
|
|
588 |
case RANK:
|
|
|
589 |
return Long.valueOf(getRank());
|
|
|
590 |
|
| 11580 |
vikram.rag |
591 |
case DEAL_FREEBIE_OPTION:
|
|
|
592 |
return Long.valueOf(getDealFreebieOption());
|
|
|
593 |
|
| 11531 |
vikram.rag |
594 |
}
|
|
|
595 |
throw new IllegalStateException();
|
|
|
596 |
}
|
|
|
597 |
|
|
|
598 |
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
|
|
|
599 |
public boolean isSet(_Fields field) {
|
|
|
600 |
if (field == null) {
|
|
|
601 |
throw new IllegalArgumentException();
|
|
|
602 |
}
|
|
|
603 |
|
|
|
604 |
switch (field) {
|
|
|
605 |
case ITEM_ID:
|
|
|
606 |
return isSetItem_id();
|
|
|
607 |
case DEAL_PRICE:
|
|
|
608 |
return isSetDealPrice();
|
|
|
609 |
case DEAL_FREEBIE_ITEM_ID:
|
|
|
610 |
return isSetDealFreebieItemId();
|
|
|
611 |
case START_DATE:
|
|
|
612 |
return isSetStartDate();
|
|
|
613 |
case END_DATE:
|
|
|
614 |
return isSetEndDate();
|
| 11580 |
vikram.rag |
615 |
case DEAL_TEXT_OPTION:
|
|
|
616 |
return isSetDealTextOption();
|
| 11531 |
vikram.rag |
617 |
case DEAL_TEXT:
|
|
|
618 |
return isSetDealText();
|
|
|
619 |
case IS_COD:
|
|
|
620 |
return isSetIsCod();
|
|
|
621 |
case RANK:
|
|
|
622 |
return isSetRank();
|
| 11580 |
vikram.rag |
623 |
case DEAL_FREEBIE_OPTION:
|
|
|
624 |
return isSetDealFreebieOption();
|
| 11531 |
vikram.rag |
625 |
}
|
|
|
626 |
throw new IllegalStateException();
|
|
|
627 |
}
|
|
|
628 |
|
|
|
629 |
@Override
|
|
|
630 |
public boolean equals(Object that) {
|
|
|
631 |
if (that == null)
|
|
|
632 |
return false;
|
|
|
633 |
if (that instanceof PrivateDeal)
|
|
|
634 |
return this.equals((PrivateDeal)that);
|
|
|
635 |
return false;
|
|
|
636 |
}
|
|
|
637 |
|
|
|
638 |
public boolean equals(PrivateDeal that) {
|
|
|
639 |
if (that == null)
|
|
|
640 |
return false;
|
|
|
641 |
|
|
|
642 |
boolean this_present_item_id = true;
|
|
|
643 |
boolean that_present_item_id = true;
|
|
|
644 |
if (this_present_item_id || that_present_item_id) {
|
|
|
645 |
if (!(this_present_item_id && that_present_item_id))
|
|
|
646 |
return false;
|
|
|
647 |
if (this.item_id != that.item_id)
|
|
|
648 |
return false;
|
|
|
649 |
}
|
|
|
650 |
|
|
|
651 |
boolean this_present_dealPrice = true;
|
|
|
652 |
boolean that_present_dealPrice = true;
|
|
|
653 |
if (this_present_dealPrice || that_present_dealPrice) {
|
|
|
654 |
if (!(this_present_dealPrice && that_present_dealPrice))
|
|
|
655 |
return false;
|
|
|
656 |
if (this.dealPrice != that.dealPrice)
|
|
|
657 |
return false;
|
|
|
658 |
}
|
|
|
659 |
|
|
|
660 |
boolean this_present_dealFreebieItemId = true;
|
|
|
661 |
boolean that_present_dealFreebieItemId = true;
|
|
|
662 |
if (this_present_dealFreebieItemId || that_present_dealFreebieItemId) {
|
|
|
663 |
if (!(this_present_dealFreebieItemId && that_present_dealFreebieItemId))
|
|
|
664 |
return false;
|
|
|
665 |
if (this.dealFreebieItemId != that.dealFreebieItemId)
|
|
|
666 |
return false;
|
|
|
667 |
}
|
|
|
668 |
|
|
|
669 |
boolean this_present_startDate = true;
|
|
|
670 |
boolean that_present_startDate = true;
|
|
|
671 |
if (this_present_startDate || that_present_startDate) {
|
|
|
672 |
if (!(this_present_startDate && that_present_startDate))
|
|
|
673 |
return false;
|
|
|
674 |
if (this.startDate != that.startDate)
|
|
|
675 |
return false;
|
|
|
676 |
}
|
|
|
677 |
|
|
|
678 |
boolean this_present_endDate = true;
|
|
|
679 |
boolean that_present_endDate = true;
|
|
|
680 |
if (this_present_endDate || that_present_endDate) {
|
|
|
681 |
if (!(this_present_endDate && that_present_endDate))
|
|
|
682 |
return false;
|
|
|
683 |
if (this.endDate != that.endDate)
|
|
|
684 |
return false;
|
|
|
685 |
}
|
|
|
686 |
|
| 11580 |
vikram.rag |
687 |
boolean this_present_dealTextOption = true;
|
|
|
688 |
boolean that_present_dealTextOption = true;
|
|
|
689 |
if (this_present_dealTextOption || that_present_dealTextOption) {
|
|
|
690 |
if (!(this_present_dealTextOption && that_present_dealTextOption))
|
| 11531 |
vikram.rag |
691 |
return false;
|
| 11580 |
vikram.rag |
692 |
if (this.dealTextOption != that.dealTextOption)
|
| 11531 |
vikram.rag |
693 |
return false;
|
|
|
694 |
}
|
|
|
695 |
|
|
|
696 |
boolean this_present_dealText = true && this.isSetDealText();
|
|
|
697 |
boolean that_present_dealText = true && that.isSetDealText();
|
|
|
698 |
if (this_present_dealText || that_present_dealText) {
|
|
|
699 |
if (!(this_present_dealText && that_present_dealText))
|
|
|
700 |
return false;
|
|
|
701 |
if (!this.dealText.equals(that.dealText))
|
|
|
702 |
return false;
|
|
|
703 |
}
|
|
|
704 |
|
|
|
705 |
boolean this_present_isCod = true;
|
|
|
706 |
boolean that_present_isCod = true;
|
|
|
707 |
if (this_present_isCod || that_present_isCod) {
|
|
|
708 |
if (!(this_present_isCod && that_present_isCod))
|
|
|
709 |
return false;
|
|
|
710 |
if (this.isCod != that.isCod)
|
|
|
711 |
return false;
|
|
|
712 |
}
|
|
|
713 |
|
|
|
714 |
boolean this_present_rank = true;
|
|
|
715 |
boolean that_present_rank = true;
|
|
|
716 |
if (this_present_rank || that_present_rank) {
|
|
|
717 |
if (!(this_present_rank && that_present_rank))
|
|
|
718 |
return false;
|
|
|
719 |
if (this.rank != that.rank)
|
|
|
720 |
return false;
|
|
|
721 |
}
|
|
|
722 |
|
| 11580 |
vikram.rag |
723 |
boolean this_present_dealFreebieOption = true;
|
|
|
724 |
boolean that_present_dealFreebieOption = true;
|
|
|
725 |
if (this_present_dealFreebieOption || that_present_dealFreebieOption) {
|
|
|
726 |
if (!(this_present_dealFreebieOption && that_present_dealFreebieOption))
|
|
|
727 |
return false;
|
|
|
728 |
if (this.dealFreebieOption != that.dealFreebieOption)
|
|
|
729 |
return false;
|
|
|
730 |
}
|
|
|
731 |
|
| 11531 |
vikram.rag |
732 |
return true;
|
|
|
733 |
}
|
|
|
734 |
|
|
|
735 |
@Override
|
|
|
736 |
public int hashCode() {
|
|
|
737 |
return 0;
|
|
|
738 |
}
|
|
|
739 |
|
|
|
740 |
public int compareTo(PrivateDeal other) {
|
|
|
741 |
if (!getClass().equals(other.getClass())) {
|
|
|
742 |
return getClass().getName().compareTo(other.getClass().getName());
|
|
|
743 |
}
|
|
|
744 |
|
|
|
745 |
int lastComparison = 0;
|
|
|
746 |
PrivateDeal typedOther = (PrivateDeal)other;
|
|
|
747 |
|
|
|
748 |
lastComparison = Boolean.valueOf(isSetItem_id()).compareTo(typedOther.isSetItem_id());
|
|
|
749 |
if (lastComparison != 0) {
|
|
|
750 |
return lastComparison;
|
|
|
751 |
}
|
|
|
752 |
if (isSetItem_id()) {
|
|
|
753 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.item_id, typedOther.item_id);
|
|
|
754 |
if (lastComparison != 0) {
|
|
|
755 |
return lastComparison;
|
|
|
756 |
}
|
|
|
757 |
}
|
|
|
758 |
lastComparison = Boolean.valueOf(isSetDealPrice()).compareTo(typedOther.isSetDealPrice());
|
|
|
759 |
if (lastComparison != 0) {
|
|
|
760 |
return lastComparison;
|
|
|
761 |
}
|
|
|
762 |
if (isSetDealPrice()) {
|
|
|
763 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.dealPrice, typedOther.dealPrice);
|
|
|
764 |
if (lastComparison != 0) {
|
|
|
765 |
return lastComparison;
|
|
|
766 |
}
|
|
|
767 |
}
|
|
|
768 |
lastComparison = Boolean.valueOf(isSetDealFreebieItemId()).compareTo(typedOther.isSetDealFreebieItemId());
|
|
|
769 |
if (lastComparison != 0) {
|
|
|
770 |
return lastComparison;
|
|
|
771 |
}
|
|
|
772 |
if (isSetDealFreebieItemId()) {
|
|
|
773 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.dealFreebieItemId, typedOther.dealFreebieItemId);
|
|
|
774 |
if (lastComparison != 0) {
|
|
|
775 |
return lastComparison;
|
|
|
776 |
}
|
|
|
777 |
}
|
|
|
778 |
lastComparison = Boolean.valueOf(isSetStartDate()).compareTo(typedOther.isSetStartDate());
|
|
|
779 |
if (lastComparison != 0) {
|
|
|
780 |
return lastComparison;
|
|
|
781 |
}
|
|
|
782 |
if (isSetStartDate()) {
|
|
|
783 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.startDate, typedOther.startDate);
|
|
|
784 |
if (lastComparison != 0) {
|
|
|
785 |
return lastComparison;
|
|
|
786 |
}
|
|
|
787 |
}
|
|
|
788 |
lastComparison = Boolean.valueOf(isSetEndDate()).compareTo(typedOther.isSetEndDate());
|
|
|
789 |
if (lastComparison != 0) {
|
|
|
790 |
return lastComparison;
|
|
|
791 |
}
|
|
|
792 |
if (isSetEndDate()) {
|
|
|
793 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.endDate, typedOther.endDate);
|
|
|
794 |
if (lastComparison != 0) {
|
|
|
795 |
return lastComparison;
|
|
|
796 |
}
|
|
|
797 |
}
|
| 11580 |
vikram.rag |
798 |
lastComparison = Boolean.valueOf(isSetDealTextOption()).compareTo(typedOther.isSetDealTextOption());
|
| 11531 |
vikram.rag |
799 |
if (lastComparison != 0) {
|
|
|
800 |
return lastComparison;
|
|
|
801 |
}
|
| 11580 |
vikram.rag |
802 |
if (isSetDealTextOption()) {
|
|
|
803 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.dealTextOption, typedOther.dealTextOption);
|
| 11531 |
vikram.rag |
804 |
if (lastComparison != 0) {
|
|
|
805 |
return lastComparison;
|
|
|
806 |
}
|
|
|
807 |
}
|
|
|
808 |
lastComparison = Boolean.valueOf(isSetDealText()).compareTo(typedOther.isSetDealText());
|
|
|
809 |
if (lastComparison != 0) {
|
|
|
810 |
return lastComparison;
|
|
|
811 |
}
|
|
|
812 |
if (isSetDealText()) {
|
|
|
813 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.dealText, typedOther.dealText);
|
|
|
814 |
if (lastComparison != 0) {
|
|
|
815 |
return lastComparison;
|
|
|
816 |
}
|
|
|
817 |
}
|
|
|
818 |
lastComparison = Boolean.valueOf(isSetIsCod()).compareTo(typedOther.isSetIsCod());
|
|
|
819 |
if (lastComparison != 0) {
|
|
|
820 |
return lastComparison;
|
|
|
821 |
}
|
|
|
822 |
if (isSetIsCod()) {
|
|
|
823 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isCod, typedOther.isCod);
|
|
|
824 |
if (lastComparison != 0) {
|
|
|
825 |
return lastComparison;
|
|
|
826 |
}
|
|
|
827 |
}
|
|
|
828 |
lastComparison = Boolean.valueOf(isSetRank()).compareTo(typedOther.isSetRank());
|
|
|
829 |
if (lastComparison != 0) {
|
|
|
830 |
return lastComparison;
|
|
|
831 |
}
|
|
|
832 |
if (isSetRank()) {
|
|
|
833 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.rank, typedOther.rank);
|
|
|
834 |
if (lastComparison != 0) {
|
|
|
835 |
return lastComparison;
|
|
|
836 |
}
|
|
|
837 |
}
|
| 11580 |
vikram.rag |
838 |
lastComparison = Boolean.valueOf(isSetDealFreebieOption()).compareTo(typedOther.isSetDealFreebieOption());
|
|
|
839 |
if (lastComparison != 0) {
|
|
|
840 |
return lastComparison;
|
|
|
841 |
}
|
|
|
842 |
if (isSetDealFreebieOption()) {
|
|
|
843 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.dealFreebieOption, typedOther.dealFreebieOption);
|
|
|
844 |
if (lastComparison != 0) {
|
|
|
845 |
return lastComparison;
|
|
|
846 |
}
|
|
|
847 |
}
|
| 11531 |
vikram.rag |
848 |
return 0;
|
|
|
849 |
}
|
|
|
850 |
|
|
|
851 |
public _Fields fieldForId(int fieldId) {
|
|
|
852 |
return _Fields.findByThriftId(fieldId);
|
|
|
853 |
}
|
|
|
854 |
|
|
|
855 |
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
|
|
|
856 |
org.apache.thrift.protocol.TField field;
|
|
|
857 |
iprot.readStructBegin();
|
|
|
858 |
while (true)
|
|
|
859 |
{
|
|
|
860 |
field = iprot.readFieldBegin();
|
|
|
861 |
if (field.type == org.apache.thrift.protocol.TType.STOP) {
|
|
|
862 |
break;
|
|
|
863 |
}
|
|
|
864 |
switch (field.id) {
|
|
|
865 |
case 1: // ITEM_ID
|
|
|
866 |
if (field.type == org.apache.thrift.protocol.TType.I64) {
|
|
|
867 |
this.item_id = iprot.readI64();
|
|
|
868 |
setItem_idIsSet(true);
|
|
|
869 |
} else {
|
|
|
870 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
871 |
}
|
|
|
872 |
break;
|
|
|
873 |
case 2: // DEAL_PRICE
|
|
|
874 |
if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
|
|
|
875 |
this.dealPrice = iprot.readDouble();
|
|
|
876 |
setDealPriceIsSet(true);
|
|
|
877 |
} else {
|
|
|
878 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
879 |
}
|
|
|
880 |
break;
|
|
|
881 |
case 3: // DEAL_FREEBIE_ITEM_ID
|
|
|
882 |
if (field.type == org.apache.thrift.protocol.TType.I64) {
|
|
|
883 |
this.dealFreebieItemId = iprot.readI64();
|
|
|
884 |
setDealFreebieItemIdIsSet(true);
|
|
|
885 |
} else {
|
|
|
886 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
887 |
}
|
|
|
888 |
break;
|
|
|
889 |
case 4: // START_DATE
|
|
|
890 |
if (field.type == org.apache.thrift.protocol.TType.I64) {
|
|
|
891 |
this.startDate = iprot.readI64();
|
|
|
892 |
setStartDateIsSet(true);
|
|
|
893 |
} else {
|
|
|
894 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
895 |
}
|
|
|
896 |
break;
|
|
|
897 |
case 5: // END_DATE
|
|
|
898 |
if (field.type == org.apache.thrift.protocol.TType.I64) {
|
|
|
899 |
this.endDate = iprot.readI64();
|
|
|
900 |
setEndDateIsSet(true);
|
|
|
901 |
} else {
|
|
|
902 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
903 |
}
|
|
|
904 |
break;
|
| 11580 |
vikram.rag |
905 |
case 6: // DEAL_TEXT_OPTION
|
|
|
906 |
if (field.type == org.apache.thrift.protocol.TType.I64) {
|
|
|
907 |
this.dealTextOption = iprot.readI64();
|
|
|
908 |
setDealTextOptionIsSet(true);
|
| 11531 |
vikram.rag |
909 |
} else {
|
|
|
910 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
911 |
}
|
|
|
912 |
break;
|
|
|
913 |
case 7: // DEAL_TEXT
|
|
|
914 |
if (field.type == org.apache.thrift.protocol.TType.STRING) {
|
|
|
915 |
this.dealText = iprot.readString();
|
|
|
916 |
} else {
|
|
|
917 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
918 |
}
|
|
|
919 |
break;
|
|
|
920 |
case 8: // IS_COD
|
|
|
921 |
if (field.type == org.apache.thrift.protocol.TType.BOOL) {
|
|
|
922 |
this.isCod = iprot.readBool();
|
|
|
923 |
setIsCodIsSet(true);
|
|
|
924 |
} else {
|
|
|
925 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
926 |
}
|
|
|
927 |
break;
|
|
|
928 |
case 9: // RANK
|
|
|
929 |
if (field.type == org.apache.thrift.protocol.TType.I64) {
|
|
|
930 |
this.rank = iprot.readI64();
|
|
|
931 |
setRankIsSet(true);
|
|
|
932 |
} else {
|
|
|
933 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
934 |
}
|
|
|
935 |
break;
|
| 11580 |
vikram.rag |
936 |
case 10: // DEAL_FREEBIE_OPTION
|
|
|
937 |
if (field.type == org.apache.thrift.protocol.TType.I64) {
|
|
|
938 |
this.dealFreebieOption = iprot.readI64();
|
|
|
939 |
setDealFreebieOptionIsSet(true);
|
|
|
940 |
} else {
|
|
|
941 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
942 |
}
|
|
|
943 |
break;
|
| 11531 |
vikram.rag |
944 |
default:
|
|
|
945 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
946 |
}
|
|
|
947 |
iprot.readFieldEnd();
|
|
|
948 |
}
|
|
|
949 |
iprot.readStructEnd();
|
|
|
950 |
validate();
|
|
|
951 |
}
|
|
|
952 |
|
|
|
953 |
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
|
|
|
954 |
validate();
|
|
|
955 |
|
|
|
956 |
oprot.writeStructBegin(STRUCT_DESC);
|
|
|
957 |
oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
|
|
|
958 |
oprot.writeI64(this.item_id);
|
|
|
959 |
oprot.writeFieldEnd();
|
|
|
960 |
oprot.writeFieldBegin(DEAL_PRICE_FIELD_DESC);
|
|
|
961 |
oprot.writeDouble(this.dealPrice);
|
|
|
962 |
oprot.writeFieldEnd();
|
|
|
963 |
oprot.writeFieldBegin(DEAL_FREEBIE_ITEM_ID_FIELD_DESC);
|
|
|
964 |
oprot.writeI64(this.dealFreebieItemId);
|
|
|
965 |
oprot.writeFieldEnd();
|
|
|
966 |
oprot.writeFieldBegin(START_DATE_FIELD_DESC);
|
|
|
967 |
oprot.writeI64(this.startDate);
|
|
|
968 |
oprot.writeFieldEnd();
|
|
|
969 |
oprot.writeFieldBegin(END_DATE_FIELD_DESC);
|
|
|
970 |
oprot.writeI64(this.endDate);
|
|
|
971 |
oprot.writeFieldEnd();
|
| 11580 |
vikram.rag |
972 |
oprot.writeFieldBegin(DEAL_TEXT_OPTION_FIELD_DESC);
|
|
|
973 |
oprot.writeI64(this.dealTextOption);
|
| 11531 |
vikram.rag |
974 |
oprot.writeFieldEnd();
|
|
|
975 |
if (this.dealText != null) {
|
|
|
976 |
oprot.writeFieldBegin(DEAL_TEXT_FIELD_DESC);
|
|
|
977 |
oprot.writeString(this.dealText);
|
|
|
978 |
oprot.writeFieldEnd();
|
|
|
979 |
}
|
|
|
980 |
oprot.writeFieldBegin(IS_COD_FIELD_DESC);
|
|
|
981 |
oprot.writeBool(this.isCod);
|
|
|
982 |
oprot.writeFieldEnd();
|
|
|
983 |
oprot.writeFieldBegin(RANK_FIELD_DESC);
|
|
|
984 |
oprot.writeI64(this.rank);
|
|
|
985 |
oprot.writeFieldEnd();
|
| 11580 |
vikram.rag |
986 |
oprot.writeFieldBegin(DEAL_FREEBIE_OPTION_FIELD_DESC);
|
|
|
987 |
oprot.writeI64(this.dealFreebieOption);
|
|
|
988 |
oprot.writeFieldEnd();
|
| 11531 |
vikram.rag |
989 |
oprot.writeFieldStop();
|
|
|
990 |
oprot.writeStructEnd();
|
|
|
991 |
}
|
|
|
992 |
|
|
|
993 |
@Override
|
|
|
994 |
public String toString() {
|
|
|
995 |
StringBuilder sb = new StringBuilder("PrivateDeal(");
|
|
|
996 |
boolean first = true;
|
|
|
997 |
|
|
|
998 |
sb.append("item_id:");
|
|
|
999 |
sb.append(this.item_id);
|
|
|
1000 |
first = false;
|
|
|
1001 |
if (!first) sb.append(", ");
|
|
|
1002 |
sb.append("dealPrice:");
|
|
|
1003 |
sb.append(this.dealPrice);
|
|
|
1004 |
first = false;
|
|
|
1005 |
if (!first) sb.append(", ");
|
|
|
1006 |
sb.append("dealFreebieItemId:");
|
|
|
1007 |
sb.append(this.dealFreebieItemId);
|
|
|
1008 |
first = false;
|
|
|
1009 |
if (!first) sb.append(", ");
|
|
|
1010 |
sb.append("startDate:");
|
|
|
1011 |
sb.append(this.startDate);
|
|
|
1012 |
first = false;
|
|
|
1013 |
if (!first) sb.append(", ");
|
|
|
1014 |
sb.append("endDate:");
|
|
|
1015 |
sb.append(this.endDate);
|
|
|
1016 |
first = false;
|
|
|
1017 |
if (!first) sb.append(", ");
|
| 11580 |
vikram.rag |
1018 |
sb.append("dealTextOption:");
|
|
|
1019 |
sb.append(this.dealTextOption);
|
| 11531 |
vikram.rag |
1020 |
first = false;
|
|
|
1021 |
if (!first) sb.append(", ");
|
|
|
1022 |
sb.append("dealText:");
|
|
|
1023 |
if (this.dealText == null) {
|
|
|
1024 |
sb.append("null");
|
|
|
1025 |
} else {
|
|
|
1026 |
sb.append(this.dealText);
|
|
|
1027 |
}
|
|
|
1028 |
first = false;
|
|
|
1029 |
if (!first) sb.append(", ");
|
|
|
1030 |
sb.append("isCod:");
|
|
|
1031 |
sb.append(this.isCod);
|
|
|
1032 |
first = false;
|
|
|
1033 |
if (!first) sb.append(", ");
|
|
|
1034 |
sb.append("rank:");
|
|
|
1035 |
sb.append(this.rank);
|
|
|
1036 |
first = false;
|
| 11580 |
vikram.rag |
1037 |
if (!first) sb.append(", ");
|
|
|
1038 |
sb.append("dealFreebieOption:");
|
|
|
1039 |
sb.append(this.dealFreebieOption);
|
|
|
1040 |
first = false;
|
| 11531 |
vikram.rag |
1041 |
sb.append(")");
|
|
|
1042 |
return sb.toString();
|
|
|
1043 |
}
|
|
|
1044 |
|
|
|
1045 |
public void validate() throws org.apache.thrift.TException {
|
|
|
1046 |
// check for required fields
|
|
|
1047 |
}
|
|
|
1048 |
|
|
|
1049 |
private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
|
|
|
1050 |
try {
|
|
|
1051 |
write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
|
|
|
1052 |
} catch (org.apache.thrift.TException te) {
|
|
|
1053 |
throw new java.io.IOException(te);
|
|
|
1054 |
}
|
|
|
1055 |
}
|
|
|
1056 |
|
|
|
1057 |
private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
|
|
|
1058 |
try {
|
|
|
1059 |
// it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
|
|
|
1060 |
__isset_bit_vector = new BitSet(1);
|
|
|
1061 |
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
|
|
|
1062 |
} catch (org.apache.thrift.TException te) {
|
|
|
1063 |
throw new java.io.IOException(te);
|
|
|
1064 |
}
|
|
|
1065 |
}
|
|
|
1066 |
|
|
|
1067 |
}
|
|
|
1068 |
|