read method
Reads the TObject from the given input protocol.
Implementation
read(TProtocol iprot) {
TField field;
iprot.readStructBegin();
while (true) {
field = iprot.readFieldBegin();
if (field.type == TType.STOP) {
break;
}
switch (field.id) {
case SPACES:
if (field.type == TType.LIST) {
{
TList _list288 = iprot.readListBegin();
this.spaces = <Int8List>[];
for (int _i289 = 0; _i289 < _list288.length; ++_i289) {
Int8List _elem290;
_elem290 = iprot.readBinary();
this.spaces?.add(_elem290);
}
iprot.readListEnd();
}
} else {
TProtocolUtil.skip(iprot, field.type);
}
break;
case BASE_BACKUP_NAME:
if (field.type == TType.STRING) {
this.base_backup_name = iprot.readBinary();
} else {
TProtocolUtil.skip(iprot, field.type);
}
break;
case CLUSTER_ID:
if (field.type == TType.I64) {
this.cluster_id = iprot.readI64();
this.__isset_cluster_id = true;
} else {
TProtocolUtil.skip(iprot, field.type);
}
break;
default:
TProtocolUtil.skip(iprot, field.type);
break;
}
iprot.readFieldEnd();
}
iprot.readStructEnd();
// check for required fields of primitive type, which can't be checked in the validate method
validate();
}