Class: MAuth::Client::LocalAuthenticator::SecurityTokenCacher::ExpirableSecurityToken

Inherits:
Struct
  • Object
show all
Defined in:
lib/mauth/client.rb

Constant Summary collapse

CACHE_LIFE =
60

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#create_timeObject

Returns the value of attribute create_time

Returns:

  • (Object)

    the current value of create_time



404
405
406
# File 'lib/mauth/client.rb', line 404

def create_time
  @create_time
end

#security_tokenObject

Returns the value of attribute security_token

Returns:

  • (Object)

    the current value of security_token



404
405
406
# File 'lib/mauth/client.rb', line 404

def security_token
  @security_token
end

Instance Method Details

#expired?Boolean

Returns:

  • (Boolean)


406
407
408
# File 'lib/mauth/client.rb', line 406

def expired?
  create_time + CACHE_LIFE < Time.now
end