diff options
Diffstat (limited to 'src/main/java/org/openslx/bwlp/thrift/iface/LectureSummary.java')
-rw-r--r-- | src/main/java/org/openslx/bwlp/thrift/iface/LectureSummary.java | 454 |
1 files changed, 202 insertions, 252 deletions
diff --git a/src/main/java/org/openslx/bwlp/thrift/iface/LectureSummary.java b/src/main/java/org/openslx/bwlp/thrift/iface/LectureSummary.java index 25e518b..18e2016 100644 --- a/src/main/java/org/openslx/bwlp/thrift/iface/LectureSummary.java +++ b/src/main/java/org/openslx/bwlp/thrift/iface/LectureSummary.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 = "2020-10-12") +@SuppressWarnings({"cast", "rawtypes", "serial", "unchecked", "unused"}) +@javax.annotation.Generated(value = "Autogenerated by Thrift Compiler (0.15.0)", date = "2021-12-17") public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, LectureSummary._Fields>, java.io.Serializable, Cloneable, Comparable<LectureSummary> { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("LectureSummary"); @@ -57,28 +30,25 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L private static final org.apache.thrift.protocol.TField IS_IMAGE_VERSION_USABLE_FIELD_DESC = new org.apache.thrift.protocol.TField("isImageVersionUsable", org.apache.thrift.protocol.TType.BOOL, (short)16); private static final org.apache.thrift.protocol.TField HAS_USB_ACCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("hasUsbAccess", org.apache.thrift.protocol.TType.BOOL, (short)17); - private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>(); - static { - schemes.put(StandardScheme.class, new LectureSummaryStandardSchemeFactory()); - schemes.put(TupleScheme.class, new LectureSummaryTupleSchemeFactory()); - } + private static final org.apache.thrift.scheme.SchemeFactory STANDARD_SCHEME_FACTORY = new LectureSummaryStandardSchemeFactory(); + private static final org.apache.thrift.scheme.SchemeFactory TUPLE_SCHEME_FACTORY = new LectureSummaryTupleSchemeFactory(); - public String lectureId; // required - public String lectureName; // required - public String description; // required - public String imageVersionId; // required - public String imageBaseId; // required + public @org.apache.thrift.annotation.Nullable java.lang.String lectureId; // required + public @org.apache.thrift.annotation.Nullable java.lang.String lectureName; // required + public @org.apache.thrift.annotation.Nullable java.lang.String description; // required + public @org.apache.thrift.annotation.Nullable java.lang.String imageVersionId; // required + public @org.apache.thrift.annotation.Nullable java.lang.String imageBaseId; // required public boolean isEnabled; // required public long startTime; // required public long endTime; // required public long lastUsed; // required public int useCount; // required - public String ownerId; // required - public String updaterId; // required + public @org.apache.thrift.annotation.Nullable java.lang.String ownerId; // required + public @org.apache.thrift.annotation.Nullable java.lang.String updaterId; // required public boolean isExam; // required public boolean hasInternetAccess; // required - public LecturePermissions defaultPermissions; // required - public LecturePermissions userPermissions; // optional + public @org.apache.thrift.annotation.Nullable LecturePermissions defaultPermissions; // required + public @org.apache.thrift.annotation.Nullable LecturePermissions userPermissions; // optional public boolean isImageVersionUsable; // required public boolean hasUsbAccess; // required @@ -103,10 +73,10 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L IS_IMAGE_VERSION_USABLE((short)16, "isImageVersionUsable"), HAS_USB_ACCESS((short)17, "hasUsbAccess"); - 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); } } @@ -114,6 +84,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L /** * 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: // LECTURE_ID @@ -163,21 +134,22 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L */ 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; } @@ -186,7 +158,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return _thriftId; } - public String getFieldName() { + public java.lang.String getFieldName() { return _fieldName; } } @@ -203,9 +175,9 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L private static final int __HASUSBACCESS_ISSET_ID = 8; private short __isset_bitfield = 0; private static final _Fields optionals[] = {_Fields.USER_PERMISSIONS}; - 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.LECTURE_ID, new org.apache.thrift.meta_data.FieldMetaData("lectureId", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING , "UUID"))); tmpMap.put(_Fields.LECTURE_NAME, new org.apache.thrift.meta_data.FieldMetaData("lectureName", org.apache.thrift.TFieldRequirementType.DEFAULT, @@ -242,7 +214,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL))); tmpMap.put(_Fields.HAS_USB_ACCESS, new org.apache.thrift.meta_data.FieldMetaData("hasUsbAccess", org.apache.thrift.TFieldRequirementType.DEFAULT, new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL))); - metaDataMap = Collections.unmodifiableMap(tmpMap); + metaDataMap = java.util.Collections.unmodifiableMap(tmpMap); org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(LectureSummary.class, metaDataMap); } @@ -250,18 +222,18 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } public LectureSummary( - String lectureId, - String lectureName, - String description, - String imageVersionId, - String imageBaseId, + java.lang.String lectureId, + java.lang.String lectureName, + java.lang.String description, + java.lang.String imageVersionId, + java.lang.String imageBaseId, boolean isEnabled, long startTime, long endTime, long lastUsed, int useCount, - String ownerId, - String updaterId, + java.lang.String ownerId, + java.lang.String updaterId, boolean isExam, boolean hasInternetAccess, LecturePermissions defaultPermissions, @@ -375,11 +347,12 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L this.hasUsbAccess = false; } - public String getLectureId() { + @org.apache.thrift.annotation.Nullable + public java.lang.String getLectureId() { return this.lectureId; } - public LectureSummary setLectureId(String lectureId) { + public LectureSummary setLectureId(@org.apache.thrift.annotation.Nullable java.lang.String lectureId) { this.lectureId = lectureId; return this; } @@ -399,11 +372,12 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } } - public String getLectureName() { + @org.apache.thrift.annotation.Nullable + public java.lang.String getLectureName() { return this.lectureName; } - public LectureSummary setLectureName(String lectureName) { + public LectureSummary setLectureName(@org.apache.thrift.annotation.Nullable java.lang.String lectureName) { this.lectureName = lectureName; return this; } @@ -423,11 +397,12 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } } - public String getDescription() { + @org.apache.thrift.annotation.Nullable + public java.lang.String getDescription() { return this.description; } - public LectureSummary setDescription(String description) { + public LectureSummary setDescription(@org.apache.thrift.annotation.Nullable java.lang.String description) { this.description = description; return this; } @@ -447,11 +422,12 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } } - public String getImageVersionId() { + @org.apache.thrift.annotation.Nullable + public java.lang.String getImageVersionId() { return this.imageVersionId; } - public LectureSummary setImageVersionId(String imageVersionId) { + public LectureSummary setImageVersionId(@org.apache.thrift.annotation.Nullable java.lang.String imageVersionId) { this.imageVersionId = imageVersionId; return this; } @@ -471,11 +447,12 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } } - public String getImageBaseId() { + @org.apache.thrift.annotation.Nullable + public java.lang.String getImageBaseId() { return this.imageBaseId; } - public LectureSummary setImageBaseId(String imageBaseId) { + public LectureSummary setImageBaseId(@org.apache.thrift.annotation.Nullable java.lang.String imageBaseId) { this.imageBaseId = imageBaseId; return this; } @@ -506,16 +483,16 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } public void unsetIsEnabled() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ISENABLED_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __ISENABLED_ISSET_ID); } /** Returns true if field isEnabled is set (has been assigned a value) and false otherwise */ public boolean isSetIsEnabled() { - return EncodingUtils.testBit(__isset_bitfield, __ISENABLED_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __ISENABLED_ISSET_ID); } public void setIsEnabledIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ISENABLED_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __ISENABLED_ISSET_ID, value); } public long getStartTime() { @@ -529,16 +506,16 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } public void unsetStartTime() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __STARTTIME_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __STARTTIME_ISSET_ID); } /** Returns true if field startTime is set (has been assigned a value) and false otherwise */ public boolean isSetStartTime() { - return EncodingUtils.testBit(__isset_bitfield, __STARTTIME_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __STARTTIME_ISSET_ID); } public void setStartTimeIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __STARTTIME_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __STARTTIME_ISSET_ID, value); } public long getEndTime() { @@ -552,16 +529,16 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } public void unsetEndTime() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ENDTIME_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __ENDTIME_ISSET_ID); } /** Returns true if field endTime is set (has been assigned a value) and false otherwise */ public boolean isSetEndTime() { - return EncodingUtils.testBit(__isset_bitfield, __ENDTIME_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __ENDTIME_ISSET_ID); } public void setEndTimeIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ENDTIME_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __ENDTIME_ISSET_ID, value); } public long getLastUsed() { @@ -575,16 +552,16 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } public void unsetLastUsed() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __LASTUSED_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __LASTUSED_ISSET_ID); } /** Returns true if field lastUsed is set (has been assigned a value) and false otherwise */ public boolean isSetLastUsed() { - return EncodingUtils.testBit(__isset_bitfield, __LASTUSED_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __LASTUSED_ISSET_ID); } public void setLastUsedIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __LASTUSED_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __LASTUSED_ISSET_ID, value); } public int getUseCount() { @@ -598,23 +575,24 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } public void unsetUseCount() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __USECOUNT_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __USECOUNT_ISSET_ID); } /** Returns true if field useCount is set (has been assigned a value) and false otherwise */ public boolean isSetUseCount() { - return EncodingUtils.testBit(__isset_bitfield, __USECOUNT_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __USECOUNT_ISSET_ID); } public void setUseCountIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __USECOUNT_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __USECOUNT_ISSET_ID, value); } - public String getOwnerId() { + @org.apache.thrift.annotation.Nullable + public java.lang.String getOwnerId() { return this.ownerId; } - public LectureSummary setOwnerId(String ownerId) { + public LectureSummary setOwnerId(@org.apache.thrift.annotation.Nullable java.lang.String ownerId) { this.ownerId = ownerId; return this; } @@ -634,11 +612,12 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } } - public String getUpdaterId() { + @org.apache.thrift.annotation.Nullable + public java.lang.String getUpdaterId() { return this.updaterId; } - public LectureSummary setUpdaterId(String updaterId) { + public LectureSummary setUpdaterId(@org.apache.thrift.annotation.Nullable java.lang.String updaterId) { this.updaterId = updaterId; return this; } @@ -669,16 +648,16 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } public void unsetIsExam() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ISEXAM_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __ISEXAM_ISSET_ID); } /** Returns true if field isExam is set (has been assigned a value) and false otherwise */ public boolean isSetIsExam() { - return EncodingUtils.testBit(__isset_bitfield, __ISEXAM_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __ISEXAM_ISSET_ID); } public void setIsExamIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ISEXAM_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __ISEXAM_ISSET_ID, value); } public boolean isHasInternetAccess() { @@ -692,23 +671,24 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } public void unsetHasInternetAccess() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __HASINTERNETACCESS_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __HASINTERNETACCESS_ISSET_ID); } /** Returns true if field hasInternetAccess is set (has been assigned a value) and false otherwise */ public boolean isSetHasInternetAccess() { - return EncodingUtils.testBit(__isset_bitfield, __HASINTERNETACCESS_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __HASINTERNETACCESS_ISSET_ID); } public void setHasInternetAccessIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __HASINTERNETACCESS_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __HASINTERNETACCESS_ISSET_ID, value); } + @org.apache.thrift.annotation.Nullable public LecturePermissions getDefaultPermissions() { return this.defaultPermissions; } - public LectureSummary setDefaultPermissions(LecturePermissions defaultPermissions) { + public LectureSummary setDefaultPermissions(@org.apache.thrift.annotation.Nullable LecturePermissions defaultPermissions) { this.defaultPermissions = defaultPermissions; return this; } @@ -728,11 +708,12 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } } + @org.apache.thrift.annotation.Nullable public LecturePermissions getUserPermissions() { return this.userPermissions; } - public LectureSummary setUserPermissions(LecturePermissions userPermissions) { + public LectureSummary setUserPermissions(@org.apache.thrift.annotation.Nullable LecturePermissions userPermissions) { this.userPermissions = userPermissions; return this; } @@ -763,16 +744,16 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } public void unsetIsImageVersionUsable() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __ISIMAGEVERSIONUSABLE_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __ISIMAGEVERSIONUSABLE_ISSET_ID); } /** Returns true if field isImageVersionUsable is set (has been assigned a value) and false otherwise */ public boolean isSetIsImageVersionUsable() { - return EncodingUtils.testBit(__isset_bitfield, __ISIMAGEVERSIONUSABLE_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __ISIMAGEVERSIONUSABLE_ISSET_ID); } public void setIsImageVersionUsableIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __ISIMAGEVERSIONUSABLE_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __ISIMAGEVERSIONUSABLE_ISSET_ID, value); } public boolean isHasUsbAccess() { @@ -786,25 +767,25 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } public void unsetHasUsbAccess() { - __isset_bitfield = EncodingUtils.clearBit(__isset_bitfield, __HASUSBACCESS_ISSET_ID); + __isset_bitfield = org.apache.thrift.EncodingUtils.clearBit(__isset_bitfield, __HASUSBACCESS_ISSET_ID); } /** Returns true if field hasUsbAccess is set (has been assigned a value) and false otherwise */ public boolean isSetHasUsbAccess() { - return EncodingUtils.testBit(__isset_bitfield, __HASUSBACCESS_ISSET_ID); + return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __HASUSBACCESS_ISSET_ID); } public void setHasUsbAccessIsSet(boolean value) { - __isset_bitfield = EncodingUtils.setBit(__isset_bitfield, __HASUSBACCESS_ISSET_ID, value); + __isset_bitfield = org.apache.thrift.EncodingUtils.setBit(__isset_bitfield, __HASUSBACCESS_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 LECTURE_ID: if (value == null) { unsetLectureId(); } else { - setLectureId((String)value); + setLectureId((java.lang.String)value); } break; @@ -812,7 +793,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L if (value == null) { unsetLectureName(); } else { - setLectureName((String)value); + setLectureName((java.lang.String)value); } break; @@ -820,7 +801,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L if (value == null) { unsetDescription(); } else { - setDescription((String)value); + setDescription((java.lang.String)value); } break; @@ -828,7 +809,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L if (value == null) { unsetImageVersionId(); } else { - setImageVersionId((String)value); + setImageVersionId((java.lang.String)value); } break; @@ -836,7 +817,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L if (value == null) { unsetImageBaseId(); } else { - setImageBaseId((String)value); + setImageBaseId((java.lang.String)value); } break; @@ -844,7 +825,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L if (value == null) { unsetIsEnabled(); } else { - setIsEnabled((Boolean)value); + setIsEnabled((java.lang.Boolean)value); } break; @@ -852,7 +833,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L if (value == null) { unsetStartTime(); } else { - setStartTime((Long)value); + setStartTime((java.lang.Long)value); } break; @@ -860,7 +841,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L if (value == null) { unsetEndTime(); } else { - setEndTime((Long)value); + setEndTime((java.lang.Long)value); } break; @@ -868,7 +849,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L if (value == null) { unsetLastUsed(); } else { - setLastUsed((Long)value); + setLastUsed((java.lang.Long)value); } break; @@ -876,7 +857,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L if (value == null) { unsetUseCount(); } else { - setUseCount((Integer)value); + setUseCount((java.lang.Integer)value); } break; @@ -884,7 +865,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L if (value == null) { unsetOwnerId(); } else { - setOwnerId((String)value); + setOwnerId((java.lang.String)value); } break; @@ -892,7 +873,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L if (value == null) { unsetUpdaterId(); } else { - setUpdaterId((String)value); + setUpdaterId((java.lang.String)value); } break; @@ -900,7 +881,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L if (value == null) { unsetIsExam(); } else { - setIsExam((Boolean)value); + setIsExam((java.lang.Boolean)value); } break; @@ -908,7 +889,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L if (value == null) { unsetHasInternetAccess(); } else { - setHasInternetAccess((Boolean)value); + setHasInternetAccess((java.lang.Boolean)value); } break; @@ -932,7 +913,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L if (value == null) { unsetIsImageVersionUsable(); } else { - setIsImageVersionUsable((Boolean)value); + setIsImageVersionUsable((java.lang.Boolean)value); } break; @@ -940,14 +921,15 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L if (value == null) { unsetHasUsbAccess(); } else { - setHasUsbAccess((Boolean)value); + setHasUsbAccess((java.lang.Boolean)value); } break; } } - public Object getFieldValue(_Fields field) { + @org.apache.thrift.annotation.Nullable + public java.lang.Object getFieldValue(_Fields field) { switch (field) { case LECTURE_ID: return getLectureId(); @@ -1004,13 +986,13 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return isHasUsbAccess(); } - 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) { @@ -1051,13 +1033,11 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L case HAS_USB_ACCESS: return isSetHasUsbAccess(); } - 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 LectureSummary) return this.equals((LectureSummary)that); return false; @@ -1066,6 +1046,8 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L public boolean equals(LectureSummary that) { if (that == null) return false; + if (this == that) + return true; boolean this_present_lectureId = true && this.isSetLectureId(); boolean that_present_lectureId = true && that.isSetLectureId(); @@ -1234,99 +1216,63 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L @Override public int hashCode() { - List<Object> list = new ArrayList<Object>(); - - boolean present_lectureId = true && (isSetLectureId()); - list.add(present_lectureId); - if (present_lectureId) - list.add(lectureId); - - boolean present_lectureName = true && (isSetLectureName()); - list.add(present_lectureName); - if (present_lectureName) - list.add(lectureName); - - boolean present_description = true && (isSetDescription()); - list.add(present_description); - if (present_description) - list.add(description); - - boolean present_imageVersionId = true && (isSetImageVersionId()); - list.add(present_imageVersionId); - if (present_imageVersionId) - list.add(imageVersionId); - - boolean present_imageBaseId = true && (isSetImageBaseId()); - list.add(present_imageBaseId); - if (present_imageBaseId) - list.add(imageBaseId); - - boolean present_isEnabled = true; - list.add(present_isEnabled); - if (present_isEnabled) - list.add(isEnabled); - - boolean present_startTime = true; - list.add(present_startTime); - if (present_startTime) - list.add(startTime); - - boolean present_endTime = true; - list.add(present_endTime); - if (present_endTime) - list.add(endTime); - - boolean present_lastUsed = true; - list.add(present_lastUsed); - if (present_lastUsed) - list.add(lastUsed); - - boolean present_useCount = true; - list.add(present_useCount); - if (present_useCount) - list.add(useCount); - - boolean present_ownerId = true && (isSetOwnerId()); - list.add(present_ownerId); - if (present_ownerId) - list.add(ownerId); - - boolean present_updaterId = true && (isSetUpdaterId()); - list.add(present_updaterId); - if (present_updaterId) - list.add(updaterId); - - boolean present_isExam = true; - list.add(present_isExam); - if (present_isExam) - list.add(isExam); - - boolean present_hasInternetAccess = true; - list.add(present_hasInternetAccess); - if (present_hasInternetAccess) - list.add(hasInternetAccess); - - boolean present_defaultPermissions = true && (isSetDefaultPermissions()); - list.add(present_defaultPermissions); - if (present_defaultPermissions) - list.add(defaultPermissions); - - boolean present_userPermissions = true && (isSetUserPermissions()); - list.add(present_userPermissions); - if (present_userPermissions) - list.add(userPermissions); - - boolean present_isImageVersionUsable = true; - list.add(present_isImageVersionUsable); - if (present_isImageVersionUsable) - list.add(isImageVersionUsable); - - boolean present_hasUsbAccess = true; - list.add(present_hasUsbAccess); - if (present_hasUsbAccess) - list.add(hasUsbAccess); - - return list.hashCode(); + int hashCode = 1; + + hashCode = hashCode * 8191 + ((isSetLectureId()) ? 131071 : 524287); + if (isSetLectureId()) + hashCode = hashCode * 8191 + lectureId.hashCode(); + + hashCode = hashCode * 8191 + ((isSetLectureName()) ? 131071 : 524287); + if (isSetLectureName()) + hashCode = hashCode * 8191 + lectureName.hashCode(); + + hashCode = hashCode * 8191 + ((isSetDescription()) ? 131071 : 524287); + if (isSetDescription()) + hashCode = hashCode * 8191 + description.hashCode(); + + hashCode = hashCode * 8191 + ((isSetImageVersionId()) ? 131071 : 524287); + if (isSetImageVersionId()) + hashCode = hashCode * 8191 + imageVersionId.hashCode(); + + hashCode = hashCode * 8191 + ((isSetImageBaseId()) ? 131071 : 524287); + if (isSetImageBaseId()) + hashCode = hashCode * 8191 + imageBaseId.hashCode(); + + hashCode = hashCode * 8191 + ((isEnabled) ? 131071 : 524287); + + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(startTime); + + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(endTime); + + hashCode = hashCode * 8191 + org.apache.thrift.TBaseHelper.hashCode(lastUsed); + + hashCode = hashCode * 8191 + useCount; + + hashCode = hashCode * 8191 + ((isSetOwnerId()) ? 131071 : 524287); + if (isSetOwnerId()) + hashCode = hashCode * 8191 + ownerId.hashCode(); + + hashCode = hashCode * 8191 + ((isSetUpdaterId()) ? 131071 : 524287); + if (isSetUpdaterId()) + hashCode = hashCode * 8191 + updaterId.hashCode(); + + hashCode = hashCode * 8191 + ((isExam) ? 131071 : 524287); + + hashCode = hashCode * 8191 + ((hasInternetAccess) ? 131071 : 524287); + + hashCode = hashCode * 8191 + ((isSetDefaultPermissions()) ? 131071 : 524287); + if (isSetDefaultPermissions()) + hashCode = hashCode * 8191 + defaultPermissions.hashCode(); + + hashCode = hashCode * 8191 + ((isSetUserPermissions()) ? 131071 : 524287); + if (isSetUserPermissions()) + hashCode = hashCode * 8191 + userPermissions.hashCode(); + + hashCode = hashCode * 8191 + ((isImageVersionUsable) ? 131071 : 524287); + + hashCode = hashCode * 8191 + ((hasUsbAccess) ? 131071 : 524287); + + return hashCode; } @Override @@ -1337,7 +1283,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L int lastComparison = 0; - lastComparison = Boolean.valueOf(isSetLectureId()).compareTo(other.isSetLectureId()); + lastComparison = java.lang.Boolean.compare(isSetLectureId(), other.isSetLectureId()); if (lastComparison != 0) { return lastComparison; } @@ -1347,7 +1293,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return lastComparison; } } - lastComparison = Boolean.valueOf(isSetLectureName()).compareTo(other.isSetLectureName()); + lastComparison = java.lang.Boolean.compare(isSetLectureName(), other.isSetLectureName()); if (lastComparison != 0) { return lastComparison; } @@ -1357,7 +1303,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return lastComparison; } } - lastComparison = Boolean.valueOf(isSetDescription()).compareTo(other.isSetDescription()); + lastComparison = java.lang.Boolean.compare(isSetDescription(), other.isSetDescription()); if (lastComparison != 0) { return lastComparison; } @@ -1367,7 +1313,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return lastComparison; } } - lastComparison = Boolean.valueOf(isSetImageVersionId()).compareTo(other.isSetImageVersionId()); + lastComparison = java.lang.Boolean.compare(isSetImageVersionId(), other.isSetImageVersionId()); if (lastComparison != 0) { return lastComparison; } @@ -1377,7 +1323,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return lastComparison; } } - lastComparison = Boolean.valueOf(isSetImageBaseId()).compareTo(other.isSetImageBaseId()); + lastComparison = java.lang.Boolean.compare(isSetImageBaseId(), other.isSetImageBaseId()); if (lastComparison != 0) { return lastComparison; } @@ -1387,7 +1333,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return lastComparison; } } - lastComparison = Boolean.valueOf(isSetIsEnabled()).compareTo(other.isSetIsEnabled()); + lastComparison = java.lang.Boolean.compare(isSetIsEnabled(), other.isSetIsEnabled()); if (lastComparison != 0) { return lastComparison; } @@ -1397,7 +1343,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return lastComparison; } } - lastComparison = Boolean.valueOf(isSetStartTime()).compareTo(other.isSetStartTime()); + lastComparison = java.lang.Boolean.compare(isSetStartTime(), other.isSetStartTime()); if (lastComparison != 0) { return lastComparison; } @@ -1407,7 +1353,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return lastComparison; } } - lastComparison = Boolean.valueOf(isSetEndTime()).compareTo(other.isSetEndTime()); + lastComparison = java.lang.Boolean.compare(isSetEndTime(), other.isSetEndTime()); if (lastComparison != 0) { return lastComparison; } @@ -1417,7 +1363,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return lastComparison; } } - lastComparison = Boolean.valueOf(isSetLastUsed()).compareTo(other.isSetLastUsed()); + lastComparison = java.lang.Boolean.compare(isSetLastUsed(), other.isSetLastUsed()); if (lastComparison != 0) { return lastComparison; } @@ -1427,7 +1373,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return lastComparison; } } - lastComparison = Boolean.valueOf(isSetUseCount()).compareTo(other.isSetUseCount()); + lastComparison = java.lang.Boolean.compare(isSetUseCount(), other.isSetUseCount()); if (lastComparison != 0) { return lastComparison; } @@ -1437,7 +1383,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return lastComparison; } } - lastComparison = Boolean.valueOf(isSetOwnerId()).compareTo(other.isSetOwnerId()); + lastComparison = java.lang.Boolean.compare(isSetOwnerId(), other.isSetOwnerId()); if (lastComparison != 0) { return lastComparison; } @@ -1447,7 +1393,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return lastComparison; } } - lastComparison = Boolean.valueOf(isSetUpdaterId()).compareTo(other.isSetUpdaterId()); + lastComparison = java.lang.Boolean.compare(isSetUpdaterId(), other.isSetUpdaterId()); if (lastComparison != 0) { return lastComparison; } @@ -1457,7 +1403,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return lastComparison; } } - lastComparison = Boolean.valueOf(isSetIsExam()).compareTo(other.isSetIsExam()); + lastComparison = java.lang.Boolean.compare(isSetIsExam(), other.isSetIsExam()); if (lastComparison != 0) { return lastComparison; } @@ -1467,7 +1413,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return lastComparison; } } - lastComparison = Boolean.valueOf(isSetHasInternetAccess()).compareTo(other.isSetHasInternetAccess()); + lastComparison = java.lang.Boolean.compare(isSetHasInternetAccess(), other.isSetHasInternetAccess()); if (lastComparison != 0) { return lastComparison; } @@ -1477,7 +1423,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return lastComparison; } } - lastComparison = Boolean.valueOf(isSetDefaultPermissions()).compareTo(other.isSetDefaultPermissions()); + lastComparison = java.lang.Boolean.compare(isSetDefaultPermissions(), other.isSetDefaultPermissions()); if (lastComparison != 0) { return lastComparison; } @@ -1487,7 +1433,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return lastComparison; } } - lastComparison = Boolean.valueOf(isSetUserPermissions()).compareTo(other.isSetUserPermissions()); + lastComparison = java.lang.Boolean.compare(isSetUserPermissions(), other.isSetUserPermissions()); if (lastComparison != 0) { return lastComparison; } @@ -1497,7 +1443,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return lastComparison; } } - lastComparison = Boolean.valueOf(isSetIsImageVersionUsable()).compareTo(other.isSetIsImageVersionUsable()); + lastComparison = java.lang.Boolean.compare(isSetIsImageVersionUsable(), other.isSetIsImageVersionUsable()); if (lastComparison != 0) { return lastComparison; } @@ -1507,7 +1453,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L return lastComparison; } } - lastComparison = Boolean.valueOf(isSetHasUsbAccess()).compareTo(other.isSetHasUsbAccess()); + lastComparison = java.lang.Boolean.compare(isSetHasUsbAccess(), other.isSetHasUsbAccess()); if (lastComparison != 0) { return lastComparison; } @@ -1520,21 +1466,22 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L 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("LectureSummary("); + public java.lang.String toString() { + java.lang.StringBuilder sb = new java.lang.StringBuilder("LectureSummary("); boolean first = true; sb.append("lectureId:"); @@ -1669,7 +1616,7 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } } - 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; @@ -1679,13 +1626,13 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } } - private static class LectureSummaryStandardSchemeFactory implements SchemeFactory { + private static class LectureSummaryStandardSchemeFactory implements org.apache.thrift.scheme.SchemeFactory { public LectureSummaryStandardScheme getScheme() { return new LectureSummaryStandardScheme(); } } - private static class LectureSummaryStandardScheme extends StandardScheme<LectureSummary> { + private static class LectureSummaryStandardScheme extends org.apache.thrift.scheme.StandardScheme<LectureSummary> { public void read(org.apache.thrift.protocol.TProtocol iprot, LectureSummary struct) throws org.apache.thrift.TException { org.apache.thrift.protocol.TField schemeField; @@ -1938,18 +1885,18 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } - private static class LectureSummaryTupleSchemeFactory implements SchemeFactory { + private static class LectureSummaryTupleSchemeFactory implements org.apache.thrift.scheme.SchemeFactory { public LectureSummaryTupleScheme getScheme() { return new LectureSummaryTupleScheme(); } } - private static class LectureSummaryTupleScheme extends TupleScheme<LectureSummary> { + private static class LectureSummaryTupleScheme extends org.apache.thrift.scheme.TupleScheme<LectureSummary> { @Override public void write(org.apache.thrift.protocol.TProtocol prot, LectureSummary 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.isSetLectureId()) { optionals.set(0); } @@ -2063,8 +2010,8 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L @Override public void read(org.apache.thrift.protocol.TProtocol prot, LectureSummary struct) throws org.apache.thrift.TException { - TTupleProtocol iprot = (TTupleProtocol) prot; - BitSet incoming = iprot.readBitSet(18); + org.apache.thrift.protocol.TTupleProtocol iprot = (org.apache.thrift.protocol.TTupleProtocol) prot; + java.util.BitSet incoming = iprot.readBitSet(18); if (incoming.get(0)) { struct.lectureId = iprot.readString(); struct.setLectureIdIsSet(true); @@ -2142,5 +2089,8 @@ public class LectureSummary implements org.apache.thrift.TBase<LectureSummary, L } } + 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(); + } } |