google-cloud-storage-control-v2 1.13.0 → 1.14.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.
- checksums.yaml +4 -4
- data/lib/google/cloud/storage/control/v2/rest.rb +1 -1
- data/lib/google/cloud/storage/control/v2/storage_control/client.rb +129 -20
- data/lib/google/cloud/storage/control/v2/storage_control/credentials.rb +1 -1
- data/lib/google/cloud/storage/control/v2/storage_control/operations.rb +1 -1
- data/lib/google/cloud/storage/control/v2/storage_control/paths.rb +20 -1
- data/lib/google/cloud/storage/control/v2/storage_control/rest/client.rb +100 -1
- data/lib/google/cloud/storage/control/v2/storage_control/rest/operations.rb +3 -3
- data/lib/google/cloud/storage/control/v2/storage_control/rest/service_stub.rb +66 -5
- data/lib/google/cloud/storage/control/v2/storage_control/rest.rb +1 -1
- data/lib/google/cloud/storage/control/v2/storage_control.rb +1 -1
- data/lib/google/cloud/storage/control/v2/version.rb +1 -1
- data/lib/google/cloud/storage/control/v2.rb +1 -1
- data/lib/google/storage/control/v2/storage_control_pb.rb +6 -1
- data/lib/google/storage/control/v2/storage_control_services_pb.rb +11 -1
- data/lib/google-cloud-storage-control-v2.rb +1 -1
- data/proto_docs/google/api/client.rb +1 -1
- data/proto_docs/google/api/field_behavior.rb +1 -1
- data/proto_docs/google/api/field_info.rb +1 -1
- data/proto_docs/google/api/launch_stage.rb +1 -1
- data/proto_docs/google/api/resource.rb +1 -1
- data/proto_docs/google/api/routing.rb +1 -1
- data/proto_docs/google/iam/v1/iam_policy.rb +1 -1
- data/proto_docs/google/iam/v1/options.rb +1 -1
- data/proto_docs/google/iam/v1/policy.rb +1 -1
- data/proto_docs/google/longrunning/operations.rb +1 -1
- data/proto_docs/google/protobuf/any.rb +1 -1
- data/proto_docs/google/protobuf/duration.rb +1 -1
- data/proto_docs/google/protobuf/empty.rb +1 -1
- data/proto_docs/google/protobuf/field_mask.rb +1 -1
- data/proto_docs/google/protobuf/timestamp.rb +8 -7
- data/proto_docs/google/rpc/status.rb +1 -1
- data/proto_docs/google/storage/control/v2/storage_control.rb +67 -1
- data/proto_docs/google/type/expr.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 58bf1b67f35d9d1c769b02eabbbd571ec5ece48d7377aef04a73260c6757e8b2
|
|
4
|
+
data.tar.gz: 1ed0b11fc6ff82e333eb6275231c6c6d2e611db3e995ad82999bff2dfa96f8c6
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 4e1dfe9caf69a7bbe769aec8884f7e761b4ee8ba440b8f3b71bfc00b9b76a628b5eace73bb8b72ebfb0179e67537bb4d7d428fc8c1942300a4668deb2f3bfea7
|
|
7
|
+
data.tar.gz: 9741346dfaf8d8ea9d205ec6586abe458ff16b671adf4f2aef27d78b15a8cb64adf4789619c05fe219266cd64ab68d0aff8d52c9ae4e2f5a601139bbb2a9d531
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
# Copyright
|
|
3
|
+
# Copyright 2026 Google LLC
|
|
4
4
|
#
|
|
5
5
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
6
|
# you may not use this file except in compliance with the License.
|
|
@@ -509,7 +509,7 @@ module Google
|
|
|
509
509
|
|
|
510
510
|
header_params = {}
|
|
511
511
|
if request.name
|
|
512
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(
|
|
512
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(?:/(?<__wildcard__>.*))?$}.match request.name
|
|
513
513
|
if regex_match
|
|
514
514
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
515
515
|
end
|
|
@@ -608,7 +608,7 @@ module Google
|
|
|
608
608
|
|
|
609
609
|
header_params = {}
|
|
610
610
|
if request.name
|
|
611
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(
|
|
611
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(?:/(?<__wildcard__>.*))?$}.match request.name
|
|
612
612
|
if regex_match
|
|
613
613
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
614
614
|
end
|
|
@@ -838,7 +838,7 @@ module Google
|
|
|
838
838
|
|
|
839
839
|
header_params = {}
|
|
840
840
|
if request.name
|
|
841
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(
|
|
841
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(?:/(?<__wildcard__>.*))?$}.match request.name
|
|
842
842
|
if regex_match
|
|
843
843
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
844
844
|
end
|
|
@@ -947,7 +947,7 @@ module Google
|
|
|
947
947
|
|
|
948
948
|
header_params = {}
|
|
949
949
|
if request.name
|
|
950
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(
|
|
950
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(?:/(?<__wildcard__>.*))?$}.match request.name
|
|
951
951
|
if regex_match
|
|
952
952
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
953
953
|
end
|
|
@@ -1044,7 +1044,7 @@ module Google
|
|
|
1044
1044
|
|
|
1045
1045
|
header_params = {}
|
|
1046
1046
|
if request.name
|
|
1047
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(
|
|
1047
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(?:/(?<__wildcard__>.*))?$}.match request.name
|
|
1048
1048
|
if regex_match
|
|
1049
1049
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
1050
1050
|
end
|
|
@@ -1244,7 +1244,7 @@ module Google
|
|
|
1244
1244
|
|
|
1245
1245
|
header_params = {}
|
|
1246
1246
|
if request.name
|
|
1247
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(
|
|
1247
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(?:/(?<__wildcard__>.*))?$}.match request.name
|
|
1248
1248
|
if regex_match
|
|
1249
1249
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
1250
1250
|
end
|
|
@@ -1343,7 +1343,7 @@ module Google
|
|
|
1343
1343
|
|
|
1344
1344
|
header_params = {}
|
|
1345
1345
|
if request.name
|
|
1346
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(
|
|
1346
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(?:/(?<__wildcard__>.*))?$}.match request.name
|
|
1347
1347
|
if regex_match
|
|
1348
1348
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
1349
1349
|
end
|
|
@@ -1555,7 +1555,7 @@ module Google
|
|
|
1555
1555
|
|
|
1556
1556
|
header_params = {}
|
|
1557
1557
|
if request.managed_folder&.name
|
|
1558
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(
|
|
1558
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(?:/(?<__wildcard__>.*))?$}.match request.managed_folder.name
|
|
1559
1559
|
if regex_match
|
|
1560
1560
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
1561
1561
|
end
|
|
@@ -1769,7 +1769,7 @@ module Google
|
|
|
1769
1769
|
|
|
1770
1770
|
header_params = {}
|
|
1771
1771
|
if request.anywhere_cache&.name
|
|
1772
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(
|
|
1772
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(?:/(?<__wildcard__>.*))?$}.match request.anywhere_cache.name
|
|
1773
1773
|
if regex_match
|
|
1774
1774
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
1775
1775
|
end
|
|
@@ -1867,7 +1867,7 @@ module Google
|
|
|
1867
1867
|
|
|
1868
1868
|
header_params = {}
|
|
1869
1869
|
if request.name
|
|
1870
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(
|
|
1870
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(?:/(?<__wildcard__>.*))?$}.match request.name
|
|
1871
1871
|
if regex_match
|
|
1872
1872
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
1873
1873
|
end
|
|
@@ -1960,7 +1960,7 @@ module Google
|
|
|
1960
1960
|
|
|
1961
1961
|
header_params = {}
|
|
1962
1962
|
if request.name
|
|
1963
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(
|
|
1963
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(?:/(?<__wildcard__>.*))?$}.match request.name
|
|
1964
1964
|
if regex_match
|
|
1965
1965
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
1966
1966
|
end
|
|
@@ -2053,7 +2053,7 @@ module Google
|
|
|
2053
2053
|
|
|
2054
2054
|
header_params = {}
|
|
2055
2055
|
if request.name
|
|
2056
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(
|
|
2056
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(?:/(?<__wildcard__>.*))?$}.match request.name
|
|
2057
2057
|
if regex_match
|
|
2058
2058
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
2059
2059
|
end
|
|
@@ -2145,7 +2145,7 @@ module Google
|
|
|
2145
2145
|
|
|
2146
2146
|
header_params = {}
|
|
2147
2147
|
if request.name
|
|
2148
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(
|
|
2148
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(?:/(?<__wildcard__>.*))?$}.match request.name
|
|
2149
2149
|
if regex_match
|
|
2150
2150
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
2151
2151
|
end
|
|
@@ -2456,7 +2456,7 @@ module Google
|
|
|
2456
2456
|
|
|
2457
2457
|
header_params = {}
|
|
2458
2458
|
if request.rapid_cache&.name
|
|
2459
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(
|
|
2459
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(?:/(?<__wildcard__>.*))?$}.match request.rapid_cache.name
|
|
2460
2460
|
if regex_match
|
|
2461
2461
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
2462
2462
|
end
|
|
@@ -2550,7 +2550,7 @@ module Google
|
|
|
2550
2550
|
|
|
2551
2551
|
header_params = {}
|
|
2552
2552
|
if request.name
|
|
2553
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(
|
|
2553
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(?:/(?<__wildcard__>.*))?$}.match request.name
|
|
2554
2554
|
if regex_match
|
|
2555
2555
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
2556
2556
|
end
|
|
@@ -3289,7 +3289,7 @@ module Google
|
|
|
3289
3289
|
header_params["bucket"] = request.resource
|
|
3290
3290
|
end
|
|
3291
3291
|
if request.resource
|
|
3292
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(
|
|
3292
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(?:/(?<__wildcard__>.*))?$}.match request.resource
|
|
3293
3293
|
if regex_match
|
|
3294
3294
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
3295
3295
|
end
|
|
@@ -3396,7 +3396,7 @@ module Google
|
|
|
3396
3396
|
header_params["bucket"] = request.resource
|
|
3397
3397
|
end
|
|
3398
3398
|
if request.resource
|
|
3399
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(
|
|
3399
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(?:/(?<__wildcard__>.*))?$}.match request.resource
|
|
3400
3400
|
if regex_match
|
|
3401
3401
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
3402
3402
|
end
|
|
@@ -3499,13 +3499,13 @@ module Google
|
|
|
3499
3499
|
header_params["bucket"] = request.resource
|
|
3500
3500
|
end
|
|
3501
3501
|
if request.resource
|
|
3502
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)/objects(
|
|
3502
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)/objects(?:/(?<__wildcard__>.*))?$}.match request.resource
|
|
3503
3503
|
if regex_match
|
|
3504
3504
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
3505
3505
|
end
|
|
3506
3506
|
end
|
|
3507
3507
|
if request.resource
|
|
3508
|
-
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)/managedFolders(
|
|
3508
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)/managedFolders(?:/(?<__wildcard__>.*))?$}.match request.resource
|
|
3509
3509
|
if regex_match
|
|
3510
3510
|
header_params["bucket"] = regex_match["bucket".to_s]
|
|
3511
3511
|
end
|
|
@@ -4041,6 +4041,108 @@ module Google
|
|
|
4041
4041
|
raise ::Google::Cloud::Error.from_error(e)
|
|
4042
4042
|
end
|
|
4043
4043
|
|
|
4044
|
+
##
|
|
4045
|
+
# Retrieves the full content of an object context, including its key, value,
|
|
4046
|
+
# and any associated extended data for a given context key.
|
|
4047
|
+
#
|
|
4048
|
+
# Object contexts can optionally contain extended data. If an object context
|
|
4049
|
+
# contains extended data, the metadata payload structure will contain only
|
|
4050
|
+
# its type URL. To retrieve the full extended data, call this method.
|
|
4051
|
+
#
|
|
4052
|
+
# Returns the complete representation of the context as an
|
|
4053
|
+
# {::Google::Cloud::Storage::Control::V2::ObjectFullContext `ObjectFullContext`}.
|
|
4054
|
+
#
|
|
4055
|
+
# @overload view_object_full_context(request, options = nil)
|
|
4056
|
+
# Pass arguments to `view_object_full_context` via a request object, either of type
|
|
4057
|
+
# {::Google::Cloud::Storage::Control::V2::ViewObjectFullContextRequest} or an equivalent Hash.
|
|
4058
|
+
#
|
|
4059
|
+
# @param request [::Google::Cloud::Storage::Control::V2::ViewObjectFullContextRequest, ::Hash]
|
|
4060
|
+
# A request object representing the call parameters. Required. To specify no
|
|
4061
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
|
4062
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
|
4063
|
+
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
|
4064
|
+
#
|
|
4065
|
+
# @overload view_object_full_context(generation: nil, context_key: nil, name: nil)
|
|
4066
|
+
# Pass arguments to `view_object_full_context` via keyword arguments. Note that at
|
|
4067
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
|
4068
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
|
4069
|
+
#
|
|
4070
|
+
# @param generation [::Integer]
|
|
4071
|
+
# Optional. If present, selects a specific revision of this object (as
|
|
4072
|
+
# opposed to the latest version, the default).
|
|
4073
|
+
# @param context_key [::String]
|
|
4074
|
+
# Required. The key of the object context to retrieve.
|
|
4075
|
+
# @param name [::String]
|
|
4076
|
+
# Required. The name of the object.
|
|
4077
|
+
# Format: `projects/{project}/buckets/{bucket}/objects/{object}`
|
|
4078
|
+
#
|
|
4079
|
+
# @yield [response, operation] Access the result along with the RPC operation
|
|
4080
|
+
# @yieldparam response [::Google::Cloud::Storage::Control::V2::ObjectFullContext]
|
|
4081
|
+
# @yieldparam operation [::GRPC::ActiveCall::Operation]
|
|
4082
|
+
#
|
|
4083
|
+
# @return [::Google::Cloud::Storage::Control::V2::ObjectFullContext]
|
|
4084
|
+
#
|
|
4085
|
+
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
|
4086
|
+
#
|
|
4087
|
+
# @example Basic example
|
|
4088
|
+
# require "google/cloud/storage/control/v2"
|
|
4089
|
+
#
|
|
4090
|
+
# # Create a client object. The client can be reused for multiple calls.
|
|
4091
|
+
# client = Google::Cloud::Storage::Control::V2::StorageControl::Client.new
|
|
4092
|
+
#
|
|
4093
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
|
4094
|
+
# request = Google::Cloud::Storage::Control::V2::ViewObjectFullContextRequest.new
|
|
4095
|
+
#
|
|
4096
|
+
# # Call the view_object_full_context method.
|
|
4097
|
+
# result = client.view_object_full_context request
|
|
4098
|
+
#
|
|
4099
|
+
# # The returned object is of type Google::Cloud::Storage::Control::V2::ObjectFullContext.
|
|
4100
|
+
# p result
|
|
4101
|
+
#
|
|
4102
|
+
def view_object_full_context request, options = nil
|
|
4103
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
|
4104
|
+
|
|
4105
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Storage::Control::V2::ViewObjectFullContextRequest
|
|
4106
|
+
|
|
4107
|
+
# Converts hash and nil to an options object
|
|
4108
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
|
4109
|
+
|
|
4110
|
+
# Customize the options with defaults
|
|
4111
|
+
metadata = @config.rpcs.view_object_full_context.metadata.to_h
|
|
4112
|
+
|
|
4113
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
|
4114
|
+
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
|
4115
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
|
4116
|
+
gapic_version: ::Google::Cloud::Storage::Control::V2::VERSION
|
|
4117
|
+
metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
|
4118
|
+
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
|
4119
|
+
|
|
4120
|
+
header_params = {}
|
|
4121
|
+
if request.name
|
|
4122
|
+
regex_match = %r{^(?<bucket>projects/[^/]+/buckets/[^/]+)(?:/(?<__wildcard__>.*))?$}.match request.name
|
|
4123
|
+
if regex_match
|
|
4124
|
+
header_params["bucket"] = regex_match["bucket".to_s]
|
|
4125
|
+
end
|
|
4126
|
+
end
|
|
4127
|
+
|
|
4128
|
+
request_params_header = URI.encode_www_form header_params
|
|
4129
|
+
metadata[:"x-goog-request-params"] ||= request_params_header
|
|
4130
|
+
|
|
4131
|
+
options.apply_defaults timeout: @config.rpcs.view_object_full_context.timeout,
|
|
4132
|
+
metadata: metadata,
|
|
4133
|
+
retry_policy: @config.rpcs.view_object_full_context.retry_policy
|
|
4134
|
+
|
|
4135
|
+
options.apply_defaults timeout: @config.timeout,
|
|
4136
|
+
metadata: @config.metadata,
|
|
4137
|
+
retry_policy: @config.retry_policy
|
|
4138
|
+
|
|
4139
|
+
@storage_control_stub.call_rpc :view_object_full_context, request, options: options do |response, operation|
|
|
4140
|
+
yield response, operation if block_given?
|
|
4141
|
+
end
|
|
4142
|
+
rescue ::GRPC::BadStatus => e
|
|
4143
|
+
raise ::Google::Cloud::Error.from_error(e)
|
|
4144
|
+
end
|
|
4145
|
+
|
|
4044
4146
|
##
|
|
4045
4147
|
# Configuration class for the StorageControl API.
|
|
4046
4148
|
#
|
|
@@ -4411,6 +4513,11 @@ module Google
|
|
|
4411
4513
|
# @return [::Gapic::Config::Method]
|
|
4412
4514
|
#
|
|
4413
4515
|
attr_reader :list_intelligence_finding_revisions
|
|
4516
|
+
##
|
|
4517
|
+
# RPC-specific configuration for `view_object_full_context`
|
|
4518
|
+
# @return [::Gapic::Config::Method]
|
|
4519
|
+
#
|
|
4520
|
+
attr_reader :view_object_full_context
|
|
4414
4521
|
|
|
4415
4522
|
# @private
|
|
4416
4523
|
def initialize parent_rpcs = nil
|
|
@@ -4488,6 +4595,8 @@ module Google
|
|
|
4488
4595
|
@get_intelligence_finding_revision = ::Gapic::Config::Method.new get_intelligence_finding_revision_config
|
|
4489
4596
|
list_intelligence_finding_revisions_config = parent_rpcs.list_intelligence_finding_revisions if parent_rpcs.respond_to? :list_intelligence_finding_revisions
|
|
4490
4597
|
@list_intelligence_finding_revisions = ::Gapic::Config::Method.new list_intelligence_finding_revisions_config
|
|
4598
|
+
view_object_full_context_config = parent_rpcs.view_object_full_context if parent_rpcs.respond_to? :view_object_full_context
|
|
4599
|
+
@view_object_full_context = ::Gapic::Config::Method.new view_object_full_context_config
|
|
4491
4600
|
|
|
4492
4601
|
yield self if block_given?
|
|
4493
4602
|
end
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
# Copyright
|
|
3
|
+
# Copyright 2026 Google LLC
|
|
4
4
|
#
|
|
5
5
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
6
|
# you may not use this file except in compliance with the License.
|
|
@@ -208,6 +208,25 @@ module Google
|
|
|
208
208
|
"projects/#{project}/buckets/#{bucket}/managedFolders/#{managed_folder}"
|
|
209
209
|
end
|
|
210
210
|
|
|
211
|
+
##
|
|
212
|
+
# Create a fully-qualified Object resource string.
|
|
213
|
+
#
|
|
214
|
+
# The resource will be in the following format:
|
|
215
|
+
#
|
|
216
|
+
# `projects/{project}/buckets/{bucket}/objects/{object}`
|
|
217
|
+
#
|
|
218
|
+
# @param project [String]
|
|
219
|
+
# @param bucket [String]
|
|
220
|
+
# @param object [String]
|
|
221
|
+
#
|
|
222
|
+
# @return [::String]
|
|
223
|
+
def object_path project:, bucket:, object:
|
|
224
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
|
225
|
+
raise ::ArgumentError, "bucket cannot contain /" if bucket.to_s.include? "/"
|
|
226
|
+
|
|
227
|
+
"projects/#{project}/buckets/#{bucket}/objects/#{object}"
|
|
228
|
+
end
|
|
229
|
+
|
|
211
230
|
##
|
|
212
231
|
# Create a fully-qualified RapidCache resource string.
|
|
213
232
|
#
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
# Copyright
|
|
3
|
+
# Copyright 2026 Google LLC
|
|
4
4
|
#
|
|
5
5
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
6
|
# you may not use this file except in compliance with the License.
|
|
@@ -1927,6 +1927,98 @@ module Google
|
|
|
1927
1927
|
raise ::Google::Cloud::Error.from_error(e)
|
|
1928
1928
|
end
|
|
1929
1929
|
|
|
1930
|
+
##
|
|
1931
|
+
# Retrieves the full content of an object context, including its key, value,
|
|
1932
|
+
# and any associated extended data for a given context key.
|
|
1933
|
+
#
|
|
1934
|
+
# Object contexts can optionally contain extended data. If an object context
|
|
1935
|
+
# contains extended data, the metadata payload structure will contain only
|
|
1936
|
+
# its type URL. To retrieve the full extended data, call this method.
|
|
1937
|
+
#
|
|
1938
|
+
# Returns the complete representation of the context as an
|
|
1939
|
+
# {::Google::Cloud::Storage::Control::V2::ObjectFullContext `ObjectFullContext`}.
|
|
1940
|
+
#
|
|
1941
|
+
# @overload view_object_full_context(request, options = nil)
|
|
1942
|
+
# Pass arguments to `view_object_full_context` via a request object, either of type
|
|
1943
|
+
# {::Google::Cloud::Storage::Control::V2::ViewObjectFullContextRequest} or an equivalent Hash.
|
|
1944
|
+
#
|
|
1945
|
+
# @param request [::Google::Cloud::Storage::Control::V2::ViewObjectFullContextRequest, ::Hash]
|
|
1946
|
+
# A request object representing the call parameters. Required. To specify no
|
|
1947
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
|
1948
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
|
1949
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
1950
|
+
#
|
|
1951
|
+
# @overload view_object_full_context(generation: nil, context_key: nil, name: nil)
|
|
1952
|
+
# Pass arguments to `view_object_full_context` via keyword arguments. Note that at
|
|
1953
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
|
1954
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
|
1955
|
+
#
|
|
1956
|
+
# @param generation [::Integer]
|
|
1957
|
+
# Optional. If present, selects a specific revision of this object (as
|
|
1958
|
+
# opposed to the latest version, the default).
|
|
1959
|
+
# @param context_key [::String]
|
|
1960
|
+
# Required. The key of the object context to retrieve.
|
|
1961
|
+
# @param name [::String]
|
|
1962
|
+
# Required. The name of the object.
|
|
1963
|
+
# Format: `projects/{project}/buckets/{bucket}/objects/{object}`
|
|
1964
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
1965
|
+
# @yieldparam result [::Google::Cloud::Storage::Control::V2::ObjectFullContext]
|
|
1966
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
1967
|
+
#
|
|
1968
|
+
# @return [::Google::Cloud::Storage::Control::V2::ObjectFullContext]
|
|
1969
|
+
#
|
|
1970
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
|
1971
|
+
#
|
|
1972
|
+
# @example Basic example
|
|
1973
|
+
# require "google/cloud/storage/control/v2"
|
|
1974
|
+
#
|
|
1975
|
+
# # Create a client object. The client can be reused for multiple calls.
|
|
1976
|
+
# client = Google::Cloud::Storage::Control::V2::StorageControl::Rest::Client.new
|
|
1977
|
+
#
|
|
1978
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
|
1979
|
+
# request = Google::Cloud::Storage::Control::V2::ViewObjectFullContextRequest.new
|
|
1980
|
+
#
|
|
1981
|
+
# # Call the view_object_full_context method.
|
|
1982
|
+
# result = client.view_object_full_context request
|
|
1983
|
+
#
|
|
1984
|
+
# # The returned object is of type Google::Cloud::Storage::Control::V2::ObjectFullContext.
|
|
1985
|
+
# p result
|
|
1986
|
+
#
|
|
1987
|
+
def view_object_full_context request, options = nil
|
|
1988
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
|
1989
|
+
|
|
1990
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Storage::Control::V2::ViewObjectFullContextRequest
|
|
1991
|
+
|
|
1992
|
+
# Converts hash and nil to an options object
|
|
1993
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
|
1994
|
+
|
|
1995
|
+
# Customize the options with defaults
|
|
1996
|
+
call_metadata = @config.rpcs.view_object_full_context.metadata.to_h
|
|
1997
|
+
|
|
1998
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
|
1999
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
|
2000
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
|
2001
|
+
gapic_version: ::Google::Cloud::Storage::Control::V2::VERSION,
|
|
2002
|
+
transports_version_send: [:rest]
|
|
2003
|
+
|
|
2004
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
|
2005
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
|
2006
|
+
|
|
2007
|
+
options.apply_defaults timeout: @config.rpcs.view_object_full_context.timeout,
|
|
2008
|
+
metadata: call_metadata,
|
|
2009
|
+
retry_policy: @config.rpcs.view_object_full_context.retry_policy
|
|
2010
|
+
|
|
2011
|
+
options.apply_defaults timeout: @config.timeout,
|
|
2012
|
+
metadata: @config.metadata,
|
|
2013
|
+
retry_policy: @config.retry_policy
|
|
2014
|
+
|
|
2015
|
+
@storage_control_stub.view_object_full_context request, options do |result, operation|
|
|
2016
|
+
yield result, operation if block_given?
|
|
2017
|
+
end
|
|
2018
|
+
rescue ::Gapic::Rest::Error => e
|
|
2019
|
+
raise ::Google::Cloud::Error.from_error(e)
|
|
2020
|
+
end
|
|
2021
|
+
|
|
1930
2022
|
##
|
|
1931
2023
|
# Configuration class for the StorageControl REST API.
|
|
1932
2024
|
#
|
|
@@ -2165,6 +2257,11 @@ module Google
|
|
|
2165
2257
|
# @return [::Gapic::Config::Method]
|
|
2166
2258
|
#
|
|
2167
2259
|
attr_reader :list_intelligence_finding_revisions
|
|
2260
|
+
##
|
|
2261
|
+
# RPC-specific configuration for `view_object_full_context`
|
|
2262
|
+
# @return [::Gapic::Config::Method]
|
|
2263
|
+
#
|
|
2264
|
+
attr_reader :view_object_full_context
|
|
2168
2265
|
|
|
2169
2266
|
# @private
|
|
2170
2267
|
def initialize parent_rpcs = nil
|
|
@@ -2204,6 +2301,8 @@ module Google
|
|
|
2204
2301
|
@get_intelligence_finding_revision = ::Gapic::Config::Method.new get_intelligence_finding_revision_config
|
|
2205
2302
|
list_intelligence_finding_revisions_config = parent_rpcs.list_intelligence_finding_revisions if parent_rpcs.respond_to? :list_intelligence_finding_revisions
|
|
2206
2303
|
@list_intelligence_finding_revisions = ::Gapic::Config::Method.new list_intelligence_finding_revisions_config
|
|
2304
|
+
view_object_full_context_config = parent_rpcs.view_object_full_context if parent_rpcs.respond_to? :view_object_full_context
|
|
2305
|
+
@view_object_full_context = ::Gapic::Config::Method.new view_object_full_context_config
|
|
2207
2306
|
|
|
2208
2307
|
yield self if block_given?
|
|
2209
2308
|
end
|
|
@@ -871,7 +871,7 @@ module Google
|
|
|
871
871
|
uri_method: :get,
|
|
872
872
|
uri_template: "/v1/{name}",
|
|
873
873
|
matches: [
|
|
874
|
-
["name", %r{^operations(
|
|
874
|
+
["name", %r{^operations(?:/(?<__wildcard__>.*))?$}, true]
|
|
875
875
|
]
|
|
876
876
|
)
|
|
877
877
|
transcoder.transcode request_pb
|
|
@@ -892,7 +892,7 @@ module Google
|
|
|
892
892
|
uri_method: :delete,
|
|
893
893
|
uri_template: "/v1/{name}",
|
|
894
894
|
matches: [
|
|
895
|
-
["name", %r{^operations(
|
|
895
|
+
["name", %r{^operations(?:/(?<__wildcard__>.*))?$}, true]
|
|
896
896
|
]
|
|
897
897
|
)
|
|
898
898
|
transcoder.transcode request_pb
|
|
@@ -914,7 +914,7 @@ module Google
|
|
|
914
914
|
uri_template: "/v1/{name}:cancel",
|
|
915
915
|
body: "*",
|
|
916
916
|
matches: [
|
|
917
|
-
["name", %r{^operations(
|
|
917
|
+
["name", %r{^operations(?:/(?<__wildcard__>.*))?$}, true]
|
|
918
918
|
]
|
|
919
919
|
)
|
|
920
920
|
transcoder.transcode request_pb
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
# Copyright
|
|
3
|
+
# Copyright 2026 Google LLC
|
|
4
4
|
#
|
|
5
5
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
6
|
# you may not use this file except in compliance with the License.
|
|
@@ -794,6 +794,46 @@ module Google
|
|
|
794
794
|
end
|
|
795
795
|
end
|
|
796
796
|
|
|
797
|
+
##
|
|
798
|
+
# Baseline implementation for the view_object_full_context REST call
|
|
799
|
+
#
|
|
800
|
+
# @param request_pb [::Google::Cloud::Storage::Control::V2::ViewObjectFullContextRequest]
|
|
801
|
+
# A request object representing the call parameters. Required.
|
|
802
|
+
# @param options [::Gapic::CallOptions]
|
|
803
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
|
804
|
+
#
|
|
805
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
|
806
|
+
# @yieldparam result [::Google::Cloud::Storage::Control::V2::ObjectFullContext]
|
|
807
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
|
808
|
+
#
|
|
809
|
+
# @return [::Google::Cloud::Storage::Control::V2::ObjectFullContext]
|
|
810
|
+
# A result object deserialized from the server's reply
|
|
811
|
+
def view_object_full_context request_pb, options = nil
|
|
812
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
|
813
|
+
|
|
814
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_view_object_full_context_request request_pb
|
|
815
|
+
query_string_params = if query_string_params.any?
|
|
816
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
|
817
|
+
else
|
|
818
|
+
{}
|
|
819
|
+
end
|
|
820
|
+
|
|
821
|
+
response = @client_stub.make_http_request(
|
|
822
|
+
verb,
|
|
823
|
+
uri: uri,
|
|
824
|
+
body: body || "",
|
|
825
|
+
params: query_string_params,
|
|
826
|
+
method_name: "view_object_full_context",
|
|
827
|
+
options: options
|
|
828
|
+
)
|
|
829
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
|
830
|
+
result = ::Google::Cloud::Storage::Control::V2::ObjectFullContext.decode_json response.body, ignore_unknown_fields: true
|
|
831
|
+
catch :response do
|
|
832
|
+
yield result, operation if block_given?
|
|
833
|
+
result
|
|
834
|
+
end
|
|
835
|
+
end
|
|
836
|
+
|
|
797
837
|
##
|
|
798
838
|
# @private
|
|
799
839
|
#
|
|
@@ -831,7 +871,7 @@ module Google
|
|
|
831
871
|
uri_method: :delete,
|
|
832
872
|
uri_template: "/v2/{name}",
|
|
833
873
|
matches: [
|
|
834
|
-
["name", %r{^projects/[^/]+/buckets/[^/]+/folders(
|
|
874
|
+
["name", %r{^projects/[^/]+/buckets/[^/]+/folders(?:/(?<__wildcard__>.*))?$}, true]
|
|
835
875
|
]
|
|
836
876
|
)
|
|
837
877
|
transcoder.transcode request_pb
|
|
@@ -852,7 +892,7 @@ module Google
|
|
|
852
892
|
uri_method: :get,
|
|
853
893
|
uri_template: "/v2/{name}",
|
|
854
894
|
matches: [
|
|
855
|
-
["name", %r{^projects/[^/]+/buckets/[^/]+/folders(
|
|
895
|
+
["name", %r{^projects/[^/]+/buckets/[^/]+/folders(?:/(?<__wildcard__>.*))?$}, true]
|
|
856
896
|
]
|
|
857
897
|
)
|
|
858
898
|
transcoder.transcode request_pb
|
|
@@ -895,7 +935,7 @@ module Google
|
|
|
895
935
|
uri_template: "/v2/{name}:rename",
|
|
896
936
|
body: "*",
|
|
897
937
|
matches: [
|
|
898
|
-
["name", %r{^projects/[^/]+/buckets/[^/]+/folders(
|
|
938
|
+
["name", %r{^projects/[^/]+/buckets/[^/]+/folders(?:/(?<__wildcard__>.*))?$}, true]
|
|
899
939
|
]
|
|
900
940
|
)
|
|
901
941
|
transcoder.transcode request_pb
|
|
@@ -917,7 +957,7 @@ module Google
|
|
|
917
957
|
uri_template: "/v2/{name}:deleteRecursive",
|
|
918
958
|
body: "*",
|
|
919
959
|
matches: [
|
|
920
|
-
["name", %r{^projects/[^/]+/buckets/[^/]+/folders(
|
|
960
|
+
["name", %r{^projects/[^/]+/buckets/[^/]+/folders(?:/(?<__wildcard__>.*))?$}, true]
|
|
921
961
|
]
|
|
922
962
|
)
|
|
923
963
|
transcoder.transcode request_pb
|
|
@@ -1191,6 +1231,27 @@ module Google
|
|
|
1191
1231
|
)
|
|
1192
1232
|
transcoder.transcode request_pb
|
|
1193
1233
|
end
|
|
1234
|
+
|
|
1235
|
+
##
|
|
1236
|
+
# @private
|
|
1237
|
+
#
|
|
1238
|
+
# GRPC transcoding helper method for the view_object_full_context REST call
|
|
1239
|
+
#
|
|
1240
|
+
# @param request_pb [::Google::Cloud::Storage::Control::V2::ViewObjectFullContextRequest]
|
|
1241
|
+
# A request object representing the call parameters. Required.
|
|
1242
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
|
1243
|
+
# Uri, Body, Query string parameters
|
|
1244
|
+
def self.transcode_view_object_full_context_request request_pb
|
|
1245
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
|
1246
|
+
.with_bindings(
|
|
1247
|
+
uri_method: :get,
|
|
1248
|
+
uri_template: "/v2/{name}:viewFullContext",
|
|
1249
|
+
matches: [
|
|
1250
|
+
["name", %r{^projects/[^/]+/buckets/[^/]+/objects(?:/(?<__wildcard__>.*))?$}, true]
|
|
1251
|
+
]
|
|
1252
|
+
)
|
|
1253
|
+
transcoder.transcode request_pb
|
|
1254
|
+
end
|
|
1194
1255
|
end
|
|
1195
1256
|
end
|
|
1196
1257
|
end
|