Class RedactImageRequest.ImageRedactionConfig.Builder (3.51.0)

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

Configuration for determining how redaction of images should occur.

Protobuf type google.privacy.dlp.v2.RedactImageRequest.ImageRedactionConfig

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public RedactImageRequest.ImageRedactionConfig.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder
Overrides

build()

public RedactImageRequest.ImageRedactionConfig build()
Returns
Type Description
RedactImageRequest.ImageRedactionConfig

buildPartial()

public RedactImageRequest.ImageRedactionConfig buildPartial()
Returns
Type Description
RedactImageRequest.ImageRedactionConfig

clear()

public RedactImageRequest.ImageRedactionConfig.Builder clear()
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder
Overrides

clearField(Descriptors.FieldDescriptor field)

public RedactImageRequest.ImageRedactionConfig.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder
Overrides

clearInfoType()

public RedactImageRequest.ImageRedactionConfig.Builder clearInfoType()

Only one per info_type should be provided per request. If not specified, and redact_all_text is false, the DLP API will redact all text that it matches against all info_types that are found, but not specified in another ImageRedactionConfig.

.google.privacy.dlp.v2.InfoType info_type = 1;

Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder

clearOneof(Descriptors.OneofDescriptor oneof)

public RedactImageRequest.ImageRedactionConfig.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder
Overrides

clearRedactAllText()

public RedactImageRequest.ImageRedactionConfig.Builder clearRedactAllText()

If true, all text found in the image, regardless whether it matches an info_type, is redacted. Only one should be provided.

bool redact_all_text = 2;

Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder

This builder for chaining.

clearRedactionColor()

public RedactImageRequest.ImageRedactionConfig.Builder clearRedactionColor()

The color to use when redacting content from an image. If not specified, the default is black.

.google.privacy.dlp.v2.Color redaction_color = 3;

Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder

clearTarget()

public RedactImageRequest.ImageRedactionConfig.Builder clearTarget()
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder

clone()

public RedactImageRequest.ImageRedactionConfig.Builder clone()
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder
Overrides

getDefaultInstanceForType()

public RedactImageRequest.ImageRedactionConfig getDefaultInstanceForType()
Returns
Type Description
RedactImageRequest.ImageRedactionConfig

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getInfoType()

public InfoType getInfoType()

Only one per info_type should be provided per request. If not specified, and redact_all_text is false, the DLP API will redact all text that it matches against all info_types that are found, but not specified in another ImageRedactionConfig.

.google.privacy.dlp.v2.InfoType info_type = 1;

Returns
Type Description
InfoType

The infoType.

getInfoTypeBuilder()

public InfoType.Builder getInfoTypeBuilder()

Only one per info_type should be provided per request. If not specified, and redact_all_text is false, the DLP API will redact all text that it matches against all info_types that are found, but not specified in another ImageRedactionConfig.

.google.privacy.dlp.v2.InfoType info_type = 1;

Returns
Type Description
InfoType.Builder

getInfoTypeOrBuilder()

public InfoTypeOrBuilder getInfoTypeOrBuilder()

Only one per info_type should be provided per request. If not specified, and redact_all_text is false, the DLP API will redact all text that it matches against all info_types that are found, but not specified in another ImageRedactionConfig.

.google.privacy.dlp.v2.InfoType info_type = 1;

Returns
Type Description
InfoTypeOrBuilder

getRedactAllText()

public boolean getRedactAllText()

If true, all text found in the image, regardless whether it matches an info_type, is redacted. Only one should be provided.

bool redact_all_text = 2;

Returns
Type Description
boolean

The redactAllText.

getRedactionColor()

public Color getRedactionColor()

The color to use when redacting content from an image. If not specified, the default is black.

.google.privacy.dlp.v2.Color redaction_color = 3;

Returns
Type Description
Color

The redactionColor.

getRedactionColorBuilder()

public Color.Builder getRedactionColorBuilder()

The color to use when redacting content from an image. If not specified, the default is black.

.google.privacy.dlp.v2.Color redaction_color = 3;

Returns
Type Description
Color.Builder

getRedactionColorOrBuilder()

public ColorOrBuilder getRedactionColorOrBuilder()

The color to use when redacting content from an image. If not specified, the default is black.

.google.privacy.dlp.v2.Color redaction_color = 3;

Returns
Type Description
ColorOrBuilder

getTargetCase()

public RedactImageRequest.ImageRedactionConfig.TargetCase getTargetCase()
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.TargetCase

hasInfoType()

public boolean hasInfoType()

Only one per info_type should be provided per request. If not specified, and redact_all_text is false, the DLP API will redact all text that it matches against all info_types that are found, but not specified in another ImageRedactionConfig.

.google.privacy.dlp.v2.InfoType info_type = 1;

Returns
Type Description
boolean

Whether the infoType field is set.

hasRedactAllText()

public boolean hasRedactAllText()

If true, all text found in the image, regardless whether it matches an info_type, is redacted. Only one should be provided.

bool redact_all_text = 2;

Returns
Type Description
boolean

Whether the redactAllText field is set.

hasRedactionColor()

public boolean hasRedactionColor()

The color to use when redacting content from an image. If not specified, the default is black.

.google.privacy.dlp.v2.Color redaction_color = 3;

Returns
Type Description
boolean

Whether the redactionColor field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(RedactImageRequest.ImageRedactionConfig other)

public RedactImageRequest.ImageRedactionConfig.Builder mergeFrom(RedactImageRequest.ImageRedactionConfig other)
Parameter
Name Description
other RedactImageRequest.ImageRedactionConfig
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public RedactImageRequest.ImageRedactionConfig.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public RedactImageRequest.ImageRedactionConfig.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder
Overrides

mergeInfoType(InfoType value)

public RedactImageRequest.ImageRedactionConfig.Builder mergeInfoType(InfoType value)

Only one per info_type should be provided per request. If not specified, and redact_all_text is false, the DLP API will redact all text that it matches against all info_types that are found, but not specified in another ImageRedactionConfig.

.google.privacy.dlp.v2.InfoType info_type = 1;

Parameter
Name Description
value InfoType
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder

mergeRedactionColor(Color value)

public RedactImageRequest.ImageRedactionConfig.Builder mergeRedactionColor(Color value)

The color to use when redacting content from an image. If not specified, the default is black.

.google.privacy.dlp.v2.Color redaction_color = 3;

Parameter
Name Description
value Color
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

public final RedactImageRequest.ImageRedactionConfig.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder
Overrides

setField(Descriptors.FieldDescriptor field, Object value)

public RedactImageRequest.ImageRedactionConfig.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder
Overrides

setInfoType(InfoType value)

public RedactImageRequest.ImageRedactionConfig.Builder setInfoType(InfoType value)

Only one per info_type should be provided per request. If not specified, and redact_all_text is false, the DLP API will redact all text that it matches against all info_types that are found, but not specified in another ImageRedactionConfig.

.google.privacy.dlp.v2.InfoType info_type = 1;

Parameter
Name Description
value InfoType
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder

setInfoType(InfoType.Builder builderForValue)

public RedactImageRequest.ImageRedactionConfig.Builder setInfoType(InfoType.Builder builderForValue)

Only one per info_type should be provided per request. If not specified, and redact_all_text is false, the DLP API will redact all text that it matches against all info_types that are found, but not specified in another ImageRedactionConfig.

.google.privacy.dlp.v2.InfoType info_type = 1;

Parameter
Name Description
builderForValue InfoType.Builder
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder

setRedactAllText(boolean value)

public RedactImageRequest.ImageRedactionConfig.Builder setRedactAllText(boolean value)

If true, all text found in the image, regardless whether it matches an info_type, is redacted. Only one should be provided.

bool redact_all_text = 2;

Parameter
Name Description
value boolean

The redactAllText to set.

Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder

This builder for chaining.

setRedactionColor(Color value)

public RedactImageRequest.ImageRedactionConfig.Builder setRedactionColor(Color value)

The color to use when redacting content from an image. If not specified, the default is black.

.google.privacy.dlp.v2.Color redaction_color = 3;

Parameter
Name Description
value Color
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder

setRedactionColor(Color.Builder builderForValue)

public RedactImageRequest.ImageRedactionConfig.Builder setRedactionColor(Color.Builder builderForValue)

The color to use when redacting content from an image. If not specified, the default is black.

.google.privacy.dlp.v2.Color redaction_color = 3;

Parameter
Name Description
builderForValue Color.Builder
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder

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

public RedactImageRequest.ImageRedactionConfig.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final RedactImageRequest.ImageRedactionConfig.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
RedactImageRequest.ImageRedactionConfig.Builder
Overrides