Class: RippleToken::Client

Inherits:
Object
  • Object
show all
Includes:
HTTParty
Defined in:
lib/ripple_token/client.rb

Class Method Summary collapse

Class Method Details

.configure {|configuration| ... } ⇒ Object

Yields:

  • (configuration)


16
17
18
19
20
21
# File 'lib/ripple_token/client.rb', line 16

def configure
  @configuration = Configuration.new
  yield(configuration)
  fetch_public_key
  'Public key retrieved successfully'
end

.public_keyObject



23
24
25
26
27
# File 'lib/ripple_token/client.rb', line 23

def public_key
  fetch_public_key if (last_update_at + public_key_ttl) < Time.now

  @public_key
end