aws-sdk-s3 1.61.1 → 1.166.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (135) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +1255 -0
  3. data/LICENSE.txt +202 -0
  4. data/VERSION +1 -0
  5. data/lib/aws-sdk-s3/access_grants_credentials.rb +57 -0
  6. data/lib/aws-sdk-s3/access_grants_credentials_provider.rb +250 -0
  7. data/lib/aws-sdk-s3/bucket.rb +814 -112
  8. data/lib/aws-sdk-s3/bucket_acl.rb +54 -17
  9. data/lib/aws-sdk-s3/bucket_cors.rb +63 -20
  10. data/lib/aws-sdk-s3/bucket_lifecycle.rb +63 -19
  11. data/lib/aws-sdk-s3/bucket_lifecycle_configuration.rb +64 -19
  12. data/lib/aws-sdk-s3/bucket_logging.rb +58 -17
  13. data/lib/aws-sdk-s3/bucket_notification.rb +47 -20
  14. data/lib/aws-sdk-s3/bucket_policy.rb +104 -17
  15. data/lib/aws-sdk-s3/bucket_region_cache.rb +11 -5
  16. data/lib/aws-sdk-s3/bucket_request_payment.rb +53 -19
  17. data/lib/aws-sdk-s3/bucket_tagging.rb +60 -17
  18. data/lib/aws-sdk-s3/bucket_versioning.rb +106 -17
  19. data/lib/aws-sdk-s3/bucket_website.rb +64 -19
  20. data/lib/aws-sdk-s3/client.rb +11280 -3232
  21. data/lib/aws-sdk-s3/client_api.rb +1078 -197
  22. data/lib/aws-sdk-s3/customizations/bucket.rb +33 -45
  23. data/lib/aws-sdk-s3/customizations/errors.rb +40 -0
  24. data/lib/aws-sdk-s3/customizations/multipart_upload.rb +2 -0
  25. data/lib/aws-sdk-s3/customizations/object.rb +237 -39
  26. data/lib/aws-sdk-s3/customizations/object_summary.rb +10 -0
  27. data/lib/aws-sdk-s3/customizations/object_version.rb +13 -0
  28. data/lib/aws-sdk-s3/customizations/types/list_object_versions_output.rb +2 -0
  29. data/lib/aws-sdk-s3/customizations/types/permanent_redirect.rb +26 -0
  30. data/lib/aws-sdk-s3/customizations.rb +27 -28
  31. data/lib/aws-sdk-s3/encryption/client.rb +25 -8
  32. data/lib/aws-sdk-s3/encryption/decrypt_handler.rb +71 -29
  33. data/lib/aws-sdk-s3/encryption/default_cipher_provider.rb +43 -5
  34. data/lib/aws-sdk-s3/encryption/default_key_provider.rb +2 -0
  35. data/lib/aws-sdk-s3/encryption/encrypt_handler.rb +13 -2
  36. data/lib/aws-sdk-s3/encryption/errors.rb +2 -0
  37. data/lib/aws-sdk-s3/encryption/io_auth_decrypter.rb +2 -0
  38. data/lib/aws-sdk-s3/encryption/io_decrypter.rb +11 -3
  39. data/lib/aws-sdk-s3/encryption/io_encrypter.rb +2 -0
  40. data/lib/aws-sdk-s3/encryption/key_provider.rb +2 -0
  41. data/lib/aws-sdk-s3/encryption/kms_cipher_provider.rb +46 -11
  42. data/lib/aws-sdk-s3/encryption/materials.rb +8 -6
  43. data/lib/aws-sdk-s3/encryption/utils.rb +25 -0
  44. data/lib/aws-sdk-s3/encryption.rb +4 -0
  45. data/lib/aws-sdk-s3/encryptionV2/client.rb +570 -0
  46. data/lib/aws-sdk-s3/encryptionV2/decrypt_handler.rb +223 -0
  47. data/lib/aws-sdk-s3/encryptionV2/default_cipher_provider.rb +170 -0
  48. data/lib/aws-sdk-s3/encryptionV2/default_key_provider.rb +40 -0
  49. data/lib/aws-sdk-s3/encryptionV2/encrypt_handler.rb +65 -0
  50. data/lib/aws-sdk-s3/encryptionV2/errors.rb +37 -0
  51. data/lib/aws-sdk-s3/encryptionV2/io_auth_decrypter.rb +58 -0
  52. data/lib/aws-sdk-s3/encryptionV2/io_decrypter.rb +37 -0
  53. data/lib/aws-sdk-s3/encryptionV2/io_encrypter.rb +73 -0
  54. data/lib/aws-sdk-s3/encryptionV2/key_provider.rb +31 -0
  55. data/lib/aws-sdk-s3/encryptionV2/kms_cipher_provider.rb +173 -0
  56. data/lib/aws-sdk-s3/encryptionV2/materials.rb +60 -0
  57. data/lib/aws-sdk-s3/encryptionV2/utils.rb +103 -0
  58. data/lib/aws-sdk-s3/encryption_v2.rb +23 -0
  59. data/lib/aws-sdk-s3/endpoint_parameters.rb +186 -0
  60. data/lib/aws-sdk-s3/endpoint_provider.rb +592 -0
  61. data/lib/aws-sdk-s3/endpoints.rb +2392 -0
  62. data/lib/aws-sdk-s3/errors.rb +27 -1
  63. data/lib/aws-sdk-s3/event_streams.rb +8 -1
  64. data/lib/aws-sdk-s3/express_credentials.rb +55 -0
  65. data/lib/aws-sdk-s3/express_credentials_provider.rb +59 -0
  66. data/lib/aws-sdk-s3/file_downloader.rb +176 -44
  67. data/lib/aws-sdk-s3/file_part.rb +2 -0
  68. data/lib/aws-sdk-s3/file_uploader.rb +28 -8
  69. data/lib/aws-sdk-s3/legacy_signer.rb +17 -25
  70. data/lib/aws-sdk-s3/multipart_file_uploader.rb +69 -13
  71. data/lib/aws-sdk-s3/multipart_stream_uploader.rb +49 -18
  72. data/lib/aws-sdk-s3/multipart_upload.rb +242 -25
  73. data/lib/aws-sdk-s3/multipart_upload_error.rb +2 -0
  74. data/lib/aws-sdk-s3/multipart_upload_part.rb +343 -31
  75. data/lib/aws-sdk-s3/object.rb +2240 -218
  76. data/lib/aws-sdk-s3/object_acl.rb +80 -21
  77. data/lib/aws-sdk-s3/object_copier.rb +9 -5
  78. data/lib/aws-sdk-s3/object_multipart_copier.rb +48 -22
  79. data/lib/aws-sdk-s3/object_summary.rb +1900 -178
  80. data/lib/aws-sdk-s3/object_version.rb +449 -59
  81. data/lib/aws-sdk-s3/plugins/accelerate.rb +17 -64
  82. data/lib/aws-sdk-s3/plugins/access_grants.rb +178 -0
  83. data/lib/aws-sdk-s3/plugins/arn.rb +70 -0
  84. data/lib/aws-sdk-s3/plugins/bucket_dns.rb +5 -41
  85. data/lib/aws-sdk-s3/plugins/bucket_name_restrictions.rb +3 -6
  86. data/lib/aws-sdk-s3/plugins/dualstack.rb +7 -50
  87. data/lib/aws-sdk-s3/plugins/endpoints.rb +289 -0
  88. data/lib/aws-sdk-s3/plugins/expect_100_continue.rb +5 -4
  89. data/lib/aws-sdk-s3/plugins/express_session_auth.rb +97 -0
  90. data/lib/aws-sdk-s3/plugins/get_bucket_location_fix.rb +3 -1
  91. data/lib/aws-sdk-s3/plugins/http_200_errors.rb +60 -15
  92. data/lib/aws-sdk-s3/plugins/iad_regional_endpoint.rb +11 -27
  93. data/lib/aws-sdk-s3/plugins/location_constraint.rb +5 -1
  94. data/lib/aws-sdk-s3/plugins/md5s.rb +32 -26
  95. data/lib/aws-sdk-s3/plugins/redirects.rb +2 -0
  96. data/lib/aws-sdk-s3/plugins/s3_host_id.rb +2 -0
  97. data/lib/aws-sdk-s3/plugins/s3_signer.rb +50 -88
  98. data/lib/aws-sdk-s3/plugins/skip_whole_multipart_get_checksums.rb +31 -0
  99. data/lib/aws-sdk-s3/plugins/sse_cpk.rb +3 -1
  100. data/lib/aws-sdk-s3/plugins/streaming_retry.rb +139 -0
  101. data/lib/aws-sdk-s3/plugins/url_encoded_keys.rb +2 -0
  102. data/lib/aws-sdk-s3/presigned_post.rb +160 -103
  103. data/lib/aws-sdk-s3/presigner.rb +136 -61
  104. data/lib/aws-sdk-s3/resource.rb +120 -15
  105. data/lib/aws-sdk-s3/types.rb +9683 -4358
  106. data/lib/aws-sdk-s3/waiters.rb +67 -1
  107. data/lib/aws-sdk-s3.rb +40 -29
  108. data/sig/bucket.rbs +213 -0
  109. data/sig/bucket_acl.rbs +78 -0
  110. data/sig/bucket_cors.rbs +69 -0
  111. data/sig/bucket_lifecycle.rbs +88 -0
  112. data/sig/bucket_lifecycle_configuration.rbs +111 -0
  113. data/sig/bucket_logging.rbs +76 -0
  114. data/sig/bucket_notification.rbs +114 -0
  115. data/sig/bucket_policy.rbs +59 -0
  116. data/sig/bucket_request_payment.rbs +54 -0
  117. data/sig/bucket_tagging.rbs +65 -0
  118. data/sig/bucket_versioning.rbs +77 -0
  119. data/sig/bucket_website.rbs +93 -0
  120. data/sig/client.rbs +2397 -0
  121. data/sig/customizations/bucket.rbs +19 -0
  122. data/sig/customizations/object.rbs +38 -0
  123. data/sig/customizations/object_summary.rbs +35 -0
  124. data/sig/errors.rbs +34 -0
  125. data/sig/multipart_upload.rbs +111 -0
  126. data/sig/multipart_upload_part.rbs +105 -0
  127. data/sig/object.rbs +443 -0
  128. data/sig/object_acl.rbs +86 -0
  129. data/sig/object_summary.rbs +335 -0
  130. data/sig/object_version.rbs +137 -0
  131. data/sig/resource.rbs +130 -0
  132. data/sig/types.rbs +2585 -0
  133. data/sig/waiters.rbs +95 -0
  134. metadata +73 -15
  135. data/lib/aws-sdk-s3/plugins/bucket_arn.rb +0 -211
@@ -1,13 +1,79 @@
1
+ # frozen_string_literal: true
2
+
1
3
  # WARNING ABOUT GENERATED CODE
2
4
  #
3
5
  # This file is generated. See the contributing guide for more information:
4
- # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
6
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
5
7
  #
6
8
  # WARNING ABOUT GENERATED CODE
7
9
 
8
10
  require 'aws-sdk-core/waiters'
9
11
 
10
12
  module Aws::S3
13
+ # Waiters are utility methods that poll for a particular state to occur
14
+ # on a client. Waiters can fail after a number of attempts at a polling
15
+ # interval defined for the service client.
16
+ #
17
+ # For a list of operations that can be waited for and the
18
+ # client methods called for each operation, see the table below or the
19
+ # {Client#wait_until} field documentation for the {Client}.
20
+ #
21
+ # # Invoking a Waiter
22
+ # To invoke a waiter, call #wait_until on a {Client}. The first parameter
23
+ # is the waiter name, which is specific to the service client and indicates
24
+ # which operation is being waited for. The second parameter is a hash of
25
+ # parameters that are passed to the client method called by the waiter,
26
+ # which varies according to the waiter name.
27
+ #
28
+ # # Wait Failures
29
+ # To catch errors in a waiter, use WaiterFailed,
30
+ # as shown in the following example.
31
+ #
32
+ # rescue rescue Aws::Waiters::Errors::WaiterFailed => error
33
+ # puts "failed waiting for instance running: #{error.message}
34
+ # end
35
+ #
36
+ # # Configuring a Waiter
37
+ # Each waiter has a default polling interval and a maximum number of
38
+ # attempts it will make before returning control to your program.
39
+ # To set these values, use the `max_attempts` and `delay` parameters
40
+ # in your `#wait_until` call.
41
+ # The following example waits for up to 25 seconds, polling every five seconds.
42
+ #
43
+ # client.wait_until(...) do |w|
44
+ # w.max_attempts = 5
45
+ # w.delay = 5
46
+ # end
47
+ #
48
+ # To disable wait failures, set the value of either of these parameters
49
+ # to `nil`.
50
+ #
51
+ # # Extending a Waiter
52
+ # To modify the behavior of waiters, you can register callbacks that are
53
+ # triggered before each polling attempt and before waiting.
54
+ #
55
+ # The following example implements an exponential backoff in a waiter
56
+ # by doubling the amount of time to wait on every attempt.
57
+ #
58
+ # client.wait_until(...) do |w|
59
+ # w.interval = 0 # disable normal sleep
60
+ # w.before_wait do |n, resp|
61
+ # sleep(n ** 2)
62
+ # end
63
+ # end
64
+ #
65
+ # # Available Waiters
66
+ #
67
+ # The following table lists the valid waiter names, the operations they call,
68
+ # and the default `:delay` and `:max_attempts` values.
69
+ #
70
+ # | waiter_name | params | :delay | :max_attempts |
71
+ # | ----------------- | -------------------- | -------- | ------------- |
72
+ # | bucket_exists | {Client#head_bucket} | 5 | 20 |
73
+ # | bucket_not_exists | {Client#head_bucket} | 5 | 20 |
74
+ # | object_exists | {Client#head_object} | 5 | 20 |
75
+ # | object_not_exists | {Client#head_object} | 5 | 20 |
76
+ #
11
77
  module Waiters
12
78
 
13
79
  class BucketExists
data/lib/aws-sdk-s3.rb CHANGED
@@ -1,40 +1,18 @@
1
+ # frozen_string_literal: true
2
+
1
3
  # WARNING ABOUT GENERATED CODE
2
4
  #
3
5
  # This file is generated. See the contributing guide for more information:
4
- # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
6
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
5
7
  #
6
8
  # WARNING ABOUT GENERATED CODE
7
9
 
10
+
8
11
  require 'aws-sdk-kms'
9
12
  require 'aws-sigv4'
10
13
  require 'aws-sdk-core'
11
14
 
12
- require_relative 'aws-sdk-s3/types'
13
- require_relative 'aws-sdk-s3/client_api'
14
- require_relative 'aws-sdk-s3/client'
15
- require_relative 'aws-sdk-s3/errors'
16
- require_relative 'aws-sdk-s3/waiters'
17
- require_relative 'aws-sdk-s3/resource'
18
- require_relative 'aws-sdk-s3/bucket'
19
- require_relative 'aws-sdk-s3/bucket_acl'
20
- require_relative 'aws-sdk-s3/bucket_cors'
21
- require_relative 'aws-sdk-s3/bucket_lifecycle'
22
- require_relative 'aws-sdk-s3/bucket_lifecycle_configuration'
23
- require_relative 'aws-sdk-s3/bucket_logging'
24
- require_relative 'aws-sdk-s3/bucket_notification'
25
- require_relative 'aws-sdk-s3/bucket_policy'
26
- require_relative 'aws-sdk-s3/bucket_request_payment'
27
- require_relative 'aws-sdk-s3/bucket_tagging'
28
- require_relative 'aws-sdk-s3/bucket_versioning'
29
- require_relative 'aws-sdk-s3/bucket_website'
30
- require_relative 'aws-sdk-s3/multipart_upload'
31
- require_relative 'aws-sdk-s3/multipart_upload_part'
32
- require_relative 'aws-sdk-s3/object'
33
- require_relative 'aws-sdk-s3/object_acl'
34
- require_relative 'aws-sdk-s3/object_summary'
35
- require_relative 'aws-sdk-s3/object_version'
36
- require_relative 'aws-sdk-s3/customizations'
37
- require_relative 'aws-sdk-s3/event_streams'
15
+ Aws::Plugins::GlobalConfiguration.add_identifier(:s3)
38
16
 
39
17
  # This module provides support for Amazon Simple Storage Service. This module is available in the
40
18
  # `aws-sdk-s3` gem.
@@ -63,9 +41,42 @@ require_relative 'aws-sdk-s3/event_streams'
63
41
  #
64
42
  # See {Errors} for more information.
65
43
  #
66
- # @service
44
+ # @!group service
67
45
  module Aws::S3
46
+ autoload :Types, 'aws-sdk-s3/types'
47
+ autoload :ClientApi, 'aws-sdk-s3/client_api'
48
+ module Plugins
49
+ autoload :Endpoints, 'aws-sdk-s3/plugins/endpoints.rb'
50
+ end
51
+ autoload :Client, 'aws-sdk-s3/client'
52
+ autoload :Errors, 'aws-sdk-s3/errors'
53
+ autoload :Waiters, 'aws-sdk-s3/waiters'
54
+ autoload :Resource, 'aws-sdk-s3/resource'
55
+ autoload :EndpointParameters, 'aws-sdk-s3/endpoint_parameters'
56
+ autoload :EndpointProvider, 'aws-sdk-s3/endpoint_provider'
57
+ autoload :Endpoints, 'aws-sdk-s3/endpoints'
58
+ autoload :Bucket, 'aws-sdk-s3/bucket'
59
+ autoload :BucketAcl, 'aws-sdk-s3/bucket_acl'
60
+ autoload :BucketCors, 'aws-sdk-s3/bucket_cors'
61
+ autoload :BucketLifecycle, 'aws-sdk-s3/bucket_lifecycle'
62
+ autoload :BucketLifecycleConfiguration, 'aws-sdk-s3/bucket_lifecycle_configuration'
63
+ autoload :BucketLogging, 'aws-sdk-s3/bucket_logging'
64
+ autoload :BucketNotification, 'aws-sdk-s3/bucket_notification'
65
+ autoload :BucketPolicy, 'aws-sdk-s3/bucket_policy'
66
+ autoload :BucketRequestPayment, 'aws-sdk-s3/bucket_request_payment'
67
+ autoload :BucketTagging, 'aws-sdk-s3/bucket_tagging'
68
+ autoload :BucketVersioning, 'aws-sdk-s3/bucket_versioning'
69
+ autoload :BucketWebsite, 'aws-sdk-s3/bucket_website'
70
+ autoload :MultipartUpload, 'aws-sdk-s3/multipart_upload'
71
+ autoload :MultipartUploadPart, 'aws-sdk-s3/multipart_upload_part'
72
+ autoload :Object, 'aws-sdk-s3/object'
73
+ autoload :ObjectAcl, 'aws-sdk-s3/object_acl'
74
+ autoload :ObjectSummary, 'aws-sdk-s3/object_summary'
75
+ autoload :ObjectVersion, 'aws-sdk-s3/object_version'
76
+ autoload :EventStreams, 'aws-sdk-s3/event_streams'
68
77
 
69
- GEM_VERSION = '1.61.1'
78
+ GEM_VERSION = '1.166.0'
70
79
 
71
80
  end
81
+
82
+ require_relative 'aws-sdk-s3/customizations'
data/sig/bucket.rbs ADDED
@@ -0,0 +1,213 @@
1
+ # WARNING ABOUT GENERATED CODE
2
+ #
3
+ # This file is generated. See the contributing guide for more information:
4
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
5
+ #
6
+ # WARNING ABOUT GENERATED CODE
7
+
8
+ module Aws
9
+ module S3
10
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html
11
+ class Bucket
12
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#initialize-instance_method
13
+ def initialize: (String name, Hash[Symbol, untyped] options) -> void
14
+ | (name: String, ?client: Client) -> void
15
+ | (Hash[Symbol, untyped] args) -> void
16
+
17
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#name-instance_method
18
+ def name: () -> String
19
+
20
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#creation_date-instance_method
21
+ def creation_date: () -> ::Time
22
+
23
+ def client: () -> Client
24
+
25
+
26
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#data-instance_method
27
+ def data: () -> Types::Bucket
28
+
29
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#data_loaded?-instance_method
30
+ def data_loaded?: () -> bool
31
+
32
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#exists?-instance_method
33
+ def exists?: (?max_attempts: Integer, ?delay: Numeric, ?before_attempt: (^(Integer attempts) -> void), ?before_wait: (^(Integer attempts, untyped response) -> void)) -> bool
34
+ | (?Hash[Symbol, untyped]) -> bool
35
+
36
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#wait_until_exists-instance_method
37
+ def wait_until_exists: (?max_attempts: Integer, ?delay: Numeric, ?before_attempt: (^(Integer attempts) -> void), ?before_wait: (^(Integer attempts, untyped response) -> void)) ?{ (untyped waiter) -> void } -> Bucket
38
+ | (?Hash[Symbol, untyped]) ?{ (untyped waiter) -> void } -> Bucket
39
+
40
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#wait_until_not_exists-instance_method
41
+ def wait_until_not_exists: (?max_attempts: Integer, ?delay: Numeric, ?before_attempt: (^(Integer attempts) -> void), ?before_wait: (^(Integer attempts, untyped response) -> void)) ?{ (untyped waiter) -> void } -> Bucket
42
+ | (?Hash[Symbol, untyped]) ?{ (untyped waiter) -> void } -> Bucket
43
+
44
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#create-instance_method
45
+ def create: (
46
+ ?acl: ("private" | "public-read" | "public-read-write" | "authenticated-read"),
47
+ ?create_bucket_configuration: {
48
+ location_constraint: ("af-south-1" | "ap-east-1" | "ap-northeast-1" | "ap-northeast-2" | "ap-northeast-3" | "ap-south-1" | "ap-south-2" | "ap-southeast-1" | "ap-southeast-2" | "ap-southeast-3" | "ca-central-1" | "cn-north-1" | "cn-northwest-1" | "EU" | "eu-central-1" | "eu-north-1" | "eu-south-1" | "eu-south-2" | "eu-west-1" | "eu-west-2" | "eu-west-3" | "me-south-1" | "sa-east-1" | "us-east-2" | "us-gov-east-1" | "us-gov-west-1" | "us-west-1" | "us-west-2")?,
49
+ location: {
50
+ type: ("AvailabilityZone")?,
51
+ name: ::String?
52
+ }?,
53
+ bucket: {
54
+ data_redundancy: ("SingleAvailabilityZone")?,
55
+ type: ("Directory")?
56
+ }?
57
+ },
58
+ ?grant_full_control: ::String,
59
+ ?grant_read: ::String,
60
+ ?grant_read_acp: ::String,
61
+ ?grant_write: ::String,
62
+ ?grant_write_acp: ::String,
63
+ ?object_lock_enabled_for_bucket: bool,
64
+ ?object_ownership: ("BucketOwnerPreferred" | "ObjectWriter" | "BucketOwnerEnforced")
65
+ ) -> Types::CreateBucketOutput
66
+ | (?Hash[Symbol, untyped]) -> Types::CreateBucketOutput
67
+
68
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#delete-instance_method
69
+ def delete: (
70
+ ?expected_bucket_owner: ::String
71
+ ) -> ::Aws::EmptyStructure
72
+ | (?Hash[Symbol, untyped]) -> ::Aws::EmptyStructure
73
+
74
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#delete_objects-instance_method
75
+ def delete_objects: (
76
+ delete: {
77
+ objects: Array[
78
+ {
79
+ key: ::String,
80
+ version_id: ::String?
81
+ },
82
+ ],
83
+ quiet: bool?
84
+ },
85
+ ?mfa: ::String,
86
+ ?request_payer: ("requester"),
87
+ ?bypass_governance_retention: bool,
88
+ ?expected_bucket_owner: ::String,
89
+ ?checksum_algorithm: ("CRC32" | "CRC32C" | "SHA1" | "SHA256")
90
+ ) -> Types::DeleteObjectsOutput
91
+ | (?Hash[Symbol, untyped]) -> Types::DeleteObjectsOutput
92
+
93
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#put_object-instance_method
94
+ def put_object: (
95
+ ?acl: ("private" | "public-read" | "public-read-write" | "authenticated-read" | "aws-exec-read" | "bucket-owner-read" | "bucket-owner-full-control"),
96
+ ?body: ::String | ::StringIO | ::File,
97
+ ?cache_control: ::String,
98
+ ?content_disposition: ::String,
99
+ ?content_encoding: ::String,
100
+ ?content_language: ::String,
101
+ ?content_length: ::Integer,
102
+ ?content_md5: ::String,
103
+ ?content_type: ::String,
104
+ ?checksum_algorithm: ("CRC32" | "CRC32C" | "SHA1" | "SHA256"),
105
+ ?checksum_crc32: ::String,
106
+ ?checksum_crc32c: ::String,
107
+ ?checksum_sha1: ::String,
108
+ ?checksum_sha256: ::String,
109
+ ?expires: ::Time,
110
+ ?if_none_match: ::String,
111
+ ?grant_full_control: ::String,
112
+ ?grant_read: ::String,
113
+ ?grant_read_acp: ::String,
114
+ ?grant_write_acp: ::String,
115
+ key: ::String,
116
+ ?metadata: Hash[::String, ::String],
117
+ ?server_side_encryption: ("AES256" | "aws:kms" | "aws:kms:dsse"),
118
+ ?storage_class: ("STANDARD" | "REDUCED_REDUNDANCY" | "STANDARD_IA" | "ONEZONE_IA" | "INTELLIGENT_TIERING" | "GLACIER" | "DEEP_ARCHIVE" | "OUTPOSTS" | "GLACIER_IR" | "SNOW" | "EXPRESS_ONEZONE"),
119
+ ?website_redirect_location: ::String,
120
+ ?sse_customer_algorithm: ::String,
121
+ ?sse_customer_key: ::String,
122
+ ?sse_customer_key_md5: ::String,
123
+ ?ssekms_key_id: ::String,
124
+ ?ssekms_encryption_context: ::String,
125
+ ?bucket_key_enabled: bool,
126
+ ?request_payer: ("requester"),
127
+ ?tagging: ::String,
128
+ ?object_lock_mode: ("GOVERNANCE" | "COMPLIANCE"),
129
+ ?object_lock_retain_until_date: ::Time,
130
+ ?object_lock_legal_hold_status: ("ON" | "OFF"),
131
+ ?expected_bucket_owner: ::String
132
+ ) -> Object
133
+ | (?Hash[Symbol, untyped]) -> Object
134
+
135
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#acl-instance_method
136
+ def acl: () -> BucketAcl
137
+
138
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#cors-instance_method
139
+ def cors: () -> BucketCors
140
+
141
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#lifecycle-instance_method
142
+ def lifecycle: () -> BucketLifecycle
143
+
144
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#lifecycle_configuration-instance_method
145
+ def lifecycle_configuration: () -> BucketLifecycleConfiguration
146
+
147
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#logging-instance_method
148
+ def logging: () -> BucketLogging
149
+
150
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#multipart_uploads-instance_method
151
+ def multipart_uploads: (
152
+ ?delimiter: ::String,
153
+ ?encoding_type: ("url"),
154
+ ?key_marker: ::String,
155
+ ?prefix: ::String,
156
+ ?upload_id_marker: ::String,
157
+ ?expected_bucket_owner: ::String,
158
+ ?request_payer: ("requester")
159
+ ) -> MultipartUpload::Collection
160
+ | (?Hash[Symbol, untyped]) -> MultipartUpload::Collection
161
+
162
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#notification-instance_method
163
+ def notification: () -> BucketNotification
164
+
165
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#object-instance_method
166
+ def object: (String key) -> Object
167
+
168
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#object_versions-instance_method
169
+ def object_versions: (
170
+ ?delimiter: ::String,
171
+ ?encoding_type: ("url"),
172
+ ?key_marker: ::String,
173
+ ?prefix: ::String,
174
+ ?version_id_marker: ::String,
175
+ ?expected_bucket_owner: ::String,
176
+ ?request_payer: ("requester"),
177
+ ?optional_object_attributes: Array[("RestoreStatus")]
178
+ ) -> ObjectVersion::Collection
179
+ | (?Hash[Symbol, untyped]) -> ObjectVersion::Collection
180
+
181
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#objects-instance_method
182
+ def objects: (
183
+ ?delimiter: ::String,
184
+ ?encoding_type: ("url"),
185
+ ?prefix: ::String,
186
+ ?fetch_owner: bool,
187
+ ?start_after: ::String,
188
+ ?request_payer: ("requester"),
189
+ ?expected_bucket_owner: ::String,
190
+ ?optional_object_attributes: Array[("RestoreStatus")]
191
+ ) -> ObjectSummary::Collection
192
+ | (?Hash[Symbol, untyped]) -> ObjectSummary::Collection
193
+
194
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#policy-instance_method
195
+ def policy: () -> BucketPolicy
196
+
197
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#request_payment-instance_method
198
+ def request_payment: () -> BucketRequestPayment
199
+
200
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#tagging-instance_method
201
+ def tagging: () -> BucketTagging
202
+
203
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#versioning-instance_method
204
+ def versioning: () -> BucketVersioning
205
+
206
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/Bucket.html#website-instance_method
207
+ def website: () -> BucketWebsite
208
+
209
+ class Collection < ::Aws::Resources::Collection[Bucket]
210
+ end
211
+ end
212
+ end
213
+ end
@@ -0,0 +1,78 @@
1
+ # WARNING ABOUT GENERATED CODE
2
+ #
3
+ # This file is generated. See the contributing guide for more information:
4
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
5
+ #
6
+ # WARNING ABOUT GENERATED CODE
7
+
8
+ module Aws
9
+ module S3
10
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketAcl.html
11
+ class BucketAcl
12
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketAcl.html#initialize-instance_method
13
+ def initialize: (String bucket_name, Hash[Symbol, untyped] options) -> void
14
+ | (bucket_name: String, ?client: Client) -> void
15
+ | (Hash[Symbol, untyped] args) -> void
16
+
17
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketAcl.html#bucket_name-instance_method
18
+ def bucket_name: () -> String
19
+
20
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketAcl.html#owner-instance_method
21
+ def owner: () -> Types::Owner
22
+
23
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketAcl.html#grants-instance_method
24
+ def grants: () -> ::Array[Types::Grant]
25
+
26
+ def client: () -> Client
27
+
28
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketAcl.html#load-instance_method
29
+ def load: () -> self
30
+ alias reload load
31
+
32
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketAcl.html#data-instance_method
33
+ def data: () -> Types::GetBucketAclOutput
34
+
35
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketAcl.html#data_loaded?-instance_method
36
+ def data_loaded?: () -> bool
37
+
38
+
39
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketAcl.html#put-instance_method
40
+ def put: (
41
+ ?acl: ("private" | "public-read" | "public-read-write" | "authenticated-read"),
42
+ ?access_control_policy: {
43
+ grants: Array[
44
+ {
45
+ grantee: {
46
+ display_name: ::String?,
47
+ email_address: ::String?,
48
+ id: ::String?,
49
+ type: ("CanonicalUser" | "AmazonCustomerByEmail" | "Group"),
50
+ uri: ::String?
51
+ }?,
52
+ permission: ("FULL_CONTROL" | "WRITE" | "WRITE_ACP" | "READ" | "READ_ACP")?
53
+ },
54
+ ]?,
55
+ owner: {
56
+ display_name: ::String?,
57
+ id: ::String?
58
+ }?
59
+ },
60
+ ?content_md5: ::String,
61
+ ?checksum_algorithm: ("CRC32" | "CRC32C" | "SHA1" | "SHA256"),
62
+ ?grant_full_control: ::String,
63
+ ?grant_read: ::String,
64
+ ?grant_read_acp: ::String,
65
+ ?grant_write: ::String,
66
+ ?grant_write_acp: ::String,
67
+ ?expected_bucket_owner: ::String
68
+ ) -> ::Aws::EmptyStructure
69
+ | (?Hash[Symbol, untyped]) -> ::Aws::EmptyStructure
70
+
71
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketAcl.html#bucket-instance_method
72
+ def bucket: () -> Bucket
73
+
74
+ class Collection < ::Aws::Resources::Collection[BucketAcl]
75
+ end
76
+ end
77
+ end
78
+ end
@@ -0,0 +1,69 @@
1
+ # WARNING ABOUT GENERATED CODE
2
+ #
3
+ # This file is generated. See the contributing guide for more information:
4
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
5
+ #
6
+ # WARNING ABOUT GENERATED CODE
7
+
8
+ module Aws
9
+ module S3
10
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketCors.html
11
+ class BucketCors
12
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketCors.html#initialize-instance_method
13
+ def initialize: (String bucket_name, Hash[Symbol, untyped] options) -> void
14
+ | (bucket_name: String, ?client: Client) -> void
15
+ | (Hash[Symbol, untyped] args) -> void
16
+
17
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketCors.html#bucket_name-instance_method
18
+ def bucket_name: () -> String
19
+
20
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketCors.html#cors_rules-instance_method
21
+ def cors_rules: () -> ::Array[Types::CORSRule]
22
+
23
+ def client: () -> Client
24
+
25
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketCors.html#load-instance_method
26
+ def load: () -> self
27
+ alias reload load
28
+
29
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketCors.html#data-instance_method
30
+ def data: () -> Types::GetBucketCorsOutput
31
+
32
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketCors.html#data_loaded?-instance_method
33
+ def data_loaded?: () -> bool
34
+
35
+
36
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketCors.html#delete-instance_method
37
+ def delete: (
38
+ ?expected_bucket_owner: ::String
39
+ ) -> ::Aws::EmptyStructure
40
+ | (?Hash[Symbol, untyped]) -> ::Aws::EmptyStructure
41
+
42
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketCors.html#put-instance_method
43
+ def put: (
44
+ cors_configuration: {
45
+ cors_rules: Array[
46
+ {
47
+ id: ::String?,
48
+ allowed_headers: Array[::String]?,
49
+ allowed_methods: Array[::String],
50
+ allowed_origins: Array[::String],
51
+ expose_headers: Array[::String]?,
52
+ max_age_seconds: ::Integer?
53
+ },
54
+ ]
55
+ },
56
+ ?content_md5: ::String,
57
+ ?checksum_algorithm: ("CRC32" | "CRC32C" | "SHA1" | "SHA256"),
58
+ ?expected_bucket_owner: ::String
59
+ ) -> ::Aws::EmptyStructure
60
+ | (?Hash[Symbol, untyped]) -> ::Aws::EmptyStructure
61
+
62
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketCors.html#bucket-instance_method
63
+ def bucket: () -> Bucket
64
+
65
+ class Collection < ::Aws::Resources::Collection[BucketCors]
66
+ end
67
+ end
68
+ end
69
+ end
@@ -0,0 +1,88 @@
1
+ # WARNING ABOUT GENERATED CODE
2
+ #
3
+ # This file is generated. See the contributing guide for more information:
4
+ # https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
5
+ #
6
+ # WARNING ABOUT GENERATED CODE
7
+
8
+ module Aws
9
+ module S3
10
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketLifecycle.html
11
+ class BucketLifecycle
12
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketLifecycle.html#initialize-instance_method
13
+ def initialize: (String bucket_name, Hash[Symbol, untyped] options) -> void
14
+ | (bucket_name: String, ?client: Client) -> void
15
+ | (Hash[Symbol, untyped] args) -> void
16
+
17
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketLifecycle.html#bucket_name-instance_method
18
+ def bucket_name: () -> String
19
+
20
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketLifecycle.html#rules-instance_method
21
+ def rules: () -> ::Array[Types::Rule]
22
+
23
+ def client: () -> Client
24
+
25
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketLifecycle.html#load-instance_method
26
+ def load: () -> self
27
+ alias reload load
28
+
29
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketLifecycle.html#data-instance_method
30
+ def data: () -> Types::GetBucketLifecycleOutput
31
+
32
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketLifecycle.html#data_loaded?-instance_method
33
+ def data_loaded?: () -> bool
34
+
35
+
36
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketLifecycle.html#delete-instance_method
37
+ def delete: (
38
+ ?expected_bucket_owner: ::String
39
+ ) -> ::Aws::EmptyStructure
40
+ | (?Hash[Symbol, untyped]) -> ::Aws::EmptyStructure
41
+
42
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketLifecycle.html#put-instance_method
43
+ def put: (
44
+ ?content_md5: ::String,
45
+ ?checksum_algorithm: ("CRC32" | "CRC32C" | "SHA1" | "SHA256"),
46
+ ?lifecycle_configuration: {
47
+ rules: Array[
48
+ {
49
+ expiration: {
50
+ date: ::Time?,
51
+ days: ::Integer?,
52
+ expired_object_delete_marker: bool?
53
+ }?,
54
+ id: ::String?,
55
+ prefix: ::String,
56
+ status: ("Enabled" | "Disabled"),
57
+ transition: {
58
+ date: ::Time?,
59
+ days: ::Integer?,
60
+ storage_class: ("GLACIER" | "STANDARD_IA" | "ONEZONE_IA" | "INTELLIGENT_TIERING" | "DEEP_ARCHIVE" | "GLACIER_IR")?
61
+ }?,
62
+ noncurrent_version_transition: {
63
+ noncurrent_days: ::Integer?,
64
+ storage_class: ("GLACIER" | "STANDARD_IA" | "ONEZONE_IA" | "INTELLIGENT_TIERING" | "DEEP_ARCHIVE" | "GLACIER_IR")?,
65
+ newer_noncurrent_versions: ::Integer?
66
+ }?,
67
+ noncurrent_version_expiration: {
68
+ noncurrent_days: ::Integer?,
69
+ newer_noncurrent_versions: ::Integer?
70
+ }?,
71
+ abort_incomplete_multipart_upload: {
72
+ days_after_initiation: ::Integer?
73
+ }?
74
+ },
75
+ ]
76
+ },
77
+ ?expected_bucket_owner: ::String
78
+ ) -> ::Aws::EmptyStructure
79
+ | (?Hash[Symbol, untyped]) -> ::Aws::EmptyStructure
80
+
81
+ # https://docs.aws.amazon.com/sdk-for-ruby/v3/api/Aws/S3/BucketLifecycle.html#bucket-instance_method
82
+ def bucket: () -> Bucket
83
+
84
+ class Collection < ::Aws::Resources::Collection[BucketLifecycle]
85
+ end
86
+ end
87
+ end
88
+ end