Package com.google.cloud.vision.v1
Class AnnotateFileRequest.Builder
- java.lang.Object
-
- com.google.protobuf.AbstractMessageLite.Builder
-
- com.google.protobuf.AbstractMessage.Builder<BuilderT>
-
- com.google.protobuf.GeneratedMessageV3.Builder<AnnotateFileRequest.Builder>
-
- com.google.cloud.vision.v1.AnnotateFileRequest.Builder
-
- All Implemented Interfaces:
AnnotateFileRequestOrBuilder,com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Cloneable
- Enclosing class:
- AnnotateFileRequest
public static final class AnnotateFileRequest.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<AnnotateFileRequest.Builder> implements AnnotateFileRequestOrBuilder
A request to annotate one single file, e.g. a PDF, TIFF or GIF file.
Protobuf typegoogle.cloud.vision.v1.AnnotateFileRequest
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description AnnotateFileRequest.BuilderaddAllFeatures(Iterable<? extends Feature> values)Required.AnnotateFileRequest.BuilderaddAllPages(Iterable<? extends Integer> values)Pages of the file to perform image annotation.AnnotateFileRequest.BuilderaddFeatures(int index, Feature value)Required.AnnotateFileRequest.BuilderaddFeatures(int index, Feature.Builder builderForValue)Required.AnnotateFileRequest.BuilderaddFeatures(Feature value)Required.AnnotateFileRequest.BuilderaddFeatures(Feature.Builder builderForValue)Required.Feature.BuilderaddFeaturesBuilder()Required.Feature.BuilderaddFeaturesBuilder(int index)Required.AnnotateFileRequest.BuilderaddPages(int value)Pages of the file to perform image annotation.AnnotateFileRequest.BuilderaddRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)AnnotateFileRequestbuild()AnnotateFileRequestbuildPartial()AnnotateFileRequest.Builderclear()AnnotateFileRequest.BuilderclearFeatures()Required.AnnotateFileRequest.BuilderclearField(com.google.protobuf.Descriptors.FieldDescriptor field)AnnotateFileRequest.BuilderclearImageContext()Additional context that may accompany the image(s) in the file.AnnotateFileRequest.BuilderclearInputConfig()Required.AnnotateFileRequest.BuilderclearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)AnnotateFileRequest.BuilderclearPages()Pages of the file to perform image annotation.AnnotateFileRequest.Builderclone()AnnotateFileRequestgetDefaultInstanceForType()static com.google.protobuf.Descriptors.DescriptorgetDescriptor()com.google.protobuf.Descriptors.DescriptorgetDescriptorForType()FeaturegetFeatures(int index)Required.Feature.BuildergetFeaturesBuilder(int index)Required.List<Feature.Builder>getFeaturesBuilderList()Required.intgetFeaturesCount()Required.List<Feature>getFeaturesList()Required.FeatureOrBuildergetFeaturesOrBuilder(int index)Required.List<? extends FeatureOrBuilder>getFeaturesOrBuilderList()Required.ImageContextgetImageContext()Additional context that may accompany the image(s) in the file.ImageContext.BuildergetImageContextBuilder()Additional context that may accompany the image(s) in the file.ImageContextOrBuildergetImageContextOrBuilder()Additional context that may accompany the image(s) in the file.InputConfiggetInputConfig()Required.InputConfig.BuildergetInputConfigBuilder()Required.InputConfigOrBuildergetInputConfigOrBuilder()Required.intgetPages(int index)Pages of the file to perform image annotation.intgetPagesCount()Pages of the file to perform image annotation.List<Integer>getPagesList()Pages of the file to perform image annotation.booleanhasImageContext()Additional context that may accompany the image(s) in the file.booleanhasInputConfig()Required.protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTableinternalGetFieldAccessorTable()booleanisInitialized()AnnotateFileRequest.BuildermergeFrom(AnnotateFileRequest other)AnnotateFileRequest.BuildermergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)AnnotateFileRequest.BuildermergeFrom(com.google.protobuf.Message other)AnnotateFileRequest.BuildermergeImageContext(ImageContext value)Additional context that may accompany the image(s) in the file.AnnotateFileRequest.BuildermergeInputConfig(InputConfig value)Required.AnnotateFileRequest.BuildermergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)AnnotateFileRequest.BuilderremoveFeatures(int index)Required.AnnotateFileRequest.BuildersetFeatures(int index, Feature value)Required.AnnotateFileRequest.BuildersetFeatures(int index, Feature.Builder builderForValue)Required.AnnotateFileRequest.BuildersetField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)AnnotateFileRequest.BuildersetImageContext(ImageContext value)Additional context that may accompany the image(s) in the file.AnnotateFileRequest.BuildersetImageContext(ImageContext.Builder builderForValue)Additional context that may accompany the image(s) in the file.AnnotateFileRequest.BuildersetInputConfig(InputConfig value)Required.AnnotateFileRequest.BuildersetInputConfig(InputConfig.Builder builderForValue)Required.AnnotateFileRequest.BuildersetPages(int index, int value)Pages of the file to perform image annotation.AnnotateFileRequest.BuildersetRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)AnnotateFileRequest.BuildersetUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)-
Methods inherited from class com.google.protobuf.GeneratedMessageV3.Builder
getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMutableMapField, isClean, markClean, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setUnknownFieldSetBuilder, setUnknownFieldsProto3
-
Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toString
-
Methods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageException
-
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
-
-
-
Method Detail
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
-
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessageV3.Builder<AnnotateFileRequest.Builder>
-
clear
public AnnotateFileRequest.Builder clear()
- Specified by:
clearin interfacecom.google.protobuf.Message.Builder- Specified by:
clearin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clearin classcom.google.protobuf.GeneratedMessageV3.Builder<AnnotateFileRequest.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.Message.Builder- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.MessageOrBuilder- Overrides:
getDescriptorForTypein classcom.google.protobuf.GeneratedMessageV3.Builder<AnnotateFileRequest.Builder>
-
getDefaultInstanceForType
public AnnotateFileRequest getDefaultInstanceForType()
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
build
public AnnotateFileRequest build()
- Specified by:
buildin interfacecom.google.protobuf.Message.Builder- Specified by:
buildin interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
public AnnotateFileRequest buildPartial()
- Specified by:
buildPartialin interfacecom.google.protobuf.Message.Builder- Specified by:
buildPartialin interfacecom.google.protobuf.MessageLite.Builder
-
clone
public AnnotateFileRequest.Builder clone()
- Specified by:
clonein interfacecom.google.protobuf.Message.Builder- Specified by:
clonein interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clonein classcom.google.protobuf.GeneratedMessageV3.Builder<AnnotateFileRequest.Builder>
-
setField
public AnnotateFileRequest.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
- Specified by:
setFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
setFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<AnnotateFileRequest.Builder>
-
clearField
public AnnotateFileRequest.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
- Specified by:
clearFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
clearFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<AnnotateFileRequest.Builder>
-
clearOneof
public AnnotateFileRequest.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
- Specified by:
clearOneofin interfacecom.google.protobuf.Message.Builder- Overrides:
clearOneofin classcom.google.protobuf.GeneratedMessageV3.Builder<AnnotateFileRequest.Builder>
-
setRepeatedField
public AnnotateFileRequest.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
- Specified by:
setRepeatedFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
setRepeatedFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<AnnotateFileRequest.Builder>
-
addRepeatedField
public AnnotateFileRequest.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
- Specified by:
addRepeatedFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
addRepeatedFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<AnnotateFileRequest.Builder>
-
mergeFrom
public AnnotateFileRequest.Builder mergeFrom(com.google.protobuf.Message other)
- Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<AnnotateFileRequest.Builder>
-
mergeFrom
public AnnotateFileRequest.Builder mergeFrom(AnnotateFileRequest other)
-
isInitialized
public final boolean isInitialized()
- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessageV3.Builder<AnnotateFileRequest.Builder>
-
mergeFrom
public AnnotateFileRequest.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
- Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Specified by:
mergeFromin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<AnnotateFileRequest.Builder>- Throws:
IOException
-
hasInputConfig
public boolean hasInputConfig()
Required. Information about the input file.
.google.cloud.vision.v1.InputConfig input_config = 1;- Specified by:
hasInputConfigin interfaceAnnotateFileRequestOrBuilder- Returns:
- Whether the inputConfig field is set.
-
getInputConfig
public InputConfig getInputConfig()
Required. Information about the input file.
.google.cloud.vision.v1.InputConfig input_config = 1;- Specified by:
getInputConfigin interfaceAnnotateFileRequestOrBuilder- Returns:
- The inputConfig.
-
setInputConfig
public AnnotateFileRequest.Builder setInputConfig(InputConfig value)
Required. Information about the input file.
.google.cloud.vision.v1.InputConfig input_config = 1;
-
setInputConfig
public AnnotateFileRequest.Builder setInputConfig(InputConfig.Builder builderForValue)
Required. Information about the input file.
.google.cloud.vision.v1.InputConfig input_config = 1;
-
mergeInputConfig
public AnnotateFileRequest.Builder mergeInputConfig(InputConfig value)
Required. Information about the input file.
.google.cloud.vision.v1.InputConfig input_config = 1;
-
clearInputConfig
public AnnotateFileRequest.Builder clearInputConfig()
Required. Information about the input file.
.google.cloud.vision.v1.InputConfig input_config = 1;
-
getInputConfigBuilder
public InputConfig.Builder getInputConfigBuilder()
Required. Information about the input file.
.google.cloud.vision.v1.InputConfig input_config = 1;
-
getInputConfigOrBuilder
public InputConfigOrBuilder getInputConfigOrBuilder()
Required. Information about the input file.
.google.cloud.vision.v1.InputConfig input_config = 1;- Specified by:
getInputConfigOrBuilderin interfaceAnnotateFileRequestOrBuilder
-
getFeaturesList
public List<Feature> getFeaturesList()
Required. Requested features.
repeated .google.cloud.vision.v1.Feature features = 2;- Specified by:
getFeaturesListin interfaceAnnotateFileRequestOrBuilder
-
getFeaturesCount
public int getFeaturesCount()
Required. Requested features.
repeated .google.cloud.vision.v1.Feature features = 2;- Specified by:
getFeaturesCountin interfaceAnnotateFileRequestOrBuilder
-
getFeatures
public Feature getFeatures(int index)
Required. Requested features.
repeated .google.cloud.vision.v1.Feature features = 2;- Specified by:
getFeaturesin interfaceAnnotateFileRequestOrBuilder
-
setFeatures
public AnnotateFileRequest.Builder setFeatures(int index, Feature value)
Required. Requested features.
repeated .google.cloud.vision.v1.Feature features = 2;
-
setFeatures
public AnnotateFileRequest.Builder setFeatures(int index, Feature.Builder builderForValue)
Required. Requested features.
repeated .google.cloud.vision.v1.Feature features = 2;
-
addFeatures
public AnnotateFileRequest.Builder addFeatures(Feature value)
Required. Requested features.
repeated .google.cloud.vision.v1.Feature features = 2;
-
addFeatures
public AnnotateFileRequest.Builder addFeatures(int index, Feature value)
Required. Requested features.
repeated .google.cloud.vision.v1.Feature features = 2;
-
addFeatures
public AnnotateFileRequest.Builder addFeatures(Feature.Builder builderForValue)
Required. Requested features.
repeated .google.cloud.vision.v1.Feature features = 2;
-
addFeatures
public AnnotateFileRequest.Builder addFeatures(int index, Feature.Builder builderForValue)
Required. Requested features.
repeated .google.cloud.vision.v1.Feature features = 2;
-
addAllFeatures
public AnnotateFileRequest.Builder addAllFeatures(Iterable<? extends Feature> values)
Required. Requested features.
repeated .google.cloud.vision.v1.Feature features = 2;
-
clearFeatures
public AnnotateFileRequest.Builder clearFeatures()
Required. Requested features.
repeated .google.cloud.vision.v1.Feature features = 2;
-
removeFeatures
public AnnotateFileRequest.Builder removeFeatures(int index)
Required. Requested features.
repeated .google.cloud.vision.v1.Feature features = 2;
-
getFeaturesBuilder
public Feature.Builder getFeaturesBuilder(int index)
Required. Requested features.
repeated .google.cloud.vision.v1.Feature features = 2;
-
getFeaturesOrBuilder
public FeatureOrBuilder getFeaturesOrBuilder(int index)
Required. Requested features.
repeated .google.cloud.vision.v1.Feature features = 2;- Specified by:
getFeaturesOrBuilderin interfaceAnnotateFileRequestOrBuilder
-
getFeaturesOrBuilderList
public List<? extends FeatureOrBuilder> getFeaturesOrBuilderList()
Required. Requested features.
repeated .google.cloud.vision.v1.Feature features = 2;- Specified by:
getFeaturesOrBuilderListin interfaceAnnotateFileRequestOrBuilder
-
addFeaturesBuilder
public Feature.Builder addFeaturesBuilder()
Required. Requested features.
repeated .google.cloud.vision.v1.Feature features = 2;
-
addFeaturesBuilder
public Feature.Builder addFeaturesBuilder(int index)
Required. Requested features.
repeated .google.cloud.vision.v1.Feature features = 2;
-
getFeaturesBuilderList
public List<Feature.Builder> getFeaturesBuilderList()
Required. Requested features.
repeated .google.cloud.vision.v1.Feature features = 2;
-
hasImageContext
public boolean hasImageContext()
Additional context that may accompany the image(s) in the file.
.google.cloud.vision.v1.ImageContext image_context = 3;- Specified by:
hasImageContextin interfaceAnnotateFileRequestOrBuilder- Returns:
- Whether the imageContext field is set.
-
getImageContext
public ImageContext getImageContext()
Additional context that may accompany the image(s) in the file.
.google.cloud.vision.v1.ImageContext image_context = 3;- Specified by:
getImageContextin interfaceAnnotateFileRequestOrBuilder- Returns:
- The imageContext.
-
setImageContext
public AnnotateFileRequest.Builder setImageContext(ImageContext value)
Additional context that may accompany the image(s) in the file.
.google.cloud.vision.v1.ImageContext image_context = 3;
-
setImageContext
public AnnotateFileRequest.Builder setImageContext(ImageContext.Builder builderForValue)
Additional context that may accompany the image(s) in the file.
.google.cloud.vision.v1.ImageContext image_context = 3;
-
mergeImageContext
public AnnotateFileRequest.Builder mergeImageContext(ImageContext value)
Additional context that may accompany the image(s) in the file.
.google.cloud.vision.v1.ImageContext image_context = 3;
-
clearImageContext
public AnnotateFileRequest.Builder clearImageContext()
Additional context that may accompany the image(s) in the file.
.google.cloud.vision.v1.ImageContext image_context = 3;
-
getImageContextBuilder
public ImageContext.Builder getImageContextBuilder()
Additional context that may accompany the image(s) in the file.
.google.cloud.vision.v1.ImageContext image_context = 3;
-
getImageContextOrBuilder
public ImageContextOrBuilder getImageContextOrBuilder()
Additional context that may accompany the image(s) in the file.
.google.cloud.vision.v1.ImageContext image_context = 3;- Specified by:
getImageContextOrBuilderin interfaceAnnotateFileRequestOrBuilder
-
getPagesList
public List<Integer> getPagesList()
Pages of the file to perform image annotation. Pages starts from 1, we assume the first page of the file is page 1. At most 5 pages are supported per request. Pages can be negative. Page 1 means the first page. Page 2 means the second page. Page -1 means the last page. Page -2 means the second to the last page. If the file is GIF instead of PDF or TIFF, page refers to GIF frames. If this field is empty, by default the service performs image annotation for the first 5 pages of the file.
repeated int32 pages = 4;- Specified by:
getPagesListin interfaceAnnotateFileRequestOrBuilder- Returns:
- A list containing the pages.
-
getPagesCount
public int getPagesCount()
Pages of the file to perform image annotation. Pages starts from 1, we assume the first page of the file is page 1. At most 5 pages are supported per request. Pages can be negative. Page 1 means the first page. Page 2 means the second page. Page -1 means the last page. Page -2 means the second to the last page. If the file is GIF instead of PDF or TIFF, page refers to GIF frames. If this field is empty, by default the service performs image annotation for the first 5 pages of the file.
repeated int32 pages = 4;- Specified by:
getPagesCountin interfaceAnnotateFileRequestOrBuilder- Returns:
- The count of pages.
-
getPages
public int getPages(int index)
Pages of the file to perform image annotation. Pages starts from 1, we assume the first page of the file is page 1. At most 5 pages are supported per request. Pages can be negative. Page 1 means the first page. Page 2 means the second page. Page -1 means the last page. Page -2 means the second to the last page. If the file is GIF instead of PDF or TIFF, page refers to GIF frames. If this field is empty, by default the service performs image annotation for the first 5 pages of the file.
repeated int32 pages = 4;- Specified by:
getPagesin interfaceAnnotateFileRequestOrBuilder- Parameters:
index- The index of the element to return.- Returns:
- The pages at the given index.
-
setPages
public AnnotateFileRequest.Builder setPages(int index, int value)
Pages of the file to perform image annotation. Pages starts from 1, we assume the first page of the file is page 1. At most 5 pages are supported per request. Pages can be negative. Page 1 means the first page. Page 2 means the second page. Page -1 means the last page. Page -2 means the second to the last page. If the file is GIF instead of PDF or TIFF, page refers to GIF frames. If this field is empty, by default the service performs image annotation for the first 5 pages of the file.
repeated int32 pages = 4;- Parameters:
index- The index to set the value at.value- The pages to set.- Returns:
- This builder for chaining.
-
addPages
public AnnotateFileRequest.Builder addPages(int value)
Pages of the file to perform image annotation. Pages starts from 1, we assume the first page of the file is page 1. At most 5 pages are supported per request. Pages can be negative. Page 1 means the first page. Page 2 means the second page. Page -1 means the last page. Page -2 means the second to the last page. If the file is GIF instead of PDF or TIFF, page refers to GIF frames. If this field is empty, by default the service performs image annotation for the first 5 pages of the file.
repeated int32 pages = 4;- Parameters:
value- The pages to add.- Returns:
- This builder for chaining.
-
addAllPages
public AnnotateFileRequest.Builder addAllPages(Iterable<? extends Integer> values)
Pages of the file to perform image annotation. Pages starts from 1, we assume the first page of the file is page 1. At most 5 pages are supported per request. Pages can be negative. Page 1 means the first page. Page 2 means the second page. Page -1 means the last page. Page -2 means the second to the last page. If the file is GIF instead of PDF or TIFF, page refers to GIF frames. If this field is empty, by default the service performs image annotation for the first 5 pages of the file.
repeated int32 pages = 4;- Parameters:
values- The pages to add.- Returns:
- This builder for chaining.
-
clearPages
public AnnotateFileRequest.Builder clearPages()
Pages of the file to perform image annotation. Pages starts from 1, we assume the first page of the file is page 1. At most 5 pages are supported per request. Pages can be negative. Page 1 means the first page. Page 2 means the second page. Page -1 means the last page. Page -2 means the second to the last page. If the file is GIF instead of PDF or TIFF, page refers to GIF frames. If this field is empty, by default the service performs image annotation for the first 5 pages of the file.
repeated int32 pages = 4;- Returns:
- This builder for chaining.
-
setUnknownFields
public final AnnotateFileRequest.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
- Specified by:
setUnknownFieldsin interfacecom.google.protobuf.Message.Builder- Overrides:
setUnknownFieldsin classcom.google.protobuf.GeneratedMessageV3.Builder<AnnotateFileRequest.Builder>
-
mergeUnknownFields
public final AnnotateFileRequest.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
- Specified by:
mergeUnknownFieldsin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeUnknownFieldsin classcom.google.protobuf.GeneratedMessageV3.Builder<AnnotateFileRequest.Builder>
-
-