Class: Google::Apis::DlpV2::GooglePrivacyDlpV2ContentPolicy

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/dlp_v2/classes.rb,
lib/google/apis/dlp_v2/representations.rb,
lib/google/apis/dlp_v2/representations.rb

Overview

A policy to apply to content based on its inspection findings.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GooglePrivacyDlpV2ContentPolicy

Returns a new instance of GooglePrivacyDlpV2ContentPolicy.



2219
2220
2221
# File 'lib/google/apis/dlp_v2/classes.rb', line 2219

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#create_timeString

Output only. The creation timestamp of a contentPolicy; output-only field. Corresponds to the JSON property createTime

Returns:

  • (String)


2150
2151
2152
# File 'lib/google/apis/dlp_v2/classes.rb', line 2150

def create_time
  @create_time
end

#default_actionGoogle::Apis::DlpV2::GooglePrivacyDlpV2PolicyAction

A possible action to take when applying a content policy. Corresponds to the JSON property defaultAction



2155
2156
2157
# File 'lib/google/apis/dlp_v2/classes.rb', line 2155

def default_action
  @default_action
end

#display_nameString

Optional. Display name (max 63 chars) Corresponds to the JSON property displayName

Returns:

  • (String)


2160
2161
2162
# File 'lib/google/apis/dlp_v2/classes.rb', line 2160

def display_name
  @display_name
end

#errorsArray<Google::Apis::DlpV2::GooglePrivacyDlpV2Error>

Output only. A stream of errors encountered when the policy was applied. Output only field. Will return the last 100 errors. Whenever the policy is modified this list will be cleared. Corresponds to the JSON property errors



2167
2168
2169
# File 'lib/google/apis/dlp_v2/classes.rb', line 2167

def errors
  @errors
end

#failed_to_scan_supported_file_typeGoogle::Apis::DlpV2::GooglePrivacyDlpV2PolicyAction

A possible action to take when applying a content policy. Corresponds to the JSON property failedToScanSupportedFileType



2172
2173
2174
# File 'lib/google/apis/dlp_v2/classes.rb', line 2172

def failed_to_scan_supported_file_type
  @failed_to_scan_supported_file_type
end

#input_too_largeGoogle::Apis::DlpV2::GooglePrivacyDlpV2PolicyAction

A possible action to take when applying a content policy. Corresponds to the JSON property inputTooLarge



2177
2178
2179
# File 'lib/google/apis/dlp_v2/classes.rb', line 2177

def input_too_large
  @input_too_large
end

#inspect_configGoogle::Apis::DlpV2::GooglePrivacyDlpV2InspectConfig

Configuration description of the scanning process. When used with redactContent only info_types and min_likelihood are currently used. Corresponds to the JSON property inspectConfig



2183
2184
2185
# File 'lib/google/apis/dlp_v2/classes.rb', line 2183

def inspect_config
  @inspect_config
end

#inspect_templateGoogle::Apis::DlpV2::GooglePrivacyDlpV2InspectTemplate

The inspectTemplate contains a configuration (set of types of sensitive data to be detected) to be used anywhere you otherwise would normally specify InspectConfig. See https://cloud.google.com/sensitive-data-protection/docs/ concepts-templates to learn more. Corresponds to the JSON property inspectTemplate



2191
2192
2193
# File 'lib/google/apis/dlp_v2/classes.rb', line 2191

def inspect_template
  @inspect_template
end

#logging_configsArray<Google::Apis::DlpV2::GooglePrivacyDlpV2LoggingConfig>

Optional. Log the actions taken by the content policy to external systems. Corresponds to the JSON property loggingConfigs



2196
2197
2198
# File 'lib/google/apis/dlp_v2/classes.rb', line 2196

def logging_configs
  @logging_configs
end

#nameString

Output only. Resource name of the policy. Corresponds to the JSON property name

Returns:

  • (String)


2201
2202
2203
# File 'lib/google/apis/dlp_v2/classes.rb', line 2201

def name
  @name
end

#rulesArray<Google::Apis::DlpV2::GooglePrivacyDlpV2PolicyRule>

Required. Policies to apply, based on the findings returned by inspection. The first rule to match applies. Corresponds to the JSON property rules



2207
2208
2209
# File 'lib/google/apis/dlp_v2/classes.rb', line 2207

def rules
  @rules
end

#unsupported_file_typeGoogle::Apis::DlpV2::GooglePrivacyDlpV2PolicyAction

A possible action to take when applying a content policy. Corresponds to the JSON property unsupportedFileType



2212
2213
2214
# File 'lib/google/apis/dlp_v2/classes.rb', line 2212

def unsupported_file_type
  @unsupported_file_type
end

#update_timeString

Output only. The last update timestamp of a contentPolicy; output-only field. Corresponds to the JSON property updateTime

Returns:

  • (String)


2217
2218
2219
# File 'lib/google/apis/dlp_v2/classes.rb', line 2217

def update_time
  @update_time
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
# File 'lib/google/apis/dlp_v2/classes.rb', line 2224

def update!(**args)
  @create_time = args[:create_time] if args.key?(:create_time)
  @default_action = args[:default_action] if args.key?(:default_action)
  @display_name = args[:display_name] if args.key?(:display_name)
  @errors = args[:errors] if args.key?(:errors)
  @failed_to_scan_supported_file_type = args[:failed_to_scan_supported_file_type] if args.key?(:failed_to_scan_supported_file_type)
  @input_too_large = args[:input_too_large] if args.key?(:input_too_large)
  @inspect_config = args[:inspect_config] if args.key?(:inspect_config)
  @inspect_template = args[:inspect_template] if args.key?(:inspect_template)
  @logging_configs = args[:logging_configs] if args.key?(:logging_configs)
  @name = args[:name] if args.key?(:name)
  @rules = args[:rules] if args.key?(:rules)
  @unsupported_file_type = args[:unsupported_file_type] if args.key?(:unsupported_file_type)
  @update_time = args[:update_time] if args.key?(:update_time)
end