| 19686 |
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.content;
|
|
|
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 BulkContentUpload implements org.apache.thrift.TBase<BulkContentUpload, BulkContentUpload._Fields>, java.io.Serializable, Cloneable {
|
|
|
24 |
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("BulkContentUpload");
|
|
|
25 |
|
|
|
26 |
private static final org.apache.thrift.protocol.TField NEW_ENTITY_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("new_entity_id", org.apache.thrift.protocol.TType.I64, (short)1);
|
|
|
27 |
private static final org.apache.thrift.protocol.TField CATEGORY_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("category_id", org.apache.thrift.protocol.TType.I64, (short)2);
|
|
|
28 |
private static final org.apache.thrift.protocol.TField COMPATIBILITY_FIELD_DESC = new org.apache.thrift.protocol.TField("compatibility", org.apache.thrift.protocol.TType.STRING, (short)3);
|
|
|
29 |
private static final org.apache.thrift.protocol.TField BATTERY_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("battery_type", org.apache.thrift.protocol.TType.I32, (short)4);
|
|
|
30 |
private static final org.apache.thrift.protocol.TField BATTERY_CAPACITY_FIELD_DESC = new org.apache.thrift.protocol.TField("battery_capacity", org.apache.thrift.protocol.TType.STRING, (short)5);
|
|
|
31 |
private static final org.apache.thrift.protocol.TField SUMMARY_FIELD_DESC = new org.apache.thrift.protocol.TField("summary", org.apache.thrift.protocol.TType.STRING, (short)6);
|
|
|
32 |
private static final org.apache.thrift.protocol.TField EXISTING_ENTITY_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("existing_entity_id", org.apache.thrift.protocol.TType.I64, (short)7);
|
|
|
33 |
private static final org.apache.thrift.protocol.TField BRAND_FIELD_DESC = new org.apache.thrift.protocol.TField("brand", org.apache.thrift.protocol.TType.STRING, (short)8);
|
|
|
34 |
private static final org.apache.thrift.protocol.TField MODEL_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("model_name", org.apache.thrift.protocol.TType.STRING, (short)9);
|
|
|
35 |
private static final org.apache.thrift.protocol.TField MODEL_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("model_number", org.apache.thrift.protocol.TType.STRING, (short)10);
|
|
|
36 |
|
|
|
37 |
private long new_entity_id; // required
|
|
|
38 |
private long category_id; // required
|
|
|
39 |
private String compatibility; // required
|
|
|
40 |
private int battery_type; // required
|
|
|
41 |
private String battery_capacity; // required
|
|
|
42 |
private String summary; // required
|
|
|
43 |
private long existing_entity_id; // required
|
|
|
44 |
private String brand; // required
|
|
|
45 |
private String model_name; // required
|
|
|
46 |
private String model_number; // required
|
|
|
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 |
NEW_ENTITY_ID((short)1, "new_entity_id"),
|
|
|
51 |
CATEGORY_ID((short)2, "category_id"),
|
|
|
52 |
COMPATIBILITY((short)3, "compatibility"),
|
|
|
53 |
BATTERY_TYPE((short)4, "battery_type"),
|
|
|
54 |
BATTERY_CAPACITY((short)5, "battery_capacity"),
|
|
|
55 |
SUMMARY((short)6, "summary"),
|
|
|
56 |
EXISTING_ENTITY_ID((short)7, "existing_entity_id"),
|
|
|
57 |
BRAND((short)8, "brand"),
|
|
|
58 |
MODEL_NAME((short)9, "model_name"),
|
|
|
59 |
MODEL_NUMBER((short)10, "model_number");
|
|
|
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: // NEW_ENTITY_ID
|
|
|
75 |
return NEW_ENTITY_ID;
|
|
|
76 |
case 2: // CATEGORY_ID
|
|
|
77 |
return CATEGORY_ID;
|
|
|
78 |
case 3: // COMPATIBILITY
|
|
|
79 |
return COMPATIBILITY;
|
|
|
80 |
case 4: // BATTERY_TYPE
|
|
|
81 |
return BATTERY_TYPE;
|
|
|
82 |
case 5: // BATTERY_CAPACITY
|
|
|
83 |
return BATTERY_CAPACITY;
|
|
|
84 |
case 6: // SUMMARY
|
|
|
85 |
return SUMMARY;
|
|
|
86 |
case 7: // EXISTING_ENTITY_ID
|
|
|
87 |
return EXISTING_ENTITY_ID;
|
|
|
88 |
case 8: // BRAND
|
|
|
89 |
return BRAND;
|
|
|
90 |
case 9: // MODEL_NAME
|
|
|
91 |
return MODEL_NAME;
|
|
|
92 |
case 10: // MODEL_NUMBER
|
|
|
93 |
return MODEL_NUMBER;
|
|
|
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 __NEW_ENTITY_ID_ISSET_ID = 0;
|
|
|
135 |
private static final int __CATEGORY_ID_ISSET_ID = 1;
|
|
|
136 |
private static final int __BATTERY_TYPE_ISSET_ID = 2;
|
|
|
137 |
private static final int __EXISTING_ENTITY_ID_ISSET_ID = 3;
|
|
|
138 |
private BitSet __isset_bit_vector = new BitSet(4);
|
|
|
139 |
|
|
|
140 |
public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
|
|
|
141 |
static {
|
|
|
142 |
Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
|
|
|
143 |
tmpMap.put(_Fields.NEW_ENTITY_ID, new org.apache.thrift.meta_data.FieldMetaData("new_entity_id", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
144 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
|
|
|
145 |
tmpMap.put(_Fields.CATEGORY_ID, new org.apache.thrift.meta_data.FieldMetaData("category_id", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
146 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
|
|
|
147 |
tmpMap.put(_Fields.COMPATIBILITY, new org.apache.thrift.meta_data.FieldMetaData("compatibility", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
148 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
|
|
|
149 |
tmpMap.put(_Fields.BATTERY_TYPE, new org.apache.thrift.meta_data.FieldMetaData("battery_type", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
150 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32)));
|
|
|
151 |
tmpMap.put(_Fields.BATTERY_CAPACITY, new org.apache.thrift.meta_data.FieldMetaData("battery_capacity", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
152 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
|
|
|
153 |
tmpMap.put(_Fields.SUMMARY, new org.apache.thrift.meta_data.FieldMetaData("summary", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
154 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
|
|
|
155 |
tmpMap.put(_Fields.EXISTING_ENTITY_ID, new org.apache.thrift.meta_data.FieldMetaData("existing_entity_id", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
156 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
|
|
|
157 |
tmpMap.put(_Fields.BRAND, new org.apache.thrift.meta_data.FieldMetaData("brand", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
158 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
|
|
|
159 |
tmpMap.put(_Fields.MODEL_NAME, new org.apache.thrift.meta_data.FieldMetaData("model_name", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
160 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
|
|
|
161 |
tmpMap.put(_Fields.MODEL_NUMBER, new org.apache.thrift.meta_data.FieldMetaData("model_number", org.apache.thrift.TFieldRequirementType.DEFAULT,
|
|
|
162 |
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
|
|
|
163 |
metaDataMap = Collections.unmodifiableMap(tmpMap);
|
|
|
164 |
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(BulkContentUpload.class, metaDataMap);
|
|
|
165 |
}
|
|
|
166 |
|
|
|
167 |
public BulkContentUpload() {
|
|
|
168 |
}
|
|
|
169 |
|
|
|
170 |
public BulkContentUpload(
|
|
|
171 |
long new_entity_id,
|
|
|
172 |
long category_id,
|
|
|
173 |
String compatibility,
|
|
|
174 |
int battery_type,
|
|
|
175 |
String battery_capacity,
|
|
|
176 |
String summary,
|
|
|
177 |
long existing_entity_id,
|
|
|
178 |
String brand,
|
|
|
179 |
String model_name,
|
|
|
180 |
String model_number)
|
|
|
181 |
{
|
|
|
182 |
this();
|
|
|
183 |
this.new_entity_id = new_entity_id;
|
|
|
184 |
setNew_entity_idIsSet(true);
|
|
|
185 |
this.category_id = category_id;
|
|
|
186 |
setCategory_idIsSet(true);
|
|
|
187 |
this.compatibility = compatibility;
|
|
|
188 |
this.battery_type = battery_type;
|
|
|
189 |
setBattery_typeIsSet(true);
|
|
|
190 |
this.battery_capacity = battery_capacity;
|
|
|
191 |
this.summary = summary;
|
|
|
192 |
this.existing_entity_id = existing_entity_id;
|
|
|
193 |
setExisting_entity_idIsSet(true);
|
|
|
194 |
this.brand = brand;
|
|
|
195 |
this.model_name = model_name;
|
|
|
196 |
this.model_number = model_number;
|
|
|
197 |
}
|
|
|
198 |
|
|
|
199 |
/**
|
|
|
200 |
* Performs a deep copy on <i>other</i>.
|
|
|
201 |
*/
|
|
|
202 |
public BulkContentUpload(BulkContentUpload other) {
|
|
|
203 |
__isset_bit_vector.clear();
|
|
|
204 |
__isset_bit_vector.or(other.__isset_bit_vector);
|
|
|
205 |
this.new_entity_id = other.new_entity_id;
|
|
|
206 |
this.category_id = other.category_id;
|
|
|
207 |
if (other.isSetCompatibility()) {
|
|
|
208 |
this.compatibility = other.compatibility;
|
|
|
209 |
}
|
|
|
210 |
this.battery_type = other.battery_type;
|
|
|
211 |
if (other.isSetBattery_capacity()) {
|
|
|
212 |
this.battery_capacity = other.battery_capacity;
|
|
|
213 |
}
|
|
|
214 |
if (other.isSetSummary()) {
|
|
|
215 |
this.summary = other.summary;
|
|
|
216 |
}
|
|
|
217 |
this.existing_entity_id = other.existing_entity_id;
|
|
|
218 |
if (other.isSetBrand()) {
|
|
|
219 |
this.brand = other.brand;
|
|
|
220 |
}
|
|
|
221 |
if (other.isSetModel_name()) {
|
|
|
222 |
this.model_name = other.model_name;
|
|
|
223 |
}
|
|
|
224 |
if (other.isSetModel_number()) {
|
|
|
225 |
this.model_number = other.model_number;
|
|
|
226 |
}
|
|
|
227 |
}
|
|
|
228 |
|
|
|
229 |
public BulkContentUpload deepCopy() {
|
|
|
230 |
return new BulkContentUpload(this);
|
|
|
231 |
}
|
|
|
232 |
|
|
|
233 |
@Override
|
|
|
234 |
public void clear() {
|
|
|
235 |
setNew_entity_idIsSet(false);
|
|
|
236 |
this.new_entity_id = 0;
|
|
|
237 |
setCategory_idIsSet(false);
|
|
|
238 |
this.category_id = 0;
|
|
|
239 |
this.compatibility = null;
|
|
|
240 |
setBattery_typeIsSet(false);
|
|
|
241 |
this.battery_type = 0;
|
|
|
242 |
this.battery_capacity = null;
|
|
|
243 |
this.summary = null;
|
|
|
244 |
setExisting_entity_idIsSet(false);
|
|
|
245 |
this.existing_entity_id = 0;
|
|
|
246 |
this.brand = null;
|
|
|
247 |
this.model_name = null;
|
|
|
248 |
this.model_number = null;
|
|
|
249 |
}
|
|
|
250 |
|
|
|
251 |
public long getNew_entity_id() {
|
|
|
252 |
return this.new_entity_id;
|
|
|
253 |
}
|
|
|
254 |
|
|
|
255 |
public void setNew_entity_id(long new_entity_id) {
|
|
|
256 |
this.new_entity_id = new_entity_id;
|
|
|
257 |
setNew_entity_idIsSet(true);
|
|
|
258 |
}
|
|
|
259 |
|
|
|
260 |
public void unsetNew_entity_id() {
|
|
|
261 |
__isset_bit_vector.clear(__NEW_ENTITY_ID_ISSET_ID);
|
|
|
262 |
}
|
|
|
263 |
|
|
|
264 |
/** Returns true if field new_entity_id is set (has been assigned a value) and false otherwise */
|
|
|
265 |
public boolean isSetNew_entity_id() {
|
|
|
266 |
return __isset_bit_vector.get(__NEW_ENTITY_ID_ISSET_ID);
|
|
|
267 |
}
|
|
|
268 |
|
|
|
269 |
public void setNew_entity_idIsSet(boolean value) {
|
|
|
270 |
__isset_bit_vector.set(__NEW_ENTITY_ID_ISSET_ID, value);
|
|
|
271 |
}
|
|
|
272 |
|
|
|
273 |
public long getCategory_id() {
|
|
|
274 |
return this.category_id;
|
|
|
275 |
}
|
|
|
276 |
|
|
|
277 |
public void setCategory_id(long category_id) {
|
|
|
278 |
this.category_id = category_id;
|
|
|
279 |
setCategory_idIsSet(true);
|
|
|
280 |
}
|
|
|
281 |
|
|
|
282 |
public void unsetCategory_id() {
|
|
|
283 |
__isset_bit_vector.clear(__CATEGORY_ID_ISSET_ID);
|
|
|
284 |
}
|
|
|
285 |
|
|
|
286 |
/** Returns true if field category_id is set (has been assigned a value) and false otherwise */
|
|
|
287 |
public boolean isSetCategory_id() {
|
|
|
288 |
return __isset_bit_vector.get(__CATEGORY_ID_ISSET_ID);
|
|
|
289 |
}
|
|
|
290 |
|
|
|
291 |
public void setCategory_idIsSet(boolean value) {
|
|
|
292 |
__isset_bit_vector.set(__CATEGORY_ID_ISSET_ID, value);
|
|
|
293 |
}
|
|
|
294 |
|
|
|
295 |
public String getCompatibility() {
|
|
|
296 |
return this.compatibility;
|
|
|
297 |
}
|
|
|
298 |
|
|
|
299 |
public void setCompatibility(String compatibility) {
|
|
|
300 |
this.compatibility = compatibility;
|
|
|
301 |
}
|
|
|
302 |
|
|
|
303 |
public void unsetCompatibility() {
|
|
|
304 |
this.compatibility = null;
|
|
|
305 |
}
|
|
|
306 |
|
|
|
307 |
/** Returns true if field compatibility is set (has been assigned a value) and false otherwise */
|
|
|
308 |
public boolean isSetCompatibility() {
|
|
|
309 |
return this.compatibility != null;
|
|
|
310 |
}
|
|
|
311 |
|
|
|
312 |
public void setCompatibilityIsSet(boolean value) {
|
|
|
313 |
if (!value) {
|
|
|
314 |
this.compatibility = null;
|
|
|
315 |
}
|
|
|
316 |
}
|
|
|
317 |
|
|
|
318 |
public int getBattery_type() {
|
|
|
319 |
return this.battery_type;
|
|
|
320 |
}
|
|
|
321 |
|
|
|
322 |
public void setBattery_type(int battery_type) {
|
|
|
323 |
this.battery_type = battery_type;
|
|
|
324 |
setBattery_typeIsSet(true);
|
|
|
325 |
}
|
|
|
326 |
|
|
|
327 |
public void unsetBattery_type() {
|
|
|
328 |
__isset_bit_vector.clear(__BATTERY_TYPE_ISSET_ID);
|
|
|
329 |
}
|
|
|
330 |
|
|
|
331 |
/** Returns true if field battery_type is set (has been assigned a value) and false otherwise */
|
|
|
332 |
public boolean isSetBattery_type() {
|
|
|
333 |
return __isset_bit_vector.get(__BATTERY_TYPE_ISSET_ID);
|
|
|
334 |
}
|
|
|
335 |
|
|
|
336 |
public void setBattery_typeIsSet(boolean value) {
|
|
|
337 |
__isset_bit_vector.set(__BATTERY_TYPE_ISSET_ID, value);
|
|
|
338 |
}
|
|
|
339 |
|
|
|
340 |
public String getBattery_capacity() {
|
|
|
341 |
return this.battery_capacity;
|
|
|
342 |
}
|
|
|
343 |
|
|
|
344 |
public void setBattery_capacity(String battery_capacity) {
|
|
|
345 |
this.battery_capacity = battery_capacity;
|
|
|
346 |
}
|
|
|
347 |
|
|
|
348 |
public void unsetBattery_capacity() {
|
|
|
349 |
this.battery_capacity = null;
|
|
|
350 |
}
|
|
|
351 |
|
|
|
352 |
/** Returns true if field battery_capacity is set (has been assigned a value) and false otherwise */
|
|
|
353 |
public boolean isSetBattery_capacity() {
|
|
|
354 |
return this.battery_capacity != null;
|
|
|
355 |
}
|
|
|
356 |
|
|
|
357 |
public void setBattery_capacityIsSet(boolean value) {
|
|
|
358 |
if (!value) {
|
|
|
359 |
this.battery_capacity = null;
|
|
|
360 |
}
|
|
|
361 |
}
|
|
|
362 |
|
|
|
363 |
public String getSummary() {
|
|
|
364 |
return this.summary;
|
|
|
365 |
}
|
|
|
366 |
|
|
|
367 |
public void setSummary(String summary) {
|
|
|
368 |
this.summary = summary;
|
|
|
369 |
}
|
|
|
370 |
|
|
|
371 |
public void unsetSummary() {
|
|
|
372 |
this.summary = null;
|
|
|
373 |
}
|
|
|
374 |
|
|
|
375 |
/** Returns true if field summary is set (has been assigned a value) and false otherwise */
|
|
|
376 |
public boolean isSetSummary() {
|
|
|
377 |
return this.summary != null;
|
|
|
378 |
}
|
|
|
379 |
|
|
|
380 |
public void setSummaryIsSet(boolean value) {
|
|
|
381 |
if (!value) {
|
|
|
382 |
this.summary = null;
|
|
|
383 |
}
|
|
|
384 |
}
|
|
|
385 |
|
|
|
386 |
public long getExisting_entity_id() {
|
|
|
387 |
return this.existing_entity_id;
|
|
|
388 |
}
|
|
|
389 |
|
|
|
390 |
public void setExisting_entity_id(long existing_entity_id) {
|
|
|
391 |
this.existing_entity_id = existing_entity_id;
|
|
|
392 |
setExisting_entity_idIsSet(true);
|
|
|
393 |
}
|
|
|
394 |
|
|
|
395 |
public void unsetExisting_entity_id() {
|
|
|
396 |
__isset_bit_vector.clear(__EXISTING_ENTITY_ID_ISSET_ID);
|
|
|
397 |
}
|
|
|
398 |
|
|
|
399 |
/** Returns true if field existing_entity_id is set (has been assigned a value) and false otherwise */
|
|
|
400 |
public boolean isSetExisting_entity_id() {
|
|
|
401 |
return __isset_bit_vector.get(__EXISTING_ENTITY_ID_ISSET_ID);
|
|
|
402 |
}
|
|
|
403 |
|
|
|
404 |
public void setExisting_entity_idIsSet(boolean value) {
|
|
|
405 |
__isset_bit_vector.set(__EXISTING_ENTITY_ID_ISSET_ID, value);
|
|
|
406 |
}
|
|
|
407 |
|
|
|
408 |
public String getBrand() {
|
|
|
409 |
return this.brand;
|
|
|
410 |
}
|
|
|
411 |
|
|
|
412 |
public void setBrand(String brand) {
|
|
|
413 |
this.brand = brand;
|
|
|
414 |
}
|
|
|
415 |
|
|
|
416 |
public void unsetBrand() {
|
|
|
417 |
this.brand = null;
|
|
|
418 |
}
|
|
|
419 |
|
|
|
420 |
/** Returns true if field brand is set (has been assigned a value) and false otherwise */
|
|
|
421 |
public boolean isSetBrand() {
|
|
|
422 |
return this.brand != null;
|
|
|
423 |
}
|
|
|
424 |
|
|
|
425 |
public void setBrandIsSet(boolean value) {
|
|
|
426 |
if (!value) {
|
|
|
427 |
this.brand = null;
|
|
|
428 |
}
|
|
|
429 |
}
|
|
|
430 |
|
|
|
431 |
public String getModel_name() {
|
|
|
432 |
return this.model_name;
|
|
|
433 |
}
|
|
|
434 |
|
|
|
435 |
public void setModel_name(String model_name) {
|
|
|
436 |
this.model_name = model_name;
|
|
|
437 |
}
|
|
|
438 |
|
|
|
439 |
public void unsetModel_name() {
|
|
|
440 |
this.model_name = null;
|
|
|
441 |
}
|
|
|
442 |
|
|
|
443 |
/** Returns true if field model_name is set (has been assigned a value) and false otherwise */
|
|
|
444 |
public boolean isSetModel_name() {
|
|
|
445 |
return this.model_name != null;
|
|
|
446 |
}
|
|
|
447 |
|
|
|
448 |
public void setModel_nameIsSet(boolean value) {
|
|
|
449 |
if (!value) {
|
|
|
450 |
this.model_name = null;
|
|
|
451 |
}
|
|
|
452 |
}
|
|
|
453 |
|
|
|
454 |
public String getModel_number() {
|
|
|
455 |
return this.model_number;
|
|
|
456 |
}
|
|
|
457 |
|
|
|
458 |
public void setModel_number(String model_number) {
|
|
|
459 |
this.model_number = model_number;
|
|
|
460 |
}
|
|
|
461 |
|
|
|
462 |
public void unsetModel_number() {
|
|
|
463 |
this.model_number = null;
|
|
|
464 |
}
|
|
|
465 |
|
|
|
466 |
/** Returns true if field model_number is set (has been assigned a value) and false otherwise */
|
|
|
467 |
public boolean isSetModel_number() {
|
|
|
468 |
return this.model_number != null;
|
|
|
469 |
}
|
|
|
470 |
|
|
|
471 |
public void setModel_numberIsSet(boolean value) {
|
|
|
472 |
if (!value) {
|
|
|
473 |
this.model_number = null;
|
|
|
474 |
}
|
|
|
475 |
}
|
|
|
476 |
|
|
|
477 |
public void setFieldValue(_Fields field, Object value) {
|
|
|
478 |
switch (field) {
|
|
|
479 |
case NEW_ENTITY_ID:
|
|
|
480 |
if (value == null) {
|
|
|
481 |
unsetNew_entity_id();
|
|
|
482 |
} else {
|
|
|
483 |
setNew_entity_id((Long)value);
|
|
|
484 |
}
|
|
|
485 |
break;
|
|
|
486 |
|
|
|
487 |
case CATEGORY_ID:
|
|
|
488 |
if (value == null) {
|
|
|
489 |
unsetCategory_id();
|
|
|
490 |
} else {
|
|
|
491 |
setCategory_id((Long)value);
|
|
|
492 |
}
|
|
|
493 |
break;
|
|
|
494 |
|
|
|
495 |
case COMPATIBILITY:
|
|
|
496 |
if (value == null) {
|
|
|
497 |
unsetCompatibility();
|
|
|
498 |
} else {
|
|
|
499 |
setCompatibility((String)value);
|
|
|
500 |
}
|
|
|
501 |
break;
|
|
|
502 |
|
|
|
503 |
case BATTERY_TYPE:
|
|
|
504 |
if (value == null) {
|
|
|
505 |
unsetBattery_type();
|
|
|
506 |
} else {
|
|
|
507 |
setBattery_type((Integer)value);
|
|
|
508 |
}
|
|
|
509 |
break;
|
|
|
510 |
|
|
|
511 |
case BATTERY_CAPACITY:
|
|
|
512 |
if (value == null) {
|
|
|
513 |
unsetBattery_capacity();
|
|
|
514 |
} else {
|
|
|
515 |
setBattery_capacity((String)value);
|
|
|
516 |
}
|
|
|
517 |
break;
|
|
|
518 |
|
|
|
519 |
case SUMMARY:
|
|
|
520 |
if (value == null) {
|
|
|
521 |
unsetSummary();
|
|
|
522 |
} else {
|
|
|
523 |
setSummary((String)value);
|
|
|
524 |
}
|
|
|
525 |
break;
|
|
|
526 |
|
|
|
527 |
case EXISTING_ENTITY_ID:
|
|
|
528 |
if (value == null) {
|
|
|
529 |
unsetExisting_entity_id();
|
|
|
530 |
} else {
|
|
|
531 |
setExisting_entity_id((Long)value);
|
|
|
532 |
}
|
|
|
533 |
break;
|
|
|
534 |
|
|
|
535 |
case BRAND:
|
|
|
536 |
if (value == null) {
|
|
|
537 |
unsetBrand();
|
|
|
538 |
} else {
|
|
|
539 |
setBrand((String)value);
|
|
|
540 |
}
|
|
|
541 |
break;
|
|
|
542 |
|
|
|
543 |
case MODEL_NAME:
|
|
|
544 |
if (value == null) {
|
|
|
545 |
unsetModel_name();
|
|
|
546 |
} else {
|
|
|
547 |
setModel_name((String)value);
|
|
|
548 |
}
|
|
|
549 |
break;
|
|
|
550 |
|
|
|
551 |
case MODEL_NUMBER:
|
|
|
552 |
if (value == null) {
|
|
|
553 |
unsetModel_number();
|
|
|
554 |
} else {
|
|
|
555 |
setModel_number((String)value);
|
|
|
556 |
}
|
|
|
557 |
break;
|
|
|
558 |
|
|
|
559 |
}
|
|
|
560 |
}
|
|
|
561 |
|
|
|
562 |
public Object getFieldValue(_Fields field) {
|
|
|
563 |
switch (field) {
|
|
|
564 |
case NEW_ENTITY_ID:
|
|
|
565 |
return Long.valueOf(getNew_entity_id());
|
|
|
566 |
|
|
|
567 |
case CATEGORY_ID:
|
|
|
568 |
return Long.valueOf(getCategory_id());
|
|
|
569 |
|
|
|
570 |
case COMPATIBILITY:
|
|
|
571 |
return getCompatibility();
|
|
|
572 |
|
|
|
573 |
case BATTERY_TYPE:
|
|
|
574 |
return Integer.valueOf(getBattery_type());
|
|
|
575 |
|
|
|
576 |
case BATTERY_CAPACITY:
|
|
|
577 |
return getBattery_capacity();
|
|
|
578 |
|
|
|
579 |
case SUMMARY:
|
|
|
580 |
return getSummary();
|
|
|
581 |
|
|
|
582 |
case EXISTING_ENTITY_ID:
|
|
|
583 |
return Long.valueOf(getExisting_entity_id());
|
|
|
584 |
|
|
|
585 |
case BRAND:
|
|
|
586 |
return getBrand();
|
|
|
587 |
|
|
|
588 |
case MODEL_NAME:
|
|
|
589 |
return getModel_name();
|
|
|
590 |
|
|
|
591 |
case MODEL_NUMBER:
|
|
|
592 |
return getModel_number();
|
|
|
593 |
|
|
|
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 NEW_ENTITY_ID:
|
|
|
606 |
return isSetNew_entity_id();
|
|
|
607 |
case CATEGORY_ID:
|
|
|
608 |
return isSetCategory_id();
|
|
|
609 |
case COMPATIBILITY:
|
|
|
610 |
return isSetCompatibility();
|
|
|
611 |
case BATTERY_TYPE:
|
|
|
612 |
return isSetBattery_type();
|
|
|
613 |
case BATTERY_CAPACITY:
|
|
|
614 |
return isSetBattery_capacity();
|
|
|
615 |
case SUMMARY:
|
|
|
616 |
return isSetSummary();
|
|
|
617 |
case EXISTING_ENTITY_ID:
|
|
|
618 |
return isSetExisting_entity_id();
|
|
|
619 |
case BRAND:
|
|
|
620 |
return isSetBrand();
|
|
|
621 |
case MODEL_NAME:
|
|
|
622 |
return isSetModel_name();
|
|
|
623 |
case MODEL_NUMBER:
|
|
|
624 |
return isSetModel_number();
|
|
|
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 BulkContentUpload)
|
|
|
634 |
return this.equals((BulkContentUpload)that);
|
|
|
635 |
return false;
|
|
|
636 |
}
|
|
|
637 |
|
|
|
638 |
public boolean equals(BulkContentUpload that) {
|
|
|
639 |
if (that == null)
|
|
|
640 |
return false;
|
|
|
641 |
|
|
|
642 |
boolean this_present_new_entity_id = true;
|
|
|
643 |
boolean that_present_new_entity_id = true;
|
|
|
644 |
if (this_present_new_entity_id || that_present_new_entity_id) {
|
|
|
645 |
if (!(this_present_new_entity_id && that_present_new_entity_id))
|
|
|
646 |
return false;
|
|
|
647 |
if (this.new_entity_id != that.new_entity_id)
|
|
|
648 |
return false;
|
|
|
649 |
}
|
|
|
650 |
|
|
|
651 |
boolean this_present_category_id = true;
|
|
|
652 |
boolean that_present_category_id = true;
|
|
|
653 |
if (this_present_category_id || that_present_category_id) {
|
|
|
654 |
if (!(this_present_category_id && that_present_category_id))
|
|
|
655 |
return false;
|
|
|
656 |
if (this.category_id != that.category_id)
|
|
|
657 |
return false;
|
|
|
658 |
}
|
|
|
659 |
|
|
|
660 |
boolean this_present_compatibility = true && this.isSetCompatibility();
|
|
|
661 |
boolean that_present_compatibility = true && that.isSetCompatibility();
|
|
|
662 |
if (this_present_compatibility || that_present_compatibility) {
|
|
|
663 |
if (!(this_present_compatibility && that_present_compatibility))
|
|
|
664 |
return false;
|
|
|
665 |
if (!this.compatibility.equals(that.compatibility))
|
|
|
666 |
return false;
|
|
|
667 |
}
|
|
|
668 |
|
|
|
669 |
boolean this_present_battery_type = true;
|
|
|
670 |
boolean that_present_battery_type = true;
|
|
|
671 |
if (this_present_battery_type || that_present_battery_type) {
|
|
|
672 |
if (!(this_present_battery_type && that_present_battery_type))
|
|
|
673 |
return false;
|
|
|
674 |
if (this.battery_type != that.battery_type)
|
|
|
675 |
return false;
|
|
|
676 |
}
|
|
|
677 |
|
|
|
678 |
boolean this_present_battery_capacity = true && this.isSetBattery_capacity();
|
|
|
679 |
boolean that_present_battery_capacity = true && that.isSetBattery_capacity();
|
|
|
680 |
if (this_present_battery_capacity || that_present_battery_capacity) {
|
|
|
681 |
if (!(this_present_battery_capacity && that_present_battery_capacity))
|
|
|
682 |
return false;
|
|
|
683 |
if (!this.battery_capacity.equals(that.battery_capacity))
|
|
|
684 |
return false;
|
|
|
685 |
}
|
|
|
686 |
|
|
|
687 |
boolean this_present_summary = true && this.isSetSummary();
|
|
|
688 |
boolean that_present_summary = true && that.isSetSummary();
|
|
|
689 |
if (this_present_summary || that_present_summary) {
|
|
|
690 |
if (!(this_present_summary && that_present_summary))
|
|
|
691 |
return false;
|
|
|
692 |
if (!this.summary.equals(that.summary))
|
|
|
693 |
return false;
|
|
|
694 |
}
|
|
|
695 |
|
|
|
696 |
boolean this_present_existing_entity_id = true;
|
|
|
697 |
boolean that_present_existing_entity_id = true;
|
|
|
698 |
if (this_present_existing_entity_id || that_present_existing_entity_id) {
|
|
|
699 |
if (!(this_present_existing_entity_id && that_present_existing_entity_id))
|
|
|
700 |
return false;
|
|
|
701 |
if (this.existing_entity_id != that.existing_entity_id)
|
|
|
702 |
return false;
|
|
|
703 |
}
|
|
|
704 |
|
|
|
705 |
boolean this_present_brand = true && this.isSetBrand();
|
|
|
706 |
boolean that_present_brand = true && that.isSetBrand();
|
|
|
707 |
if (this_present_brand || that_present_brand) {
|
|
|
708 |
if (!(this_present_brand && that_present_brand))
|
|
|
709 |
return false;
|
|
|
710 |
if (!this.brand.equals(that.brand))
|
|
|
711 |
return false;
|
|
|
712 |
}
|
|
|
713 |
|
|
|
714 |
boolean this_present_model_name = true && this.isSetModel_name();
|
|
|
715 |
boolean that_present_model_name = true && that.isSetModel_name();
|
|
|
716 |
if (this_present_model_name || that_present_model_name) {
|
|
|
717 |
if (!(this_present_model_name && that_present_model_name))
|
|
|
718 |
return false;
|
|
|
719 |
if (!this.model_name.equals(that.model_name))
|
|
|
720 |
return false;
|
|
|
721 |
}
|
|
|
722 |
|
|
|
723 |
boolean this_present_model_number = true && this.isSetModel_number();
|
|
|
724 |
boolean that_present_model_number = true && that.isSetModel_number();
|
|
|
725 |
if (this_present_model_number || that_present_model_number) {
|
|
|
726 |
if (!(this_present_model_number && that_present_model_number))
|
|
|
727 |
return false;
|
|
|
728 |
if (!this.model_number.equals(that.model_number))
|
|
|
729 |
return false;
|
|
|
730 |
}
|
|
|
731 |
|
|
|
732 |
return true;
|
|
|
733 |
}
|
|
|
734 |
|
|
|
735 |
@Override
|
|
|
736 |
public int hashCode() {
|
|
|
737 |
return 0;
|
|
|
738 |
}
|
|
|
739 |
|
|
|
740 |
public int compareTo(BulkContentUpload other) {
|
|
|
741 |
if (!getClass().equals(other.getClass())) {
|
|
|
742 |
return getClass().getName().compareTo(other.getClass().getName());
|
|
|
743 |
}
|
|
|
744 |
|
|
|
745 |
int lastComparison = 0;
|
|
|
746 |
BulkContentUpload typedOther = (BulkContentUpload)other;
|
|
|
747 |
|
|
|
748 |
lastComparison = Boolean.valueOf(isSetNew_entity_id()).compareTo(typedOther.isSetNew_entity_id());
|
|
|
749 |
if (lastComparison != 0) {
|
|
|
750 |
return lastComparison;
|
|
|
751 |
}
|
|
|
752 |
if (isSetNew_entity_id()) {
|
|
|
753 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.new_entity_id, typedOther.new_entity_id);
|
|
|
754 |
if (lastComparison != 0) {
|
|
|
755 |
return lastComparison;
|
|
|
756 |
}
|
|
|
757 |
}
|
|
|
758 |
lastComparison = Boolean.valueOf(isSetCategory_id()).compareTo(typedOther.isSetCategory_id());
|
|
|
759 |
if (lastComparison != 0) {
|
|
|
760 |
return lastComparison;
|
|
|
761 |
}
|
|
|
762 |
if (isSetCategory_id()) {
|
|
|
763 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.category_id, typedOther.category_id);
|
|
|
764 |
if (lastComparison != 0) {
|
|
|
765 |
return lastComparison;
|
|
|
766 |
}
|
|
|
767 |
}
|
|
|
768 |
lastComparison = Boolean.valueOf(isSetCompatibility()).compareTo(typedOther.isSetCompatibility());
|
|
|
769 |
if (lastComparison != 0) {
|
|
|
770 |
return lastComparison;
|
|
|
771 |
}
|
|
|
772 |
if (isSetCompatibility()) {
|
|
|
773 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.compatibility, typedOther.compatibility);
|
|
|
774 |
if (lastComparison != 0) {
|
|
|
775 |
return lastComparison;
|
|
|
776 |
}
|
|
|
777 |
}
|
|
|
778 |
lastComparison = Boolean.valueOf(isSetBattery_type()).compareTo(typedOther.isSetBattery_type());
|
|
|
779 |
if (lastComparison != 0) {
|
|
|
780 |
return lastComparison;
|
|
|
781 |
}
|
|
|
782 |
if (isSetBattery_type()) {
|
|
|
783 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.battery_type, typedOther.battery_type);
|
|
|
784 |
if (lastComparison != 0) {
|
|
|
785 |
return lastComparison;
|
|
|
786 |
}
|
|
|
787 |
}
|
|
|
788 |
lastComparison = Boolean.valueOf(isSetBattery_capacity()).compareTo(typedOther.isSetBattery_capacity());
|
|
|
789 |
if (lastComparison != 0) {
|
|
|
790 |
return lastComparison;
|
|
|
791 |
}
|
|
|
792 |
if (isSetBattery_capacity()) {
|
|
|
793 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.battery_capacity, typedOther.battery_capacity);
|
|
|
794 |
if (lastComparison != 0) {
|
|
|
795 |
return lastComparison;
|
|
|
796 |
}
|
|
|
797 |
}
|
|
|
798 |
lastComparison = Boolean.valueOf(isSetSummary()).compareTo(typedOther.isSetSummary());
|
|
|
799 |
if (lastComparison != 0) {
|
|
|
800 |
return lastComparison;
|
|
|
801 |
}
|
|
|
802 |
if (isSetSummary()) {
|
|
|
803 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.summary, typedOther.summary);
|
|
|
804 |
if (lastComparison != 0) {
|
|
|
805 |
return lastComparison;
|
|
|
806 |
}
|
|
|
807 |
}
|
|
|
808 |
lastComparison = Boolean.valueOf(isSetExisting_entity_id()).compareTo(typedOther.isSetExisting_entity_id());
|
|
|
809 |
if (lastComparison != 0) {
|
|
|
810 |
return lastComparison;
|
|
|
811 |
}
|
|
|
812 |
if (isSetExisting_entity_id()) {
|
|
|
813 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.existing_entity_id, typedOther.existing_entity_id);
|
|
|
814 |
if (lastComparison != 0) {
|
|
|
815 |
return lastComparison;
|
|
|
816 |
}
|
|
|
817 |
}
|
|
|
818 |
lastComparison = Boolean.valueOf(isSetBrand()).compareTo(typedOther.isSetBrand());
|
|
|
819 |
if (lastComparison != 0) {
|
|
|
820 |
return lastComparison;
|
|
|
821 |
}
|
|
|
822 |
if (isSetBrand()) {
|
|
|
823 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.brand, typedOther.brand);
|
|
|
824 |
if (lastComparison != 0) {
|
|
|
825 |
return lastComparison;
|
|
|
826 |
}
|
|
|
827 |
}
|
|
|
828 |
lastComparison = Boolean.valueOf(isSetModel_name()).compareTo(typedOther.isSetModel_name());
|
|
|
829 |
if (lastComparison != 0) {
|
|
|
830 |
return lastComparison;
|
|
|
831 |
}
|
|
|
832 |
if (isSetModel_name()) {
|
|
|
833 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.model_name, typedOther.model_name);
|
|
|
834 |
if (lastComparison != 0) {
|
|
|
835 |
return lastComparison;
|
|
|
836 |
}
|
|
|
837 |
}
|
|
|
838 |
lastComparison = Boolean.valueOf(isSetModel_number()).compareTo(typedOther.isSetModel_number());
|
|
|
839 |
if (lastComparison != 0) {
|
|
|
840 |
return lastComparison;
|
|
|
841 |
}
|
|
|
842 |
if (isSetModel_number()) {
|
|
|
843 |
lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.model_number, typedOther.model_number);
|
|
|
844 |
if (lastComparison != 0) {
|
|
|
845 |
return lastComparison;
|
|
|
846 |
}
|
|
|
847 |
}
|
|
|
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: // NEW_ENTITY_ID
|
|
|
866 |
if (field.type == org.apache.thrift.protocol.TType.I64) {
|
|
|
867 |
this.new_entity_id = iprot.readI64();
|
|
|
868 |
setNew_entity_idIsSet(true);
|
|
|
869 |
} else {
|
|
|
870 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
871 |
}
|
|
|
872 |
break;
|
|
|
873 |
case 2: // CATEGORY_ID
|
|
|
874 |
if (field.type == org.apache.thrift.protocol.TType.I64) {
|
|
|
875 |
this.category_id = iprot.readI64();
|
|
|
876 |
setCategory_idIsSet(true);
|
|
|
877 |
} else {
|
|
|
878 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
879 |
}
|
|
|
880 |
break;
|
|
|
881 |
case 3: // COMPATIBILITY
|
|
|
882 |
if (field.type == org.apache.thrift.protocol.TType.STRING) {
|
|
|
883 |
this.compatibility = iprot.readString();
|
|
|
884 |
} else {
|
|
|
885 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
886 |
}
|
|
|
887 |
break;
|
|
|
888 |
case 4: // BATTERY_TYPE
|
|
|
889 |
if (field.type == org.apache.thrift.protocol.TType.I32) {
|
|
|
890 |
this.battery_type = iprot.readI32();
|
|
|
891 |
setBattery_typeIsSet(true);
|
|
|
892 |
} else {
|
|
|
893 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
894 |
}
|
|
|
895 |
break;
|
|
|
896 |
case 5: // BATTERY_CAPACITY
|
|
|
897 |
if (field.type == org.apache.thrift.protocol.TType.STRING) {
|
|
|
898 |
this.battery_capacity = iprot.readString();
|
|
|
899 |
} else {
|
|
|
900 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
901 |
}
|
|
|
902 |
break;
|
|
|
903 |
case 6: // SUMMARY
|
|
|
904 |
if (field.type == org.apache.thrift.protocol.TType.STRING) {
|
|
|
905 |
this.summary = iprot.readString();
|
|
|
906 |
} else {
|
|
|
907 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
908 |
}
|
|
|
909 |
break;
|
|
|
910 |
case 7: // EXISTING_ENTITY_ID
|
|
|
911 |
if (field.type == org.apache.thrift.protocol.TType.I64) {
|
|
|
912 |
this.existing_entity_id = iprot.readI64();
|
|
|
913 |
setExisting_entity_idIsSet(true);
|
|
|
914 |
} else {
|
|
|
915 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
916 |
}
|
|
|
917 |
break;
|
|
|
918 |
case 8: // BRAND
|
|
|
919 |
if (field.type == org.apache.thrift.protocol.TType.STRING) {
|
|
|
920 |
this.brand = iprot.readString();
|
|
|
921 |
} else {
|
|
|
922 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
923 |
}
|
|
|
924 |
break;
|
|
|
925 |
case 9: // MODEL_NAME
|
|
|
926 |
if (field.type == org.apache.thrift.protocol.TType.STRING) {
|
|
|
927 |
this.model_name = iprot.readString();
|
|
|
928 |
} else {
|
|
|
929 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
930 |
}
|
|
|
931 |
break;
|
|
|
932 |
case 10: // MODEL_NUMBER
|
|
|
933 |
if (field.type == org.apache.thrift.protocol.TType.STRING) {
|
|
|
934 |
this.model_number = iprot.readString();
|
|
|
935 |
} else {
|
|
|
936 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
937 |
}
|
|
|
938 |
break;
|
|
|
939 |
default:
|
|
|
940 |
org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
|
|
|
941 |
}
|
|
|
942 |
iprot.readFieldEnd();
|
|
|
943 |
}
|
|
|
944 |
iprot.readStructEnd();
|
|
|
945 |
validate();
|
|
|
946 |
}
|
|
|
947 |
|
|
|
948 |
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
|
|
|
949 |
validate();
|
|
|
950 |
|
|
|
951 |
oprot.writeStructBegin(STRUCT_DESC);
|
|
|
952 |
oprot.writeFieldBegin(NEW_ENTITY_ID_FIELD_DESC);
|
|
|
953 |
oprot.writeI64(this.new_entity_id);
|
|
|
954 |
oprot.writeFieldEnd();
|
|
|
955 |
oprot.writeFieldBegin(CATEGORY_ID_FIELD_DESC);
|
|
|
956 |
oprot.writeI64(this.category_id);
|
|
|
957 |
oprot.writeFieldEnd();
|
|
|
958 |
if (this.compatibility != null) {
|
|
|
959 |
oprot.writeFieldBegin(COMPATIBILITY_FIELD_DESC);
|
|
|
960 |
oprot.writeString(this.compatibility);
|
|
|
961 |
oprot.writeFieldEnd();
|
|
|
962 |
}
|
|
|
963 |
oprot.writeFieldBegin(BATTERY_TYPE_FIELD_DESC);
|
|
|
964 |
oprot.writeI32(this.battery_type);
|
|
|
965 |
oprot.writeFieldEnd();
|
|
|
966 |
if (this.battery_capacity != null) {
|
|
|
967 |
oprot.writeFieldBegin(BATTERY_CAPACITY_FIELD_DESC);
|
|
|
968 |
oprot.writeString(this.battery_capacity);
|
|
|
969 |
oprot.writeFieldEnd();
|
|
|
970 |
}
|
|
|
971 |
if (this.summary != null) {
|
|
|
972 |
oprot.writeFieldBegin(SUMMARY_FIELD_DESC);
|
|
|
973 |
oprot.writeString(this.summary);
|
|
|
974 |
oprot.writeFieldEnd();
|
|
|
975 |
}
|
|
|
976 |
oprot.writeFieldBegin(EXISTING_ENTITY_ID_FIELD_DESC);
|
|
|
977 |
oprot.writeI64(this.existing_entity_id);
|
|
|
978 |
oprot.writeFieldEnd();
|
|
|
979 |
if (this.brand != null) {
|
|
|
980 |
oprot.writeFieldBegin(BRAND_FIELD_DESC);
|
|
|
981 |
oprot.writeString(this.brand);
|
|
|
982 |
oprot.writeFieldEnd();
|
|
|
983 |
}
|
|
|
984 |
if (this.model_name != null) {
|
|
|
985 |
oprot.writeFieldBegin(MODEL_NAME_FIELD_DESC);
|
|
|
986 |
oprot.writeString(this.model_name);
|
|
|
987 |
oprot.writeFieldEnd();
|
|
|
988 |
}
|
|
|
989 |
if (this.model_number != null) {
|
|
|
990 |
oprot.writeFieldBegin(MODEL_NUMBER_FIELD_DESC);
|
|
|
991 |
oprot.writeString(this.model_number);
|
|
|
992 |
oprot.writeFieldEnd();
|
|
|
993 |
}
|
|
|
994 |
oprot.writeFieldStop();
|
|
|
995 |
oprot.writeStructEnd();
|
|
|
996 |
}
|
|
|
997 |
|
|
|
998 |
@Override
|
|
|
999 |
public String toString() {
|
|
|
1000 |
StringBuilder sb = new StringBuilder("BulkContentUpload(");
|
|
|
1001 |
boolean first = true;
|
|
|
1002 |
|
|
|
1003 |
sb.append("new_entity_id:");
|
|
|
1004 |
sb.append(this.new_entity_id);
|
|
|
1005 |
first = false;
|
|
|
1006 |
if (!first) sb.append(", ");
|
|
|
1007 |
sb.append("category_id:");
|
|
|
1008 |
sb.append(this.category_id);
|
|
|
1009 |
first = false;
|
|
|
1010 |
if (!first) sb.append(", ");
|
|
|
1011 |
sb.append("compatibility:");
|
|
|
1012 |
if (this.compatibility == null) {
|
|
|
1013 |
sb.append("null");
|
|
|
1014 |
} else {
|
|
|
1015 |
sb.append(this.compatibility);
|
|
|
1016 |
}
|
|
|
1017 |
first = false;
|
|
|
1018 |
if (!first) sb.append(", ");
|
|
|
1019 |
sb.append("battery_type:");
|
|
|
1020 |
sb.append(this.battery_type);
|
|
|
1021 |
first = false;
|
|
|
1022 |
if (!first) sb.append(", ");
|
|
|
1023 |
sb.append("battery_capacity:");
|
|
|
1024 |
if (this.battery_capacity == null) {
|
|
|
1025 |
sb.append("null");
|
|
|
1026 |
} else {
|
|
|
1027 |
sb.append(this.battery_capacity);
|
|
|
1028 |
}
|
|
|
1029 |
first = false;
|
|
|
1030 |
if (!first) sb.append(", ");
|
|
|
1031 |
sb.append("summary:");
|
|
|
1032 |
if (this.summary == null) {
|
|
|
1033 |
sb.append("null");
|
|
|
1034 |
} else {
|
|
|
1035 |
sb.append(this.summary);
|
|
|
1036 |
}
|
|
|
1037 |
first = false;
|
|
|
1038 |
if (!first) sb.append(", ");
|
|
|
1039 |
sb.append("existing_entity_id:");
|
|
|
1040 |
sb.append(this.existing_entity_id);
|
|
|
1041 |
first = false;
|
|
|
1042 |
if (!first) sb.append(", ");
|
|
|
1043 |
sb.append("brand:");
|
|
|
1044 |
if (this.brand == null) {
|
|
|
1045 |
sb.append("null");
|
|
|
1046 |
} else {
|
|
|
1047 |
sb.append(this.brand);
|
|
|
1048 |
}
|
|
|
1049 |
first = false;
|
|
|
1050 |
if (!first) sb.append(", ");
|
|
|
1051 |
sb.append("model_name:");
|
|
|
1052 |
if (this.model_name == null) {
|
|
|
1053 |
sb.append("null");
|
|
|
1054 |
} else {
|
|
|
1055 |
sb.append(this.model_name);
|
|
|
1056 |
}
|
|
|
1057 |
first = false;
|
|
|
1058 |
if (!first) sb.append(", ");
|
|
|
1059 |
sb.append("model_number:");
|
|
|
1060 |
if (this.model_number == null) {
|
|
|
1061 |
sb.append("null");
|
|
|
1062 |
} else {
|
|
|
1063 |
sb.append(this.model_number);
|
|
|
1064 |
}
|
|
|
1065 |
first = false;
|
|
|
1066 |
sb.append(")");
|
|
|
1067 |
return sb.toString();
|
|
|
1068 |
}
|
|
|
1069 |
|
|
|
1070 |
public void validate() throws org.apache.thrift.TException {
|
|
|
1071 |
// check for required fields
|
|
|
1072 |
}
|
|
|
1073 |
|
|
|
1074 |
private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
|
|
|
1075 |
try {
|
|
|
1076 |
write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
|
|
|
1077 |
} catch (org.apache.thrift.TException te) {
|
|
|
1078 |
throw new java.io.IOException(te);
|
|
|
1079 |
}
|
|
|
1080 |
}
|
|
|
1081 |
|
|
|
1082 |
private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
|
|
|
1083 |
try {
|
|
|
1084 |
// it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
|
|
|
1085 |
__isset_bit_vector = new BitSet(1);
|
|
|
1086 |
read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
|
|
|
1087 |
} catch (org.apache.thrift.TException te) {
|
|
|
1088 |
throw new java.io.IOException(te);
|
|
|
1089 |
}
|
|
|
1090 |
}
|
|
|
1091 |
|
|
|
1092 |
}
|
|
|
1093 |
|