Class ContentMetadata.Builder (3.103.0)

public static final class ContentMetadata.Builder extends GeneratedMessage.Builder<ContentMetadata.Builder> implements ContentMetadataOrBuilder

Metadata on content to be scanned.

Protobuf type google.privacy.dlp.v2.ContentMetadata

Static Methods

getDescriptor()

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

Methods

addAllFileLabels(Iterable<? extends FileLabel> values)

public ContentMetadata.Builder addAllFileLabels(Iterable<? extends FileLabel> values)

Optional. The file labels associated with the content.

repeated .google.privacy.dlp.v2.FileLabel file_labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
values Iterable<? extends com.google.privacy.dlp.v2.FileLabel>
Returns
Type Description
ContentMetadata.Builder

addAllProperties(Iterable<? extends KeyValueMetadataProperty> values)

public ContentMetadata.Builder addAllProperties(Iterable<? extends KeyValueMetadataProperty> values)

User provided key-value pairs of content metadata.

repeated .google.privacy.dlp.v2.KeyValueMetadataProperty properties = 2;

Parameter
Name Description
values Iterable<? extends com.google.privacy.dlp.v2.KeyValueMetadataProperty>
Returns
Type Description
ContentMetadata.Builder

addFileLabels(FileLabel value)

public ContentMetadata.Builder addFileLabels(FileLabel value)

Optional. The file labels associated with the content.

repeated .google.privacy.dlp.v2.FileLabel file_labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value FileLabel
Returns
Type Description
ContentMetadata.Builder

addFileLabels(FileLabel.Builder builderForValue)

public ContentMetadata.Builder addFileLabels(FileLabel.Builder builderForValue)

Optional. The file labels associated with the content.

repeated .google.privacy.dlp.v2.FileLabel file_labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
builderForValue FileLabel.Builder
Returns
Type Description
ContentMetadata.Builder

addFileLabels(int index, FileLabel value)

public ContentMetadata.Builder addFileLabels(int index, FileLabel value)

Optional. The file labels associated with the content.

repeated .google.privacy.dlp.v2.FileLabel file_labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameters
Name Description
index int
value FileLabel
Returns
Type Description
ContentMetadata.Builder

addFileLabels(int index, FileLabel.Builder builderForValue)

public ContentMetadata.Builder addFileLabels(int index, FileLabel.Builder builderForValue)

Optional. The file labels associated with the content.

repeated .google.privacy.dlp.v2.FileLabel file_labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameters
Name Description
index int
builderForValue FileLabel.Builder
Returns
Type Description
ContentMetadata.Builder

addFileLabelsBuilder()

public FileLabel.Builder addFileLabelsBuilder()

Optional. The file labels associated with the content.

repeated .google.privacy.dlp.v2.FileLabel file_labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
FileLabel.Builder

addFileLabelsBuilder(int index)

public FileLabel.Builder addFileLabelsBuilder(int index)

Optional. The file labels associated with the content.

repeated .google.privacy.dlp.v2.FileLabel file_labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
index int
Returns
Type Description
FileLabel.Builder

addProperties(KeyValueMetadataProperty value)

public ContentMetadata.Builder addProperties(KeyValueMetadataProperty value)

User provided key-value pairs of content metadata.

repeated .google.privacy.dlp.v2.KeyValueMetadataProperty properties = 2;

Parameter
Name Description
value KeyValueMetadataProperty
Returns
Type Description
ContentMetadata.Builder

addProperties(KeyValueMetadataProperty.Builder builderForValue)

public ContentMetadata.Builder addProperties(KeyValueMetadataProperty.Builder builderForValue)

User provided key-value pairs of content metadata.

repeated .google.privacy.dlp.v2.KeyValueMetadataProperty properties = 2;

Parameter
Name Description
builderForValue KeyValueMetadataProperty.Builder
Returns
Type Description
ContentMetadata.Builder

addProperties(int index, KeyValueMetadataProperty value)

public ContentMetadata.Builder addProperties(int index, KeyValueMetadataProperty value)

User provided key-value pairs of content metadata.

repeated .google.privacy.dlp.v2.KeyValueMetadataProperty properties = 2;

Parameters
Name Description
index int
value KeyValueMetadataProperty
Returns
Type Description
ContentMetadata.Builder

addProperties(int index, KeyValueMetadataProperty.Builder builderForValue)

public ContentMetadata.Builder addProperties(int index, KeyValueMetadataProperty.Builder builderForValue)

User provided key-value pairs of content metadata.

repeated .google.privacy.dlp.v2.KeyValueMetadataProperty properties = 2;

Parameters
Name Description
index int
builderForValue KeyValueMetadataProperty.Builder
Returns
Type Description
ContentMetadata.Builder

addPropertiesBuilder()

public KeyValueMetadataProperty.Builder addPropertiesBuilder()

User provided key-value pairs of content metadata.

repeated .google.privacy.dlp.v2.KeyValueMetadataProperty properties = 2;

Returns
Type Description
KeyValueMetadataProperty.Builder

addPropertiesBuilder(int index)

public KeyValueMetadataProperty.Builder addPropertiesBuilder(int index)

User provided key-value pairs of content metadata.

repeated .google.privacy.dlp.v2.KeyValueMetadataProperty properties = 2;

Parameter
Name Description
index int
Returns
Type Description
KeyValueMetadataProperty.Builder

build()

public ContentMetadata build()
Returns
Type Description
ContentMetadata

buildPartial()

public ContentMetadata buildPartial()
Returns
Type Description
ContentMetadata

clear()

public ContentMetadata.Builder clear()
Returns
Type Description
ContentMetadata.Builder
Overrides

clearFileLabels()

public ContentMetadata.Builder clearFileLabels()

Optional. The file labels associated with the content.

repeated .google.privacy.dlp.v2.FileLabel file_labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ContentMetadata.Builder

clearProperties()

public ContentMetadata.Builder clearProperties()

User provided key-value pairs of content metadata.

repeated .google.privacy.dlp.v2.KeyValueMetadataProperty properties = 2;

Returns
Type Description
ContentMetadata.Builder

getDefaultInstanceForType()

public ContentMetadata getDefaultInstanceForType()
Returns
Type Description
ContentMetadata

getDescriptorForType()

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

getFileLabels(int index)

public FileLabel getFileLabels(int index)

Optional. The file labels associated with the content.

repeated .google.privacy.dlp.v2.FileLabel file_labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
index int
Returns
Type Description
FileLabel

getFileLabelsBuilder(int index)

public FileLabel.Builder getFileLabelsBuilder(int index)

Optional. The file labels associated with the content.

repeated .google.privacy.dlp.v2.FileLabel file_labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
index int
Returns
Type Description
FileLabel.Builder

getFileLabelsBuilderList()

public List<FileLabel.Builder> getFileLabelsBuilderList()

Optional. The file labels associated with the content.

repeated .google.privacy.dlp.v2.FileLabel file_labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
List<Builder>

getFileLabelsCount()

public int getFileLabelsCount()

Optional. The file labels associated with the content.

repeated .google.privacy.dlp.v2.FileLabel file_labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
int

getFileLabelsList()

public List<FileLabel> getFileLabelsList()

Optional. The file labels associated with the content.

repeated .google.privacy.dlp.v2.FileLabel file_labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
List<FileLabel>

getFileLabelsOrBuilder(int index)

public FileLabelOrBuilder getFileLabelsOrBuilder(int index)

Optional. The file labels associated with the content.

repeated .google.privacy.dlp.v2.FileLabel file_labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
index int
Returns
Type Description
FileLabelOrBuilder

getFileLabelsOrBuilderList()

public List<? extends FileLabelOrBuilder> getFileLabelsOrBuilderList()

Optional. The file labels associated with the content.

repeated .google.privacy.dlp.v2.FileLabel file_labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
List<? extends com.google.privacy.dlp.v2.FileLabelOrBuilder>

getProperties(int index)

public KeyValueMetadataProperty getProperties(int index)

User provided key-value pairs of content metadata.

repeated .google.privacy.dlp.v2.KeyValueMetadataProperty properties = 2;

Parameter
Name Description
index int
Returns
Type Description
KeyValueMetadataProperty

getPropertiesBuilder(int index)

public KeyValueMetadataProperty.Builder getPropertiesBuilder(int index)

User provided key-value pairs of content metadata.

repeated .google.privacy.dlp.v2.KeyValueMetadataProperty properties = 2;

Parameter
Name Description
index int
Returns
Type Description
KeyValueMetadataProperty.Builder

getPropertiesBuilderList()

public List<KeyValueMetadataProperty.Builder> getPropertiesBuilderList()

User provided key-value pairs of content metadata.

repeated .google.privacy.dlp.v2.KeyValueMetadataProperty properties = 2;

Returns
Type Description
List<Builder>

getPropertiesCount()

public int getPropertiesCount()

User provided key-value pairs of content metadata.

repeated .google.privacy.dlp.v2.KeyValueMetadataProperty properties = 2;

Returns
Type Description
int

getPropertiesList()

public List<KeyValueMetadataProperty> getPropertiesList()

User provided key-value pairs of content metadata.

repeated .google.privacy.dlp.v2.KeyValueMetadataProperty properties = 2;

Returns
Type Description
List<KeyValueMetadataProperty>

getPropertiesOrBuilder(int index)

public KeyValueMetadataPropertyOrBuilder getPropertiesOrBuilder(int index)

User provided key-value pairs of content metadata.

repeated .google.privacy.dlp.v2.KeyValueMetadataProperty properties = 2;

Parameter
Name Description
index int
Returns
Type Description
KeyValueMetadataPropertyOrBuilder

getPropertiesOrBuilderList()

public List<? extends KeyValueMetadataPropertyOrBuilder> getPropertiesOrBuilderList()

User provided key-value pairs of content metadata.

repeated .google.privacy.dlp.v2.KeyValueMetadataProperty properties = 2;

Returns
Type Description
List<? extends com.google.privacy.dlp.v2.KeyValueMetadataPropertyOrBuilder>

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(ContentMetadata other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

removeFileLabels(int index)

public ContentMetadata.Builder removeFileLabels(int index)

Optional. The file labels associated with the content.

repeated .google.privacy.dlp.v2.FileLabel file_labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
index int
Returns
Type Description
ContentMetadata.Builder

removeProperties(int index)

public ContentMetadata.Builder removeProperties(int index)

User provided key-value pairs of content metadata.

repeated .google.privacy.dlp.v2.KeyValueMetadataProperty properties = 2;

Parameter
Name Description
index int
Returns
Type Description
ContentMetadata.Builder

setFileLabels(int index, FileLabel value)

public ContentMetadata.Builder setFileLabels(int index, FileLabel value)

Optional. The file labels associated with the content.

repeated .google.privacy.dlp.v2.FileLabel file_labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameters
Name Description
index int
value FileLabel
Returns
Type Description
ContentMetadata.Builder

setFileLabels(int index, FileLabel.Builder builderForValue)

public ContentMetadata.Builder setFileLabels(int index, FileLabel.Builder builderForValue)

Optional. The file labels associated with the content.

repeated .google.privacy.dlp.v2.FileLabel file_labels = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameters
Name Description
index int
builderForValue FileLabel.Builder
Returns
Type Description
ContentMetadata.Builder

setProperties(int index, KeyValueMetadataProperty value)

public ContentMetadata.Builder setProperties(int index, KeyValueMetadataProperty value)

User provided key-value pairs of content metadata.

repeated .google.privacy.dlp.v2.KeyValueMetadataProperty properties = 2;

Parameters
Name Description
index int
value KeyValueMetadataProperty
Returns
Type Description
ContentMetadata.Builder

setProperties(int index, KeyValueMetadataProperty.Builder builderForValue)

public ContentMetadata.Builder setProperties(int index, KeyValueMetadataProperty.Builder builderForValue)

User provided key-value pairs of content metadata.

repeated .google.privacy.dlp.v2.KeyValueMetadataProperty properties = 2;

Parameters
Name Description
index int
builderForValue KeyValueMetadataProperty.Builder
Returns
Type Description
ContentMetadata.Builder