google-cloud-parameter_manager-v1 0.1.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.
Files changed (33) hide show
  1. checksums.yaml +7 -0
  2. data/.yardopts +12 -0
  3. data/AUTHENTICATION.md +122 -0
  4. data/LICENSE.md +201 -0
  5. data/README.md +154 -0
  6. data/lib/google/cloud/parameter_manager/v1/bindings_override.rb +102 -0
  7. data/lib/google/cloud/parameter_manager/v1/parameter_manager/client.rb +1578 -0
  8. data/lib/google/cloud/parameter_manager/v1/parameter_manager/credentials.rb +47 -0
  9. data/lib/google/cloud/parameter_manager/v1/parameter_manager/paths.rb +90 -0
  10. data/lib/google/cloud/parameter_manager/v1/parameter_manager/rest/client.rb +1483 -0
  11. data/lib/google/cloud/parameter_manager/v1/parameter_manager/rest/service_stub.rb +756 -0
  12. data/lib/google/cloud/parameter_manager/v1/parameter_manager/rest.rb +53 -0
  13. data/lib/google/cloud/parameter_manager/v1/parameter_manager.rb +55 -0
  14. data/lib/google/cloud/parameter_manager/v1/rest.rb +38 -0
  15. data/lib/google/cloud/parameter_manager/v1/version.rb +28 -0
  16. data/lib/google/cloud/parameter_manager/v1.rb +45 -0
  17. data/lib/google/cloud/parametermanager/v1/service_pb.rb +73 -0
  18. data/lib/google/cloud/parametermanager/v1/service_services_pb.rb +65 -0
  19. data/lib/google-cloud-parameter_manager-v1.rb +21 -0
  20. data/proto_docs/README.md +4 -0
  21. data/proto_docs/google/api/client.rb +473 -0
  22. data/proto_docs/google/api/field_behavior.rb +85 -0
  23. data/proto_docs/google/api/field_info.rb +88 -0
  24. data/proto_docs/google/api/launch_stage.rb +71 -0
  25. data/proto_docs/google/api/resource.rb +227 -0
  26. data/proto_docs/google/cloud/parametermanager/v1/service.rb +436 -0
  27. data/proto_docs/google/iam/v1/resource_policy_member.rb +49 -0
  28. data/proto_docs/google/protobuf/any.rb +145 -0
  29. data/proto_docs/google/protobuf/duration.rb +98 -0
  30. data/proto_docs/google/protobuf/empty.rb +34 -0
  31. data/proto_docs/google/protobuf/field_mask.rb +229 -0
  32. data/proto_docs/google/protobuf/timestamp.rb +127 -0
  33. metadata +147 -0
@@ -0,0 +1,436 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2025 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Cloud
22
+ module ParameterManager
23
+ module V1
24
+ # Message describing Parameter resource
25
+ # @!attribute [rw] name
26
+ # @return [::String]
27
+ # Identifier. [Output only] The resource name of the Parameter in the format
28
+ # `projects/*/locations/*/parameters/*`.
29
+ # @!attribute [r] create_time
30
+ # @return [::Google::Protobuf::Timestamp]
31
+ # Output only. [Output only] Create time stamp
32
+ # @!attribute [r] update_time
33
+ # @return [::Google::Protobuf::Timestamp]
34
+ # Output only. [Output only] Update time stamp
35
+ # @!attribute [rw] labels
36
+ # @return [::Google::Protobuf::Map{::String => ::String}]
37
+ # Optional. Labels as key value pairs
38
+ # @!attribute [rw] format
39
+ # @return [::Google::Cloud::ParameterManager::V1::ParameterFormat]
40
+ # Optional. Specifies the format of a Parameter.
41
+ # @!attribute [r] policy_member
42
+ # @return [::Google::Iam::V1::ResourcePolicyMember]
43
+ # Output only. [Output-only] policy member strings of a Google Cloud
44
+ # resource.
45
+ class Parameter
46
+ include ::Google::Protobuf::MessageExts
47
+ extend ::Google::Protobuf::MessageExts::ClassMethods
48
+
49
+ # @!attribute [rw] key
50
+ # @return [::String]
51
+ # @!attribute [rw] value
52
+ # @return [::String]
53
+ class LabelsEntry
54
+ include ::Google::Protobuf::MessageExts
55
+ extend ::Google::Protobuf::MessageExts::ClassMethods
56
+ end
57
+ end
58
+
59
+ # Message for requesting list of Parameters
60
+ # @!attribute [rw] parent
61
+ # @return [::String]
62
+ # Required. Parent value for ListParametersRequest in the format
63
+ # `projects/*/locations/*`.
64
+ # @!attribute [rw] page_size
65
+ # @return [::Integer]
66
+ # Optional. Requested page size. Server may return fewer items than
67
+ # requested. If unspecified, server will pick an appropriate default.
68
+ # @!attribute [rw] page_token
69
+ # @return [::String]
70
+ # Optional. A token identifying a page of results the server should return.
71
+ # @!attribute [rw] filter
72
+ # @return [::String]
73
+ # Optional. Filtering results
74
+ # @!attribute [rw] order_by
75
+ # @return [::String]
76
+ # Optional. Hint for how to order the results
77
+ class ListParametersRequest
78
+ include ::Google::Protobuf::MessageExts
79
+ extend ::Google::Protobuf::MessageExts::ClassMethods
80
+ end
81
+
82
+ # Message for response to listing Parameters
83
+ # @!attribute [rw] parameters
84
+ # @return [::Array<::Google::Cloud::ParameterManager::V1::Parameter>]
85
+ # The list of Parameters
86
+ # @!attribute [rw] next_page_token
87
+ # @return [::String]
88
+ # A token identifying a page of results the server should return.
89
+ # @!attribute [rw] unreachable
90
+ # @return [::Array<::String>]
91
+ # Unordered list. Locations that could not be reached.
92
+ class ListParametersResponse
93
+ include ::Google::Protobuf::MessageExts
94
+ extend ::Google::Protobuf::MessageExts::ClassMethods
95
+ end
96
+
97
+ # Message for getting a Parameter
98
+ # @!attribute [rw] name
99
+ # @return [::String]
100
+ # Required. Name of the resource in the format
101
+ # `projects/*/locations/*/parameters/*`.
102
+ class GetParameterRequest
103
+ include ::Google::Protobuf::MessageExts
104
+ extend ::Google::Protobuf::MessageExts::ClassMethods
105
+ end
106
+
107
+ # Message for creating a Parameter
108
+ # @!attribute [rw] parent
109
+ # @return [::String]
110
+ # Required. Value for parent in the format
111
+ # `projects/*/locations/*`.
112
+ # @!attribute [rw] parameter_id
113
+ # @return [::String]
114
+ # Required. Id of the Parameter resource
115
+ # @!attribute [rw] parameter
116
+ # @return [::Google::Cloud::ParameterManager::V1::Parameter]
117
+ # Required. The Parameter resource being created
118
+ # @!attribute [rw] request_id
119
+ # @return [::String]
120
+ # Optional. An optional request ID to identify requests. Specify a unique
121
+ # request ID so that if you must retry your request, the server will know to
122
+ # ignore the request if it has already been completed. The server will
123
+ # guarantee that for at least 60 minutes since the first request.
124
+ #
125
+ # For example, consider a situation where you make an initial request and the
126
+ # request times out. If you make the request again with the same request
127
+ # ID, the server can check if original operation with the same request ID
128
+ # was received, and if so, will ignore the second request. This prevents
129
+ # clients from accidentally creating duplicate commitments.
130
+ #
131
+ # The request ID must be a valid UUID with the exception that zero UUID is
132
+ # not supported (00000000-0000-0000-0000-000000000000).
133
+ class CreateParameterRequest
134
+ include ::Google::Protobuf::MessageExts
135
+ extend ::Google::Protobuf::MessageExts::ClassMethods
136
+ end
137
+
138
+ # Message for updating a Parameter
139
+ # @!attribute [rw] update_mask
140
+ # @return [::Google::Protobuf::FieldMask]
141
+ # Optional. Field mask is used to specify the fields to be overwritten in the
142
+ # Parameter resource by the update.
143
+ # The fields specified in the update_mask are relative to the resource, not
144
+ # the full request. A mutable field will be overwritten if it is in the
145
+ # mask. If the user does not provide a mask then all mutable fields present
146
+ # in the request will be overwritten.
147
+ # @!attribute [rw] parameter
148
+ # @return [::Google::Cloud::ParameterManager::V1::Parameter]
149
+ # Required. The Parameter resource being updated
150
+ # @!attribute [rw] request_id
151
+ # @return [::String]
152
+ # Optional. An optional request ID to identify requests. Specify a unique
153
+ # request ID so that if you must retry your request, the server will know to
154
+ # ignore the request if it has already been completed. The server will
155
+ # guarantee that for at least 60 minutes since the first request.
156
+ #
157
+ # For example, consider a situation where you make an initial request and the
158
+ # request times out. If you make the request again with the same request
159
+ # ID, the server can check if original operation with the same request ID
160
+ # was received, and if so, will ignore the second request. This prevents
161
+ # clients from accidentally creating duplicate commitments.
162
+ #
163
+ # The request ID must be a valid UUID with the exception that zero UUID is
164
+ # not supported (00000000-0000-0000-0000-000000000000).
165
+ class UpdateParameterRequest
166
+ include ::Google::Protobuf::MessageExts
167
+ extend ::Google::Protobuf::MessageExts::ClassMethods
168
+ end
169
+
170
+ # Message for deleting a Parameter
171
+ # @!attribute [rw] name
172
+ # @return [::String]
173
+ # Required. Name of the resource in the format
174
+ # `projects/*/locations/*/parameters/*`.
175
+ # @!attribute [rw] request_id
176
+ # @return [::String]
177
+ # Optional. An optional request ID to identify requests. Specify a unique
178
+ # request ID so that if you must retry your request, the server will know to
179
+ # ignore the request if it has already been completed. The server will
180
+ # guarantee that for at least 60 minutes after the first request.
181
+ #
182
+ # For example, consider a situation where you make an initial request and the
183
+ # request times out. If you make the request again with the same request
184
+ # ID, the server can check if original operation with the same request ID
185
+ # was received, and if so, will ignore the second request. This prevents
186
+ # clients from accidentally creating duplicate commitments.
187
+ #
188
+ # The request ID must be a valid UUID with the exception that zero UUID is
189
+ # not supported (00000000-0000-0000-0000-000000000000).
190
+ class DeleteParameterRequest
191
+ include ::Google::Protobuf::MessageExts
192
+ extend ::Google::Protobuf::MessageExts::ClassMethods
193
+ end
194
+
195
+ # Message describing ParameterVersion resource
196
+ # @!attribute [rw] name
197
+ # @return [::String]
198
+ # Identifier. [Output only] The resource name of the ParameterVersion in the
199
+ # format `projects/*/locations/*/parameters/*/versions/*`.
200
+ # @!attribute [r] create_time
201
+ # @return [::Google::Protobuf::Timestamp]
202
+ # Output only. [Output only] Create time stamp
203
+ # @!attribute [r] update_time
204
+ # @return [::Google::Protobuf::Timestamp]
205
+ # Output only. [Output only] Update time stamp
206
+ # @!attribute [rw] disabled
207
+ # @return [::Boolean]
208
+ # Optional. Disabled boolean to determine if a ParameterVersion acts as a
209
+ # metadata only resource (payload is never returned if disabled is true). If
210
+ # true any calls will always default to BASIC view even if the user
211
+ # explicitly passes FULL view as part of the request. A render call on a
212
+ # disabled resource fails with an error. Default value is False.
213
+ # @!attribute [rw] payload
214
+ # @return [::Google::Cloud::ParameterManager::V1::ParameterVersionPayload]
215
+ # Required. Immutable. Payload content of a ParameterVersion resource. This
216
+ # is only returned when the request provides the View value of FULL (default
217
+ # for GET request).
218
+ class ParameterVersion
219
+ include ::Google::Protobuf::MessageExts
220
+ extend ::Google::Protobuf::MessageExts::ClassMethods
221
+ end
222
+
223
+ # Message for storing a ParameterVersion resource's payload data
224
+ # @!attribute [rw] data
225
+ # @return [::String]
226
+ # Required. bytes data for storing payload.
227
+ class ParameterVersionPayload
228
+ include ::Google::Protobuf::MessageExts
229
+ extend ::Google::Protobuf::MessageExts::ClassMethods
230
+ end
231
+
232
+ # Message for requesting list of ParameterVersions
233
+ # @!attribute [rw] parent
234
+ # @return [::String]
235
+ # Required. Parent value for ListParameterVersionsRequest in the format
236
+ # `projects/*/locations/*/parameters/*`.
237
+ # @!attribute [rw] page_size
238
+ # @return [::Integer]
239
+ # Optional. Requested page size. Server may return fewer items than
240
+ # requested. If unspecified, server will pick an appropriate default.
241
+ # @!attribute [rw] page_token
242
+ # @return [::String]
243
+ # Optional. A token identifying a page of results the server should return.
244
+ # @!attribute [rw] filter
245
+ # @return [::String]
246
+ # Optional. Filtering results
247
+ # @!attribute [rw] order_by
248
+ # @return [::String]
249
+ # Optional. Hint for how to order the results
250
+ class ListParameterVersionsRequest
251
+ include ::Google::Protobuf::MessageExts
252
+ extend ::Google::Protobuf::MessageExts::ClassMethods
253
+ end
254
+
255
+ # Message for response to listing ParameterVersions
256
+ # @!attribute [rw] parameter_versions
257
+ # @return [::Array<::Google::Cloud::ParameterManager::V1::ParameterVersion>]
258
+ # The list of ParameterVersions
259
+ # @!attribute [rw] next_page_token
260
+ # @return [::String]
261
+ # A token identifying a page of results the server should return.
262
+ # @!attribute [rw] unreachable
263
+ # @return [::Array<::String>]
264
+ # Unordered list. Locations that could not be reached.
265
+ class ListParameterVersionsResponse
266
+ include ::Google::Protobuf::MessageExts
267
+ extend ::Google::Protobuf::MessageExts::ClassMethods
268
+ end
269
+
270
+ # Message for getting a ParameterVersion
271
+ # @!attribute [rw] name
272
+ # @return [::String]
273
+ # Required. Name of the resource in the format
274
+ # `projects/*/locations/*/parameters/*/versions/*`.
275
+ # @!attribute [rw] view
276
+ # @return [::Google::Cloud::ParameterManager::V1::View]
277
+ # Optional. View of the ParameterVersion.
278
+ # In the default FULL view, all metadata & payload associated with the
279
+ # ParameterVersion will be returned.
280
+ class GetParameterVersionRequest
281
+ include ::Google::Protobuf::MessageExts
282
+ extend ::Google::Protobuf::MessageExts::ClassMethods
283
+ end
284
+
285
+ # Message for getting a ParameterVersionRender
286
+ # @!attribute [rw] name
287
+ # @return [::String]
288
+ # Required. Name of the resource
289
+ class RenderParameterVersionRequest
290
+ include ::Google::Protobuf::MessageExts
291
+ extend ::Google::Protobuf::MessageExts::ClassMethods
292
+ end
293
+
294
+ # Message describing RenderParameterVersionResponse resource
295
+ # @!attribute [r] parameter_version
296
+ # @return [::String]
297
+ # Output only. Resource identifier of a ParameterVersion in the format
298
+ # `projects/*/locations/*/parameters/*/versions/*`.
299
+ # @!attribute [rw] payload
300
+ # @return [::Google::Cloud::ParameterManager::V1::ParameterVersionPayload]
301
+ # Payload content of a ParameterVersion resource.
302
+ # @!attribute [r] rendered_payload
303
+ # @return [::String]
304
+ # Output only. Server generated rendered version of the user provided payload
305
+ # data (ParameterVersionPayload) which has substitutions of all (if any)
306
+ # references to a SecretManager SecretVersion resources. This substituion
307
+ # only works for a Parameter which is in JSON or YAML format.
308
+ class RenderParameterVersionResponse
309
+ include ::Google::Protobuf::MessageExts
310
+ extend ::Google::Protobuf::MessageExts::ClassMethods
311
+ end
312
+
313
+ # Message for creating a ParameterVersion
314
+ # @!attribute [rw] parent
315
+ # @return [::String]
316
+ # Required. Value for parent in the format
317
+ # `projects/*/locations/*/parameters/*`.
318
+ # @!attribute [rw] parameter_version_id
319
+ # @return [::String]
320
+ # Required. Id of the ParameterVersion resource
321
+ # @!attribute [rw] parameter_version
322
+ # @return [::Google::Cloud::ParameterManager::V1::ParameterVersion]
323
+ # Required. The ParameterVersion resource being created
324
+ # @!attribute [rw] request_id
325
+ # @return [::String]
326
+ # Optional. An optional request ID to identify requests. Specify a unique
327
+ # request ID so that if you must retry your request, the server will know to
328
+ # ignore the request if it has already been completed. The server will
329
+ # guarantee that for at least 60 minutes since the first request.
330
+ #
331
+ # For example, consider a situation where you make an initial request and the
332
+ # request times out. If you make the request again with the same request
333
+ # ID, the server can check if original operation with the same request ID
334
+ # was received, and if so, will ignore the second request. This prevents
335
+ # clients from accidentally creating duplicate commitments.
336
+ #
337
+ # The request ID must be a valid UUID with the exception that zero UUID is
338
+ # not supported (00000000-0000-0000-0000-000000000000).
339
+ class CreateParameterVersionRequest
340
+ include ::Google::Protobuf::MessageExts
341
+ extend ::Google::Protobuf::MessageExts::ClassMethods
342
+ end
343
+
344
+ # Message for updating a ParameterVersion
345
+ # @!attribute [rw] update_mask
346
+ # @return [::Google::Protobuf::FieldMask]
347
+ # Optional. Field mask is used to specify the fields to be overwritten in the
348
+ # ParameterVersion resource by the update.
349
+ # The fields specified in the update_mask are relative to the resource, not
350
+ # the full request. A mutable field will be overwritten if it is in the
351
+ # mask. If the user does not provide a mask then all mutable fields present
352
+ # in the request will be overwritten.
353
+ # @!attribute [rw] parameter_version
354
+ # @return [::Google::Cloud::ParameterManager::V1::ParameterVersion]
355
+ # Required. The ParameterVersion resource being updated
356
+ # @!attribute [rw] request_id
357
+ # @return [::String]
358
+ # Optional. An optional request ID to identify requests. Specify a unique
359
+ # request ID so that if you must retry your request, the server will know to
360
+ # ignore the request if it has already been completed. The server will
361
+ # guarantee that for at least 60 minutes since the first request.
362
+ #
363
+ # For example, consider a situation where you make an initial request and the
364
+ # request times out. If you make the request again with the same request
365
+ # ID, the server can check if original operation with the same request ID
366
+ # was received, and if so, will ignore the second request. This prevents
367
+ # clients from accidentally creating duplicate commitments.
368
+ #
369
+ # The request ID must be a valid UUID with the exception that zero UUID is
370
+ # not supported (00000000-0000-0000-0000-000000000000).
371
+ class UpdateParameterVersionRequest
372
+ include ::Google::Protobuf::MessageExts
373
+ extend ::Google::Protobuf::MessageExts::ClassMethods
374
+ end
375
+
376
+ # Message for deleting a ParameterVersion
377
+ # @!attribute [rw] name
378
+ # @return [::String]
379
+ # Required. Name of the resource in the format
380
+ # `projects/*/locations/*/parameters/*/versions/*`.
381
+ # @!attribute [rw] request_id
382
+ # @return [::String]
383
+ # Optional. An optional request ID to identify requests. Specify a unique
384
+ # request ID so that if you must retry your request, the server will know to
385
+ # ignore the request if it has already been completed. The server will
386
+ # guarantee that for at least 60 minutes after the first request.
387
+ #
388
+ # For example, consider a situation where you make an initial request and the
389
+ # request times out. If you make the request again with the same request
390
+ # ID, the server can check if original operation with the same request ID
391
+ # was received, and if so, will ignore the second request. This prevents
392
+ # clients from accidentally creating duplicate commitments.
393
+ #
394
+ # The request ID must be a valid UUID with the exception that zero UUID is
395
+ # not supported (00000000-0000-0000-0000-000000000000).
396
+ class DeleteParameterVersionRequest
397
+ include ::Google::Protobuf::MessageExts
398
+ extend ::Google::Protobuf::MessageExts::ClassMethods
399
+ end
400
+
401
+ # Option to specify the format of a Parameter resource (UNFORMATTED / YAML /
402
+ # JSON). This option is user specified at the time of creation of the resource
403
+ # and is immutable.
404
+ module ParameterFormat
405
+ # The default / unset value.
406
+ # The API will default to the UNFORMATTED format.
407
+ PARAMETER_FORMAT_UNSPECIFIED = 0
408
+
409
+ # Unformatted.
410
+ UNFORMATTED = 1
411
+
412
+ # YAML format.
413
+ YAML = 2
414
+
415
+ # JSON format.
416
+ JSON = 3
417
+ end
418
+
419
+ # Option for requesting only metadata, or user provided payload
420
+ # of a ParameterVersion resource.
421
+ module View
422
+ # The default / unset value.
423
+ # The API will default to the FULL view..
424
+ VIEW_UNSPECIFIED = 0
425
+
426
+ # Include only the metadata for the resource.
427
+ BASIC = 1
428
+
429
+ # Include metadata & other relevant payload data as well.
430
+ # This is the default view.
431
+ FULL = 2
432
+ end
433
+ end
434
+ end
435
+ end
436
+ end
@@ -0,0 +1,49 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2025 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Iam
22
+ module V1
23
+ # Output-only policy member strings of a Google Cloud resource's built-in
24
+ # identity.
25
+ # @!attribute [r] iam_policy_name_principal
26
+ # @return [::String]
27
+ # IAM policy binding member referring to a Google Cloud resource by
28
+ # user-assigned name (https://google.aip.dev/122). If a resource is deleted
29
+ # and recreated with the same name, the binding will be applicable to the new
30
+ # resource.
31
+ #
32
+ # Example:
33
+ # `principal://parametermanager.googleapis.com/projects/12345/name/locations/us-central1-a/parameters/my-parameter`
34
+ # @!attribute [r] iam_policy_uid_principal
35
+ # @return [::String]
36
+ # IAM policy binding member referring to a Google Cloud resource by
37
+ # system-assigned unique identifier (https://google.aip.dev/148#uid). If a
38
+ # resource is deleted and recreated with the same name, the binding will not
39
+ # be applicable to the new resource
40
+ #
41
+ # Example:
42
+ # `principal://parametermanager.googleapis.com/projects/12345/uid/locations/us-central1-a/parameters/a918fed5`
43
+ class ResourcePolicyMember
44
+ include ::Google::Protobuf::MessageExts
45
+ extend ::Google::Protobuf::MessageExts::ClassMethods
46
+ end
47
+ end
48
+ end
49
+ end
@@ -0,0 +1,145 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2025 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Protobuf
22
+ # `Any` contains an arbitrary serialized protocol buffer message along with a
23
+ # URL that describes the type of the serialized message.
24
+ #
25
+ # Protobuf library provides support to pack/unpack Any values in the form
26
+ # of utility functions or additional generated methods of the Any type.
27
+ #
28
+ # Example 1: Pack and unpack a message in C++.
29
+ #
30
+ # Foo foo = ...;
31
+ # Any any;
32
+ # any.PackFrom(foo);
33
+ # ...
34
+ # if (any.UnpackTo(&foo)) {
35
+ # ...
36
+ # }
37
+ #
38
+ # Example 2: Pack and unpack a message in Java.
39
+ #
40
+ # Foo foo = ...;
41
+ # Any any = Any.pack(foo);
42
+ # ...
43
+ # if (any.is(Foo.class)) {
44
+ # foo = any.unpack(Foo.class);
45
+ # }
46
+ # // or ...
47
+ # if (any.isSameTypeAs(Foo.getDefaultInstance())) {
48
+ # foo = any.unpack(Foo.getDefaultInstance());
49
+ # }
50
+ #
51
+ # Example 3: Pack and unpack a message in Python.
52
+ #
53
+ # foo = Foo(...)
54
+ # any = Any()
55
+ # any.Pack(foo)
56
+ # ...
57
+ # if any.Is(Foo.DESCRIPTOR):
58
+ # any.Unpack(foo)
59
+ # ...
60
+ #
61
+ # Example 4: Pack and unpack a message in Go
62
+ #
63
+ # foo := &pb.Foo{...}
64
+ # any, err := anypb.New(foo)
65
+ # if err != nil {
66
+ # ...
67
+ # }
68
+ # ...
69
+ # foo := &pb.Foo{}
70
+ # if err := any.UnmarshalTo(foo); err != nil {
71
+ # ...
72
+ # }
73
+ #
74
+ # The pack methods provided by protobuf library will by default use
75
+ # 'type.googleapis.com/full.type.name' as the type URL and the unpack
76
+ # methods only use the fully qualified type name after the last '/'
77
+ # in the type URL, for example "foo.bar.com/x/y.z" will yield type
78
+ # name "y.z".
79
+ #
80
+ # JSON
81
+ # ====
82
+ # The JSON representation of an `Any` value uses the regular
83
+ # representation of the deserialized, embedded message, with an
84
+ # additional field `@type` which contains the type URL. Example:
85
+ #
86
+ # package google.profile;
87
+ # message Person {
88
+ # string first_name = 1;
89
+ # string last_name = 2;
90
+ # }
91
+ #
92
+ # {
93
+ # "@type": "type.googleapis.com/google.profile.Person",
94
+ # "firstName": <string>,
95
+ # "lastName": <string>
96
+ # }
97
+ #
98
+ # If the embedded message type is well-known and has a custom JSON
99
+ # representation, that representation will be embedded adding a field
100
+ # `value` which holds the custom JSON in addition to the `@type`
101
+ # field. Example (for message [google.protobuf.Duration][]):
102
+ #
103
+ # {
104
+ # "@type": "type.googleapis.com/google.protobuf.Duration",
105
+ # "value": "1.212s"
106
+ # }
107
+ # @!attribute [rw] type_url
108
+ # @return [::String]
109
+ # A URL/resource name that uniquely identifies the type of the serialized
110
+ # protocol buffer message. This string must contain at least
111
+ # one "/" character. The last segment of the URL's path must represent
112
+ # the fully qualified name of the type (as in
113
+ # `path/google.protobuf.Duration`). The name should be in a canonical form
114
+ # (e.g., leading "." is not accepted).
115
+ #
116
+ # In practice, teams usually precompile into the binary all types that they
117
+ # expect it to use in the context of Any. However, for URLs which use the
118
+ # scheme `http`, `https`, or no scheme, one can optionally set up a type
119
+ # server that maps type URLs to message definitions as follows:
120
+ #
121
+ # * If no scheme is provided, `https` is assumed.
122
+ # * An HTTP GET on the URL must yield a [google.protobuf.Type][]
123
+ # value in binary format, or produce an error.
124
+ # * Applications are allowed to cache lookup results based on the
125
+ # URL, or have them precompiled into a binary to avoid any
126
+ # lookup. Therefore, binary compatibility needs to be preserved
127
+ # on changes to types. (Use versioned type names to manage
128
+ # breaking changes.)
129
+ #
130
+ # Note: this functionality is not currently available in the official
131
+ # protobuf release, and it is not used for type URLs beginning with
132
+ # type.googleapis.com. As of May 2023, there are no widely used type server
133
+ # implementations and no plans to implement one.
134
+ #
135
+ # Schemes other than `http`, `https` (or the empty scheme) might be
136
+ # used with implementation specific semantics.
137
+ # @!attribute [rw] value
138
+ # @return [::String]
139
+ # Must be a valid serialized protocol buffer of the above specified type.
140
+ class Any
141
+ include ::Google::Protobuf::MessageExts
142
+ extend ::Google::Protobuf::MessageExts::ClassMethods
143
+ end
144
+ end
145
+ end