/** * * * <pre> * Key-value pairs that can be attached to a product. At query time, * constraints can be specified based on the product_labels. * Note that integer values can be provided as strings, e.g. "1199". Only * strings with integer values can match a range-based restriction which is * to be supported soon. * Multiple values can be assigned to the same key. One product may have up to * 100 product_labels. * </pre> * * <code>repeated .google.cloud.vision.v1.Product.KeyValue product_labels = 5;</code> */ public com.google.cloud.vision.v1.Product.KeyValue.Builder addProductLabelsBuilder() { return getProductLabelsFieldBuilder() .addBuilder(com.google.cloud.vision.v1.Product.KeyValue.getDefaultInstance()); } /**
/** * * * <pre> * Key-value pairs that can be attached to a product. At query time, * constraints can be specified based on the product_labels. * Note that integer values can be provided as strings, e.g. "1199". Only * strings with integer values can match a range-based restriction which is * to be supported soon. * Multiple values can be assigned to the same key. One product may have up to * 100 product_labels. * </pre> * * <code>repeated .google.cloud.vision.v1.Product.KeyValue product_labels = 5;</code> */ public com.google.cloud.vision.v1.Product.KeyValue.Builder addProductLabelsBuilder(int index) { return getProductLabelsFieldBuilder() .addBuilder(index, com.google.cloud.vision.v1.Product.KeyValue.getDefaultInstance()); } /**
public Builder mergeFrom(com.google.cloud.vision.v1.Product.KeyValue other) { if (other == com.google.cloud.vision.v1.Product.KeyValue.getDefaultInstance()) return this; if (!other.getKey().isEmpty()) { key_ = other.key_; onChanged(); } if (!other.getValue().isEmpty()) { value_ = other.value_; onChanged(); } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; }
/** * * * <pre> * Key-value pairs that can be attached to a product. At query time, * constraints can be specified based on the product_labels. * Note that integer values can be provided as strings, e.g. "1199". Only * strings with integer values can match a range-based restriction which is * to be supported soon. * Multiple values can be assigned to the same key. One product may have up to * 100 product_labels. * </pre> * * <code>repeated .google.cloud.vision.v1.Product.KeyValue product_labels = 5;</code> */ public com.google.cloud.vision.v1.Product.KeyValue.Builder addProductLabelsBuilder(int index) { return getProductLabelsFieldBuilder() .addBuilder(index, com.google.cloud.vision.v1.Product.KeyValue.getDefaultInstance()); } /**
/** * * * <pre> * Key-value pairs that can be attached to a product. At query time, * constraints can be specified based on the product_labels. * Note that integer values can be provided as strings, e.g. "1199". Only * strings with integer values can match a range-based restriction which is * to be supported soon. * Multiple values can be assigned to the same key. One product may have up to * 100 product_labels. * </pre> * * <code>repeated .google.cloud.vision.v1.Product.KeyValue product_labels = 5;</code> */ public com.google.cloud.vision.v1.Product.KeyValue.Builder addProductLabelsBuilder() { return getProductLabelsFieldBuilder() .addBuilder(com.google.cloud.vision.v1.Product.KeyValue.getDefaultInstance()); } /**
/** * * * <pre> * The key of the label attached to the product. Cannot be empty and cannot * exceed 128 bytes. * </pre> * * <code>string key = 1;</code> */ public Builder clearKey() { key_ = getDefaultInstance().getKey(); onChanged(); return this; } /**
/** * * * <pre> * The value of the label attached to the product. Cannot be empty and * cannot exceed 128 bytes. * </pre> * * <code>string value = 2;</code> */ public Builder clearValue() { value_ = getDefaultInstance().getValue(); onChanged(); return this; } /**
public Builder mergeFrom(com.google.cloud.vision.v1.Product.KeyValue other) { if (other == com.google.cloud.vision.v1.Product.KeyValue.getDefaultInstance()) return this; if (!other.getKey().isEmpty()) { key_ = other.key_; onChanged(); } if (!other.getValue().isEmpty()) { value_ = other.value_; onChanged(); } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; }
@java.lang.Override public com.google.cloud.vision.v1.Product.KeyValue getDefaultInstanceForType() { return com.google.cloud.vision.v1.Product.KeyValue.getDefaultInstance(); }
/** * * * <pre> * The value of the label attached to the product. Cannot be empty and * cannot exceed 128 bytes. * </pre> * * <code>string value = 2;</code> */ public Builder clearValue() { value_ = getDefaultInstance().getValue(); onChanged(); return this; } /**
/** * * * <pre> * The key of the label attached to the product. Cannot be empty and cannot * exceed 128 bytes. * </pre> * * <code>string key = 1;</code> */ public Builder clearKey() { key_ = getDefaultInstance().getKey(); onChanged(); return this; } /**
@java.lang.Override public com.google.cloud.vision.v1.Product.KeyValue getDefaultInstanceForType() { return com.google.cloud.vision.v1.Product.KeyValue.getDefaultInstance(); }