summaryrefslogtreecommitdiffstats
path: root/src/main/java/org/openslx/bwlp/thrift/iface/ImageBaseWrite.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/org/openslx/bwlp/thrift/iface/ImageBaseWrite.java')
-rw-r--r--src/main/java/org/openslx/bwlp/thrift/iface/ImageBaseWrite.java313
1 files changed, 143 insertions, 170 deletions
diff --git a/src/main/java/org/openslx/bwlp/thrift/iface/ImageBaseWrite.java b/src/main/java/org/openslx/bwlp/thrift/iface/ImageBaseWrite.java
index 6e35111..1c796fa 100644
--- a/src/main/java/org/openslx/bwlp/thrift/iface/ImageBaseWrite.java
+++ b/src/main/java/org/openslx/bwlp/thrift/iface/ImageBaseWrite.java
@@ -1,40 +1,13 @@
/**
- * Autogenerated by Thrift Compiler (0.9.3)
+ * Autogenerated by Thrift Compiler (0.15.0)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
package org.openslx.bwlp.thrift.iface;
-import org.apache.thrift.scheme.IScheme;
-import org.apache.thrift.scheme.SchemeFactory;
-import org.apache.thrift.scheme.StandardScheme;
-
-import org.apache.thrift.scheme.TupleScheme;
-import org.apache.thrift.protocol.TTupleProtocol;
-import org.apache.thrift.protocol.TProtocolException;
-import org.apache.thrift.EncodingUtils;
-import org.apache.thrift.TException;
-import org.apache.thrift.async.AsyncMethodCallback;
-import org.apache.thrift.server.AbstractNonblockingServer.*;
-import java.util.List;
-import java.util.ArrayList;
-import java.util.Map;
-import java.util.HashMap;
-import java.util.EnumMap;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.EnumSet;
-import java.util.Collections;
-import java.util.BitSet;
-import java.nio.ByteBuffer;
-import java.util.Arrays;
-import javax.annotation.Generated;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
-@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2016-01-04")
+@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"})
+@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.15.0)", date = "2021-12-17")
public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, ImageBaseWrite._Fields>, java.io.Serializable, Cloneable, Comparable<ImageBaseWrite> {
private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ImageBaseWrite");
@@ -48,25 +21,22 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
private static final org.apache.thrift.protocol.TField ADD_TAGS_FIELD_DESC = new org.apache.thrift.protocol.TField("addTags", org.apache.thrift.protocol.TType.LIST, (short)8);
private static final org.apache.thrift.protocol.TField REM_TAGS_FIELD_DESC = new org.apache.thrift.protocol.TField("remTags", org.apache.thrift.protocol.TType.LIST, (short)9);
- private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
- static {
- schemes.put(StandardScheme.class, new ImageBaseWriteStandardSchemeFactory());
- schemes.put(TupleScheme.class, new ImageBaseWriteTupleSchemeFactory());
- }
+ private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new ImageBaseWriteStandardSchemeFactory();
+ private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new ImageBaseWriteTupleSchemeFactory();
- public String imageName; // required
- public String description; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String imageName; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String description; // required
public int osId; // required
- public String virtId; // required
+ public @org.apache.thrift.annotation.Nullable java.lang.String virtId; // required
public boolean isTemplate; // required
- public ImagePermissions defaultPermissions; // required
+ public @org.apache.thrift.annotation.Nullable ImagePermissions defaultPermissions; // required
/**
*
* @see ShareMode
*/
- public ShareMode shareMode; // required
- public List<String> addTags; // optional
- public List<String> remTags; // optional
+ public @org.apache.thrift.annotation.Nullable ShareMode shareMode; // required
+ public @org.apache.thrift.annotation.Nullable java.util.List<java.lang.String> addTags; // optional
+ public @org.apache.thrift.annotation.Nullable java.util.List<java.lang.String> remTags; // optional
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
public enum _Fields implements org.apache.thrift.TFieldIdEnum {
@@ -84,10 +54,10 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
ADD_TAGS((short)8, "addTags"),
REM_TAGS((short)9, "remTags");
- private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
+ private static final java.util.Map<java.lang.String, _Fields> byName = new java.util.HashMap<java.lang.String, _Fields>();
static {
- for (_Fields field : EnumSet.allOf(_Fields.class)) {
+ for (_Fields field : java.util.EnumSet.allOf(_Fields.class)) {
byName.put(field.getFieldName(), field);
}
}
@@ -95,6 +65,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
/**
* Find the _Fields constant that matches fieldId, or null if its not found.
*/
+ @org.apache.thrift.annotation.Nullable
public static _Fields findByThriftId(int fieldId) {
switch(fieldId) {
case 1: // IMAGE_NAME
@@ -126,21 +97,22 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
*/
public static _Fields findByThriftIdOrThrow(int fieldId) {
_Fields fields = findByThriftId(fieldId);
- if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
+ if (fields == null) throw new java.lang.IllegalArgumentException("Field " + fieldId + " doesn't exist!");
return fields;
}
/**
* Find the _Fields constant that matches name, or null if its not found.
*/
- public static _Fields findByName(String name) {
+ @org.apache.thrift.annotation.Nullable
+ public static _Fields findByName(java.lang.String name) {
return byName.get(name);
}
private final short _thriftId;
- private final String _fieldName;
+ private final java.lang.String _fieldName;
- _Fields(short thriftId, String fieldName) {
+ _Fields(short thriftId, java.lang.String fieldName) {
_thriftId = thriftId;
_fieldName = fieldName;
}
@@ -149,7 +121,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
return _thriftId;
}
- public String getFieldName() {
+ public java.lang.String getFieldName() {
return _fieldName;
}
}
@@ -159,9 +131,9 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
private static final int __ISTEMPLATE_ISSET_ID = 1;
private byte __isset_bitfield = 0;
private static final _Fields optionals[] = {_Fields.ADD_TAGS,_Fields.REM_TAGS};
- public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
+ public static final java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
static {
- Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
+ java.util.Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new java.util.EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
tmpMap.put(_Fields.IMAGE_NAME, new org.apache.thrift.meta_data.FieldMetaData("imageName", org.apache.thrift.TFieldRequirementType.DEFAULT,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
tmpMap.put(_Fields.DESCRIPTION, new org.apache.thrift.meta_data.FieldMetaData("description", org.apache.thrift.TFieldRequirementType.DEFAULT,
@@ -182,7 +154,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
tmpMap.put(_Fields.REM_TAGS, new org.apache.thrift.meta_data.FieldMetaData("remTags", org.apache.thrift.TFieldRequirementType.OPTIONAL,
new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST,
new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
- metaDataMap = Collections.unmodifiableMap(tmpMap);
+ metaDataMap = java.util.Collections.unmodifiableMap(tmpMap);
org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ImageBaseWrite.class, metaDataMap);
}
@@ -190,10 +162,10 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
}
public ImageBaseWrite(
- String imageName,
- String description,
+ java.lang.String imageName,
+ java.lang.String description,
int osId,
- String virtId,
+ java.lang.String virtId,
boolean isTemplate,
ImagePermissions defaultPermissions,
ShareMode shareMode)
@@ -233,11 +205,11 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
this.shareMode = other.shareMode;
}
if (other.isSetAddTags()) {
- List<String> __this__addTags = new ArrayList<String>(other.addTags);
+ java.util.List<java.lang.String> __this__addTags = new java.util.ArrayList<java.lang.String>(other.addTags);
this.addTags = __this__addTags;
}
if (other.isSetRemTags()) {
- List<String> __this__remTags = new ArrayList<String>(other.remTags);
+ java.util.List<java.lang.String> __this__remTags = new java.util.ArrayList<java.lang.String>(other.remTags);
this.remTags = __this__remTags;
}
}
@@ -261,11 +233,12 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
this.remTags = null;
}
- public String getImageName() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getImageName() {
return this.imageName;
}
- public ImageBaseWrite setImageName(String imageName) {
+ public ImageBaseWrite setImageName(@org.apache.thrift.annotation.Nullable java.lang.String imageName) {
this.imageName = imageName;
return this;
}
@@ -285,11 +258,12 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
}
}
- public String getDescription() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getDescription() {
return this.description;
}
- public ImageBaseWrite setDescription(String description) {
+ public ImageBaseWrite setDescription(@org.apache.thrift.annotation.Nullable java.lang.String description) {
this.description = description;
return this;
}
@@ -320,23 +294,24 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
}
public void unsetOsId() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __OSID_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __OSID_ISSET_ID);
}
/** Returns true if field osId is set (has been assigned a value) and false otherwise */
public boolean isSetOsId() {
- return EncodingUtils.testBit(__isset_bitfield, __OSID_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __OSID_ISSET_ID);
}
public void setOsIdIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __OSID_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __OSID_ISSET_ID, value);
}
- public String getVirtId() {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.String getVirtId() {
return this.virtId;
}
- public ImageBaseWrite setVirtId(String virtId) {
+ public ImageBaseWrite setVirtId(@org.apache.thrift.annotation.Nullable java.lang.String virtId) {
this.virtId = virtId;
return this;
}
@@ -367,23 +342,24 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
}
public void unsetIsTemplate() {
- __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ISTEMPLATE_ISSET_ID);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __ISTEMPLATE_ISSET_ID);
}
/** Returns true if field isTemplate is set (has been assigned a value) and false otherwise */
public boolean isSetIsTemplate() {
- return EncodingUtils.testBit(__isset_bitfield, __ISTEMPLATE_ISSET_ID);
+ return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __ISTEMPLATE_ISSET_ID);
}
public void setIsTemplateIsSet(boolean value) {
- __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ISTEMPLATE_ISSET_ID, value);
+ __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __ISTEMPLATE_ISSET_ID, value);
}
+ @org.apache.thrift.annotation.Nullable
public ImagePermissions getDefaultPermissions() {
return this.defaultPermissions;
}
- public ImageBaseWrite setDefaultPermissions(ImagePermissions defaultPermissions) {
+ public ImageBaseWrite setDefaultPermissions(@org.apache.thrift.annotation.Nullable ImagePermissions defaultPermissions) {
this.defaultPermissions = defaultPermissions;
return this;
}
@@ -407,6 +383,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
*
* @see ShareMode
*/
+ @org.apache.thrift.annotation.Nullable
public ShareMode getShareMode() {
return this.shareMode;
}
@@ -415,7 +392,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
*
* @see ShareMode
*/
- public ImageBaseWrite setShareMode(ShareMode shareMode) {
+ public ImageBaseWrite setShareMode(@org.apache.thrift.annotation.Nullable ShareMode shareMode) {
this.shareMode = shareMode;
return this;
}
@@ -439,22 +416,24 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
return (this.addTags == null) ? 0 : this.addTags.size();
}
- public java.util.Iterator<String> getAddTagsIterator() {
+ @org.apache.thrift.annotation.Nullable
+ public java.util.Iterator<java.lang.String> getAddTagsIterator() {
return (this.addTags == null) ? null : this.addTags.iterator();
}
- public void addToAddTags(String elem) {
+ public void addToAddTags(java.lang.String elem) {
if (this.addTags == null) {
- this.addTags = new ArrayList<String>();
+ this.addTags = new java.util.ArrayList<java.lang.String>();
}
this.addTags.add(elem);
}
- public List<String> getAddTags() {
+ @org.apache.thrift.annotation.Nullable
+ public java.util.List<java.lang.String> getAddTags() {
return this.addTags;
}
- public ImageBaseWrite setAddTags(List<String> addTags) {
+ public ImageBaseWrite setAddTags(@org.apache.thrift.annotation.Nullable java.util.List<java.lang.String> addTags) {
this.addTags = addTags;
return this;
}
@@ -478,22 +457,24 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
return (this.remTags == null) ? 0 : this.remTags.size();
}
- public java.util.Iterator<String> getRemTagsIterator() {
+ @org.apache.thrift.annotation.Nullable
+ public java.util.Iterator<java.lang.String> getRemTagsIterator() {
return (this.remTags == null) ? null : this.remTags.iterator();
}
- public void addToRemTags(String elem) {
+ public void addToRemTags(java.lang.String elem) {
if (this.remTags == null) {
- this.remTags = new ArrayList<String>();
+ this.remTags = new java.util.ArrayList<java.lang.String>();
}
this.remTags.add(elem);
}
- public List<String> getRemTags() {
+ @org.apache.thrift.annotation.Nullable
+ public java.util.List<java.lang.String> getRemTags() {
return this.remTags;
}
- public ImageBaseWrite setRemTags(List<String> remTags) {
+ public ImageBaseWrite setRemTags(@org.apache.thrift.annotation.Nullable java.util.List<java.lang.String> remTags) {
this.remTags = remTags;
return this;
}
@@ -513,13 +494,13 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
}
}
- public void setFieldValue(_Fields field, Object value) {
+ public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) {
switch (field) {
case IMAGE_NAME:
if (value == null) {
unsetImageName();
} else {
- setImageName((String)value);
+ setImageName((java.lang.String)value);
}
break;
@@ -527,7 +508,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
if (value == null) {
unsetDescription();
} else {
- setDescription((String)value);
+ setDescription((java.lang.String)value);
}
break;
@@ -535,7 +516,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
if (value == null) {
unsetOsId();
} else {
- setOsId((Integer)value);
+ setOsId((java.lang.Integer)value);
}
break;
@@ -543,7 +524,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
if (value == null) {
unsetVirtId();
} else {
- setVirtId((String)value);
+ setVirtId((java.lang.String)value);
}
break;
@@ -551,7 +532,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
if (value == null) {
unsetIsTemplate();
} else {
- setIsTemplate((Boolean)value);
+ setIsTemplate((java.lang.Boolean)value);
}
break;
@@ -575,7 +556,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
if (value == null) {
unsetAddTags();
} else {
- setAddTags((List<String>)value);
+ setAddTags((java.util.List<java.lang.String>)value);
}
break;
@@ -583,14 +564,15 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
if (value == null) {
unsetRemTags();
} else {
- setRemTags((List<String>)value);
+ setRemTags((java.util.List<java.lang.String>)value);
}
break;
}
}
- public Object getFieldValue(_Fields field) {
+ @org.apache.thrift.annotation.Nullable
+ public java.lang.Object getFieldValue(_Fields field) {
switch (field) {
case IMAGE_NAME:
return getImageName();
@@ -620,13 +602,13 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
return getRemTags();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
/** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
public boolean isSet(_Fields field) {
if (field == null) {
- throw new IllegalArgumentException();
+ throw new java.lang.IllegalArgumentException();
}
switch (field) {
@@ -649,13 +631,11 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
case REM_TAGS:
return isSetRemTags();
}
- throw new IllegalStateException();
+ throw new java.lang.IllegalStateException();
}
@Override
- public boolean equals(Object that) {
- if (that == null)
- return false;
+ public boolean equals(java.lang.Object that) {
if (that instanceof ImageBaseWrite)
return this.equals((ImageBaseWrite)that);
return false;
@@ -664,6 +644,8 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
public boolean equals(ImageBaseWrite that) {
if (that == null)
return false;
+ if (this == that)
+ return true;
boolean this_present_imageName = true && this.isSetImageName();
boolean that_present_imageName = true && that.isSetImageName();
@@ -751,54 +733,41 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
@Override
public int hashCode() {
- List<Object> list = new ArrayList<Object>();
+ int hashCode = 1;
- boolean present_imageName = true && (isSetImageName());
- list.add(present_imageName);
- if (present_imageName)
- list.add(imageName);
+ hashCode = hashCode * 8191 + ((isSetImageName()) ? 131071 : 524287);
+ if (isSetImageName())
+ hashCode = hashCode * 8191 + imageName.hashCode();
- boolean present_description = true && (isSetDescription());
- list.add(present_description);
- if (present_description)
- list.add(description);
+ hashCode = hashCode * 8191 + ((isSetDescription()) ? 131071 : 524287);
+ if (isSetDescription())
+ hashCode = hashCode * 8191 + description.hashCode();
- boolean present_osId = true;
- list.add(present_osId);
- if (present_osId)
- list.add(osId);
+ hashCode = hashCode * 8191 + osId;
- boolean present_virtId = true && (isSetVirtId());
- list.add(present_virtId);
- if (present_virtId)
- list.add(virtId);
+ hashCode = hashCode * 8191 + ((isSetVirtId()) ? 131071 : 524287);
+ if (isSetVirtId())
+ hashCode = hashCode * 8191 + virtId.hashCode();
- boolean present_isTemplate = true;
- list.add(present_isTemplate);
- if (present_isTemplate)
- list.add(isTemplate);
+ hashCode = hashCode * 8191 + ((isTemplate) ? 131071 : 524287);
- boolean present_defaultPermissions = true && (isSetDefaultPermissions());
- list.add(present_defaultPermissions);
- if (present_defaultPermissions)
- list.add(defaultPermissions);
+ hashCode = hashCode * 8191 + ((isSetDefaultPermissions()) ? 131071 : 524287);
+ if (isSetDefaultPermissions())
+ hashCode = hashCode * 8191 + defaultPermissions.hashCode();
- boolean present_shareMode = true && (isSetShareMode());
- list.add(present_shareMode);
- if (present_shareMode)
- list.add(shareMode.getValue());
+ hashCode = hashCode * 8191 + ((isSetShareMode()) ? 131071 : 524287);
+ if (isSetShareMode())
+ hashCode = hashCode * 8191 + shareMode.getValue();
- boolean present_addTags = true && (isSetAddTags());
- list.add(present_addTags);
- if (present_addTags)
- list.add(addTags);
+ hashCode = hashCode * 8191 + ((isSetAddTags()) ? 131071 : 524287);
+ if (isSetAddTags())
+ hashCode = hashCode * 8191 + addTags.hashCode();
- boolean present_remTags = true && (isSetRemTags());
- list.add(present_remTags);
- if (present_remTags)
- list.add(remTags);
+ hashCode = hashCode * 8191 + ((isSetRemTags()) ? 131071 : 524287);
+ if (isSetRemTags())
+ hashCode = hashCode * 8191 + remTags.hashCode();
- return list.hashCode();
+ return hashCode;
}
@Override
@@ -809,7 +778,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
int lastComparison = 0;
- lastComparison = Boolean.valueOf(isSetImageName()).compareTo(other.isSetImageName());
+ lastComparison = java.lang.Boolean.compare(isSetImageName(), other.isSetImageName());
if (lastComparison != 0) {
return lastComparison;
}
@@ -819,7 +788,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription());
+ lastComparison = java.lang.Boolean.compare(isSetDescription(), other.isSetDescription());
if (lastComparison != 0) {
return lastComparison;
}
@@ -829,7 +798,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetOsId()).compareTo(other.isSetOsId());
+ lastComparison = java.lang.Boolean.compare(isSetOsId(), other.isSetOsId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -839,7 +808,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetVirtId()).compareTo(other.isSetVirtId());
+ lastComparison = java.lang.Boolean.compare(isSetVirtId(), other.isSetVirtId());
if (lastComparison != 0) {
return lastComparison;
}
@@ -849,7 +818,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetIsTemplate()).compareTo(other.isSetIsTemplate());
+ lastComparison = java.lang.Boolean.compare(isSetIsTemplate(), other.isSetIsTemplate());
if (lastComparison != 0) {
return lastComparison;
}
@@ -859,7 +828,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetDefaultPermissions()).compareTo(other.isSetDefaultPermissions());
+ lastComparison = java.lang.Boolean.compare(isSetDefaultPermissions(), other.isSetDefaultPermissions());
if (lastComparison != 0) {
return lastComparison;
}
@@ -869,7 +838,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetShareMode()).compareTo(other.isSetShareMode());
+ lastComparison = java.lang.Boolean.compare(isSetShareMode(), other.isSetShareMode());
if (lastComparison != 0) {
return lastComparison;
}
@@ -879,7 +848,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetAddTags()).compareTo(other.isSetAddTags());
+ lastComparison = java.lang.Boolean.compare(isSetAddTags(), other.isSetAddTags());
if (lastComparison != 0) {
return lastComparison;
}
@@ -889,7 +858,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
return lastComparison;
}
}
- lastComparison = Boolean.valueOf(isSetRemTags()).compareTo(other.isSetRemTags());
+ lastComparison = java.lang.Boolean.compare(isSetRemTags(), other.isSetRemTags());
if (lastComparison != 0) {
return lastComparison;
}
@@ -902,21 +871,22 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
return 0;
}
+ @org.apache.thrift.annotation.Nullable
public _Fields fieldForId(int fieldId) {
return _Fields.findByThriftId(fieldId);
}
public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
- schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
+ scheme(iprot).read(iprot, this);
}
public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
- schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
+ scheme(oprot).write(oprot, this);
}
@Override
- public String toString() {
- StringBuilder sb = new StringBuilder("ImageBaseWrite(");
+ public java.lang.String toString() {
+ java.lang.StringBuilder sb = new java.lang.StringBuilder("ImageBaseWrite(");
boolean first = true;
sb.append("imageName:");
@@ -1006,7 +976,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
}
}
- private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
+ private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundException {
try {
// it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
__isset_bitfield = 0;
@@ -1016,13 +986,13 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
}
}
- private static class ImageBaseWriteStandardSchemeFactory implements SchemeFactory {
+ private static class ImageBaseWriteStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ImageBaseWriteStandardScheme getScheme() {
return new ImageBaseWriteStandardScheme();
}
}
- private static class ImageBaseWriteStandardScheme extends StandardScheme<ImageBaseWrite> {
+ private static class ImageBaseWriteStandardScheme extends org.apache.thrift.scheme.StandardScheme<ImageBaseWrite> {
public void read(org.apache.thrift.protocol.TProtocol iprot, ImageBaseWrite struct) throws org.apache.thrift.TException {
org.apache.thrift.protocol.TField schemeField;
@@ -1095,8 +1065,8 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list34 = iprot.readListBegin();
- struct.addTags = new ArrayList<String>(_list34.size);
- String _elem35;
+ struct.addTags = new java.util.ArrayList<java.lang.String>(_list34.size);
+ @org.apache.thrift.annotation.Nullable java.lang.String _elem35;
for (int _i36 = 0; _i36 < _list34.size; ++_i36)
{
_elem35 = iprot.readString();
@@ -1113,8 +1083,8 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
if (schemeField.type == org.apache.thrift.protocol.TType.LIST) {
{
org.apache.thrift.protocol.TList _list37 = iprot.readListBegin();
- struct.remTags = new ArrayList<String>(_list37.size);
- String _elem38;
+ struct.remTags = new java.util.ArrayList<java.lang.String>(_list37.size);
+ @org.apache.thrift.annotation.Nullable java.lang.String _elem38;
for (int _i39 = 0; _i39 < _list37.size; ++_i39)
{
_elem38 = iprot.readString();
@@ -1178,7 +1148,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
oprot.writeFieldBegin(ADD_TAGS_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.addTags.size()));
- for (String _iter40 : struct.addTags)
+ for (java.lang.String _iter40 : struct.addTags)
{
oprot.writeString(_iter40);
}
@@ -1192,7 +1162,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
oprot.writeFieldBegin(REM_TAGS_FIELD_DESC);
{
oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, struct.remTags.size()));
- for (String _iter41 : struct.remTags)
+ for (java.lang.String _iter41 : struct.remTags)
{
oprot.writeString(_iter41);
}
@@ -1207,18 +1177,18 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
}
- private static class ImageBaseWriteTupleSchemeFactory implements SchemeFactory {
+ private static class ImageBaseWriteTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory {
public ImageBaseWriteTupleScheme getScheme() {
return new ImageBaseWriteTupleScheme();
}
}
- private static class ImageBaseWriteTupleScheme extends TupleScheme<ImageBaseWrite> {
+ private static class ImageBaseWriteTupleScheme extends org.apache.thrift.scheme.TupleScheme<ImageBaseWrite> {
@Override
public void write(org.apache.thrift.protocol.TProtocol prot, ImageBaseWrite struct) throws org.apache.thrift.TException {
- TTupleProtocol oprot = (TTupleProtocol) prot;
- BitSet optionals = new BitSet();
+ org.apache.thrift.protocol.TTupleProtocol oprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet optionals = new java.util.BitSet();
if (struct.isSetImageName()) {
optionals.set(0);
}
@@ -1271,7 +1241,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
if (struct.isSetAddTags()) {
{
oprot.writeI32(struct.addTags.size());
- for (String _iter42 : struct.addTags)
+ for (java.lang.String _iter42 : struct.addTags)
{
oprot.writeString(_iter42);
}
@@ -1280,7 +1250,7 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
if (struct.isSetRemTags()) {
{
oprot.writeI32(struct.remTags.size());
- for (String _iter43 : struct.remTags)
+ for (java.lang.String _iter43 : struct.remTags)
{
oprot.writeString(_iter43);
}
@@ -1290,8 +1260,8 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
@Override
public void read(org.apache.thrift.protocol.TProtocol prot, ImageBaseWrite struct) throws org.apache.thrift.TException {
- TTupleProtocol iprot = (TTupleProtocol) prot;
- BitSet incoming = iprot.readBitSet(9);
+ org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot;
+ java.util.BitSet incoming = iprot.readBitSet(9);
if (incoming.get(0)) {
struct.imageName = iprot.readString();
struct.setImageNameIsSet(true);
@@ -1323,9 +1293,9 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
}
if (incoming.get(7)) {
{
- org.apache.thrift.protocol.TList _list44 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.addTags = new ArrayList<String>(_list44.size);
- String _elem45;
+ org.apache.thrift.protocol.TList _list44 = iprot.readListBegin(org.apache.thrift.protocol.TType.STRING);
+ struct.addTags = new java.util.ArrayList<java.lang.String>(_list44.size);
+ @org.apache.thrift.annotation.Nullable java.lang.String _elem45;
for (int _i46 = 0; _i46 < _list44.size; ++_i46)
{
_elem45 = iprot.readString();
@@ -1336,9 +1306,9 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
}
if (incoming.get(8)) {
{
- org.apache.thrift.protocol.TList _list47 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32());
- struct.remTags = new ArrayList<String>(_list47.size);
- String _elem48;
+ org.apache.thrift.protocol.TList _list47 = iprot.readListBegin(org.apache.thrift.protocol.TType.STRING);
+ struct.remTags = new java.util.ArrayList<java.lang.String>(_list47.size);
+ @org.apache.thrift.annotation.Nullable java.lang.String _elem48;
for (int _i49 = 0; _i49 < _list47.size; ++_i49)
{
_elem48 = iprot.readString();
@@ -1350,5 +1320,8 @@ public class ImageBaseWrite implements org.apache.thrift.TBase<ImageBaseWrite, I
}
}
+ private static <S extends org.apache.thrift.scheme.IScheme> S scheme(org.apache.thrift.protocol.TProtocol proto) {
+ return (org.apache.thrift.scheme.StandardScheme.class.equals(proto.getScheme()) ? STANDARD_SCHEME_FACTORY : TUPLE_SCHEME_FACTORY).getScheme();
+ }
}