Class: Aws::S3::ExpressCredentialsCache Private
- Inherits:
-
Object
- Object
- Aws::S3::ExpressCredentialsCache
- Defined in:
- lib/aws-sdk-s3/express_credentials_cache.rb
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Instance Method Summary collapse
- #[](bucket_name) ⇒ Object private
- #[]=(bucket_name, credential_provider) ⇒ Object private
- #clear ⇒ Object private
-
#initialize ⇒ ExpressCredentialsCache
constructor
private
A new instance of ExpressCredentialsCache.
Constructor Details
#initialize ⇒ ExpressCredentialsCache
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of ExpressCredentialsCache.
7 8 9 10 |
# File 'lib/aws-sdk-s3/express_credentials_cache.rb', line 7 def initialize @credentials = {} @mutex = Mutex.new end |
Instance Method Details
#[](bucket_name) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
12 13 14 |
# File 'lib/aws-sdk-s3/express_credentials_cache.rb', line 12 def [](bucket_name) @mutex.synchronize { @credentials[bucket_name] } end |
#[]=(bucket_name, credential_provider) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
16 17 18 19 20 |
# File 'lib/aws-sdk-s3/express_credentials_cache.rb', line 16 def []=(bucket_name, credential_provider) @mutex.synchronize do @credentials[bucket_name] = credential_provider end end |
#clear ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
22 23 24 |
# File 'lib/aws-sdk-s3/express_credentials_cache.rb', line 22 def clear @mutex.synchronize { @credentials = {} } end |