com.clarifai.grpc.api.AnnotationSearchMetrics Maven / Gradle / Ivy
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: proto/clarifai/api/resources.proto
package com.clarifai.grpc.api;
/**
*
* AnnotationSearchMetrics
*
*
* Protobuf type {@code clarifai.api.AnnotationSearchMetrics}
*/
public final class AnnotationSearchMetrics extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:clarifai.api.AnnotationSearchMetrics)
AnnotationSearchMetricsOrBuilder {
private static final long serialVersionUID = 0L;
// Use AnnotationSearchMetrics.newBuilder() to construct.
private AnnotationSearchMetrics(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private AnnotationSearchMetrics() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new AnnotationSearchMetrics();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private AnnotationSearchMetrics(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
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.Search.Builder subBuilder = null;
if (groundTruth_ != null) {
subBuilder = groundTruth_.toBuilder();
}
groundTruth_ = input.readMessage(com.clarifai.grpc.api.Search.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(groundTruth_);
groundTruth_ = subBuilder.buildPartial();
}
break;
}
case 18: {
com.clarifai.grpc.api.Search.Builder subBuilder = null;
if (searchToEval_ != null) {
subBuilder = searchToEval_.toBuilder();
}
searchToEval_ = input.readMessage(com.clarifai.grpc.api.Search.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(searchToEval_);
searchToEval_ = subBuilder.buildPartial();
}
break;
}
case 26: {
com.clarifai.grpc.api.EvalMetrics.Builder subBuilder = null;
if (metrics_ != null) {
subBuilder = metrics_.toBuilder();
}
metrics_ = input.readMessage(com.clarifai.grpc.api.EvalMetrics.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(metrics_);
metrics_ = subBuilder.buildPartial();
}
break;
}
case 34: {
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 40: {
activeConceptCount_ = input.readUInt32();
break;
}
case 50: {
com.clarifai.grpc.api.Visibility.Builder subBuilder = null;
if (visibility_ != null) {
subBuilder = visibility_.toBuilder();
}
visibility_ = input.readMessage(com.clarifai.grpc.api.Visibility.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(visibility_);
visibility_ = subBuilder.buildPartial();
}
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 {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.clarifai.grpc.api.Resources.internal_static_clarifai_api_AnnotationSearchMetrics_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.clarifai.grpc.api.Resources.internal_static_clarifai_api_AnnotationSearchMetrics_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.clarifai.grpc.api.AnnotationSearchMetrics.class, com.clarifai.grpc.api.AnnotationSearchMetrics.Builder.class);
}
public static final int GROUND_TRUTH_FIELD_NUMBER = 1;
private com.clarifai.grpc.api.Search groundTruth_;
/**
*
* The ground truth we are evaluating against
*
*
* .clarifai.api.Search ground_truth = 1;
* @return Whether the groundTruth field is set.
*/
@java.lang.Override
public boolean hasGroundTruth() {
return groundTruth_ != null;
}
/**
*
* The ground truth we are evaluating against
*
*
* .clarifai.api.Search ground_truth = 1;
* @return The groundTruth.
*/
@java.lang.Override
public com.clarifai.grpc.api.Search getGroundTruth() {
return groundTruth_ == null ? com.clarifai.grpc.api.Search.getDefaultInstance() : groundTruth_;
}
/**
*
* The ground truth we are evaluating against
*
*
* .clarifai.api.Search ground_truth = 1;
*/
@java.lang.Override
public com.clarifai.grpc.api.SearchOrBuilder getGroundTruthOrBuilder() {
return getGroundTruth();
}
public static final int SEARCH_TO_EVAL_FIELD_NUMBER = 2;
private com.clarifai.grpc.api.Search searchToEval_;
/**
*
* The set we are evaluating
*
*
* .clarifai.api.Search search_to_eval = 2;
* @return Whether the searchToEval field is set.
*/
@java.lang.Override
public boolean hasSearchToEval() {
return searchToEval_ != null;
}
/**
*
* The set we are evaluating
*
*
* .clarifai.api.Search search_to_eval = 2;
* @return The searchToEval.
*/
@java.lang.Override
public com.clarifai.grpc.api.Search getSearchToEval() {
return searchToEval_ == null ? com.clarifai.grpc.api.Search.getDefaultInstance() : searchToEval_;
}
/**
*
* The set we are evaluating
*
*
* .clarifai.api.Search search_to_eval = 2;
*/
@java.lang.Override
public com.clarifai.grpc.api.SearchOrBuilder getSearchToEvalOrBuilder() {
return getSearchToEval();
}
public static final int METRICS_FIELD_NUMBER = 3;
private com.clarifai.grpc.api.EvalMetrics metrics_;
/**
*
* The metric result
*
*
* .clarifai.api.EvalMetrics metrics = 3;
* @return Whether the metrics field is set.
*/
@java.lang.Override
public boolean hasMetrics() {
return metrics_ != null;
}
/**
*
* The metric result
*
*
* .clarifai.api.EvalMetrics metrics = 3;
* @return The metrics.
*/
@java.lang.Override
public com.clarifai.grpc.api.EvalMetrics getMetrics() {
return metrics_ == null ? com.clarifai.grpc.api.EvalMetrics.getDefaultInstance() : metrics_;
}
/**
*
* The metric result
*
*
* .clarifai.api.EvalMetrics metrics = 3;
*/
@java.lang.Override
public com.clarifai.grpc.api.EvalMetricsOrBuilder getMetricsOrBuilder() {
return getMetrics();
}
public static final int DATA_FIELD_NUMBER = 4;
private com.clarifai.grpc.api.Data data_;
/**
*
* data is filled out with the concepts used for this evaluation
*
*
* .clarifai.api.Data data = 4;
* @return Whether the data field is set.
*/
@java.lang.Override
public boolean hasData() {
return data_ != null;
}
/**
*
* data is filled out with the concepts used for this evaluation
*
*
* .clarifai.api.Data data = 4;
* @return The data.
*/
@java.lang.Override
public com.clarifai.grpc.api.Data getData() {
return data_ == null ? com.clarifai.grpc.api.Data.getDefaultInstance() : data_;
}
/**
*
* data is filled out with the concepts used for this evaluation
*
*
* .clarifai.api.Data data = 4;
*/
@java.lang.Override
public com.clarifai.grpc.api.DataOrBuilder getDataOrBuilder() {
return getData();
}
public static final int ACTIVE_CONCEPT_COUNT_FIELD_NUMBER = 5;
private int activeConceptCount_;
/**
*
* active_concept_count is the number of concepts for this evaluation
*
*
* uint32 active_concept_count = 5;
* @return The activeConceptCount.
*/
@java.lang.Override
public int getActiveConceptCount() {
return activeConceptCount_;
}
public static final int VISIBILITY_FIELD_NUMBER = 6;
private com.clarifai.grpc.api.Visibility visibility_;
/**
*
* The visibility field represents whether this message is privately/publicly visible.
* To be visible to the public the App that contains it AND the User that contains the App must
* also be publicly visible.
*
*
* .clarifai.api.Visibility visibility = 6;
* @return Whether the visibility field is set.
*/
@java.lang.Override
public boolean hasVisibility() {
return visibility_ != null;
}
/**
*
* The visibility field represents whether this message is privately/publicly visible.
* To be visible to the public the App that contains it AND the User that contains the App must
* also be publicly visible.
*
*
* .clarifai.api.Visibility visibility = 6;
* @return The visibility.
*/
@java.lang.Override
public com.clarifai.grpc.api.Visibility getVisibility() {
return visibility_ == null ? com.clarifai.grpc.api.Visibility.getDefaultInstance() : visibility_;
}
/**
*
* The visibility field represents whether this message is privately/publicly visible.
* To be visible to the public the App that contains it AND the User that contains the App must
* also be publicly visible.
*
*
* .clarifai.api.Visibility visibility = 6;
*/
@java.lang.Override
public com.clarifai.grpc.api.VisibilityOrBuilder getVisibilityOrBuilder() {
return getVisibility();
}
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 (groundTruth_ != null) {
output.writeMessage(1, getGroundTruth());
}
if (searchToEval_ != null) {
output.writeMessage(2, getSearchToEval());
}
if (metrics_ != null) {
output.writeMessage(3, getMetrics());
}
if (data_ != null) {
output.writeMessage(4, getData());
}
if (activeConceptCount_ != 0) {
output.writeUInt32(5, activeConceptCount_);
}
if (visibility_ != null) {
output.writeMessage(6, getVisibility());
}
unknownFields.writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (groundTruth_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, getGroundTruth());
}
if (searchToEval_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, getSearchToEval());
}
if (metrics_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, getMetrics());
}
if (data_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(4, getData());
}
if (activeConceptCount_ != 0) {
size += com.google.protobuf.CodedOutputStream
.computeUInt32Size(5, activeConceptCount_);
}
if (visibility_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(6, getVisibility());
}
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.AnnotationSearchMetrics)) {
return super.equals(obj);
}
com.clarifai.grpc.api.AnnotationSearchMetrics other = (com.clarifai.grpc.api.AnnotationSearchMetrics) obj;
if (hasGroundTruth() != other.hasGroundTruth()) return false;
if (hasGroundTruth()) {
if (!getGroundTruth()
.equals(other.getGroundTruth())) return false;
}
if (hasSearchToEval() != other.hasSearchToEval()) return false;
if (hasSearchToEval()) {
if (!getSearchToEval()
.equals(other.getSearchToEval())) return false;
}
if (hasMetrics() != other.hasMetrics()) return false;
if (hasMetrics()) {
if (!getMetrics()
.equals(other.getMetrics())) return false;
}
if (hasData() != other.hasData()) return false;
if (hasData()) {
if (!getData()
.equals(other.getData())) return false;
}
if (getActiveConceptCount()
!= other.getActiveConceptCount()) return false;
if (hasVisibility() != other.hasVisibility()) return false;
if (hasVisibility()) {
if (!getVisibility()
.equals(other.getVisibility())) 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 (hasGroundTruth()) {
hash = (37 * hash) + GROUND_TRUTH_FIELD_NUMBER;
hash = (53 * hash) + getGroundTruth().hashCode();
}
if (hasSearchToEval()) {
hash = (37 * hash) + SEARCH_TO_EVAL_FIELD_NUMBER;
hash = (53 * hash) + getSearchToEval().hashCode();
}
if (hasMetrics()) {
hash = (37 * hash) + METRICS_FIELD_NUMBER;
hash = (53 * hash) + getMetrics().hashCode();
}
if (hasData()) {
hash = (37 * hash) + DATA_FIELD_NUMBER;
hash = (53 * hash) + getData().hashCode();
}
hash = (37 * hash) + ACTIVE_CONCEPT_COUNT_FIELD_NUMBER;
hash = (53 * hash) + getActiveConceptCount();
if (hasVisibility()) {
hash = (37 * hash) + VISIBILITY_FIELD_NUMBER;
hash = (53 * hash) + getVisibility().hashCode();
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.clarifai.grpc.api.AnnotationSearchMetrics parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.clarifai.grpc.api.AnnotationSearchMetrics 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.AnnotationSearchMetrics parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.clarifai.grpc.api.AnnotationSearchMetrics 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.AnnotationSearchMetrics parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.clarifai.grpc.api.AnnotationSearchMetrics parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.clarifai.grpc.api.AnnotationSearchMetrics parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.clarifai.grpc.api.AnnotationSearchMetrics 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.AnnotationSearchMetrics parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.clarifai.grpc.api.AnnotationSearchMetrics 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.AnnotationSearchMetrics parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.clarifai.grpc.api.AnnotationSearchMetrics 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.AnnotationSearchMetrics 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;
}
/**
*
* AnnotationSearchMetrics
*
*
* Protobuf type {@code clarifai.api.AnnotationSearchMetrics}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:clarifai.api.AnnotationSearchMetrics)
com.clarifai.grpc.api.AnnotationSearchMetricsOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.clarifai.grpc.api.Resources.internal_static_clarifai_api_AnnotationSearchMetrics_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.clarifai.grpc.api.Resources.internal_static_clarifai_api_AnnotationSearchMetrics_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.clarifai.grpc.api.AnnotationSearchMetrics.class, com.clarifai.grpc.api.AnnotationSearchMetrics.Builder.class);
}
// Construct using com.clarifai.grpc.api.AnnotationSearchMetrics.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
}
@java.lang.Override
public Builder clear() {
super.clear();
if (groundTruthBuilder_ == null) {
groundTruth_ = null;
} else {
groundTruth_ = null;
groundTruthBuilder_ = null;
}
if (searchToEvalBuilder_ == null) {
searchToEval_ = null;
} else {
searchToEval_ = null;
searchToEvalBuilder_ = null;
}
if (metricsBuilder_ == null) {
metrics_ = null;
} else {
metrics_ = null;
metricsBuilder_ = null;
}
if (dataBuilder_ == null) {
data_ = null;
} else {
data_ = null;
dataBuilder_ = null;
}
activeConceptCount_ = 0;
if (visibilityBuilder_ == null) {
visibility_ = null;
} else {
visibility_ = null;
visibilityBuilder_ = null;
}
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.clarifai.grpc.api.Resources.internal_static_clarifai_api_AnnotationSearchMetrics_descriptor;
}
@java.lang.Override
public com.clarifai.grpc.api.AnnotationSearchMetrics getDefaultInstanceForType() {
return com.clarifai.grpc.api.AnnotationSearchMetrics.getDefaultInstance();
}
@java.lang.Override
public com.clarifai.grpc.api.AnnotationSearchMetrics build() {
com.clarifai.grpc.api.AnnotationSearchMetrics result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.clarifai.grpc.api.AnnotationSearchMetrics buildPartial() {
com.clarifai.grpc.api.AnnotationSearchMetrics result = new com.clarifai.grpc.api.AnnotationSearchMetrics(this);
if (groundTruthBuilder_ == null) {
result.groundTruth_ = groundTruth_;
} else {
result.groundTruth_ = groundTruthBuilder_.build();
}
if (searchToEvalBuilder_ == null) {
result.searchToEval_ = searchToEval_;
} else {
result.searchToEval_ = searchToEvalBuilder_.build();
}
if (metricsBuilder_ == null) {
result.metrics_ = metrics_;
} else {
result.metrics_ = metricsBuilder_.build();
}
if (dataBuilder_ == null) {
result.data_ = data_;
} else {
result.data_ = dataBuilder_.build();
}
result.activeConceptCount_ = activeConceptCount_;
if (visibilityBuilder_ == null) {
result.visibility_ = visibility_;
} else {
result.visibility_ = visibilityBuilder_.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.AnnotationSearchMetrics) {
return mergeFrom((com.clarifai.grpc.api.AnnotationSearchMetrics)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.clarifai.grpc.api.AnnotationSearchMetrics other) {
if (other == com.clarifai.grpc.api.AnnotationSearchMetrics.getDefaultInstance()) return this;
if (other.hasGroundTruth()) {
mergeGroundTruth(other.getGroundTruth());
}
if (other.hasSearchToEval()) {
mergeSearchToEval(other.getSearchToEval());
}
if (other.hasMetrics()) {
mergeMetrics(other.getMetrics());
}
if (other.hasData()) {
mergeData(other.getData());
}
if (other.getActiveConceptCount() != 0) {
setActiveConceptCount(other.getActiveConceptCount());
}
if (other.hasVisibility()) {
mergeVisibility(other.getVisibility());
}
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.AnnotationSearchMetrics parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.clarifai.grpc.api.AnnotationSearchMetrics) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private com.clarifai.grpc.api.Search groundTruth_;
private com.google.protobuf.SingleFieldBuilderV3<
com.clarifai.grpc.api.Search, com.clarifai.grpc.api.Search.Builder, com.clarifai.grpc.api.SearchOrBuilder> groundTruthBuilder_;
/**
*
* The ground truth we are evaluating against
*
*
* .clarifai.api.Search ground_truth = 1;
* @return Whether the groundTruth field is set.
*/
public boolean hasGroundTruth() {
return groundTruthBuilder_ != null || groundTruth_ != null;
}
/**
*
* The ground truth we are evaluating against
*
*
* .clarifai.api.Search ground_truth = 1;
* @return The groundTruth.
*/
public com.clarifai.grpc.api.Search getGroundTruth() {
if (groundTruthBuilder_ == null) {
return groundTruth_ == null ? com.clarifai.grpc.api.Search.getDefaultInstance() : groundTruth_;
} else {
return groundTruthBuilder_.getMessage();
}
}
/**
*
* The ground truth we are evaluating against
*
*
* .clarifai.api.Search ground_truth = 1;
*/
public Builder setGroundTruth(com.clarifai.grpc.api.Search value) {
if (groundTruthBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
groundTruth_ = value;
onChanged();
} else {
groundTruthBuilder_.setMessage(value);
}
return this;
}
/**
*
* The ground truth we are evaluating against
*
*
* .clarifai.api.Search ground_truth = 1;
*/
public Builder setGroundTruth(
com.clarifai.grpc.api.Search.Builder builderForValue) {
if (groundTruthBuilder_ == null) {
groundTruth_ = builderForValue.build();
onChanged();
} else {
groundTruthBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* The ground truth we are evaluating against
*
*
* .clarifai.api.Search ground_truth = 1;
*/
public Builder mergeGroundTruth(com.clarifai.grpc.api.Search value) {
if (groundTruthBuilder_ == null) {
if (groundTruth_ != null) {
groundTruth_ =
com.clarifai.grpc.api.Search.newBuilder(groundTruth_).mergeFrom(value).buildPartial();
} else {
groundTruth_ = value;
}
onChanged();
} else {
groundTruthBuilder_.mergeFrom(value);
}
return this;
}
/**
*
* The ground truth we are evaluating against
*
*
* .clarifai.api.Search ground_truth = 1;
*/
public Builder clearGroundTruth() {
if (groundTruthBuilder_ == null) {
groundTruth_ = null;
onChanged();
} else {
groundTruth_ = null;
groundTruthBuilder_ = null;
}
return this;
}
/**
*
* The ground truth we are evaluating against
*
*
* .clarifai.api.Search ground_truth = 1;
*/
public com.clarifai.grpc.api.Search.Builder getGroundTruthBuilder() {
onChanged();
return getGroundTruthFieldBuilder().getBuilder();
}
/**
*
* The ground truth we are evaluating against
*
*
* .clarifai.api.Search ground_truth = 1;
*/
public com.clarifai.grpc.api.SearchOrBuilder getGroundTruthOrBuilder() {
if (groundTruthBuilder_ != null) {
return groundTruthBuilder_.getMessageOrBuilder();
} else {
return groundTruth_ == null ?
com.clarifai.grpc.api.Search.getDefaultInstance() : groundTruth_;
}
}
/**
*
* The ground truth we are evaluating against
*
*
* .clarifai.api.Search ground_truth = 1;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.clarifai.grpc.api.Search, com.clarifai.grpc.api.Search.Builder, com.clarifai.grpc.api.SearchOrBuilder>
getGroundTruthFieldBuilder() {
if (groundTruthBuilder_ == null) {
groundTruthBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.clarifai.grpc.api.Search, com.clarifai.grpc.api.Search.Builder, com.clarifai.grpc.api.SearchOrBuilder>(
getGroundTruth(),
getParentForChildren(),
isClean());
groundTruth_ = null;
}
return groundTruthBuilder_;
}
private com.clarifai.grpc.api.Search searchToEval_;
private com.google.protobuf.SingleFieldBuilderV3<
com.clarifai.grpc.api.Search, com.clarifai.grpc.api.Search.Builder, com.clarifai.grpc.api.SearchOrBuilder> searchToEvalBuilder_;
/**
*
* The set we are evaluating
*
*
* .clarifai.api.Search search_to_eval = 2;
* @return Whether the searchToEval field is set.
*/
public boolean hasSearchToEval() {
return searchToEvalBuilder_ != null || searchToEval_ != null;
}
/**
*
* The set we are evaluating
*
*
* .clarifai.api.Search search_to_eval = 2;
* @return The searchToEval.
*/
public com.clarifai.grpc.api.Search getSearchToEval() {
if (searchToEvalBuilder_ == null) {
return searchToEval_ == null ? com.clarifai.grpc.api.Search.getDefaultInstance() : searchToEval_;
} else {
return searchToEvalBuilder_.getMessage();
}
}
/**
*
* The set we are evaluating
*
*
* .clarifai.api.Search search_to_eval = 2;
*/
public Builder setSearchToEval(com.clarifai.grpc.api.Search value) {
if (searchToEvalBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
searchToEval_ = value;
onChanged();
} else {
searchToEvalBuilder_.setMessage(value);
}
return this;
}
/**
*
* The set we are evaluating
*
*
* .clarifai.api.Search search_to_eval = 2;
*/
public Builder setSearchToEval(
com.clarifai.grpc.api.Search.Builder builderForValue) {
if (searchToEvalBuilder_ == null) {
searchToEval_ = builderForValue.build();
onChanged();
} else {
searchToEvalBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* The set we are evaluating
*
*
* .clarifai.api.Search search_to_eval = 2;
*/
public Builder mergeSearchToEval(com.clarifai.grpc.api.Search value) {
if (searchToEvalBuilder_ == null) {
if (searchToEval_ != null) {
searchToEval_ =
com.clarifai.grpc.api.Search.newBuilder(searchToEval_).mergeFrom(value).buildPartial();
} else {
searchToEval_ = value;
}
onChanged();
} else {
searchToEvalBuilder_.mergeFrom(value);
}
return this;
}
/**
*
* The set we are evaluating
*
*
* .clarifai.api.Search search_to_eval = 2;
*/
public Builder clearSearchToEval() {
if (searchToEvalBuilder_ == null) {
searchToEval_ = null;
onChanged();
} else {
searchToEval_ = null;
searchToEvalBuilder_ = null;
}
return this;
}
/**
*
* The set we are evaluating
*
*
* .clarifai.api.Search search_to_eval = 2;
*/
public com.clarifai.grpc.api.Search.Builder getSearchToEvalBuilder() {
onChanged();
return getSearchToEvalFieldBuilder().getBuilder();
}
/**
*
* The set we are evaluating
*
*
* .clarifai.api.Search search_to_eval = 2;
*/
public com.clarifai.grpc.api.SearchOrBuilder getSearchToEvalOrBuilder() {
if (searchToEvalBuilder_ != null) {
return searchToEvalBuilder_.getMessageOrBuilder();
} else {
return searchToEval_ == null ?
com.clarifai.grpc.api.Search.getDefaultInstance() : searchToEval_;
}
}
/**
*
* The set we are evaluating
*
*
* .clarifai.api.Search search_to_eval = 2;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.clarifai.grpc.api.Search, com.clarifai.grpc.api.Search.Builder, com.clarifai.grpc.api.SearchOrBuilder>
getSearchToEvalFieldBuilder() {
if (searchToEvalBuilder_ == null) {
searchToEvalBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.clarifai.grpc.api.Search, com.clarifai.grpc.api.Search.Builder, com.clarifai.grpc.api.SearchOrBuilder>(
getSearchToEval(),
getParentForChildren(),
isClean());
searchToEval_ = null;
}
return searchToEvalBuilder_;
}
private com.clarifai.grpc.api.EvalMetrics metrics_;
private com.google.protobuf.SingleFieldBuilderV3<
com.clarifai.grpc.api.EvalMetrics, com.clarifai.grpc.api.EvalMetrics.Builder, com.clarifai.grpc.api.EvalMetricsOrBuilder> metricsBuilder_;
/**
*
* The metric result
*
*
* .clarifai.api.EvalMetrics metrics = 3;
* @return Whether the metrics field is set.
*/
public boolean hasMetrics() {
return metricsBuilder_ != null || metrics_ != null;
}
/**
*
* The metric result
*
*
* .clarifai.api.EvalMetrics metrics = 3;
* @return The metrics.
*/
public com.clarifai.grpc.api.EvalMetrics getMetrics() {
if (metricsBuilder_ == null) {
return metrics_ == null ? com.clarifai.grpc.api.EvalMetrics.getDefaultInstance() : metrics_;
} else {
return metricsBuilder_.getMessage();
}
}
/**
*
* The metric result
*
*
* .clarifai.api.EvalMetrics metrics = 3;
*/
public Builder setMetrics(com.clarifai.grpc.api.EvalMetrics value) {
if (metricsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
metrics_ = value;
onChanged();
} else {
metricsBuilder_.setMessage(value);
}
return this;
}
/**
*
* The metric result
*
*
* .clarifai.api.EvalMetrics metrics = 3;
*/
public Builder setMetrics(
com.clarifai.grpc.api.EvalMetrics.Builder builderForValue) {
if (metricsBuilder_ == null) {
metrics_ = builderForValue.build();
onChanged();
} else {
metricsBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* The metric result
*
*
* .clarifai.api.EvalMetrics metrics = 3;
*/
public Builder mergeMetrics(com.clarifai.grpc.api.EvalMetrics value) {
if (metricsBuilder_ == null) {
if (metrics_ != null) {
metrics_ =
com.clarifai.grpc.api.EvalMetrics.newBuilder(metrics_).mergeFrom(value).buildPartial();
} else {
metrics_ = value;
}
onChanged();
} else {
metricsBuilder_.mergeFrom(value);
}
return this;
}
/**
*
* The metric result
*
*
* .clarifai.api.EvalMetrics metrics = 3;
*/
public Builder clearMetrics() {
if (metricsBuilder_ == null) {
metrics_ = null;
onChanged();
} else {
metrics_ = null;
metricsBuilder_ = null;
}
return this;
}
/**
*
* The metric result
*
*
* .clarifai.api.EvalMetrics metrics = 3;
*/
public com.clarifai.grpc.api.EvalMetrics.Builder getMetricsBuilder() {
onChanged();
return getMetricsFieldBuilder().getBuilder();
}
/**
*
* The metric result
*
*
* .clarifai.api.EvalMetrics metrics = 3;
*/
public com.clarifai.grpc.api.EvalMetricsOrBuilder getMetricsOrBuilder() {
if (metricsBuilder_ != null) {
return metricsBuilder_.getMessageOrBuilder();
} else {
return metrics_ == null ?
com.clarifai.grpc.api.EvalMetrics.getDefaultInstance() : metrics_;
}
}
/**
*
* The metric result
*
*
* .clarifai.api.EvalMetrics metrics = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.clarifai.grpc.api.EvalMetrics, com.clarifai.grpc.api.EvalMetrics.Builder, com.clarifai.grpc.api.EvalMetricsOrBuilder>
getMetricsFieldBuilder() {
if (metricsBuilder_ == null) {
metricsBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.clarifai.grpc.api.EvalMetrics, com.clarifai.grpc.api.EvalMetrics.Builder, com.clarifai.grpc.api.EvalMetricsOrBuilder>(
getMetrics(),
getParentForChildren(),
isClean());
metrics_ = null;
}
return metricsBuilder_;
}
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_;
/**
*
* data is filled out with the concepts used for this evaluation
*
*
* .clarifai.api.Data data = 4;
* @return Whether the data field is set.
*/
public boolean hasData() {
return dataBuilder_ != null || data_ != null;
}
/**
*
* data is filled out with the concepts used for this evaluation
*
*
* .clarifai.api.Data data = 4;
* @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();
}
}
/**
*
* data is filled out with the concepts used for this evaluation
*
*
* .clarifai.api.Data data = 4;
*/
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;
}
/**
*
* data is filled out with the concepts used for this evaluation
*
*
* .clarifai.api.Data data = 4;
*/
public Builder setData(
com.clarifai.grpc.api.Data.Builder builderForValue) {
if (dataBuilder_ == null) {
data_ = builderForValue.build();
onChanged();
} else {
dataBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* data is filled out with the concepts used for this evaluation
*
*
* .clarifai.api.Data data = 4;
*/
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;
}
/**
*
* data is filled out with the concepts used for this evaluation
*
*
* .clarifai.api.Data data = 4;
*/
public Builder clearData() {
if (dataBuilder_ == null) {
data_ = null;
onChanged();
} else {
data_ = null;
dataBuilder_ = null;
}
return this;
}
/**
*
* data is filled out with the concepts used for this evaluation
*
*
* .clarifai.api.Data data = 4;
*/
public com.clarifai.grpc.api.Data.Builder getDataBuilder() {
onChanged();
return getDataFieldBuilder().getBuilder();
}
/**
*
* data is filled out with the concepts used for this evaluation
*
*
* .clarifai.api.Data data = 4;
*/
public com.clarifai.grpc.api.DataOrBuilder getDataOrBuilder() {
if (dataBuilder_ != null) {
return dataBuilder_.getMessageOrBuilder();
} else {
return data_ == null ?
com.clarifai.grpc.api.Data.getDefaultInstance() : data_;
}
}
/**
*
* data is filled out with the concepts used for this evaluation
*
*
* .clarifai.api.Data data = 4;
*/
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 int activeConceptCount_ ;
/**
*
* active_concept_count is the number of concepts for this evaluation
*
*
* uint32 active_concept_count = 5;
* @return The activeConceptCount.
*/
@java.lang.Override
public int getActiveConceptCount() {
return activeConceptCount_;
}
/**
*
* active_concept_count is the number of concepts for this evaluation
*
*
* uint32 active_concept_count = 5;
* @param value The activeConceptCount to set.
* @return This builder for chaining.
*/
public Builder setActiveConceptCount(int value) {
activeConceptCount_ = value;
onChanged();
return this;
}
/**
*
* active_concept_count is the number of concepts for this evaluation
*
*
* uint32 active_concept_count = 5;
* @return This builder for chaining.
*/
public Builder clearActiveConceptCount() {
activeConceptCount_ = 0;
onChanged();
return this;
}
private com.clarifai.grpc.api.Visibility visibility_;
private com.google.protobuf.SingleFieldBuilderV3<
com.clarifai.grpc.api.Visibility, com.clarifai.grpc.api.Visibility.Builder, com.clarifai.grpc.api.VisibilityOrBuilder> visibilityBuilder_;
/**
*
* The visibility field represents whether this message is privately/publicly visible.
* To be visible to the public the App that contains it AND the User that contains the App must
* also be publicly visible.
*
*
* .clarifai.api.Visibility visibility = 6;
* @return Whether the visibility field is set.
*/
public boolean hasVisibility() {
return visibilityBuilder_ != null || visibility_ != null;
}
/**
*
* The visibility field represents whether this message is privately/publicly visible.
* To be visible to the public the App that contains it AND the User that contains the App must
* also be publicly visible.
*
*
* .clarifai.api.Visibility visibility = 6;
* @return The visibility.
*/
public com.clarifai.grpc.api.Visibility getVisibility() {
if (visibilityBuilder_ == null) {
return visibility_ == null ? com.clarifai.grpc.api.Visibility.getDefaultInstance() : visibility_;
} else {
return visibilityBuilder_.getMessage();
}
}
/**
*
* The visibility field represents whether this message is privately/publicly visible.
* To be visible to the public the App that contains it AND the User that contains the App must
* also be publicly visible.
*
*
* .clarifai.api.Visibility visibility = 6;
*/
public Builder setVisibility(com.clarifai.grpc.api.Visibility value) {
if (visibilityBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
visibility_ = value;
onChanged();
} else {
visibilityBuilder_.setMessage(value);
}
return this;
}
/**
*
* The visibility field represents whether this message is privately/publicly visible.
* To be visible to the public the App that contains it AND the User that contains the App must
* also be publicly visible.
*
*
* .clarifai.api.Visibility visibility = 6;
*/
public Builder setVisibility(
com.clarifai.grpc.api.Visibility.Builder builderForValue) {
if (visibilityBuilder_ == null) {
visibility_ = builderForValue.build();
onChanged();
} else {
visibilityBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* The visibility field represents whether this message is privately/publicly visible.
* To be visible to the public the App that contains it AND the User that contains the App must
* also be publicly visible.
*
*
* .clarifai.api.Visibility visibility = 6;
*/
public Builder mergeVisibility(com.clarifai.grpc.api.Visibility value) {
if (visibilityBuilder_ == null) {
if (visibility_ != null) {
visibility_ =
com.clarifai.grpc.api.Visibility.newBuilder(visibility_).mergeFrom(value).buildPartial();
} else {
visibility_ = value;
}
onChanged();
} else {
visibilityBuilder_.mergeFrom(value);
}
return this;
}
/**
*
* The visibility field represents whether this message is privately/publicly visible.
* To be visible to the public the App that contains it AND the User that contains the App must
* also be publicly visible.
*
*
* .clarifai.api.Visibility visibility = 6;
*/
public Builder clearVisibility() {
if (visibilityBuilder_ == null) {
visibility_ = null;
onChanged();
} else {
visibility_ = null;
visibilityBuilder_ = null;
}
return this;
}
/**
*
* The visibility field represents whether this message is privately/publicly visible.
* To be visible to the public the App that contains it AND the User that contains the App must
* also be publicly visible.
*
*
* .clarifai.api.Visibility visibility = 6;
*/
public com.clarifai.grpc.api.Visibility.Builder getVisibilityBuilder() {
onChanged();
return getVisibilityFieldBuilder().getBuilder();
}
/**
*
* The visibility field represents whether this message is privately/publicly visible.
* To be visible to the public the App that contains it AND the User that contains the App must
* also be publicly visible.
*
*
* .clarifai.api.Visibility visibility = 6;
*/
public com.clarifai.grpc.api.VisibilityOrBuilder getVisibilityOrBuilder() {
if (visibilityBuilder_ != null) {
return visibilityBuilder_.getMessageOrBuilder();
} else {
return visibility_ == null ?
com.clarifai.grpc.api.Visibility.getDefaultInstance() : visibility_;
}
}
/**
*
* The visibility field represents whether this message is privately/publicly visible.
* To be visible to the public the App that contains it AND the User that contains the App must
* also be publicly visible.
*
*
* .clarifai.api.Visibility visibility = 6;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.clarifai.grpc.api.Visibility, com.clarifai.grpc.api.Visibility.Builder, com.clarifai.grpc.api.VisibilityOrBuilder>
getVisibilityFieldBuilder() {
if (visibilityBuilder_ == null) {
visibilityBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.clarifai.grpc.api.Visibility, com.clarifai.grpc.api.Visibility.Builder, com.clarifai.grpc.api.VisibilityOrBuilder>(
getVisibility(),
getParentForChildren(),
isClean());
visibility_ = null;
}
return visibilityBuilder_;
}
@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.AnnotationSearchMetrics)
}
// @@protoc_insertion_point(class_scope:clarifai.api.AnnotationSearchMetrics)
private static final com.clarifai.grpc.api.AnnotationSearchMetrics DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.clarifai.grpc.api.AnnotationSearchMetrics();
}
public static com.clarifai.grpc.api.AnnotationSearchMetrics getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public AnnotationSearchMetrics parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new AnnotationSearchMetrics(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.AnnotationSearchMetrics getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}