Class: Aws::Crt::Auth::StaticCredentialsProvider

Inherits:
Object
  • Object
show all
Includes:
ManagedNative
Defined in:
lib/aws-crt/auth/static_credentials_provider.rb

Overview

Utility class for Credentials.

Instance Method Summary collapse

Methods included from ManagedNative

included, #manage_native, #native, #native_set?, #release

Constructor Details

#initialize(access_key_id, secret_access_key, session_token = nil) ⇒ StaticCredentialsProvider

Returns a new instance of StaticCredentialsProvider.

Parameters:

  • access_key_id (String)
  • secret_access_key (String)
  • session_token (String) (defaults to: nil)

    (nil)



52
53
54
55
56
57
58
59
60
61
62
63
64
# File 'lib/aws-crt/auth/static_credentials_provider.rb', line 52

def initialize(access_key_id, secret_access_key,
               session_token = nil)

  credential_options = StaticCredentialsProviderOptions.new(
    access_key_id, secret_access_key,
    session_token
  )
  manage_native do
    Aws::Crt::Native.credentials_provider_static_new(
      credential_options.native
    )
  end
end