com.clarifai.grpc.api.OutputInfo Maven / Gradle / Ivy
The newest version!
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: proto/clarifai/api/resources.proto
package com.clarifai.grpc.api;
/**
*
* OutputInfo defines some of the settings for each model version that PatchModels can effect. These
* parameters control some of the training or inference operations that this model can do.
* As the number of parameters continued to grow when we launched more ModelTypes we decided to move
* to using the OutputInfo.params field which is a Struct (or JSON object if you're using
* our JSON REST APIs). This allows each ModelType to define the set of fields, their default values
* and description of each field so that we can display those in Portal and make the creation of
* Model's very extensible. The OutputConfig object will eventually go away in favor of
* infer_params struct.
*
*
* Protobuf type {@code clarifai.api.OutputInfo}
*/
public final class OutputInfo extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:clarifai.api.OutputInfo)
OutputInfoOrBuilder {
private static final long serialVersionUID = 0L;
// Use OutputInfo.newBuilder() to construct.
private OutputInfo(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private OutputInfo() {
message_ = "";
paramsSpecs_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new OutputInfo();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private OutputInfo(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
com.clarifai.grpc.api.Data.Builder subBuilder = null;
if (data_ != null) {
subBuilder = data_.toBuilder();
}
data_ = input.readMessage(com.clarifai.grpc.api.Data.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(data_);
data_ = subBuilder.buildPartial();
}
break;
}
case 18: {
com.clarifai.grpc.api.OutputConfig.Builder subBuilder = null;
if (outputConfig_ != null) {
subBuilder = outputConfig_.toBuilder();
}
outputConfig_ = input.readMessage(com.clarifai.grpc.api.OutputConfig.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(outputConfig_);
outputConfig_ = subBuilder.buildPartial();
}
break;
}
case 26: {
java.lang.String s = input.readStringRequireUtf8();
message_ = s;
break;
}
case 50: {
com.google.protobuf.Struct.Builder subBuilder = null;
if (fieldsMap_ != null) {
subBuilder = fieldsMap_.toBuilder();
}
fieldsMap_ = input.readMessage(com.google.protobuf.Struct.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(fieldsMap_);
fieldsMap_ = subBuilder.buildPartial();
}
break;
}
case 58: {
com.google.protobuf.Struct.Builder subBuilder = null;
if (params_ != null) {
subBuilder = params_.toBuilder();
}
params_ = input.readMessage(com.google.protobuf.Struct.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(params_);
params_ = subBuilder.buildPartial();
}
break;
}
case 66: {
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
paramsSpecs_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000001;
}
paramsSpecs_.add(
input.readMessage(com.clarifai.grpc.api.ModelTypeField.parser(), extensionRegistry));
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
if (((mutable_bitField0_ & 0x00000001) != 0)) {
paramsSpecs_ = java.util.Collections.unmodifiableList(paramsSpecs_);
}
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.clarifai.grpc.api.Resources.internal_static_clarifai_api_OutputInfo_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.clarifai.grpc.api.Resources.internal_static_clarifai_api_OutputInfo_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.clarifai.grpc.api.OutputInfo.class, com.clarifai.grpc.api.OutputInfo.Builder.class);
}
public static final int DATA_FIELD_NUMBER = 1;
private com.clarifai.grpc.api.Data data_;
/**
*
* List of concepts or other output related data for the model.
*
*
* .clarifai.api.Data data = 1;
* @return Whether the data field is set.
*/
@java.lang.Override
public boolean hasData() {
return data_ != null;
}
/**
*
* List of concepts or other output related data for the model.
*
*
* .clarifai.api.Data data = 1;
* @return The data.
*/
@java.lang.Override
public com.clarifai.grpc.api.Data getData() {
return data_ == null ? com.clarifai.grpc.api.Data.getDefaultInstance() : data_;
}
/**
*
* List of concepts or other output related data for the model.
*
*
* .clarifai.api.Data data = 1;
*/
@java.lang.Override
public com.clarifai.grpc.api.DataOrBuilder getDataOrBuilder() {
return getData();
}
public static final int OUTPUT_CONFIG_FIELD_NUMBER = 2;
private com.clarifai.grpc.api.OutputConfig outputConfig_;
/**
*
* Model configuration...going away in favor of infer_params and train_params over time.
* TO BE DEPRECATED
*
*
* .clarifai.api.OutputConfig output_config = 2;
* @return Whether the outputConfig field is set.
*/
@java.lang.Override
public boolean hasOutputConfig() {
return outputConfig_ != null;
}
/**
*
* Model configuration...going away in favor of infer_params and train_params over time.
* TO BE DEPRECATED
*
*
* .clarifai.api.OutputConfig output_config = 2;
* @return The outputConfig.
*/
@java.lang.Override
public com.clarifai.grpc.api.OutputConfig getOutputConfig() {
return outputConfig_ == null ? com.clarifai.grpc.api.OutputConfig.getDefaultInstance() : outputConfig_;
}
/**
*
* Model configuration...going away in favor of infer_params and train_params over time.
* TO BE DEPRECATED
*
*
* .clarifai.api.OutputConfig output_config = 2;
*/
@java.lang.Override
public com.clarifai.grpc.api.OutputConfigOrBuilder getOutputConfigOrBuilder() {
return getOutputConfig();
}
public static final int MESSAGE_FIELD_NUMBER = 3;
private volatile java.lang.Object message_;
/**
*
* For returning where to look for the Output info if not returning it.
*
*
* string message = 3;
* @return The message.
*/
@java.lang.Override
public java.lang.String getMessage() {
java.lang.Object ref = message_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
message_ = s;
return s;
}
}
/**
*
* For returning where to look for the Output info if not returning it.
*
*
* string message = 3;
* @return The bytes for message.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getMessageBytes() {
java.lang.Object ref = message_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
message_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int FIELDS_MAP_FIELD_NUMBER = 6;
private com.google.protobuf.Struct fieldsMap_;
/**
*
* Map from the api.Data field names to the underlying model graph's outputs. When using a
* PretrainedModelConfig the values in this map need to match the Triton config.pbtxt output names.
*
*
* .google.protobuf.Struct fields_map = 6;
* @return Whether the fieldsMap field is set.
*/
@java.lang.Override
public boolean hasFieldsMap() {
return fieldsMap_ != null;
}
/**
*
* Map from the api.Data field names to the underlying model graph's outputs. When using a
* PretrainedModelConfig the values in this map need to match the Triton config.pbtxt output names.
*
*
* .google.protobuf.Struct fields_map = 6;
* @return The fieldsMap.
*/
@java.lang.Override
public com.google.protobuf.Struct getFieldsMap() {
return fieldsMap_ == null ? com.google.protobuf.Struct.getDefaultInstance() : fieldsMap_;
}
/**
*
* Map from the api.Data field names to the underlying model graph's outputs. When using a
* PretrainedModelConfig the values in this map need to match the Triton config.pbtxt output names.
*
*
* .google.protobuf.Struct fields_map = 6;
*/
@java.lang.Override
public com.google.protobuf.StructOrBuilder getFieldsMapOrBuilder() {
return getFieldsMap();
}
public static final int PARAMS_FIELD_NUMBER = 7;
private com.google.protobuf.Struct params_;
/**
*
* For predicting with the various ModelType's we accept a Struct (JSON object) worth of args
* that the ModelTypeField defines. During inference, the settings contained within are sent
* to the model predictor to alter predictions from this Model.
*
*
* .google.protobuf.Struct params = 7;
* @return Whether the params field is set.
*/
@java.lang.Override
public boolean hasParams() {
return params_ != null;
}
/**
*
* For predicting with the various ModelType's we accept a Struct (JSON object) worth of args
* that the ModelTypeField defines. During inference, the settings contained within are sent
* to the model predictor to alter predictions from this Model.
*
*
* .google.protobuf.Struct params = 7;
* @return The params.
*/
@java.lang.Override
public com.google.protobuf.Struct getParams() {
return params_ == null ? com.google.protobuf.Struct.getDefaultInstance() : params_;
}
/**
*
* For predicting with the various ModelType's we accept a Struct (JSON object) worth of args
* that the ModelTypeField defines. During inference, the settings contained within are sent
* to the model predictor to alter predictions from this Model.
*
*
* .google.protobuf.Struct params = 7;
*/
@java.lang.Override
public com.google.protobuf.StructOrBuilder getParamsOrBuilder() {
return getParams();
}
public static final int PARAMS_SPECS_FIELD_NUMBER = 8;
private java.util.List paramsSpecs_;
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
@java.lang.Override
public java.util.List getParamsSpecsList() {
return paramsSpecs_;
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
@java.lang.Override
public java.util.List extends com.clarifai.grpc.api.ModelTypeFieldOrBuilder>
getParamsSpecsOrBuilderList() {
return paramsSpecs_;
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
@java.lang.Override
public int getParamsSpecsCount() {
return paramsSpecs_.size();
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
@java.lang.Override
public com.clarifai.grpc.api.ModelTypeField getParamsSpecs(int index) {
return paramsSpecs_.get(index);
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
@java.lang.Override
public com.clarifai.grpc.api.ModelTypeFieldOrBuilder getParamsSpecsOrBuilder(
int index) {
return paramsSpecs_.get(index);
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (data_ != null) {
output.writeMessage(1, getData());
}
if (outputConfig_ != null) {
output.writeMessage(2, getOutputConfig());
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(message_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 3, message_);
}
if (fieldsMap_ != null) {
output.writeMessage(6, getFieldsMap());
}
if (params_ != null) {
output.writeMessage(7, getParams());
}
for (int i = 0; i < paramsSpecs_.size(); i++) {
output.writeMessage(8, paramsSpecs_.get(i));
}
unknownFields.writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (data_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, getData());
}
if (outputConfig_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, getOutputConfig());
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(message_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, message_);
}
if (fieldsMap_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(6, getFieldsMap());
}
if (params_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(7, getParams());
}
for (int i = 0; i < paramsSpecs_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(8, paramsSpecs_.get(i));
}
size += unknownFields.getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof com.clarifai.grpc.api.OutputInfo)) {
return super.equals(obj);
}
com.clarifai.grpc.api.OutputInfo other = (com.clarifai.grpc.api.OutputInfo) obj;
if (hasData() != other.hasData()) return false;
if (hasData()) {
if (!getData()
.equals(other.getData())) return false;
}
if (hasOutputConfig() != other.hasOutputConfig()) return false;
if (hasOutputConfig()) {
if (!getOutputConfig()
.equals(other.getOutputConfig())) return false;
}
if (!getMessage()
.equals(other.getMessage())) return false;
if (hasFieldsMap() != other.hasFieldsMap()) return false;
if (hasFieldsMap()) {
if (!getFieldsMap()
.equals(other.getFieldsMap())) return false;
}
if (hasParams() != other.hasParams()) return false;
if (hasParams()) {
if (!getParams()
.equals(other.getParams())) return false;
}
if (!getParamsSpecsList()
.equals(other.getParamsSpecsList())) return false;
if (!unknownFields.equals(other.unknownFields)) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (hasData()) {
hash = (37 * hash) + DATA_FIELD_NUMBER;
hash = (53 * hash) + getData().hashCode();
}
if (hasOutputConfig()) {
hash = (37 * hash) + OUTPUT_CONFIG_FIELD_NUMBER;
hash = (53 * hash) + getOutputConfig().hashCode();
}
hash = (37 * hash) + MESSAGE_FIELD_NUMBER;
hash = (53 * hash) + getMessage().hashCode();
if (hasFieldsMap()) {
hash = (37 * hash) + FIELDS_MAP_FIELD_NUMBER;
hash = (53 * hash) + getFieldsMap().hashCode();
}
if (hasParams()) {
hash = (37 * hash) + PARAMS_FIELD_NUMBER;
hash = (53 * hash) + getParams().hashCode();
}
if (getParamsSpecsCount() > 0) {
hash = (37 * hash) + PARAMS_SPECS_FIELD_NUMBER;
hash = (53 * hash) + getParamsSpecsList().hashCode();
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.clarifai.grpc.api.OutputInfo parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.clarifai.grpc.api.OutputInfo parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.clarifai.grpc.api.OutputInfo parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.clarifai.grpc.api.OutputInfo parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.clarifai.grpc.api.OutputInfo parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.clarifai.grpc.api.OutputInfo parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.clarifai.grpc.api.OutputInfo parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.clarifai.grpc.api.OutputInfo parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static com.clarifai.grpc.api.OutputInfo parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.clarifai.grpc.api.OutputInfo parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static com.clarifai.grpc.api.OutputInfo parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.clarifai.grpc.api.OutputInfo parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(com.clarifai.grpc.api.OutputInfo prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* OutputInfo defines some of the settings for each model version that PatchModels can effect. These
* parameters control some of the training or inference operations that this model can do.
* As the number of parameters continued to grow when we launched more ModelTypes we decided to move
* to using the OutputInfo.params field which is a Struct (or JSON object if you're using
* our JSON REST APIs). This allows each ModelType to define the set of fields, their default values
* and description of each field so that we can display those in Portal and make the creation of
* Model's very extensible. The OutputConfig object will eventually go away in favor of
* infer_params struct.
*
*
* Protobuf type {@code clarifai.api.OutputInfo}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:clarifai.api.OutputInfo)
com.clarifai.grpc.api.OutputInfoOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.clarifai.grpc.api.Resources.internal_static_clarifai_api_OutputInfo_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.clarifai.grpc.api.Resources.internal_static_clarifai_api_OutputInfo_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.clarifai.grpc.api.OutputInfo.class, com.clarifai.grpc.api.OutputInfo.Builder.class);
}
// Construct using com.clarifai.grpc.api.OutputInfo.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getParamsSpecsFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
if (dataBuilder_ == null) {
data_ = null;
} else {
data_ = null;
dataBuilder_ = null;
}
if (outputConfigBuilder_ == null) {
outputConfig_ = null;
} else {
outputConfig_ = null;
outputConfigBuilder_ = null;
}
message_ = "";
if (fieldsMapBuilder_ == null) {
fieldsMap_ = null;
} else {
fieldsMap_ = null;
fieldsMapBuilder_ = null;
}
if (paramsBuilder_ == null) {
params_ = null;
} else {
params_ = null;
paramsBuilder_ = null;
}
if (paramsSpecsBuilder_ == null) {
paramsSpecs_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
} else {
paramsSpecsBuilder_.clear();
}
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.clarifai.grpc.api.Resources.internal_static_clarifai_api_OutputInfo_descriptor;
}
@java.lang.Override
public com.clarifai.grpc.api.OutputInfo getDefaultInstanceForType() {
return com.clarifai.grpc.api.OutputInfo.getDefaultInstance();
}
@java.lang.Override
public com.clarifai.grpc.api.OutputInfo build() {
com.clarifai.grpc.api.OutputInfo result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.clarifai.grpc.api.OutputInfo buildPartial() {
com.clarifai.grpc.api.OutputInfo result = new com.clarifai.grpc.api.OutputInfo(this);
int from_bitField0_ = bitField0_;
if (dataBuilder_ == null) {
result.data_ = data_;
} else {
result.data_ = dataBuilder_.build();
}
if (outputConfigBuilder_ == null) {
result.outputConfig_ = outputConfig_;
} else {
result.outputConfig_ = outputConfigBuilder_.build();
}
result.message_ = message_;
if (fieldsMapBuilder_ == null) {
result.fieldsMap_ = fieldsMap_;
} else {
result.fieldsMap_ = fieldsMapBuilder_.build();
}
if (paramsBuilder_ == null) {
result.params_ = params_;
} else {
result.params_ = paramsBuilder_.build();
}
if (paramsSpecsBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) {
paramsSpecs_ = java.util.Collections.unmodifiableList(paramsSpecs_);
bitField0_ = (bitField0_ & ~0x00000001);
}
result.paramsSpecs_ = paramsSpecs_;
} else {
result.paramsSpecs_ = paramsSpecsBuilder_.build();
}
onBuilt();
return result;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof com.clarifai.grpc.api.OutputInfo) {
return mergeFrom((com.clarifai.grpc.api.OutputInfo)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.clarifai.grpc.api.OutputInfo other) {
if (other == com.clarifai.grpc.api.OutputInfo.getDefaultInstance()) return this;
if (other.hasData()) {
mergeData(other.getData());
}
if (other.hasOutputConfig()) {
mergeOutputConfig(other.getOutputConfig());
}
if (!other.getMessage().isEmpty()) {
message_ = other.message_;
onChanged();
}
if (other.hasFieldsMap()) {
mergeFieldsMap(other.getFieldsMap());
}
if (other.hasParams()) {
mergeParams(other.getParams());
}
if (paramsSpecsBuilder_ == null) {
if (!other.paramsSpecs_.isEmpty()) {
if (paramsSpecs_.isEmpty()) {
paramsSpecs_ = other.paramsSpecs_;
bitField0_ = (bitField0_ & ~0x00000001);
} else {
ensureParamsSpecsIsMutable();
paramsSpecs_.addAll(other.paramsSpecs_);
}
onChanged();
}
} else {
if (!other.paramsSpecs_.isEmpty()) {
if (paramsSpecsBuilder_.isEmpty()) {
paramsSpecsBuilder_.dispose();
paramsSpecsBuilder_ = null;
paramsSpecs_ = other.paramsSpecs_;
bitField0_ = (bitField0_ & ~0x00000001);
paramsSpecsBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getParamsSpecsFieldBuilder() : null;
} else {
paramsSpecsBuilder_.addAllMessages(other.paramsSpecs_);
}
}
}
this.mergeUnknownFields(other.unknownFields);
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
com.clarifai.grpc.api.OutputInfo parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.clarifai.grpc.api.OutputInfo) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int bitField0_;
private com.clarifai.grpc.api.Data data_;
private com.google.protobuf.SingleFieldBuilderV3<
com.clarifai.grpc.api.Data, com.clarifai.grpc.api.Data.Builder, com.clarifai.grpc.api.DataOrBuilder> dataBuilder_;
/**
*
* List of concepts or other output related data for the model.
*
*
* .clarifai.api.Data data = 1;
* @return Whether the data field is set.
*/
public boolean hasData() {
return dataBuilder_ != null || data_ != null;
}
/**
*
* List of concepts or other output related data for the model.
*
*
* .clarifai.api.Data data = 1;
* @return The data.
*/
public com.clarifai.grpc.api.Data getData() {
if (dataBuilder_ == null) {
return data_ == null ? com.clarifai.grpc.api.Data.getDefaultInstance() : data_;
} else {
return dataBuilder_.getMessage();
}
}
/**
*
* List of concepts or other output related data for the model.
*
*
* .clarifai.api.Data data = 1;
*/
public Builder setData(com.clarifai.grpc.api.Data value) {
if (dataBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
data_ = value;
onChanged();
} else {
dataBuilder_.setMessage(value);
}
return this;
}
/**
*
* List of concepts or other output related data for the model.
*
*
* .clarifai.api.Data data = 1;
*/
public Builder setData(
com.clarifai.grpc.api.Data.Builder builderForValue) {
if (dataBuilder_ == null) {
data_ = builderForValue.build();
onChanged();
} else {
dataBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* List of concepts or other output related data for the model.
*
*
* .clarifai.api.Data data = 1;
*/
public Builder mergeData(com.clarifai.grpc.api.Data value) {
if (dataBuilder_ == null) {
if (data_ != null) {
data_ =
com.clarifai.grpc.api.Data.newBuilder(data_).mergeFrom(value).buildPartial();
} else {
data_ = value;
}
onChanged();
} else {
dataBuilder_.mergeFrom(value);
}
return this;
}
/**
*
* List of concepts or other output related data for the model.
*
*
* .clarifai.api.Data data = 1;
*/
public Builder clearData() {
if (dataBuilder_ == null) {
data_ = null;
onChanged();
} else {
data_ = null;
dataBuilder_ = null;
}
return this;
}
/**
*
* List of concepts or other output related data for the model.
*
*
* .clarifai.api.Data data = 1;
*/
public com.clarifai.grpc.api.Data.Builder getDataBuilder() {
onChanged();
return getDataFieldBuilder().getBuilder();
}
/**
*
* List of concepts or other output related data for the model.
*
*
* .clarifai.api.Data data = 1;
*/
public com.clarifai.grpc.api.DataOrBuilder getDataOrBuilder() {
if (dataBuilder_ != null) {
return dataBuilder_.getMessageOrBuilder();
} else {
return data_ == null ?
com.clarifai.grpc.api.Data.getDefaultInstance() : data_;
}
}
/**
*
* List of concepts or other output related data for the model.
*
*
* .clarifai.api.Data data = 1;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.clarifai.grpc.api.Data, com.clarifai.grpc.api.Data.Builder, com.clarifai.grpc.api.DataOrBuilder>
getDataFieldBuilder() {
if (dataBuilder_ == null) {
dataBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.clarifai.grpc.api.Data, com.clarifai.grpc.api.Data.Builder, com.clarifai.grpc.api.DataOrBuilder>(
getData(),
getParentForChildren(),
isClean());
data_ = null;
}
return dataBuilder_;
}
private com.clarifai.grpc.api.OutputConfig outputConfig_;
private com.google.protobuf.SingleFieldBuilderV3<
com.clarifai.grpc.api.OutputConfig, com.clarifai.grpc.api.OutputConfig.Builder, com.clarifai.grpc.api.OutputConfigOrBuilder> outputConfigBuilder_;
/**
*
* Model configuration...going away in favor of infer_params and train_params over time.
* TO BE DEPRECATED
*
*
* .clarifai.api.OutputConfig output_config = 2;
* @return Whether the outputConfig field is set.
*/
public boolean hasOutputConfig() {
return outputConfigBuilder_ != null || outputConfig_ != null;
}
/**
*
* Model configuration...going away in favor of infer_params and train_params over time.
* TO BE DEPRECATED
*
*
* .clarifai.api.OutputConfig output_config = 2;
* @return The outputConfig.
*/
public com.clarifai.grpc.api.OutputConfig getOutputConfig() {
if (outputConfigBuilder_ == null) {
return outputConfig_ == null ? com.clarifai.grpc.api.OutputConfig.getDefaultInstance() : outputConfig_;
} else {
return outputConfigBuilder_.getMessage();
}
}
/**
*
* Model configuration...going away in favor of infer_params and train_params over time.
* TO BE DEPRECATED
*
*
* .clarifai.api.OutputConfig output_config = 2;
*/
public Builder setOutputConfig(com.clarifai.grpc.api.OutputConfig value) {
if (outputConfigBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
outputConfig_ = value;
onChanged();
} else {
outputConfigBuilder_.setMessage(value);
}
return this;
}
/**
*
* Model configuration...going away in favor of infer_params and train_params over time.
* TO BE DEPRECATED
*
*
* .clarifai.api.OutputConfig output_config = 2;
*/
public Builder setOutputConfig(
com.clarifai.grpc.api.OutputConfig.Builder builderForValue) {
if (outputConfigBuilder_ == null) {
outputConfig_ = builderForValue.build();
onChanged();
} else {
outputConfigBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* Model configuration...going away in favor of infer_params and train_params over time.
* TO BE DEPRECATED
*
*
* .clarifai.api.OutputConfig output_config = 2;
*/
public Builder mergeOutputConfig(com.clarifai.grpc.api.OutputConfig value) {
if (outputConfigBuilder_ == null) {
if (outputConfig_ != null) {
outputConfig_ =
com.clarifai.grpc.api.OutputConfig.newBuilder(outputConfig_).mergeFrom(value).buildPartial();
} else {
outputConfig_ = value;
}
onChanged();
} else {
outputConfigBuilder_.mergeFrom(value);
}
return this;
}
/**
*
* Model configuration...going away in favor of infer_params and train_params over time.
* TO BE DEPRECATED
*
*
* .clarifai.api.OutputConfig output_config = 2;
*/
public Builder clearOutputConfig() {
if (outputConfigBuilder_ == null) {
outputConfig_ = null;
onChanged();
} else {
outputConfig_ = null;
outputConfigBuilder_ = null;
}
return this;
}
/**
*
* Model configuration...going away in favor of infer_params and train_params over time.
* TO BE DEPRECATED
*
*
* .clarifai.api.OutputConfig output_config = 2;
*/
public com.clarifai.grpc.api.OutputConfig.Builder getOutputConfigBuilder() {
onChanged();
return getOutputConfigFieldBuilder().getBuilder();
}
/**
*
* Model configuration...going away in favor of infer_params and train_params over time.
* TO BE DEPRECATED
*
*
* .clarifai.api.OutputConfig output_config = 2;
*/
public com.clarifai.grpc.api.OutputConfigOrBuilder getOutputConfigOrBuilder() {
if (outputConfigBuilder_ != null) {
return outputConfigBuilder_.getMessageOrBuilder();
} else {
return outputConfig_ == null ?
com.clarifai.grpc.api.OutputConfig.getDefaultInstance() : outputConfig_;
}
}
/**
*
* Model configuration...going away in favor of infer_params and train_params over time.
* TO BE DEPRECATED
*
*
* .clarifai.api.OutputConfig output_config = 2;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.clarifai.grpc.api.OutputConfig, com.clarifai.grpc.api.OutputConfig.Builder, com.clarifai.grpc.api.OutputConfigOrBuilder>
getOutputConfigFieldBuilder() {
if (outputConfigBuilder_ == null) {
outputConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.clarifai.grpc.api.OutputConfig, com.clarifai.grpc.api.OutputConfig.Builder, com.clarifai.grpc.api.OutputConfigOrBuilder>(
getOutputConfig(),
getParentForChildren(),
isClean());
outputConfig_ = null;
}
return outputConfigBuilder_;
}
private java.lang.Object message_ = "";
/**
*
* For returning where to look for the Output info if not returning it.
*
*
* string message = 3;
* @return The message.
*/
public java.lang.String getMessage() {
java.lang.Object ref = message_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
message_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* For returning where to look for the Output info if not returning it.
*
*
* string message = 3;
* @return The bytes for message.
*/
public com.google.protobuf.ByteString
getMessageBytes() {
java.lang.Object ref = message_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
message_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* For returning where to look for the Output info if not returning it.
*
*
* string message = 3;
* @param value The message to set.
* @return This builder for chaining.
*/
public Builder setMessage(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
message_ = value;
onChanged();
return this;
}
/**
*
* For returning where to look for the Output info if not returning it.
*
*
* string message = 3;
* @return This builder for chaining.
*/
public Builder clearMessage() {
message_ = getDefaultInstance().getMessage();
onChanged();
return this;
}
/**
*
* For returning where to look for the Output info if not returning it.
*
*
* string message = 3;
* @param value The bytes for message to set.
* @return This builder for chaining.
*/
public Builder setMessageBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
message_ = value;
onChanged();
return this;
}
private com.google.protobuf.Struct fieldsMap_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Struct, com.google.protobuf.Struct.Builder, com.google.protobuf.StructOrBuilder> fieldsMapBuilder_;
/**
*
* Map from the api.Data field names to the underlying model graph's outputs. When using a
* PretrainedModelConfig the values in this map need to match the Triton config.pbtxt output names.
*
*
* .google.protobuf.Struct fields_map = 6;
* @return Whether the fieldsMap field is set.
*/
public boolean hasFieldsMap() {
return fieldsMapBuilder_ != null || fieldsMap_ != null;
}
/**
*
* Map from the api.Data field names to the underlying model graph's outputs. When using a
* PretrainedModelConfig the values in this map need to match the Triton config.pbtxt output names.
*
*
* .google.protobuf.Struct fields_map = 6;
* @return The fieldsMap.
*/
public com.google.protobuf.Struct getFieldsMap() {
if (fieldsMapBuilder_ == null) {
return fieldsMap_ == null ? com.google.protobuf.Struct.getDefaultInstance() : fieldsMap_;
} else {
return fieldsMapBuilder_.getMessage();
}
}
/**
*
* Map from the api.Data field names to the underlying model graph's outputs. When using a
* PretrainedModelConfig the values in this map need to match the Triton config.pbtxt output names.
*
*
* .google.protobuf.Struct fields_map = 6;
*/
public Builder setFieldsMap(com.google.protobuf.Struct value) {
if (fieldsMapBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
fieldsMap_ = value;
onChanged();
} else {
fieldsMapBuilder_.setMessage(value);
}
return this;
}
/**
*
* Map from the api.Data field names to the underlying model graph's outputs. When using a
* PretrainedModelConfig the values in this map need to match the Triton config.pbtxt output names.
*
*
* .google.protobuf.Struct fields_map = 6;
*/
public Builder setFieldsMap(
com.google.protobuf.Struct.Builder builderForValue) {
if (fieldsMapBuilder_ == null) {
fieldsMap_ = builderForValue.build();
onChanged();
} else {
fieldsMapBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* Map from the api.Data field names to the underlying model graph's outputs. When using a
* PretrainedModelConfig the values in this map need to match the Triton config.pbtxt output names.
*
*
* .google.protobuf.Struct fields_map = 6;
*/
public Builder mergeFieldsMap(com.google.protobuf.Struct value) {
if (fieldsMapBuilder_ == null) {
if (fieldsMap_ != null) {
fieldsMap_ =
com.google.protobuf.Struct.newBuilder(fieldsMap_).mergeFrom(value).buildPartial();
} else {
fieldsMap_ = value;
}
onChanged();
} else {
fieldsMapBuilder_.mergeFrom(value);
}
return this;
}
/**
*
* Map from the api.Data field names to the underlying model graph's outputs. When using a
* PretrainedModelConfig the values in this map need to match the Triton config.pbtxt output names.
*
*
* .google.protobuf.Struct fields_map = 6;
*/
public Builder clearFieldsMap() {
if (fieldsMapBuilder_ == null) {
fieldsMap_ = null;
onChanged();
} else {
fieldsMap_ = null;
fieldsMapBuilder_ = null;
}
return this;
}
/**
*
* Map from the api.Data field names to the underlying model graph's outputs. When using a
* PretrainedModelConfig the values in this map need to match the Triton config.pbtxt output names.
*
*
* .google.protobuf.Struct fields_map = 6;
*/
public com.google.protobuf.Struct.Builder getFieldsMapBuilder() {
onChanged();
return getFieldsMapFieldBuilder().getBuilder();
}
/**
*
* Map from the api.Data field names to the underlying model graph's outputs. When using a
* PretrainedModelConfig the values in this map need to match the Triton config.pbtxt output names.
*
*
* .google.protobuf.Struct fields_map = 6;
*/
public com.google.protobuf.StructOrBuilder getFieldsMapOrBuilder() {
if (fieldsMapBuilder_ != null) {
return fieldsMapBuilder_.getMessageOrBuilder();
} else {
return fieldsMap_ == null ?
com.google.protobuf.Struct.getDefaultInstance() : fieldsMap_;
}
}
/**
*
* Map from the api.Data field names to the underlying model graph's outputs. When using a
* PretrainedModelConfig the values in this map need to match the Triton config.pbtxt output names.
*
*
* .google.protobuf.Struct fields_map = 6;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Struct, com.google.protobuf.Struct.Builder, com.google.protobuf.StructOrBuilder>
getFieldsMapFieldBuilder() {
if (fieldsMapBuilder_ == null) {
fieldsMapBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Struct, com.google.protobuf.Struct.Builder, com.google.protobuf.StructOrBuilder>(
getFieldsMap(),
getParentForChildren(),
isClean());
fieldsMap_ = null;
}
return fieldsMapBuilder_;
}
private com.google.protobuf.Struct params_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Struct, com.google.protobuf.Struct.Builder, com.google.protobuf.StructOrBuilder> paramsBuilder_;
/**
*
* For predicting with the various ModelType's we accept a Struct (JSON object) worth of args
* that the ModelTypeField defines. During inference, the settings contained within are sent
* to the model predictor to alter predictions from this Model.
*
*
* .google.protobuf.Struct params = 7;
* @return Whether the params field is set.
*/
public boolean hasParams() {
return paramsBuilder_ != null || params_ != null;
}
/**
*
* For predicting with the various ModelType's we accept a Struct (JSON object) worth of args
* that the ModelTypeField defines. During inference, the settings contained within are sent
* to the model predictor to alter predictions from this Model.
*
*
* .google.protobuf.Struct params = 7;
* @return The params.
*/
public com.google.protobuf.Struct getParams() {
if (paramsBuilder_ == null) {
return params_ == null ? com.google.protobuf.Struct.getDefaultInstance() : params_;
} else {
return paramsBuilder_.getMessage();
}
}
/**
*
* For predicting with the various ModelType's we accept a Struct (JSON object) worth of args
* that the ModelTypeField defines. During inference, the settings contained within are sent
* to the model predictor to alter predictions from this Model.
*
*
* .google.protobuf.Struct params = 7;
*/
public Builder setParams(com.google.protobuf.Struct value) {
if (paramsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
params_ = value;
onChanged();
} else {
paramsBuilder_.setMessage(value);
}
return this;
}
/**
*
* For predicting with the various ModelType's we accept a Struct (JSON object) worth of args
* that the ModelTypeField defines. During inference, the settings contained within are sent
* to the model predictor to alter predictions from this Model.
*
*
* .google.protobuf.Struct params = 7;
*/
public Builder setParams(
com.google.protobuf.Struct.Builder builderForValue) {
if (paramsBuilder_ == null) {
params_ = builderForValue.build();
onChanged();
} else {
paramsBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* For predicting with the various ModelType's we accept a Struct (JSON object) worth of args
* that the ModelTypeField defines. During inference, the settings contained within are sent
* to the model predictor to alter predictions from this Model.
*
*
* .google.protobuf.Struct params = 7;
*/
public Builder mergeParams(com.google.protobuf.Struct value) {
if (paramsBuilder_ == null) {
if (params_ != null) {
params_ =
com.google.protobuf.Struct.newBuilder(params_).mergeFrom(value).buildPartial();
} else {
params_ = value;
}
onChanged();
} else {
paramsBuilder_.mergeFrom(value);
}
return this;
}
/**
*
* For predicting with the various ModelType's we accept a Struct (JSON object) worth of args
* that the ModelTypeField defines. During inference, the settings contained within are sent
* to the model predictor to alter predictions from this Model.
*
*
* .google.protobuf.Struct params = 7;
*/
public Builder clearParams() {
if (paramsBuilder_ == null) {
params_ = null;
onChanged();
} else {
params_ = null;
paramsBuilder_ = null;
}
return this;
}
/**
*
* For predicting with the various ModelType's we accept a Struct (JSON object) worth of args
* that the ModelTypeField defines. During inference, the settings contained within are sent
* to the model predictor to alter predictions from this Model.
*
*
* .google.protobuf.Struct params = 7;
*/
public com.google.protobuf.Struct.Builder getParamsBuilder() {
onChanged();
return getParamsFieldBuilder().getBuilder();
}
/**
*
* For predicting with the various ModelType's we accept a Struct (JSON object) worth of args
* that the ModelTypeField defines. During inference, the settings contained within are sent
* to the model predictor to alter predictions from this Model.
*
*
* .google.protobuf.Struct params = 7;
*/
public com.google.protobuf.StructOrBuilder getParamsOrBuilder() {
if (paramsBuilder_ != null) {
return paramsBuilder_.getMessageOrBuilder();
} else {
return params_ == null ?
com.google.protobuf.Struct.getDefaultInstance() : params_;
}
}
/**
*
* For predicting with the various ModelType's we accept a Struct (JSON object) worth of args
* that the ModelTypeField defines. During inference, the settings contained within are sent
* to the model predictor to alter predictions from this Model.
*
*
* .google.protobuf.Struct params = 7;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Struct, com.google.protobuf.Struct.Builder, com.google.protobuf.StructOrBuilder>
getParamsFieldBuilder() {
if (paramsBuilder_ == null) {
paramsBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Struct, com.google.protobuf.Struct.Builder, com.google.protobuf.StructOrBuilder>(
getParams(),
getParentForChildren(),
isClean());
params_ = null;
}
return paramsBuilder_;
}
private java.util.List paramsSpecs_ =
java.util.Collections.emptyList();
private void ensureParamsSpecsIsMutable() {
if (!((bitField0_ & 0x00000001) != 0)) {
paramsSpecs_ = new java.util.ArrayList(paramsSpecs_);
bitField0_ |= 0x00000001;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.clarifai.grpc.api.ModelTypeField, com.clarifai.grpc.api.ModelTypeField.Builder, com.clarifai.grpc.api.ModelTypeFieldOrBuilder> paramsSpecsBuilder_;
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
public java.util.List getParamsSpecsList() {
if (paramsSpecsBuilder_ == null) {
return java.util.Collections.unmodifiableList(paramsSpecs_);
} else {
return paramsSpecsBuilder_.getMessageList();
}
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
public int getParamsSpecsCount() {
if (paramsSpecsBuilder_ == null) {
return paramsSpecs_.size();
} else {
return paramsSpecsBuilder_.getCount();
}
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
public com.clarifai.grpc.api.ModelTypeField getParamsSpecs(int index) {
if (paramsSpecsBuilder_ == null) {
return paramsSpecs_.get(index);
} else {
return paramsSpecsBuilder_.getMessage(index);
}
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
public Builder setParamsSpecs(
int index, com.clarifai.grpc.api.ModelTypeField value) {
if (paramsSpecsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureParamsSpecsIsMutable();
paramsSpecs_.set(index, value);
onChanged();
} else {
paramsSpecsBuilder_.setMessage(index, value);
}
return this;
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
public Builder setParamsSpecs(
int index, com.clarifai.grpc.api.ModelTypeField.Builder builderForValue) {
if (paramsSpecsBuilder_ == null) {
ensureParamsSpecsIsMutable();
paramsSpecs_.set(index, builderForValue.build());
onChanged();
} else {
paramsSpecsBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
public Builder addParamsSpecs(com.clarifai.grpc.api.ModelTypeField value) {
if (paramsSpecsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureParamsSpecsIsMutable();
paramsSpecs_.add(value);
onChanged();
} else {
paramsSpecsBuilder_.addMessage(value);
}
return this;
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
public Builder addParamsSpecs(
int index, com.clarifai.grpc.api.ModelTypeField value) {
if (paramsSpecsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureParamsSpecsIsMutable();
paramsSpecs_.add(index, value);
onChanged();
} else {
paramsSpecsBuilder_.addMessage(index, value);
}
return this;
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
public Builder addParamsSpecs(
com.clarifai.grpc.api.ModelTypeField.Builder builderForValue) {
if (paramsSpecsBuilder_ == null) {
ensureParamsSpecsIsMutable();
paramsSpecs_.add(builderForValue.build());
onChanged();
} else {
paramsSpecsBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
public Builder addParamsSpecs(
int index, com.clarifai.grpc.api.ModelTypeField.Builder builderForValue) {
if (paramsSpecsBuilder_ == null) {
ensureParamsSpecsIsMutable();
paramsSpecs_.add(index, builderForValue.build());
onChanged();
} else {
paramsSpecsBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
public Builder addAllParamsSpecs(
java.lang.Iterable extends com.clarifai.grpc.api.ModelTypeField> values) {
if (paramsSpecsBuilder_ == null) {
ensureParamsSpecsIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, paramsSpecs_);
onChanged();
} else {
paramsSpecsBuilder_.addAllMessages(values);
}
return this;
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
public Builder clearParamsSpecs() {
if (paramsSpecsBuilder_ == null) {
paramsSpecs_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
} else {
paramsSpecsBuilder_.clear();
}
return this;
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
public Builder removeParamsSpecs(int index) {
if (paramsSpecsBuilder_ == null) {
ensureParamsSpecsIsMutable();
paramsSpecs_.remove(index);
onChanged();
} else {
paramsSpecsBuilder_.remove(index);
}
return this;
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
public com.clarifai.grpc.api.ModelTypeField.Builder getParamsSpecsBuilder(
int index) {
return getParamsSpecsFieldBuilder().getBuilder(index);
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
public com.clarifai.grpc.api.ModelTypeFieldOrBuilder getParamsSpecsOrBuilder(
int index) {
if (paramsSpecsBuilder_ == null) {
return paramsSpecs_.get(index); } else {
return paramsSpecsBuilder_.getMessageOrBuilder(index);
}
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
public java.util.List extends com.clarifai.grpc.api.ModelTypeFieldOrBuilder>
getParamsSpecsOrBuilderList() {
if (paramsSpecsBuilder_ != null) {
return paramsSpecsBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(paramsSpecs_);
}
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
public com.clarifai.grpc.api.ModelTypeField.Builder addParamsSpecsBuilder() {
return getParamsSpecsFieldBuilder().addBuilder(
com.clarifai.grpc.api.ModelTypeField.getDefaultInstance());
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
public com.clarifai.grpc.api.ModelTypeField.Builder addParamsSpecsBuilder(
int index) {
return getParamsSpecsFieldBuilder().addBuilder(
index, com.clarifai.grpc.api.ModelTypeField.getDefaultInstance());
}
/**
* repeated .clarifai.api.ModelTypeField params_specs = 8;
*/
public java.util.List
getParamsSpecsBuilderList() {
return getParamsSpecsFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.clarifai.grpc.api.ModelTypeField, com.clarifai.grpc.api.ModelTypeField.Builder, com.clarifai.grpc.api.ModelTypeFieldOrBuilder>
getParamsSpecsFieldBuilder() {
if (paramsSpecsBuilder_ == null) {
paramsSpecsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
com.clarifai.grpc.api.ModelTypeField, com.clarifai.grpc.api.ModelTypeField.Builder, com.clarifai.grpc.api.ModelTypeFieldOrBuilder>(
paramsSpecs_,
((bitField0_ & 0x00000001) != 0),
getParentForChildren(),
isClean());
paramsSpecs_ = null;
}
return paramsSpecsBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:clarifai.api.OutputInfo)
}
// @@protoc_insertion_point(class_scope:clarifai.api.OutputInfo)
private static final com.clarifai.grpc.api.OutputInfo DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.clarifai.grpc.api.OutputInfo();
}
public static com.clarifai.grpc.api.OutputInfo getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public OutputInfo parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new OutputInfo(input, extensionRegistry);
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public com.clarifai.grpc.api.OutputInfo getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}