Data Loss Prevention V2 Client - Class DiscoveryConfig (1.12.0)

Reference documentation and code samples for the Data Loss Prevention V2 Client class DiscoveryConfig.

Configuration for discovery to scan resources for profile generation.

Only one discovery configuration may exist per organization, folder, or project. The generated data profiles are retained according to the data retention policy.

Generated from protobuf message google.privacy.dlp.v2.DiscoveryConfig

Namespace

Google \ Cloud \ Dlp \ V2

Methods

__construct

Constructor.

Parameters
NameDescription
data array

Optional. Data for populating the Message object.

↳ name string

Unique resource name for the DiscoveryConfig, assigned by the service when the DiscoveryConfig is created, for example projects/dlp-test-project/locations/global/discoveryConfigs/53234423.

↳ display_name string

Display name (max 100 chars)

↳ org_config Google\Cloud\Dlp\V2\DiscoveryConfig\OrgConfig

Only set when the parent is an org.

↳ inspect_templates array

Detection logic for profile generation. Not all template features are used by Discovery. FindingLimits, include_quote and exclude_info_types have no impact on Discovery. Multiple templates may be provided if there is data in multiple regions. At most one template must be specified per-region (including "global"). Each region is scanned using the applicable template. If no region-specific template is specified, but a "global" template is specified, it will be copied to that region and used instead. If no global or region-specific template is provided for a region with data, that region's data will not be scanned. For more information, see https://cloud.google.com/dlp/docs/data-profiles#data-residency.

↳ actions array<Google\Cloud\Dlp\V2\DataProfileAction>

Actions to execute at the completion of scanning.

↳ targets array<Google\Cloud\Dlp\V2\DiscoveryTarget>

Target to match against for determining what to scan and how frequently.

↳ errors array<Google\Cloud\Dlp\V2\Error>

Output only. A stream of errors encountered when the config was activated. Repeated errors may result in the config automatically being paused. Output only field. Will return the last 100 errors. Whenever the config is modified this list will be cleared.

↳ create_time Google\Protobuf\Timestamp

Output only. The creation timestamp of a DiscoveryConfig.

↳ update_time Google\Protobuf\Timestamp

Output only. The last update timestamp of a DiscoveryConfig.

↳ last_run_time Google\Protobuf\Timestamp

Output only. The timestamp of the last time this config was executed.

↳ status int

Required. A status for this configuration.

getName

Unique resource name for the DiscoveryConfig, assigned by the service when the DiscoveryConfig is created, for example projects/dlp-test-project/locations/global/discoveryConfigs/53234423.

Returns
TypeDescription
string

setName

Unique resource name for the DiscoveryConfig, assigned by the service when the DiscoveryConfig is created, for example projects/dlp-test-project/locations/global/discoveryConfigs/53234423.

Parameter
NameDescription
var string
Returns
TypeDescription
$this

getDisplayName

Display name (max 100 chars)

Returns
TypeDescription
string

setDisplayName

Display name (max 100 chars)

Parameter
NameDescription
var string
Returns
TypeDescription
$this

getOrgConfig

Only set when the parent is an org.

Returns
TypeDescription
Google\Cloud\Dlp\V2\DiscoveryConfig\OrgConfig|null

hasOrgConfig

clearOrgConfig

setOrgConfig

Only set when the parent is an org.

Parameter
NameDescription
var Google\Cloud\Dlp\V2\DiscoveryConfig\OrgConfig
Returns
TypeDescription
$this

getInspectTemplates

Detection logic for profile generation.

Not all template features are used by Discovery. FindingLimits, include_quote and exclude_info_types have no impact on Discovery. Multiple templates may be provided if there is data in multiple regions. At most one template must be specified per-region (including "global"). Each region is scanned using the applicable template. If no region-specific template is specified, but a "global" template is specified, it will be copied to that region and used instead. If no global or region-specific template is provided for a region with data, that region's data will not be scanned. For more information, see https://cloud.google.com/dlp/docs/data-profiles#data-residency.

Returns
TypeDescription
Google\Protobuf\Internal\RepeatedField

setInspectTemplates

Detection logic for profile generation.

Not all template features are used by Discovery. FindingLimits, include_quote and exclude_info_types have no impact on Discovery. Multiple templates may be provided if there is data in multiple regions. At most one template must be specified per-region (including "global"). Each region is scanned using the applicable template. If no region-specific template is specified, but a "global" template is specified, it will be copied to that region and used instead. If no global or region-specific template is provided for a region with data, that region's data will not be scanned. For more information, see https://cloud.google.com/dlp/docs/data-profiles#data-residency.

Parameter
NameDescription
var string[]
Returns
TypeDescription
$this

getActions

Actions to execute at the completion of scanning.

Returns
TypeDescription
Google\Protobuf\Internal\RepeatedField

setActions

Actions to execute at the completion of scanning.

Parameter
NameDescription
var array<Google\Cloud\Dlp\V2\DataProfileAction>
Returns
TypeDescription
$this

getTargets

Target to match against for determining what to scan and how frequently.

Returns
TypeDescription
Google\Protobuf\Internal\RepeatedField

setTargets

Target to match against for determining what to scan and how frequently.

Parameter
NameDescription
var array<Google\Cloud\Dlp\V2\DiscoveryTarget>
Returns
TypeDescription
$this

getErrors

Output only. A stream of errors encountered when the config was activated.

Repeated errors may result in the config automatically being paused. Output only field. Will return the last 100 errors. Whenever the config is modified this list will be cleared.

Returns
TypeDescription
Google\Protobuf\Internal\RepeatedField

setErrors

Output only. A stream of errors encountered when the config was activated.

Repeated errors may result in the config automatically being paused. Output only field. Will return the last 100 errors. Whenever the config is modified this list will be cleared.

Parameter
NameDescription
var array<Google\Cloud\Dlp\V2\Error>
Returns
TypeDescription
$this

getCreateTime

Output only. The creation timestamp of a DiscoveryConfig.

Returns
TypeDescription
Google\Protobuf\Timestamp|null

hasCreateTime

clearCreateTime

setCreateTime

Output only. The creation timestamp of a DiscoveryConfig.

Parameter
NameDescription
var Google\Protobuf\Timestamp
Returns
TypeDescription
$this

getUpdateTime

Output only. The last update timestamp of a DiscoveryConfig.

Returns
TypeDescription
Google\Protobuf\Timestamp|null

hasUpdateTime

clearUpdateTime

setUpdateTime

Output only. The last update timestamp of a DiscoveryConfig.

Parameter
NameDescription
var Google\Protobuf\Timestamp
Returns
TypeDescription
$this

getLastRunTime

Output only. The timestamp of the last time this config was executed.

Returns
TypeDescription
Google\Protobuf\Timestamp|null

hasLastRunTime

clearLastRunTime

setLastRunTime

Output only. The timestamp of the last time this config was executed.

Parameter
NameDescription
var Google\Protobuf\Timestamp
Returns
TypeDescription
$this

getStatus

Required. A status for this configuration.

Returns
TypeDescription
int

setStatus

Required. A status for this configuration.

Parameter
NameDescription
var int
Returns
TypeDescription
$this