Class: OAuth::Token
- Includes:
- Helper
- Defined in:
- lib/oauth/tokens/token.rb
Overview
Superclass for the various tokens used by OAuth
Direct Known Subclasses
Instance Attribute Summary collapse
-
#secret ⇒ Object
Returns the value of attribute secret.
-
#token ⇒ Object
Returns the value of attribute token.
Instance Method Summary collapse
-
#initialize(token, secret) ⇒ Token
constructor
A new instance of Token.
- #to_query ⇒ Object
Methods included from Helper
#escape, #generate_key, #generate_timestamp, #normalize, #normalize_nested_query, #parse_header, #stringify_keys, #unescape
Constructor Details
#initialize(token, secret) ⇒ Token
Returns a new instance of Token.
8 9 10 11 |
# File 'lib/oauth/tokens/token.rb', line 8 def initialize(token, secret) @token = token @secret = secret end |
Instance Attribute Details
#secret ⇒ Object
Returns the value of attribute secret.
6 7 8 |
# File 'lib/oauth/tokens/token.rb', line 6 def secret @secret end |
#token ⇒ Object
Returns the value of attribute token.
6 7 8 |
# File 'lib/oauth/tokens/token.rb', line 6 def token @token end |
Instance Method Details
#to_query ⇒ Object
13 14 15 |
# File 'lib/oauth/tokens/token.rb', line 13 def to_query "oauth_token=#{escape(token)}&oauth_secret=#{escape(secret)}" end |