restoreMeta method

Future<RestoreMetaResp> restoreMeta(
  1. RestoreMetaReq? req
)
override

Implementation

Future<RestoreMetaResp> restoreMeta(RestoreMetaReq? req) async {
  oprot.writeMessageBegin(
      new TMessage("restoreMeta", TMessageType.CALL, nextSeqid()));
  restoreMeta_args args = new restoreMeta_args();
  args.req = req;
  args.write(oprot);
  oprot.writeMessageEnd();

  await oprot.trans_.flush();

  TMessage msg = iprot.readMessageBegin();
  if (msg.type == TMessageType.EXCEPTION) {
    TApplicationError error = TApplicationError.read(iprot);
    iprot.readMessageEnd();
    throw error;
  }

  restoreMeta_result result = new restoreMeta_result();
  result.read(iprot);
  iprot.readMessageEnd();
  if (result.isSetSuccess()) {
    return result.success!;
  }

  throw new TApplicationError(TApplicationErrorType.MISSING_RESULT,
      "restoreMeta failed: unknown result");
}