Class RedactImageRequest.Builder (3.9.0)

public static final class RedactImageRequest.Builder extends GeneratedMessageV3.Builder<RedactImageRequest.Builder> implements RedactImageRequestOrBuilder

Request to search for potentially sensitive info in an image and redact it by covering it with a colored rectangle.

Protobuf type google.privacy.dlp.v2.RedactImageRequest

com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder()
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownLengthDelimitedField(int,com.google.protobuf.ByteString)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownVarintField(int,int)
com.google.protobuf.GeneratedMessageV3.Builder.parseUnknownField(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite,int)
com.google.protobuf.GeneratedMessageV3.Builder.setUnknownFieldSetBuilder(com.google.protobuf.UnknownFieldSet.Builder)

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addAllImageRedactionConfigs(Iterable<? extends RedactImageRequest.ImageRedactionConfig> values)

public RedactImageRequest.Builder addAllImageRedactionConfigs(Iterable<? extends RedactImageRequest.ImageRedactionConfig> values)

The configuration for specifying what content to redact from images.

repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5;

Parameter
NameDescription
valuesIterable<? extends com.google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig>
Returns

addImageRedactionConfigs(RedactImageRequest.ImageRedactionConfig value)

public RedactImageRequest.Builder addImageRedactionConfigs(RedactImageRequest.ImageRedactionConfig value)

The configuration for specifying what content to redact from images.

repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5;

Parameter Returns

addImageRedactionConfigs(RedactImageRequest.ImageRedactionConfig.Builder builderForValue)

public RedactImageRequest.Builder addImageRedactionConfigs(RedactImageRequest.ImageRedactionConfig.Builder builderForValue)

The configuration for specifying what content to redact from images.

repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5;

Parameter Returns

addImageRedactionConfigs(int index, RedactImageRequest.ImageRedactionConfig value)

public RedactImageRequest.Builder addImageRedactionConfigs(int index, RedactImageRequest.ImageRedactionConfig value)

The configuration for specifying what content to redact from images.

repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5;

Parameters Returns

addImageRedactionConfigs(int index, RedactImageRequest.ImageRedactionConfig.Builder builderForValue)

public RedactImageRequest.Builder addImageRedactionConfigs(int index, RedactImageRequest.ImageRedactionConfig.Builder builderForValue)

The configuration for specifying what content to redact from images.

repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5;

Parameters
NameDescription
indexint
builderForValueRedactImageRequest.ImageRedactionConfig.Builder
Returns

addImageRedactionConfigsBuilder()

public RedactImageRequest.ImageRedactionConfig.Builder addImageRedactionConfigsBuilder()

The configuration for specifying what content to redact from images.

repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5;

Returns

addImageRedactionConfigsBuilder(int index)

public RedactImageRequest.ImageRedactionConfig.Builder addImageRedactionConfigsBuilder(int index)

The configuration for specifying what content to redact from images.

repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5;

Parameter
NameDescription
indexint
Returns

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public RedactImageRequest.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns Overrides

build()

public RedactImageRequest build()
Returns
TypeDescription
RedactImageRequest

buildPartial()

public RedactImageRequest buildPartial()
Returns
TypeDescription
RedactImageRequest

clear()

public RedactImageRequest.Builder clear()
Returns Overrides

clearByteItem()

public RedactImageRequest.Builder clearByteItem()

The content must be PNG, JPEG, SVG or BMP.

.google.privacy.dlp.v2.ByteContentItem byte_item = 7;

Returns

clearField(Descriptors.FieldDescriptor field)

public RedactImageRequest.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns Overrides

clearImageRedactionConfigs()

public RedactImageRequest.Builder clearImageRedactionConfigs()

The configuration for specifying what content to redact from images.

repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5;

Returns

clearIncludeFindings()

public RedactImageRequest.Builder clearIncludeFindings()

Whether the response should include findings along with the redacted image.

bool include_findings = 6;

Returns
TypeDescription
RedactImageRequest.Builder

This builder for chaining.

clearInspectConfig()

public RedactImageRequest.Builder clearInspectConfig()

Configuration for the inspector.

.google.privacy.dlp.v2.InspectConfig inspect_config = 2;

Returns

clearLocationId()

public RedactImageRequest.Builder clearLocationId()

Deprecated. This field has no effect.

string location_id = 8;

Returns
TypeDescription
RedactImageRequest.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public RedactImageRequest.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns Overrides

clearParent()

public RedactImageRequest.Builder clearParent()

Parent resource name. The format of this value varies depending on whether you have specified a processing location:

  • Projects scope, location specified:<br/> projects/<var>PROJECT_ID</var>/locations/<var>LOCATION_ID</var>
  • Projects scope, no location specified (defaults to global):<br/> projects/<var>PROJECT_ID</var> The following example parent string specifies a parent project with the identifier example-project, and specifies the europe-west3 location for processing data: parent=projects/example-project/locations/europe-west3

string parent = 1 [(.google.api.resource_reference) = { ... }

Returns
TypeDescription
RedactImageRequest.Builder

This builder for chaining.

clone()

public RedactImageRequest.Builder clone()
Returns Overrides

getByteItem()

public ByteContentItem getByteItem()

The content must be PNG, JPEG, SVG or BMP.

.google.privacy.dlp.v2.ByteContentItem byte_item = 7;

Returns
TypeDescription
ByteContentItem

The byteItem.

getByteItemBuilder()

public ByteContentItem.Builder getByteItemBuilder()

The content must be PNG, JPEG, SVG or BMP.

.google.privacy.dlp.v2.ByteContentItem byte_item = 7;

Returns

getByteItemOrBuilder()

public ByteContentItemOrBuilder getByteItemOrBuilder()

The content must be PNG, JPEG, SVG or BMP.

.google.privacy.dlp.v2.ByteContentItem byte_item = 7;

Returns

getDefaultInstanceForType()

public RedactImageRequest getDefaultInstanceForType()
Returns
TypeDescription
RedactImageRequest

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getImageRedactionConfigs(int index)

public RedactImageRequest.ImageRedactionConfig getImageRedactionConfigs(int index)

The configuration for specifying what content to redact from images.

repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5;

Parameter
NameDescription
indexint
Returns

getImageRedactionConfigsBuilder(int index)

public RedactImageRequest.ImageRedactionConfig.Builder getImageRedactionConfigsBuilder(int index)

The configuration for specifying what content to redact from images.

repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5;

Parameter
NameDescription
indexint
Returns

getImageRedactionConfigsBuilderList()

public List<RedactImageRequest.ImageRedactionConfig.Builder> getImageRedactionConfigsBuilderList()

The configuration for specifying what content to redact from images.

repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5;

Returns
TypeDescription
List<Builder>

getImageRedactionConfigsCount()

public int getImageRedactionConfigsCount()

The configuration for specifying what content to redact from images.

repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5;

Returns
TypeDescription
int

getImageRedactionConfigsList()

public List<RedactImageRequest.ImageRedactionConfig> getImageRedactionConfigsList()

The configuration for specifying what content to redact from images.

repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5;

Returns
TypeDescription
List<ImageRedactionConfig>

getImageRedactionConfigsOrBuilder(int index)

public RedactImageRequest.ImageRedactionConfigOrBuilder getImageRedactionConfigsOrBuilder(int index)

The configuration for specifying what content to redact from images.

repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5;

Parameter
NameDescription
indexint
Returns

getImageRedactionConfigsOrBuilderList()

public List<? extends RedactImageRequest.ImageRedactionConfigOrBuilder> getImageRedactionConfigsOrBuilderList()

The configuration for specifying what content to redact from images.

repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5;

Returns
TypeDescription
List<? extends com.google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfigOrBuilder>

getIncludeFindings()

public boolean getIncludeFindings()

Whether the response should include findings along with the redacted image.

bool include_findings = 6;

Returns
TypeDescription
boolean

The includeFindings.

getInspectConfig()

public InspectConfig getInspectConfig()

Configuration for the inspector.

.google.privacy.dlp.v2.InspectConfig inspect_config = 2;

Returns
TypeDescription
InspectConfig

The inspectConfig.

getInspectConfigBuilder()

public InspectConfig.Builder getInspectConfigBuilder()

Configuration for the inspector.

.google.privacy.dlp.v2.InspectConfig inspect_config = 2;

Returns
TypeDescription
InspectConfig.Builder

getInspectConfigOrBuilder()

public InspectConfigOrBuilder getInspectConfigOrBuilder()

Configuration for the inspector.

.google.privacy.dlp.v2.InspectConfig inspect_config = 2;

Returns
TypeDescription
InspectConfigOrBuilder

getLocationId()

public String getLocationId()

Deprecated. This field has no effect.

string location_id = 8;

Returns
TypeDescription
String

The locationId.

getLocationIdBytes()

public ByteString getLocationIdBytes()

Deprecated. This field has no effect.

string location_id = 8;

Returns
TypeDescription
ByteString

The bytes for locationId.

getParent()

public String getParent()

Parent resource name. The format of this value varies depending on whether you have specified a processing location:

  • Projects scope, location specified:<br/> projects/<var>PROJECT_ID</var>/locations/<var>LOCATION_ID</var>
  • Projects scope, no location specified (defaults to global):<br/> projects/<var>PROJECT_ID</var> The following example parent string specifies a parent project with the identifier example-project, and specifies the europe-west3 location for processing data: parent=projects/example-project/locations/europe-west3

string parent = 1 [(.google.api.resource_reference) = { ... }

Returns
TypeDescription
String

The parent.

getParentBytes()

public ByteString getParentBytes()

Parent resource name. The format of this value varies depending on whether you have specified a processing location:

  • Projects scope, location specified:<br/> projects/<var>PROJECT_ID</var>/locations/<var>LOCATION_ID</var>
  • Projects scope, no location specified (defaults to global):<br/> projects/<var>PROJECT_ID</var> The following example parent string specifies a parent project with the identifier example-project, and specifies the europe-west3 location for processing data: parent=projects/example-project/locations/europe-west3

string parent = 1 [(.google.api.resource_reference) = { ... }

Returns
TypeDescription
ByteString

The bytes for parent.

hasByteItem()

public boolean hasByteItem()

The content must be PNG, JPEG, SVG or BMP.

.google.privacy.dlp.v2.ByteContentItem byte_item = 7;

Returns
TypeDescription
boolean

Whether the byteItem field is set.

hasInspectConfig()

public boolean hasInspectConfig()

Configuration for the inspector.

.google.privacy.dlp.v2.InspectConfig inspect_config = 2;

Returns
TypeDescription
boolean

Whether the inspectConfig field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeByteItem(ByteContentItem value)

public RedactImageRequest.Builder mergeByteItem(ByteContentItem value)

The content must be PNG, JPEG, SVG or BMP.

.google.privacy.dlp.v2.ByteContentItem byte_item = 7;

Parameter
NameDescription
valueByteContentItem
Returns

mergeFrom(RedactImageRequest other)

public RedactImageRequest.Builder mergeFrom(RedactImageRequest other)
Parameter
NameDescription
otherRedactImageRequest
Returns

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public RedactImageRequest.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns Overrides Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public RedactImageRequest.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns Overrides

mergeInspectConfig(InspectConfig value)

public RedactImageRequest.Builder mergeInspectConfig(InspectConfig value)

Configuration for the inspector.

.google.privacy.dlp.v2.InspectConfig inspect_config = 2;

Parameter
NameDescription
valueInspectConfig
Returns

mergeUnknownFields(UnknownFieldSet unknownFields)

public final RedactImageRequest.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns Overrides

removeImageRedactionConfigs(int index)

public RedactImageRequest.Builder removeImageRedactionConfigs(int index)

The configuration for specifying what content to redact from images.

repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5;

Parameter
NameDescription
indexint
Returns

setByteItem(ByteContentItem value)

public RedactImageRequest.Builder setByteItem(ByteContentItem value)

The content must be PNG, JPEG, SVG or BMP.

.google.privacy.dlp.v2.ByteContentItem byte_item = 7;

Parameter
NameDescription
valueByteContentItem
Returns

setByteItem(ByteContentItem.Builder builderForValue)

public RedactImageRequest.Builder setByteItem(ByteContentItem.Builder builderForValue)

The content must be PNG, JPEG, SVG or BMP.

.google.privacy.dlp.v2.ByteContentItem byte_item = 7;

Parameter
NameDescription
builderForValueByteContentItem.Builder
Returns

setField(Descriptors.FieldDescriptor field, Object value)

public RedactImageRequest.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns Overrides

setImageRedactionConfigs(int index, RedactImageRequest.ImageRedactionConfig value)

public RedactImageRequest.Builder setImageRedactionConfigs(int index, RedactImageRequest.ImageRedactionConfig value)

The configuration for specifying what content to redact from images.

repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5;

Parameters Returns

setImageRedactionConfigs(int index, RedactImageRequest.ImageRedactionConfig.Builder builderForValue)

public RedactImageRequest.Builder setImageRedactionConfigs(int index, RedactImageRequest.ImageRedactionConfig.Builder builderForValue)

The configuration for specifying what content to redact from images.

repeated .google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig image_redaction_configs = 5;

Parameters
NameDescription
indexint
builderForValueRedactImageRequest.ImageRedactionConfig.Builder
Returns

setIncludeFindings(boolean value)

public RedactImageRequest.Builder setIncludeFindings(boolean value)

Whether the response should include findings along with the redacted image.

bool include_findings = 6;

Parameter
NameDescription
valueboolean

The includeFindings to set.

Returns
TypeDescription
RedactImageRequest.Builder

This builder for chaining.

setInspectConfig(InspectConfig value)

public RedactImageRequest.Builder setInspectConfig(InspectConfig value)

Configuration for the inspector.

.google.privacy.dlp.v2.InspectConfig inspect_config = 2;

Parameter
NameDescription
valueInspectConfig
Returns

setInspectConfig(InspectConfig.Builder builderForValue)

public RedactImageRequest.Builder setInspectConfig(InspectConfig.Builder builderForValue)

Configuration for the inspector.

.google.privacy.dlp.v2.InspectConfig inspect_config = 2;

Parameter
NameDescription
builderForValueInspectConfig.Builder
Returns

setLocationId(String value)

public RedactImageRequest.Builder setLocationId(String value)

Deprecated. This field has no effect.

string location_id = 8;

Parameter
NameDescription
valueString

The locationId to set.

Returns
TypeDescription
RedactImageRequest.Builder

This builder for chaining.

setLocationIdBytes(ByteString value)

public RedactImageRequest.Builder setLocationIdBytes(ByteString value)

Deprecated. This field has no effect.

string location_id = 8;

Parameter
NameDescription
valueByteString

The bytes for locationId to set.

Returns
TypeDescription
RedactImageRequest.Builder

This builder for chaining.

setParent(String value)

public RedactImageRequest.Builder setParent(String value)

Parent resource name. The format of this value varies depending on whether you have specified a processing location:

  • Projects scope, location specified:<br/> projects/<var>PROJECT_ID</var>/locations/<var>LOCATION_ID</var>
  • Projects scope, no location specified (defaults to global):<br/> projects/<var>PROJECT_ID</var> The following example parent string specifies a parent project with the identifier example-project, and specifies the europe-west3 location for processing data: parent=projects/example-project/locations/europe-west3

string parent = 1 [(.google.api.resource_reference) = { ... }

Parameter
NameDescription
valueString

The parent to set.

Returns
TypeDescription
RedactImageRequest.Builder

This builder for chaining.

setParentBytes(ByteString value)

public RedactImageRequest.Builder setParentBytes(ByteString value)

Parent resource name. The format of this value varies depending on whether you have specified a processing location:

  • Projects scope, location specified:<br/> projects/<var>PROJECT_ID</var>/locations/<var>LOCATION_ID</var>
  • Projects scope, no location specified (defaults to global):<br/> projects/<var>PROJECT_ID</var> The following example parent string specifies a parent project with the identifier example-project, and specifies the europe-west3 location for processing data: parent=projects/example-project/locations/europe-west3

string parent = 1 [(.google.api.resource_reference) = { ... }

Parameter
NameDescription
valueByteString

The bytes for parent to set.

Returns
TypeDescription
RedactImageRequest.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public RedactImageRequest.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final RedactImageRequest.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns Overrides