diff options
Diffstat (limited to 'src/main/java/org/openslx/bwlp/thrift/iface/OperatingSystem.java')
-rw-r--r-- | src/main/java/org/openslx/bwlp/thrift/iface/OperatingSystem.java | 242 |
1 files changed, 105 insertions, 137 deletions
diff --git a/src/main/java/org/openslx/bwlp/thrift/iface/OperatingSystem.java b/src/main/java/org/openslx/bwlp/thrift/iface/OperatingSystem.java index 364ad03..fc1e577 100644 --- a/src/main/java/org/openslx/bwlp/thrift/iface/OperatingSystem.java +++ b/src/main/java/org/openslx/bwlp/thrift/iface/OperatingSystem.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 OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, OperatingSystem._Fields>, java.io.Serializable, Cloneable, Comparable<OperatingSystem> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("OperatingSystem"); @@ -45,16 +18,13 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, private static final org.apache.thrift.protocol.TField MAX_MEM_MB_FIELD_DESC = new org.apache.thrift.protocol.TField("maxMemMb", org.apache.thrift.protocol.TType.I32, (short)5); private static final org.apache.thrift.protocol.TField MAX_CORES_FIELD_DESC = new org.apache.thrift.protocol.TField("maxCores", org.apache.thrift.protocol.TType.I32, (short)6); - private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new OperatingSystemStandardSchemeFactory()); - schemes.put(TupleScheme.class, new OperatingSystemTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new OperatingSystemStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new OperatingSystemTupleSchemeFactory(); public int osId; // required - public String osName; // required - public Map<String,String> virtualizerOsId; // required - public String architecture; // required + public @org.apache.thrift.annotation.Nullable java.lang.String osName; // required + public @org.apache.thrift.annotation.Nullable java.util.Map<java.lang.String,java.lang.String> virtualizerOsId; // required + public @org.apache.thrift.annotation.Nullable java.lang.String architecture; // required public int maxMemMb; // required public int maxCores; // required @@ -67,10 +37,10 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, MAX_MEM_MB((short)5, "maxMemMb"), MAX_CORES((short)6, "maxCores"); - 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); } } @@ -78,6 +48,7 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, /** * 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: // OS_ID @@ -103,21 +74,22 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, */ 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; } @@ -126,7 +98,7 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, return _thriftId; } - public String getFieldName() { + public java.lang.String getFieldName() { return _fieldName; } } @@ -136,9 +108,9 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, private static final int __MAXMEMMB_ISSET_ID = 1; private static final int __MAXCORES_ISSET_ID = 2; private byte __isset_bitfield = 0; - 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.OS_ID, new org.apache.thrift.meta_data.FieldMetaData("osId", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))); tmpMap.put(_Fields.OS_NAME, new org.apache.thrift.meta_data.FieldMetaData("osName", org.apache.thrift.TFieldRequirementType.DEFAULT, @@ -153,7 +125,7 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))); tmpMap.put(_Fields.MAX_CORES, new org.apache.thrift.meta_data.FieldMetaData("maxCores", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I32))); - metaDataMap = Collections.unmodifiableMap(tmpMap); + metaDataMap = java.util.Collections.unmodifiableMap(tmpMap); org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(OperatingSystem.class, metaDataMap); } @@ -162,9 +134,9 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, public OperatingSystem( int osId, - String osName, - Map<String,String> virtualizerOsId, - String architecture, + java.lang.String osName, + java.util.Map<java.lang.String,java.lang.String> virtualizerOsId, + java.lang.String architecture, int maxMemMb, int maxCores) { @@ -190,7 +162,7 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, this.osName = other.osName; } if (other.isSetVirtualizerOsId()) { - Map<String,String> __this__virtualizerOsId = new HashMap<String,String>(other.virtualizerOsId); + java.util.Map<java.lang.String,java.lang.String> __this__virtualizerOsId = new java.util.HashMap<java.lang.String,java.lang.String>(other.virtualizerOsId); this.virtualizerOsId = __this__virtualizerOsId; } if (other.isSetArchitecture()) { @@ -228,23 +200,24 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, } 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 getOsName() { + @org.apache.thrift.annotation.Nullable + public java.lang.String getOsName() { return this.osName; } - public OperatingSystem setOsName(String osName) { + public OperatingSystem setOsName(@org.apache.thrift.annotation.Nullable java.lang.String osName) { this.osName = osName; return this; } @@ -268,18 +241,19 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, return (this.virtualizerOsId == null) ? 0 : this.virtualizerOsId.size(); } - public void putToVirtualizerOsId(String key, String val) { + public void putToVirtualizerOsId(java.lang.String key, java.lang.String val) { if (this.virtualizerOsId == null) { - this.virtualizerOsId = new HashMap<String,String>(); + this.virtualizerOsId = new java.util.HashMap<java.lang.String,java.lang.String>(); } this.virtualizerOsId.put(key, val); } - public Map<String,String> getVirtualizerOsId() { + @org.apache.thrift.annotation.Nullable + public java.util.Map<java.lang.String,java.lang.String> getVirtualizerOsId() { return this.virtualizerOsId; } - public OperatingSystem setVirtualizerOsId(Map<String,String> virtualizerOsId) { + public OperatingSystem setVirtualizerOsId(@org.apache.thrift.annotation.Nullable java.util.Map<java.lang.String,java.lang.String> virtualizerOsId) { this.virtualizerOsId = virtualizerOsId; return this; } @@ -299,11 +273,12 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, } } - public String getArchitecture() { + @org.apache.thrift.annotation.Nullable + public java.lang.String getArchitecture() { return this.architecture; } - public OperatingSystem setArchitecture(String architecture) { + public OperatingSystem setArchitecture(@org.apache.thrift.annotation.Nullable java.lang.String architecture) { this.architecture = architecture; return this; } @@ -334,16 +309,16 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, } public void unsetMaxMemMb() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __MAXMEMMB_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __MAXMEMMB_ISSET_ID); } /** Returns true if field maxMemMb is set (has been assigned a value) and false otherwise */ public boolean isSetMaxMemMb() { - return EncodingUtils.testBit(__isset_bitfield, __MAXMEMMB_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __MAXMEMMB_ISSET_ID); } public void setMaxMemMbIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __MAXMEMMB_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __MAXMEMMB_ISSET_ID, value); } public int getMaxCores() { @@ -357,25 +332,25 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, } public void unsetMaxCores() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __MAXCORES_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __MAXCORES_ISSET_ID); } /** Returns true if field maxCores is set (has been assigned a value) and false otherwise */ public boolean isSetMaxCores() { - return EncodingUtils.testBit(__isset_bitfield, __MAXCORES_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __MAXCORES_ISSET_ID); } public void setMaxCoresIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __MAXCORES_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __MAXCORES_ISSET_ID, value); } - public void setFieldValue(_Fields field, Object value) { + public void setFieldValue(_Fields field, @org.apache.thrift.annotation.Nullable java.lang.Object value) { switch (field) { case OS_ID: if (value == null) { unsetOsId(); } else { - setOsId((Integer)value); + setOsId((java.lang.Integer)value); } break; @@ -383,7 +358,7 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, if (value == null) { unsetOsName(); } else { - setOsName((String)value); + setOsName((java.lang.String)value); } break; @@ -391,7 +366,7 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, if (value == null) { unsetVirtualizerOsId(); } else { - setVirtualizerOsId((Map<String,String>)value); + setVirtualizerOsId((java.util.Map<java.lang.String,java.lang.String>)value); } break; @@ -399,7 +374,7 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, if (value == null) { unsetArchitecture(); } else { - setArchitecture((String)value); + setArchitecture((java.lang.String)value); } break; @@ -407,7 +382,7 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, if (value == null) { unsetMaxMemMb(); } else { - setMaxMemMb((Integer)value); + setMaxMemMb((java.lang.Integer)value); } break; @@ -415,14 +390,15 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, if (value == null) { unsetMaxCores(); } else { - setMaxCores((Integer)value); + setMaxCores((java.lang.Integer)value); } break; } } - public Object getFieldValue(_Fields field) { + @org.apache.thrift.annotation.Nullable + public java.lang.Object getFieldValue(_Fields field) { switch (field) { case OS_ID: return getOsId(); @@ -443,13 +419,13 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, return getMaxCores(); } - 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) { @@ -466,13 +442,11 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, case MAX_CORES: return isSetMaxCores(); } - 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 OperatingSystem) return this.equals((OperatingSystem)that); return false; @@ -481,6 +455,8 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, public boolean equals(OperatingSystem that) { if (that == null) return false; + if (this == that) + return true; boolean this_present_osId = true; boolean that_present_osId = true; @@ -541,39 +517,27 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, @Override public int hashCode() { - List<Object> list = new ArrayList<Object>(); + int hashCode = 1; - boolean present_osId = true; - list.add(present_osId); - if (present_osId) - list.add(osId); + hashCode = hashCode * 8191 + osId; - boolean present_osName = true && (isSetOsName()); - list.add(present_osName); - if (present_osName) - list.add(osName); + hashCode = hashCode * 8191 + ((isSetOsName()) ? 131071 : 524287); + if (isSetOsName()) + hashCode = hashCode * 8191 + osName.hashCode(); - boolean present_virtualizerOsId = true && (isSetVirtualizerOsId()); - list.add(present_virtualizerOsId); - if (present_virtualizerOsId) - list.add(virtualizerOsId); + hashCode = hashCode * 8191 + ((isSetVirtualizerOsId()) ? 131071 : 524287); + if (isSetVirtualizerOsId()) + hashCode = hashCode * 8191 + virtualizerOsId.hashCode(); - boolean present_architecture = true && (isSetArchitecture()); - list.add(present_architecture); - if (present_architecture) - list.add(architecture); + hashCode = hashCode * 8191 + ((isSetArchitecture()) ? 131071 : 524287); + if (isSetArchitecture()) + hashCode = hashCode * 8191 + architecture.hashCode(); - boolean present_maxMemMb = true; - list.add(present_maxMemMb); - if (present_maxMemMb) - list.add(maxMemMb); + hashCode = hashCode * 8191 + maxMemMb; - boolean present_maxCores = true; - list.add(present_maxCores); - if (present_maxCores) - list.add(maxCores); + hashCode = hashCode * 8191 + maxCores; - return list.hashCode(); + return hashCode; } @Override @@ -584,7 +548,7 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, int lastComparison = 0; - lastComparison = Boolean.valueOf(isSetOsId()).compareTo(other.isSetOsId()); + lastComparison = java.lang.Boolean.compare(isSetOsId(), other.isSetOsId()); if (lastComparison != 0) { return lastComparison; } @@ -594,7 +558,7 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, return lastComparison; } } - lastComparison = Boolean.valueOf(isSetOsName()).compareTo(other.isSetOsName()); + lastComparison = java.lang.Boolean.compare(isSetOsName(), other.isSetOsName()); if (lastComparison != 0) { return lastComparison; } @@ -604,7 +568,7 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, return lastComparison; } } - lastComparison = Boolean.valueOf(isSetVirtualizerOsId()).compareTo(other.isSetVirtualizerOsId()); + lastComparison = java.lang.Boolean.compare(isSetVirtualizerOsId(), other.isSetVirtualizerOsId()); if (lastComparison != 0) { return lastComparison; } @@ -614,7 +578,7 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, return lastComparison; } } - lastComparison = Boolean.valueOf(isSetArchitecture()).compareTo(other.isSetArchitecture()); + lastComparison = java.lang.Boolean.compare(isSetArchitecture(), other.isSetArchitecture()); if (lastComparison != 0) { return lastComparison; } @@ -624,7 +588,7 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, return lastComparison; } } - lastComparison = Boolean.valueOf(isSetMaxMemMb()).compareTo(other.isSetMaxMemMb()); + lastComparison = java.lang.Boolean.compare(isSetMaxMemMb(), other.isSetMaxMemMb()); if (lastComparison != 0) { return lastComparison; } @@ -634,7 +598,7 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, return lastComparison; } } - lastComparison = Boolean.valueOf(isSetMaxCores()).compareTo(other.isSetMaxCores()); + lastComparison = java.lang.Boolean.compare(isSetMaxCores(), other.isSetMaxCores()); if (lastComparison != 0) { return lastComparison; } @@ -647,21 +611,22 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, 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("OperatingSystem("); + public java.lang.String toString() { + java.lang.StringBuilder sb = new java.lang.StringBuilder("OperatingSystem("); boolean first = true; sb.append("osId:"); @@ -716,7 +681,7 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, } } - 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; @@ -726,13 +691,13 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, } } - private static class OperatingSystemStandardSchemeFactory implements SchemeFactory { + private static class OperatingSystemStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory { public OperatingSystemStandardScheme getScheme() { return new OperatingSystemStandardScheme(); } } - private static class OperatingSystemStandardScheme extends StandardScheme<OperatingSystem> { + private static class OperatingSystemStandardScheme extends org.apache.thrift.scheme.StandardScheme<OperatingSystem> { public void read(org.apache.thrift.protocol.TProtocol iprot, OperatingSystem struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -764,9 +729,9 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, if (schemeField.type == org.apache.thrift.protocol.TType.MAP) { { org.apache.thrift.protocol.TMap _map24 = iprot.readMapBegin(); - struct.virtualizerOsId = new HashMap<String,String>(2*_map24.size); - String _key25; - String _val26; + struct.virtualizerOsId = new java.util.HashMap<java.lang.String,java.lang.String>(2*_map24.size); + @org.apache.thrift.annotation.Nullable java.lang.String _key25; + @org.apache.thrift.annotation.Nullable java.lang.String _val26; for (int _i27 = 0; _i27 < _map24.size; ++_i27) { _key25 = iprot.readString(); @@ -831,7 +796,7 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, oprot.writeFieldBegin(VIRTUALIZER_OS_ID_FIELD_DESC); { oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, struct.virtualizerOsId.size())); - for (Map.Entry<String, String> _iter28 : struct.virtualizerOsId.entrySet()) + for (java.util.Map.Entry<java.lang.String, java.lang.String> _iter28 : struct.virtualizerOsId.entrySet()) { oprot.writeString(_iter28.getKey()); oprot.writeString(_iter28.getValue()); @@ -857,18 +822,18 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, } - private static class OperatingSystemTupleSchemeFactory implements SchemeFactory { + private static class OperatingSystemTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory { public OperatingSystemTupleScheme getScheme() { return new OperatingSystemTupleScheme(); } } - private static class OperatingSystemTupleScheme extends TupleScheme<OperatingSystem> { + private static class OperatingSystemTupleScheme extends org.apache.thrift.scheme.TupleScheme<OperatingSystem> { @Override public void write(org.apache.thrift.protocol.TProtocol prot, OperatingSystem 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.isSetOsId()) { optionals.set(0); } @@ -897,7 +862,7 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, if (struct.isSetVirtualizerOsId()) { { oprot.writeI32(struct.virtualizerOsId.size()); - for (Map.Entry<String, String> _iter29 : struct.virtualizerOsId.entrySet()) + for (java.util.Map.Entry<java.lang.String, java.lang.String> _iter29 : struct.virtualizerOsId.entrySet()) { oprot.writeString(_iter29.getKey()); oprot.writeString(_iter29.getValue()); @@ -917,8 +882,8 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, @Override public void read(org.apache.thrift.protocol.TProtocol prot, OperatingSystem struct) throws org.apache.thrift.TException { - TTupleProtocol iprot = (TTupleProtocol) prot; - BitSet incoming = iprot.readBitSet(6); + org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot; + java.util.BitSet incoming = iprot.readBitSet(6); if (incoming.get(0)) { struct.osId = iprot.readI32(); struct.setOsIdIsSet(true); @@ -929,10 +894,10 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, } if (incoming.get(2)) { { - org.apache.thrift.protocol.TMap _map30 = new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.virtualizerOsId = new HashMap<String,String>(2*_map30.size); - String _key31; - String _val32; + org.apache.thrift.protocol.TMap _map30 = iprot.readMapBegin(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.STRING); + struct.virtualizerOsId = new java.util.HashMap<java.lang.String,java.lang.String>(2*_map30.size); + @org.apache.thrift.annotation.Nullable java.lang.String _key31; + @org.apache.thrift.annotation.Nullable java.lang.String _val32; for (int _i33 = 0; _i33 < _map30.size; ++_i33) { _key31 = iprot.readString(); @@ -957,5 +922,8 @@ public class OperatingSystem implements org.apache.thrift.TBase<OperatingSystem, } } + 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(); + } } |