From fa93f97c19fafc53f42e574e8e483e8aa033521f Mon Sep 17 00:00:00 2001 From: Simon Rettberg Date: Thu, 14 Jun 2018 16:13:00 +0200 Subject: Add support for (ldap)filters for lectures --- .../openslx/bwlp/thrift/iface/LectureWrite.java | 295 ++++++++++++++++----- 1 file changed, 228 insertions(+), 67 deletions(-) (limited to 'src/main/java/org/openslx/bwlp/thrift/iface/LectureWrite.java') diff --git a/src/main/java/org/openslx/bwlp/thrift/iface/LectureWrite.java b/src/main/java/org/openslx/bwlp/thrift/iface/LectureWrite.java index ce42bd3..fc0f59d 100644 --- a/src/main/java/org/openslx/bwlp/thrift/iface/LectureWrite.java +++ b/src/main/java/org/openslx/bwlp/thrift/iface/LectureWrite.java @@ -34,7 +34,7 @@ import org.slf4j.Logger; import org.slf4j.LoggerFactory; @SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"}) -@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2017-09-06") +@Generated(value = "Autogenerated by Thrift Compiler (0.9.3)", date = "2018-06-13") public class LectureWrite implements org.apache.thrift.TBase, java.io.Serializable, Cloneable, Comparable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("LectureWrite"); @@ -58,6 +58,7 @@ public class LectureWrite implements org.apache.thrift.TBase, SchemeFactory> schemes = new HashMap, SchemeFactory>(); static { @@ -85,6 +86,7 @@ public class LectureWrite implements org.apache.thrift.TBase networkShares; // optional + public List ldapFilters; // 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 { @@ -107,7 +109,8 @@ public class LectureWrite implements org.apache.thrift.TBase byName = new HashMap(); @@ -162,6 +165,8 @@ public class LectureWrite implements org.apache.thrift.TBase metaDataMap; static { Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class); @@ -262,6 +267,9 @@ public class LectureWrite implements org.apache.thrift.TBase __this__ldapFilters = new ArrayList(other.ldapFilters.size()); + for (LdapFilter other_element : other.ldapFilters) { + __this__ldapFilters.add(new LdapFilter(other_element)); + } + this.ldapFilters = __this__ldapFilters; + } } public LectureWrite deepCopy() { @@ -411,6 +426,7 @@ public class LectureWrite implements org.apache.thrift.TBase getLdapFiltersIterator() { + return (this.ldapFilters == null) ? null : this.ldapFilters.iterator(); + } + + public void addToLdapFilters(LdapFilter elem) { + if (this.ldapFilters == null) { + this.ldapFilters = new ArrayList(); + } + this.ldapFilters.add(elem); + } + + public List getLdapFilters() { + return this.ldapFilters; + } + + public LectureWrite setLdapFilters(List ldapFilters) { + this.ldapFilters = ldapFilters; + return this; + } + + public void unsetLdapFilters() { + this.ldapFilters = null; + } + + /** Returns true if field ldapFilters is set (has been assigned a value) and false otherwise */ + public boolean isSetLdapFilters() { + return this.ldapFilters != null; + } + + public void setLdapFiltersIsSet(boolean value) { + if (!value) { + this.ldapFilters = null; + } + } + public void setFieldValue(_Fields field, Object value) { switch (field) { case LECTURE_NAME: @@ -1136,6 +1191,14 @@ public class LectureWrite implements org.apache.thrift.TBase)value); + } + break; + } } @@ -1201,6 +1264,9 @@ public class LectureWrite implements org.apache.thrift.TBase(_list108.size); + LdapFilter _elem109; + for (int _i110 = 0; _i110 < _list108.size; ++_i110) + { + _elem109 = new LdapFilter(); + _elem109.read(iprot); + struct.ldapFilters.add(_elem109); + } + iprot.readListEnd(); + } + struct.setLdapFiltersIsSet(true); + } else { + org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); + } + break; default: org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type); } @@ -2240,9 +2361,9 @@ public class LectureWrite implements org.apache.thrift.TBase(_list120.size); - String _elem121; - for (int _i122 = 0; _i122 < _list120.size; ++_i122) + org.apache.thrift.protocol.TList _list125 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.nics = new ArrayList(_list125.size); + String _elem126; + for (int _i127 = 0; _i127 < _list125.size; ++_i127) { - _elem121 = iprot.readString(); - struct.nics.add(_elem121); + _elem126 = iprot.readString(); + struct.nics.add(_elem126); } } struct.setNicsIsSet(true); } if (incoming.get(9)) { { - org.apache.thrift.protocol.TList _list123 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); - struct.networkExceptions = new ArrayList(_list123.size); - NetRule _elem124; - for (int _i125 = 0; _i125 < _list123.size; ++_i125) + org.apache.thrift.protocol.TList _list128 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.networkExceptions = new ArrayList(_list128.size); + NetRule _elem129; + for (int _i130 = 0; _i130 < _list128.size; ++_i130) { - _elem124 = new NetRule(); - _elem124.read(iprot); - struct.networkExceptions.add(_elem124); + _elem129 = new NetRule(); + _elem129.read(iprot); + struct.networkExceptions.add(_elem129); } } struct.setNetworkExceptionsIsSet(true); @@ -2591,39 +2738,39 @@ public class LectureWrite implements org.apache.thrift.TBase(_list126.size); - String _elem127; - for (int _i128 = 0; _i128 < _list126.size; ++_i128) + org.apache.thrift.protocol.TList _list131 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.addAllowedUsers = new ArrayList(_list131.size); + String _elem132; + for (int _i133 = 0; _i133 < _list131.size; ++_i133) { - _elem127 = iprot.readString(); - struct.addAllowedUsers.add(_elem127); + _elem132 = iprot.readString(); + struct.addAllowedUsers.add(_elem132); } } struct.setAddAllowedUsersIsSet(true); } if (incoming.get(14)) { { - org.apache.thrift.protocol.TList _list129 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); - struct.remAllowedUsers = new ArrayList(_list129.size); - String _elem130; - for (int _i131 = 0; _i131 < _list129.size; ++_i131) + org.apache.thrift.protocol.TList _list134 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, iprot.readI32()); + struct.remAllowedUsers = new ArrayList(_list134.size); + String _elem135; + for (int _i136 = 0; _i136 < _list134.size; ++_i136) { - _elem130 = iprot.readString(); - struct.remAllowedUsers.add(_elem130); + _elem135 = iprot.readString(); + struct.remAllowedUsers.add(_elem135); } } struct.setRemAllowedUsersIsSet(true); } if (incoming.get(15)) { { - org.apache.thrift.protocol.TList _list132 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I32, iprot.readI32()); - struct.locationIds = new ArrayList(_list132.size); - int _elem133; - for (int _i134 = 0; _i134 < _list132.size; ++_i134) + org.apache.thrift.protocol.TList _list137 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I32, iprot.readI32()); + struct.locationIds = new ArrayList(_list137.size); + int _elem138; + for (int _i139 = 0; _i139 < _list137.size; ++_i139) { - _elem133 = iprot.readI32(); - struct.locationIds.add(_elem133); + _elem138 = iprot.readI32(); + struct.locationIds.add(_elem138); } } struct.setLocationIdsIsSet(true); @@ -2642,18 +2789,32 @@ public class LectureWrite implements org.apache.thrift.TBase(_list135.size); - NetShare _elem136; - for (int _i137 = 0; _i137 < _list135.size; ++_i137) + org.apache.thrift.protocol.TList _list140 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.networkShares = new ArrayList(_list140.size); + NetShare _elem141; + for (int _i142 = 0; _i142 < _list140.size; ++_i142) { - _elem136 = new NetShare(); - _elem136.read(iprot); - struct.networkShares.add(_elem136); + _elem141 = new NetShare(); + _elem141.read(iprot); + struct.networkShares.add(_elem141); } } struct.setNetworkSharesIsSet(true); } + if (incoming.get(20)) { + { + org.apache.thrift.protocol.TList _list143 = new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, iprot.readI32()); + struct.ldapFilters = new ArrayList(_list143.size); + LdapFilter _elem144; + for (int _i145 = 0; _i145 < _list143.size; ++_i145) + { + _elem144 = new LdapFilter(); + _elem144.read(iprot); + struct.ldapFilters.add(_elem144); + } + } + struct.setLdapFiltersIsSet(true); + } } } -- cgit v1.2.3-55-g7522