Exemple #1
0
    public void write(org.apache.thrift.protocol.TProtocol oprot, WorkerSummary struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      oprot.writeFieldBegin(PORT_FIELD_DESC);
      oprot.writeI32(struct.port);
      oprot.writeFieldEnd();
      oprot.writeFieldBegin(UPTIME_FIELD_DESC);
      oprot.writeI32(struct.uptime);
      oprot.writeFieldEnd();
      if (struct.topology != null) {
        oprot.writeFieldBegin(TOPOLOGY_FIELD_DESC);
        oprot.writeString(struct.topology);
        oprot.writeFieldEnd();
      }
      if (struct.tasks != null) {
        oprot.writeFieldBegin(TASKS_FIELD_DESC);
        {
          oprot.writeListBegin(
              new org.apache.thrift.protocol.TList(
                  org.apache.thrift.protocol.TType.STRUCT, struct.tasks.size()));
          for (TaskComponent _iter101 : struct.tasks) {
            _iter101.write(oprot);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
    public void write(org.apache.thrift.protocol.TProtocol oprot, SelectQuery struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.operations != null) {
        oprot.writeFieldBegin(OPERATIONS_FIELD_DESC);
        {
          oprot.writeListBegin(
              new org.apache.thrift.protocol.TList(
                  org.apache.thrift.protocol.TType.STRUCT, struct.operations.size()));
          for (SelectOperation _iter19 : struct.operations) {
            _iter19.write(oprot);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      if (struct.page != null) {
        oprot.writeFieldBegin(PAGE_FIELD_DESC);
        struct.page.write(oprot);
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
Exemple #3
0
    public void write(org.apache.thrift.protocol.TProtocol oprot, LineageCommand struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.commandType != null) {
        oprot.writeFieldBegin(COMMAND_TYPE_FIELD_DESC);
        oprot.writeI32(struct.commandType.getValue());
        oprot.writeFieldEnd();
      }
      if (struct.checkpointFiles != null) {
        oprot.writeFieldBegin(CHECKPOINT_FILES_FIELD_DESC);
        {
          oprot.writeListBegin(
              new org.apache.thrift.protocol.TList(
                  org.apache.thrift.protocol.TType.STRUCT, struct.checkpointFiles.size()));
          for (CheckpointFile _iter11 : struct.checkpointFiles) {
            _iter11.write(oprot);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
    public void write(org.apache.thrift.protocol.TProtocol oprot, TPrioritizeLoadRequest struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.protocol_version != null) {
        oprot.writeFieldBegin(PROTOCOL_VERSION_FIELD_DESC);
        oprot.writeI32(struct.protocol_version.getValue());
        oprot.writeFieldEnd();
      }
      if (struct.header != null) {
        if (struct.isSetHeader()) {
          oprot.writeFieldBegin(HEADER_FIELD_DESC);
          struct.header.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.object_descs != null) {
        oprot.writeFieldBegin(OBJECT_DESCS_FIELD_DESC);
        {
          oprot.writeListBegin(
              new org.apache.thrift.protocol.TList(
                  org.apache.thrift.protocol.TType.STRUCT, struct.object_descs.size()));
          for (com.cloudera.impala.thrift.TCatalogObject _iter19 : struct.object_descs) {
            _iter19.write(oprot);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
    public void write(org.apache.thrift.protocol.TProtocol oprot, ConditionalUpdates struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.conditions != null) {
        oprot.writeFieldBegin(CONDITIONS_FIELD_DESC);
        {
          oprot.writeListBegin(
              new org.apache.thrift.protocol.TList(
                  org.apache.thrift.protocol.TType.STRUCT, struct.conditions.size()));
          for (Condition _iter96 : struct.conditions) {
            _iter96.write(oprot);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      if (struct.updates != null) {
        oprot.writeFieldBegin(UPDATES_FIELD_DESC);
        {
          oprot.writeListBegin(
              new org.apache.thrift.protocol.TList(
                  org.apache.thrift.protocol.TType.STRUCT, struct.updates.size()));
          for (ColumnUpdate _iter97 : struct.updates) {
            _iter97.write(oprot);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
    public void write(org.apache.thrift.protocol.TProtocol oprot, UnaryPredicate struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.predicateName != null) {
        oprot.writeFieldBegin(PREDICATE_NAME_FIELD_DESC);
        oprot.writeString(struct.predicateName);
        oprot.writeFieldEnd();
      }
      if (struct.values != null) {
        oprot.writeFieldBegin(VALUES_FIELD_DESC);
        {
          oprot.writeListBegin(
              new org.apache.thrift.protocol.TList(
                  org.apache.thrift.protocol.TType.STRUCT, struct.values.size()));
          for (PredicateValue _iter3 : struct.values) {
            _iter3.write(oprot);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
    public void write(org.apache.thrift.protocol.TProtocol oprot, ClientRawTableInfo struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      oprot.writeFieldBegin(ID_FIELD_DESC);
      oprot.writeI32(struct.id);
      oprot.writeFieldEnd();
      if (struct.name != null) {
        oprot.writeFieldBegin(NAME_FIELD_DESC);
        oprot.writeString(struct.name);
        oprot.writeFieldEnd();
      }
      if (struct.path != null) {
        oprot.writeFieldBegin(PATH_FIELD_DESC);
        oprot.writeString(struct.path);
        oprot.writeFieldEnd();
      }
      oprot.writeFieldBegin(COLUMNS_FIELD_DESC);
      oprot.writeI32(struct.columns);
      oprot.writeFieldEnd();
      if (struct.metadata != null) {
        oprot.writeFieldBegin(METADATA_FIELD_DESC);
        oprot.writeBinary(struct.metadata);
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
    public void write(org.apache.thrift.protocol.TProtocol oprot, DomainVersionMetadata struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.properties != null) {
        oprot.writeFieldBegin(PROPERTIES_FIELD_DESC);
        oprot.writeBinary(struct.properties);
        oprot.writeFieldEnd();
      }
      if (struct.partitions != null) {
        oprot.writeFieldBegin(PARTITIONS_FIELD_DESC);
        {
          oprot.writeMapBegin(
              new org.apache.thrift.protocol.TMap(
                  org.apache.thrift.protocol.TType.I32,
                  org.apache.thrift.protocol.TType.STRUCT,
                  struct.partitions.size()));
          for (Map.Entry<Integer, PartitionMetadata> _iter12 : struct.partitions.entrySet()) {
            oprot.writeI32(_iter12.getKey());
            _iter12.getValue().write(oprot);
          }
          oprot.writeMapEnd();
        }
        oprot.writeFieldEnd();
      }
      oprot.writeFieldBegin(DEFUNCT_FIELD_DESC);
      oprot.writeBool(struct.defunct);
      oprot.writeFieldEnd();
      oprot.writeFieldBegin(CLOSED_AT_FIELD_DESC);
      oprot.writeI64(struct.closed_at);
      oprot.writeFieldEnd();
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
  public void write(org.apache.thrift.protocol.TProtocol oprot)
      throws org.apache.thrift.TException {
    validate();

    oprot.writeStructBegin(STRUCT_DESC);
    if (this.iDate != null) {
      oprot.writeFieldBegin(I_DATE_FIELD_DESC);
      oprot.writeString(this.iDate);
      oprot.writeFieldEnd();
    }
    if (this.iOperation != null) {
      oprot.writeFieldBegin(I_OPERATION_FIELD_DESC);
      oprot.writeString(this.iOperation);
      oprot.writeFieldEnd();
    }
    if (this.iPlace != null) {
      oprot.writeFieldBegin(I_PLACE_FIELD_DESC);
      oprot.writeString(this.iPlace);
      oprot.writeFieldEnd();
    }
    oprot.writeFieldBegin(I_AMOUNT_FIELD_DESC);
    oprot.writeDouble(this.iAmount);
    oprot.writeFieldEnd();
    oprot.writeFieldStop();
    oprot.writeStructEnd();
  }
    public void write(org.apache.thrift.protocol.TProtocol oprot, TCreateSentryRoleRequest struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      oprot.writeFieldBegin(PROTOCOL_VERSION_FIELD_DESC);
      oprot.writeI32(struct.protocol_version);
      oprot.writeFieldEnd();
      if (struct.requestorUserName != null) {
        oprot.writeFieldBegin(REQUESTOR_USER_NAME_FIELD_DESC);
        oprot.writeString(struct.requestorUserName);
        oprot.writeFieldEnd();
      }
      if (struct.requestorGroupNames != null) {
        oprot.writeFieldBegin(REQUESTOR_GROUP_NAMES_FIELD_DESC);
        {
          oprot.writeSetBegin(
              new org.apache.thrift.protocol.TSet(
                  org.apache.thrift.protocol.TType.STRING, struct.requestorGroupNames.size()));
          for (String _iter3 : struct.requestorGroupNames) {
            oprot.writeString(_iter3);
          }
          oprot.writeSetEnd();
        }
        oprot.writeFieldEnd();
      }
      if (struct.roleName != null) {
        oprot.writeFieldBegin(ROLE_NAME_FIELD_DESC);
        oprot.writeString(struct.roleName);
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
Exemple #11
0
    public void write(org.apache.thrift.protocol.TProtocol oprot, BlockInfo struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      oprot.writeFieldBegin(BLOCK_ID_FIELD_DESC);
      oprot.writeI64(struct.blockId);
      oprot.writeFieldEnd();
      oprot.writeFieldBegin(LENGTH_FIELD_DESC);
      oprot.writeI64(struct.length);
      oprot.writeFieldEnd();
      if (struct.locations != null) {
        oprot.writeFieldBegin(LOCATIONS_FIELD_DESC);
        {
          oprot.writeListBegin(
              new org.apache.thrift.protocol.TList(
                  org.apache.thrift.protocol.TType.STRUCT, struct.locations.size()));
          for (BlockLocation _iter3 : struct.locations) {
            _iter3.write(oprot);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
Exemple #12
0
    public void write(org.apache.thrift.protocol.TProtocol oprot, TKey struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.row != null) {
        oprot.writeFieldBegin(ROW_FIELD_DESC);
        oprot.writeBinary(struct.row);
        oprot.writeFieldEnd();
      }
      if (struct.colFamily != null) {
        oprot.writeFieldBegin(COL_FAMILY_FIELD_DESC);
        oprot.writeBinary(struct.colFamily);
        oprot.writeFieldEnd();
      }
      if (struct.colQualifier != null) {
        oprot.writeFieldBegin(COL_QUALIFIER_FIELD_DESC);
        oprot.writeBinary(struct.colQualifier);
        oprot.writeFieldEnd();
      }
      if (struct.colVisibility != null) {
        oprot.writeFieldBegin(COL_VISIBILITY_FIELD_DESC);
        oprot.writeBinary(struct.colVisibility);
        oprot.writeFieldEnd();
      }
      oprot.writeFieldBegin(TIMESTAMP_FIELD_DESC);
      oprot.writeI64(struct.timestamp);
      oprot.writeFieldEnd();
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
Exemple #13
0
    public void write(org.apache.thrift.protocol.TProtocol oprot, TDataSink struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.type != null) {
        oprot.writeFieldBegin(TYPE_FIELD_DESC);
        oprot.writeI32(struct.type.getValue());
        oprot.writeFieldEnd();
      }
      if (struct.stream_sink != null) {
        if (struct.isSetStream_sink()) {
          oprot.writeFieldBegin(STREAM_SINK_FIELD_DESC);
          struct.stream_sink.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.table_sink != null) {
        if (struct.isSetTable_sink()) {
          oprot.writeFieldBegin(TABLE_SINK_FIELD_DESC);
          struct.table_sink.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
    public void write(org.apache.thrift.protocol.TProtocol oprot, FrontendRequest struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.type != null) {
        if (struct.isSetType()) {
          oprot.writeFieldBegin(TYPE_FIELD_DESC);
          oprot.writeI32(struct.type.getValue());
          oprot.writeFieldEnd();
        }
      }
      if (struct.startBuild != null) {
        if (struct.isSetStartBuild()) {
          oprot.writeFieldBegin(START_BUILD_FIELD_DESC);
          struct.startBuild.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      if (struct.buildStatus != null) {
        if (struct.isSetBuildStatus()) {
          oprot.writeFieldBegin(BUILD_STATUS_FIELD_DESC);
          struct.buildStatus.write(oprot);
          oprot.writeFieldEnd();
        }
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
Exemple #15
0
    public void write(org.apache.thrift.protocol.TProtocol oprot, AggregationInfo struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.aggregationType != null) {
        if (struct.isSetAggregationType()) {
          oprot.writeFieldBegin(AGGREGATION_TYPE_FIELD_DESC);
          oprot.writeString(struct.aggregationType);
          oprot.writeFieldEnd();
        }
      }
      if (struct.aggregationParams != null) {
        if (struct.isSetAggregationParams()) {
          oprot.writeFieldBegin(AGGREGATION_PARAMS_FIELD_DESC);
          {
            oprot.writeMapBegin(
                new org.apache.thrift.protocol.TMap(
                    org.apache.thrift.protocol.TType.STRING,
                    org.apache.thrift.protocol.TType.STRING,
                    struct.aggregationParams.size()));
            for (Map.Entry<String, String> _iter30 : struct.aggregationParams.entrySet()) {
              oprot.writeString(_iter30.getKey());
              oprot.writeString(_iter30.getValue());
            }
            oprot.writeMapEnd();
          }
          oprot.writeFieldEnd();
        }
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
    public void write(org.apache.thrift.protocol.TProtocol oprot, OnlineStatus struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.name != null) {
        oprot.writeFieldBegin(NAME_FIELD_DESC);
        oprot.writeString(struct.name);
        oprot.writeFieldEnd();
      }
      if (struct.plugin != null) {
        oprot.writeFieldBegin(PLUGIN_FIELD_DESC);
        oprot.writeString(struct.plugin);
        oprot.writeFieldEnd();
      }
      if (struct.packagename != null) {
        oprot.writeFieldBegin(PACKAGENAME_FIELD_DESC);
        oprot.writeString(struct.packagename);
        oprot.writeFieldEnd();
      }
      if (struct.status != null) {
        oprot.writeFieldBegin(STATUS_FIELD_DESC);
        oprot.writeI32(struct.status.getValue());
        oprot.writeFieldEnd();
      }
      oprot.writeFieldBegin(SIZE_FIELD_DESC);
      oprot.writeI64(struct.size);
      oprot.writeFieldEnd();
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
Exemple #17
0
    public void write(org.apache.thrift.protocol.TProtocol oprot, TColumnValue struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.family != null) {
        oprot.writeFieldBegin(FAMILY_FIELD_DESC);
        oprot.writeBinary(struct.family);
        oprot.writeFieldEnd();
      }
      if (struct.qualifier != null) {
        oprot.writeFieldBegin(QUALIFIER_FIELD_DESC);
        oprot.writeBinary(struct.qualifier);
        oprot.writeFieldEnd();
      }
      if (struct.value != null) {
        oprot.writeFieldBegin(VALUE_FIELD_DESC);
        oprot.writeBinary(struct.value);
        oprot.writeFieldEnd();
      }
      if (struct.isSetTimestamp()) {
        oprot.writeFieldBegin(TIMESTAMP_FIELD_DESC);
        oprot.writeI64(struct.timestamp);
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
Exemple #18
0
    public void write(org.apache.thrift.protocol.TProtocol oprot, SettableBlobMeta struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.acl != null) {
        oprot.writeFieldBegin(ACL_FIELD_DESC);
        {
          oprot.writeListBegin(
              new org.apache.thrift.protocol.TList(
                  org.apache.thrift.protocol.TType.STRUCT, struct.acl.size()));
          for (AccessControl _iter561 : struct.acl) {
            _iter561.write(oprot);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      if (struct.is_set_replication_factor()) {
        oprot.writeFieldBegin(REPLICATION_FACTOR_FIELD_DESC);
        oprot.writeI32(struct.replication_factor);
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
Exemple #19
0
  public void write(TProtocol oprot) throws TException {
    validate();

    oprot.writeStructBegin(STRUCT_DESC);
    if (this.start_token != null) {
      oprot.writeFieldBegin(START_TOKEN_FIELD_DESC);
      oprot.writeString(this.start_token);
      oprot.writeFieldEnd();
    }
    if (this.end_token != null) {
      oprot.writeFieldBegin(END_TOKEN_FIELD_DESC);
      oprot.writeString(this.end_token);
      oprot.writeFieldEnd();
    }
    if (this.endpoints != null) {
      oprot.writeFieldBegin(ENDPOINTS_FIELD_DESC);
      {
        oprot.writeListBegin(new TList(TType.STRING, this.endpoints.size()));
        for (String _iter19 : this.endpoints) {
          oprot.writeString(_iter19);
        }
        oprot.writeListEnd();
      }
      oprot.writeFieldEnd();
    }
    oprot.writeFieldStop();
    oprot.writeStructEnd();
  }
    public void write(org.apache.thrift.protocol.TProtocol oprot, TOperationHandle struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.operationId != null) {
        oprot.writeFieldBegin(OPERATION_ID_FIELD_DESC);
        struct.operationId.write(oprot);
        oprot.writeFieldEnd();
      }
      if (struct.operationType != null) {
        oprot.writeFieldBegin(OPERATION_TYPE_FIELD_DESC);
        oprot.writeI32(struct.operationType.getValue());
        oprot.writeFieldEnd();
      }
      oprot.writeFieldBegin(HAS_RESULT_SET_FIELD_DESC);
      oprot.writeBool(struct.hasResultSet);
      oprot.writeFieldEnd();
      if (struct.isSetModifiedRowCount()) {
        oprot.writeFieldBegin(MODIFIED_ROW_COUNT_FIELD_DESC);
        oprot.writeDouble(struct.modifiedRowCount);
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
Exemple #21
0
  public void write(TProtocol oprot) throws TException {
    validate();

    oprot.writeStructBegin(STRUCT_DESC);
    if (this.user != null) {
      oprot.writeFieldBegin(USER_FIELD_DESC);
      oprot.writeString(this.user);
      oprot.writeFieldEnd();
    }
    if (this.jobID != null) {
      oprot.writeFieldBegin(JOB_ID_FIELD_DESC);
      this.jobID.write(oprot);
      oprot.writeFieldEnd();
    }
    if (this.jobFile != null) {
      oprot.writeFieldBegin(JOB_FILE_FIELD_DESC);
      oprot.writeString(this.jobFile);
      oprot.writeFieldEnd();
    }
    if (this.name != null) {
      oprot.writeFieldBegin(NAME_FIELD_DESC);
      oprot.writeString(this.name);
      oprot.writeFieldEnd();
    }
    if (this.queueName != null) {
      oprot.writeFieldBegin(QUEUE_NAME_FIELD_DESC);
      oprot.writeString(this.queueName);
      oprot.writeFieldEnd();
    }
    oprot.writeFieldStop();
    oprot.writeStructEnd();
  }
Exemple #22
0
    public void write(org.apache.thrift.protocol.TProtocol oprot, TI16Column struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.values != null) {
        oprot.writeFieldBegin(VALUES_FIELD_DESC);
        {
          oprot.writeListBegin(
              new org.apache.thrift.protocol.TList(
                  org.apache.thrift.protocol.TType.I16, struct.values.size()));
          for (short _iter73 : struct.values) {
            oprot.writeI16(_iter73);
          }
          oprot.writeListEnd();
        }
        oprot.writeFieldEnd();
      }
      if (struct.nulls != null) {
        oprot.writeFieldBegin(NULLS_FIELD_DESC);
        oprot.writeBinary(struct.nulls);
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
    public void write(org.apache.thrift.protocol.TProtocol oprot, TCommandTransfer struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.applicationName != null) {
        oprot.writeFieldBegin(APPLICATION_NAME_FIELD_DESC);
        oprot.writeString(struct.applicationName);
        oprot.writeFieldEnd();
      }
      if (struct.agentId != null) {
        oprot.writeFieldBegin(AGENT_ID_FIELD_DESC);
        oprot.writeString(struct.agentId);
        oprot.writeFieldEnd();
      }
      if (struct.isSetStartTime()) {
        oprot.writeFieldBegin(START_TIME_FIELD_DESC);
        oprot.writeI64(struct.startTime);
        oprot.writeFieldEnd();
      }
      if (struct.payload != null) {
        oprot.writeFieldBegin(PAYLOAD_FIELD_DESC);
        oprot.writeBinary(struct.payload);
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
    public void write(org.apache.thrift.protocol.TProtocol oprot, QueryFListResult struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.result != null) {
        oprot.writeFieldBegin(RESULT_FIELD_DESC);
        struct.result.write(oprot);
        oprot.writeFieldEnd();
      }
      if (struct.files != null) {
        if (struct.isSetFiles()) {
          oprot.writeFieldBegin(FILES_FIELD_DESC);
          {
            oprot.writeListBegin(
                new org.apache.thrift.protocol.TList(
                    org.apache.thrift.protocol.TType.STRUCT, struct.files.size()));
            for (FileInfo _iter3 : struct.files) {
              _iter3.write(oprot);
            }
            oprot.writeListEnd();
          }
          oprot.writeFieldEnd();
        }
      }
      if (struct.isSetSpare()) {
        oprot.writeFieldBegin(SPARE_FIELD_DESC);
        oprot.writeI32(struct.spare);
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
    public void write(org.apache.thrift.protocol.TProtocol oprot, ClusterWorkerHeartbeat struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.storm_id != null) {
        oprot.writeFieldBegin(STORM_ID_FIELD_DESC);
        oprot.writeString(struct.storm_id);
        oprot.writeFieldEnd();
      }
      if (struct.executor_stats != null) {
        oprot.writeFieldBegin(EXECUTOR_STATS_FIELD_DESC);
        {
          oprot.writeMapBegin(
              new org.apache.thrift.protocol.TMap(
                  org.apache.thrift.protocol.TType.STRUCT,
                  org.apache.thrift.protocol.TType.STRUCT,
                  struct.executor_stats.size()));
          for (Map.Entry<ExecutorInfo, ExecutorStats> _iter612 : struct.executor_stats.entrySet()) {
            _iter612.getKey().write(oprot);
            _iter612.getValue().write(oprot);
          }
          oprot.writeMapEnd();
        }
        oprot.writeFieldEnd();
      }
      oprot.writeFieldBegin(TIME_SECS_FIELD_DESC);
      oprot.writeI32(struct.time_secs);
      oprot.writeFieldEnd();
      oprot.writeFieldBegin(UPTIME_SECS_FIELD_DESC);
      oprot.writeI32(struct.uptime_secs);
      oprot.writeFieldEnd();
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
  public void write(TProtocol oprot) throws TException {
    validate();

    oprot.writeStructBegin(STRUCT_DESC);
    oprot.writeFieldBegin(UID_FIELD_DESC);
    oprot.writeI32(this.uid);
    oprot.writeFieldEnd();
    if (this.itemNumber != null) {
      oprot.writeFieldBegin(ITEM_NUMBER_FIELD_DESC);
      oprot.writeString(this.itemNumber);
      oprot.writeFieldEnd();
    }
    oprot.writeFieldBegin(RESERVE_QUANTITY_FIELD_DESC);
    oprot.writeI32(this.reserveQuantity);
    oprot.writeFieldEnd();
    if (this.orderNumber != null) {
      oprot.writeFieldBegin(ORDER_NUMBER_FIELD_DESC);
      oprot.writeString(this.orderNumber);
      oprot.writeFieldEnd();
    }
    if (this.fromId != null) {
      oprot.writeFieldBegin(FROM_ID_FIELD_DESC);
      oprot.writeString(this.fromId);
      oprot.writeFieldEnd();
    }
    oprot.writeFieldStop();
    oprot.writeStructEnd();
  }
Exemple #27
0
    public void write(org.apache.thrift.protocol.TProtocol oprot, PrivilegeGrantInfo struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.privilege != null) {
        oprot.writeFieldBegin(PRIVILEGE_FIELD_DESC);
        oprot.writeString(struct.privilege);
        oprot.writeFieldEnd();
      }
      oprot.writeFieldBegin(CREATE_TIME_FIELD_DESC);
      oprot.writeI32(struct.createTime);
      oprot.writeFieldEnd();
      if (struct.grantor != null) {
        oprot.writeFieldBegin(GRANTOR_FIELD_DESC);
        oprot.writeString(struct.grantor);
        oprot.writeFieldEnd();
      }
      if (struct.grantorType != null) {
        oprot.writeFieldBegin(GRANTOR_TYPE_FIELD_DESC);
        oprot.writeI32(struct.grantorType.getValue());
        oprot.writeFieldEnd();
      }
      oprot.writeFieldBegin(GRANT_OPTION_FIELD_DESC);
      oprot.writeBool(struct.grantOption);
      oprot.writeFieldEnd();
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
Exemple #28
0
  public void write(org.apache.thrift.protocol.TProtocol oprot)
      throws org.apache.thrift.TException {
    validate();

    oprot.writeStructBegin(STRUCT_DESC);
    if (this.oldTablet != null) {
      oprot.writeFieldBegin(OLD_TABLET_FIELD_DESC);
      this.oldTablet.write(oprot);
      oprot.writeFieldEnd();
    }
    if (this.newTablets != null) {
      oprot.writeFieldBegin(NEW_TABLETS_FIELD_DESC);
      {
        oprot.writeListBegin(
            new org.apache.thrift.protocol.TList(
                org.apache.thrift.protocol.TType.STRUCT, this.newTablets.size()));
        for (org.apache.accumulo.core.data.thrift.TKeyExtent _iter46 : this.newTablets) {
          _iter46.write(oprot);
        }
        oprot.writeListEnd();
      }
      oprot.writeFieldEnd();
    }
    oprot.writeFieldStop();
    oprot.writeStructEnd();
  }
    public void write(org.apache.thrift.protocol.TProtocol oprot, NimbusSummary struct)
        throws org.apache.thrift.TException {
      struct.validate();

      oprot.writeStructBegin(STRUCT_DESC);
      if (struct.host != null) {
        oprot.writeFieldBegin(HOST_FIELD_DESC);
        oprot.writeString(struct.host);
        oprot.writeFieldEnd();
      }
      oprot.writeFieldBegin(PORT_FIELD_DESC);
      oprot.writeI32(struct.port);
      oprot.writeFieldEnd();
      oprot.writeFieldBegin(UPTIME_SECS_FIELD_DESC);
      oprot.writeI32(struct.uptime_secs);
      oprot.writeFieldEnd();
      oprot.writeFieldBegin(IS_LEADER_FIELD_DESC);
      oprot.writeBool(struct.isLeader);
      oprot.writeFieldEnd();
      if (struct.version != null) {
        oprot.writeFieldBegin(VERSION_FIELD_DESC);
        oprot.writeString(struct.version);
        oprot.writeFieldEnd();
      }
      oprot.writeFieldStop();
      oprot.writeStructEnd();
    }
 public void write(TProtocol _oprot) throws org.apache.thrift.TException {
   validate();
   _oprot.writeStructBegin(STRUCT);
   _oprot.writeFieldBegin(UrlField);
   String url_item = url;
   _oprot.writeString(url_item);
   _oprot.writeFieldEnd();
   if (title.isDefined()) {
     _oprot.writeFieldBegin(TitleField);
     String title_item = title.get();
     _oprot.writeString(title_item);
     _oprot.writeFieldEnd();
   }
   if (keywords.isDefined()) {
     _oprot.writeFieldBegin(KeywordsField);
     String keywords_item = keywords.get();
     _oprot.writeString(keywords_item);
     _oprot.writeFieldEnd();
   }
   _oprot.writeFieldBegin(TypesField);
   List<RecommendTypeParam> types_item = types;
   _oprot.writeListBegin(new TList(TType.STRUCT, types_item.size()));
   for (RecommendTypeParam _types_item_element : types_item) {
     _types_item_element.write(_oprot);
   }
   _oprot.writeListEnd();
   _oprot.writeFieldEnd();
   _oprot.writeFieldStop();
   _oprot.writeStructEnd();
 }