google-cloud-dlp-v2 0.21.0 → 0.23.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -24,6 +24,68 @@ module Google
24
24
  module DlpService
25
25
  # Path helper methods for the DlpService API.
26
26
  module Paths
27
+ ##
28
+ # Create a fully-qualified ColumnDataProfile resource string.
29
+ #
30
+ # @overload column_data_profile_path(organization:, location:, column_data_profile:)
31
+ # The resource will be in the following format:
32
+ #
33
+ # `organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}`
34
+ #
35
+ # @param organization [String]
36
+ # @param location [String]
37
+ # @param column_data_profile [String]
38
+ #
39
+ # @overload column_data_profile_path(project:, location:, column_data_profile:)
40
+ # The resource will be in the following format:
41
+ #
42
+ # `projects/{project}/locations/{location}/columnDataProfiles/{column_data_profile}`
43
+ #
44
+ # @param project [String]
45
+ # @param location [String]
46
+ # @param column_data_profile [String]
47
+ #
48
+ # @return [::String]
49
+ def column_data_profile_path **args
50
+ resources = {
51
+ "column_data_profile:location:organization" => (proc do |organization:, location:, column_data_profile:|
52
+ raise ::ArgumentError, "organization cannot contain /" if organization.to_s.include? "/"
53
+ raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
54
+
55
+ "organizations/#{organization}/locations/#{location}/columnDataProfiles/#{column_data_profile}"
56
+ end),
57
+ "column_data_profile:location:project" => (proc do |project:, location:, column_data_profile:|
58
+ raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
59
+ raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
60
+
61
+ "projects/#{project}/locations/#{location}/columnDataProfiles/#{column_data_profile}"
62
+ end)
63
+ }
64
+
65
+ resource = resources[args.keys.sort.join(":")]
66
+ raise ::ArgumentError, "no resource found for values #{args.keys}" if resource.nil?
67
+ resource.call(**args)
68
+ end
69
+
70
+ ##
71
+ # Create a fully-qualified Connection resource string.
72
+ #
73
+ # The resource will be in the following format:
74
+ #
75
+ # `projects/{project}/locations/{location}/connections/{connection}`
76
+ #
77
+ # @param project [String]
78
+ # @param location [String]
79
+ # @param connection [String]
80
+ #
81
+ # @return [::String]
82
+ def connection_path project:, location:, connection:
83
+ raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
84
+ raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
85
+
86
+ "projects/#{project}/locations/#{location}/connections/#{connection}"
87
+ end
88
+
27
89
  ##
28
90
  # Create a fully-qualified DeidentifyTemplate resource string.
29
91
  #
@@ -325,6 +387,49 @@ module Google
325
387
  "projects/#{project}"
326
388
  end
327
389
 
390
+ ##
391
+ # Create a fully-qualified ProjectDataProfile resource string.
392
+ #
393
+ # @overload project_data_profile_path(organization:, location:, project_data_profile:)
394
+ # The resource will be in the following format:
395
+ #
396
+ # `organizations/{organization}/locations/{location}/projectDataProfiles/{project_data_profile}`
397
+ #
398
+ # @param organization [String]
399
+ # @param location [String]
400
+ # @param project_data_profile [String]
401
+ #
402
+ # @overload project_data_profile_path(project:, location:, project_data_profile:)
403
+ # The resource will be in the following format:
404
+ #
405
+ # `projects/{project}/locations/{location}/projectDataProfiles/{project_data_profile}`
406
+ #
407
+ # @param project [String]
408
+ # @param location [String]
409
+ # @param project_data_profile [String]
410
+ #
411
+ # @return [::String]
412
+ def project_data_profile_path **args
413
+ resources = {
414
+ "location:organization:project_data_profile" => (proc do |organization:, location:, project_data_profile:|
415
+ raise ::ArgumentError, "organization cannot contain /" if organization.to_s.include? "/"
416
+ raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
417
+
418
+ "organizations/#{organization}/locations/#{location}/projectDataProfiles/#{project_data_profile}"
419
+ end),
420
+ "location:project:project_data_profile" => (proc do |project:, location:, project_data_profile:|
421
+ raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
422
+ raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
423
+
424
+ "projects/#{project}/locations/#{location}/projectDataProfiles/#{project_data_profile}"
425
+ end)
426
+ }
427
+
428
+ resource = resources[args.keys.sort.join(":")]
429
+ raise ::ArgumentError, "no resource found for values #{args.keys}" if resource.nil?
430
+ resource.call(**args)
431
+ end
432
+
328
433
  ##
329
434
  # Create a fully-qualified StoredInfoType resource string.
330
435
  #
@@ -394,6 +499,49 @@ module Google
394
499
  resource.call(**args)
395
500
  end
396
501
 
502
+ ##
503
+ # Create a fully-qualified TableDataProfile resource string.
504
+ #
505
+ # @overload table_data_profile_path(organization:, location:, table_data_profile:)
506
+ # The resource will be in the following format:
507
+ #
508
+ # `organizations/{organization}/locations/{location}/tableDataProfiles/{table_data_profile}`
509
+ #
510
+ # @param organization [String]
511
+ # @param location [String]
512
+ # @param table_data_profile [String]
513
+ #
514
+ # @overload table_data_profile_path(project:, location:, table_data_profile:)
515
+ # The resource will be in the following format:
516
+ #
517
+ # `projects/{project}/locations/{location}/tableDataProfiles/{table_data_profile}`
518
+ #
519
+ # @param project [String]
520
+ # @param location [String]
521
+ # @param table_data_profile [String]
522
+ #
523
+ # @return [::String]
524
+ def table_data_profile_path **args
525
+ resources = {
526
+ "location:organization:table_data_profile" => (proc do |organization:, location:, table_data_profile:|
527
+ raise ::ArgumentError, "organization cannot contain /" if organization.to_s.include? "/"
528
+ raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
529
+
530
+ "organizations/#{organization}/locations/#{location}/tableDataProfiles/#{table_data_profile}"
531
+ end),
532
+ "location:project:table_data_profile" => (proc do |project:, location:, table_data_profile:|
533
+ raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
534
+ raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
535
+
536
+ "projects/#{project}/locations/#{location}/tableDataProfiles/#{table_data_profile}"
537
+ end)
538
+ }
539
+
540
+ resource = resources[args.keys.sort.join(":")]
541
+ raise ::ArgumentError, "no resource found for values #{args.keys}" if resource.nil?
542
+ resource.call(**args)
543
+ end
544
+
397
545
  extend self
398
546
  end
399
547
  end