public TMap readMapBegin() throws TException { return new TMap(readByte(), readByte(), readI32()); }
@Override public void read(libthrift091.protocol.TProtocol prot, DatumMapMeta struct) throws libthrift091.TException { TTupleProtocol iprot = (TTupleProtocol) prot; BitSet incoming = iprot.readBitSet(1); if (incoming.get(0)) { { libthrift091.protocol.TMap _map6 = new libthrift091.protocol.TMap(libthrift091.protocol.TType.I16, libthrift091.protocol.TType.STRING, iprot.readI32()); struct.keyIdMap = new HashMap<Short,String>(2*_map6.size); short _key7; String _val8; for (int _i9 = 0; _i9 < _map6.size; ++_i9) { _key7 = iprot.readI16(); _val8 = iprot.readString(); struct.keyIdMap.put(_key7, _val8); } } struct.setKeyIdMapIsSet(true); } } }
public TMap readMapBegin() throws TException { return new TMap(readByte(), readByte(), readI32()); }
@Override public void read(libthrift091.protocol.TProtocol prot, DatumMapMeta struct) throws libthrift091.TException { TTupleProtocol iprot = (TTupleProtocol) prot; BitSet incoming = iprot.readBitSet(1); if (incoming.get(0)) { { libthrift091.protocol.TMap _map6 = new libthrift091.protocol.TMap(libthrift091.protocol.TType.I16, libthrift091.protocol.TType.STRING, iprot.readI32()); struct.keyIdMap = new HashMap<Short,String>(2*_map6.size); short _key7; String _val8; for (int _i9 = 0; _i9 < _map6.size; ++_i9) { _key7 = iprot.readI16(); _val8 = iprot.readString(); struct.keyIdMap.put(_key7, _val8); } } struct.setKeyIdMapIsSet(true); } } }
@Override public void read(libthrift091.protocol.TProtocol prot, ListPermissionResponse struct) throws libthrift091.TException { TTupleProtocol iprot = (TTupleProtocol) prot; { libthrift091.protocol.TMap _map90 = new libthrift091.protocol.TMap(libthrift091.protocol.TType.STRING, libthrift091.protocol.TType.I32, iprot.readI32()); struct.permissions = new HashMap<String,Permission>(2*_map90.size); String _key91; Permission _val92; for (int _i93 = 0; _i93 < _map90.size; ++_i93) { _key91 = iprot.readString(); _val92 = com.xiaomi.infra.galaxy.emr.thrift.Permission.findByValue(iprot.readI32()); struct.permissions.put(_key91, _val92); } } struct.setPermissionsIsSet(true); } }
@Override public void read(libthrift091.protocol.TProtocol prot, ListPermissionsResponse struct) throws libthrift091.TException { TTupleProtocol iprot = (TTupleProtocol) prot; BitSet incoming = iprot.readBitSet(1); if (incoming.get(0)) { { libthrift091.protocol.TMap _map40 = new libthrift091.protocol.TMap(libthrift091.protocol.TType.STRING, libthrift091.protocol.TType.I32, iprot.readI32()); struct.permissionList = new HashMap<String,Permission>(2*_map40.size); String _key41; Permission _val42; for (int _i43 = 0; _i43 < _map40.size; ++_i43) { _key41 = iprot.readString(); _val42 = com.xiaomi.infra.galaxy.emq.thrift.Permission.findByValue(iprot.readI32()); struct.permissionList.put(_key41, _val42); } } struct.setPermissionListIsSet(true); } } }
/** * Read a map header off the wire. If the size is zero, skip reading the key * and value type. This means that 0-length maps will yield TMaps without the * "correct" types. */ public TMap readMapBegin() throws TException { int size = readVarint32(); byte keyAndValueType = size == 0 ? 0 : readByte(); return new TMap(getTType((byte)(keyAndValueType >> 4)), getTType((byte)(keyAndValueType & 0xf)), size); }
@Override public void read(libthrift091.protocol.TProtocol prot, ListPermissionResponse struct) throws libthrift091.TException { TTupleProtocol iprot = (TTupleProtocol) prot; { libthrift091.protocol.TMap _map90 = new libthrift091.protocol.TMap(libthrift091.protocol.TType.STRING, libthrift091.protocol.TType.I32, iprot.readI32()); struct.permissions = new HashMap<String,Permission>(2*_map90.size); String _key91; Permission _val92; for (int _i93 = 0; _i93 < _map90.size; ++_i93) { _key91 = iprot.readString(); _val92 = com.xiaomi.infra.galaxy.emr.thrift.Permission.findByValue(iprot.readI32()); struct.permissions.put(_key91, _val92); } } struct.setPermissionsIsSet(true); } }
/** * Read a map header off the wire. If the size is zero, skip reading the key * and value type. This means that 0-length maps will yield TMaps without the * "correct" types. */ public TMap readMapBegin() throws TException { int size = readVarint32(); byte keyAndValueType = size == 0 ? 0 : readByte(); return new TMap(getTType((byte)(keyAndValueType >> 4)), getTType((byte)(keyAndValueType & 0xf)), size); }
@Override public void read(libthrift091.protocol.TProtocol prot, AddTagRequest struct) throws libthrift091.TException { TTupleProtocol iprot = (TTupleProtocol) prot; struct.clusterId = iprot.readString(); struct.setClusterIdIsSet(true); { libthrift091.protocol.TMap _map156 = new libthrift091.protocol.TMap(libthrift091.protocol.TType.STRING, libthrift091.protocol.TType.STRING, iprot.readI32()); struct.tags = new HashMap<String,String>(2*_map156.size); String _key157; String _val158; for (int _i159 = 0; _i159 < _map156.size; ++_i159) { _key157 = iprot.readString(); _val158 = iprot.readString(); struct.tags.put(_key157, _val158); } } struct.setTagsIsSet(true); } }
@Override public void read(libthrift091.protocol.TProtocol prot, AddTagRequest struct) throws libthrift091.TException { TTupleProtocol iprot = (TTupleProtocol) prot; struct.clusterId = iprot.readString(); struct.setClusterIdIsSet(true); { libthrift091.protocol.TMap _map156 = new libthrift091.protocol.TMap(libthrift091.protocol.TType.STRING, libthrift091.protocol.TType.STRING, iprot.readI32()); struct.tags = new HashMap<String,String>(2*_map156.size); String _key157; String _val158; for (int _i159 = 0; _i159 < _map156.size; ++_i159) { _key157 = iprot.readString(); _val158 = iprot.readString(); struct.tags.put(_key157, _val158); } } struct.setTagsIsSet(true); } }
public void write(libthrift091.protocol.TProtocol oprot, ListPermissionsResponse struct) throws libthrift091.TException { struct.validate(); oprot.writeStructBegin(STRUCT_DESC); if (struct.permissionList != null) { oprot.writeFieldBegin(PERMISSION_LIST_FIELD_DESC); { oprot.writeMapBegin(new libthrift091.protocol.TMap(libthrift091.protocol.TType.STRING, libthrift091.protocol.TType.I32, struct.permissionList.size())); for (Map.Entry<String, Permission> _iter38 : struct.permissionList.entrySet()) { oprot.writeString(_iter38.getKey()); oprot.writeI32(_iter38.getValue().getValue()); } oprot.writeMapEnd(); } oprot.writeFieldEnd(); } oprot.writeFieldStop(); oprot.writeStructEnd(); }
public void write(libthrift091.protocol.TProtocol oprot, ListPermissionResponse struct) throws libthrift091.TException { struct.validate(); oprot.writeStructBegin(STRUCT_DESC); if (struct.permissions != null) { oprot.writeFieldBegin(PERMISSIONS_FIELD_DESC); { oprot.writeMapBegin(new libthrift091.protocol.TMap(libthrift091.protocol.TType.STRING, libthrift091.protocol.TType.I32, struct.permissions.size())); for (Map.Entry<String, Permission> _iter88 : struct.permissions.entrySet()) { oprot.writeString(_iter88.getKey()); oprot.writeI32(_iter88.getValue().getValue()); } oprot.writeMapEnd(); } oprot.writeFieldEnd(); } oprot.writeFieldStop(); oprot.writeStructEnd(); }
public void write(libthrift091.protocol.TProtocol oprot, ListPermissionResponse struct) throws libthrift091.TException { struct.validate(); oprot.writeStructBegin(STRUCT_DESC); if (struct.permissions != null) { oprot.writeFieldBegin(PERMISSIONS_FIELD_DESC); { oprot.writeMapBegin(new libthrift091.protocol.TMap(libthrift091.protocol.TType.STRING, libthrift091.protocol.TType.I32, struct.permissions.size())); for (Map.Entry<String, Permission> _iter88 : struct.permissions.entrySet()) { oprot.writeString(_iter88.getKey()); oprot.writeI32(_iter88.getValue().getValue()); } oprot.writeMapEnd(); } oprot.writeFieldEnd(); } oprot.writeFieldStop(); oprot.writeStructEnd(); }
public void write(libthrift091.protocol.TProtocol oprot, ListPermissionsResponse struct) throws libthrift091.TException { struct.validate(); oprot.writeStructBegin(STRUCT_DESC); if (struct.permissionList != null) { oprot.writeFieldBegin(PERMISSION_LIST_FIELD_DESC); { oprot.writeMapBegin(new libthrift091.protocol.TMap(libthrift091.protocol.TType.STRING, libthrift091.protocol.TType.I32, struct.permissionList.size())); for (Map.Entry<String, Permission> _iter38 : struct.permissionList.entrySet()) { oprot.writeString(_iter38.getKey()); oprot.writeI32(_iter38.getValue().getValue()); } oprot.writeMapEnd(); } oprot.writeFieldEnd(); } oprot.writeFieldStop(); oprot.writeStructEnd(); }
public void write(libthrift091.protocol.TProtocol oprot, GetResult struct) throws libthrift091.TException { struct.validate(); oprot.writeStructBegin(STRUCT_DESC); if (struct.item != null) { if (struct.isSetItem()) { oprot.writeFieldBegin(ITEM_FIELD_DESC); { oprot.writeMapBegin(new libthrift091.protocol.TMap(libthrift091.protocol.TType.STRING, libthrift091.protocol.TType.STRUCT, struct.item.size())); for (Map.Entry<String, Datum> _iter238 : struct.item.entrySet()) { oprot.writeString(_iter238.getKey()); _iter238.getValue().write(oprot); } oprot.writeMapEnd(); } oprot.writeFieldEnd(); } } oprot.writeFieldStop(); oprot.writeStructEnd(); }
public void write(libthrift091.protocol.TProtocol oprot, GetResult struct) throws libthrift091.TException { struct.validate(); oprot.writeStructBegin(STRUCT_DESC); if (struct.item != null) { if (struct.isSetItem()) { oprot.writeFieldBegin(ITEM_FIELD_DESC); { oprot.writeMapBegin(new libthrift091.protocol.TMap(libthrift091.protocol.TType.STRING, libthrift091.protocol.TType.STRUCT, struct.item.size())); for (Map.Entry<String, Datum> _iter238 : struct.item.entrySet()) { oprot.writeString(_iter238.getKey()); _iter238.getValue().write(oprot); } oprot.writeMapEnd(); } oprot.writeFieldEnd(); } } oprot.writeFieldStop(); oprot.writeStructEnd(); }
@Override public void read(libthrift091.protocol.TProtocol prot, TagFilter struct) throws libthrift091.TException { TTupleProtocol iprot = (TTupleProtocol) prot; { libthrift091.protocol.TMap _map50 = new libthrift091.protocol.TMap(libthrift091.protocol.TType.STRING, libthrift091.protocol.TType.STRUCT, iprot.readI32()); struct.attributes = new HashMap<String,com.xiaomi.infra.galaxy.emq.thrift.MessageAttribute>(2*_map50.size); String _key51; com.xiaomi.infra.galaxy.emq.thrift.MessageAttribute _val52; for (int _i53 = 0; _i53 < _map50.size; ++_i53) { _key51 = iprot.readString(); _val52 = new com.xiaomi.infra.galaxy.emq.thrift.MessageAttribute(); _val52.read(iprot); struct.attributes.put(_key51, _val52); } } struct.setAttributesIsSet(true); struct.op = com.xiaomi.infra.galaxy.emq.thrift.LogicalOperator.findByValue(iprot.readI32()); struct.setOpIsSet(true); } }
@Override public TMap readMapBegin() throws TException { readJSONArrayStart(); byte keyType = getTypeIDForTypeName(readJSONString(false).get()); byte valueType = getTypeIDForTypeName(readJSONString(false).get()); int size = (int)readJSONInteger(); readJSONObjectStart(); return new TMap(keyType, valueType, size); }
@Override public TMap readMapBegin() throws TException { readJSONArrayStart(); byte keyType = getTypeIDForTypeName(readJSONString(false).get()); byte valueType = getTypeIDForTypeName(readJSONString(false).get()); int size = (int)readJSONInteger(); readJSONObjectStart(); return new TMap(keyType, valueType, size); }