Class: HTTPClient::OAuth::Config

Inherits:
Object
  • Object
show all
Includes:
Util
Defined in:
lib/httpclient/auth.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Util

#argument_to_hash, hash_find_value, #http?, #https?, #keyword_argument, try_require, uri_dirname, uri_part_of, urify, #warning

Constructor Details

#initialize(*args) ⇒ Config

Returns a new instance of Config.



707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
# File 'lib/httpclient/auth.rb', line 707

def initialize(*args)
  @http_method,
    @realm,
    @consumer_key,
    @consumer_secret,
    @token,
    @secret,
    @signature_method,
    @version,
    @callback,
    @verifier =
  keyword_argument(args,
    :http_method,
    :realm,
    :consumer_key,
    :consumer_secret,
    :token,
    :secret,
    :signature_method,
    :version,
    :callback,
    :verifier
  )
  @http_method ||= :post
  @session_handle = nil
  @signature_handler = {}
end

Instance Attribute Details

#callbackObject

Returns the value of attribute callback.



696
697
698
# File 'lib/httpclient/auth.rb', line 696

def callback
  @callback
end

#consumer_keyObject

Returns the value of attribute consumer_key.



690
691
692
# File 'lib/httpclient/auth.rb', line 690

def consumer_key
  @consumer_key
end

#consumer_secretObject

Returns the value of attribute consumer_secret.



691
692
693
# File 'lib/httpclient/auth.rb', line 691

def consumer_secret
  @consumer_secret
end

#debug_nonceObject

Returns the value of attribute debug_nonce.



705
706
707
# File 'lib/httpclient/auth.rb', line 705

def debug_nonce
  @debug_nonce
end

#debug_timestampObject

Returns the value of attribute debug_timestamp.



704
705
706
# File 'lib/httpclient/auth.rb', line 704

def debug_timestamp
  @debug_timestamp
end

#http_methodObject

Returns the value of attribute http_method.



688
689
690
# File 'lib/httpclient/auth.rb', line 688

def http_method
  @http_method
end

#realmObject

Returns the value of attribute realm.



689
690
691
# File 'lib/httpclient/auth.rb', line 689

def realm
  @realm
end

#secretObject

Returns the value of attribute secret.



693
694
695
# File 'lib/httpclient/auth.rb', line 693

def secret
  @secret
end

#session_handleObject

for OAuth Session 1.0 (draft)



700
701
702
# File 'lib/httpclient/auth.rb', line 700

def session_handle
  @session_handle
end

#signature_handlerObject (readonly)

Returns the value of attribute signature_handler.



702
703
704
# File 'lib/httpclient/auth.rb', line 702

def signature_handler
  @signature_handler
end

#signature_methodObject

Returns the value of attribute signature_method.



694
695
696
# File 'lib/httpclient/auth.rb', line 694

def signature_method
  @signature_method
end

#tokenObject

Returns the value of attribute token.



692
693
694
# File 'lib/httpclient/auth.rb', line 692

def token
  @token
end

#verifierObject

Returns the value of attribute verifier.



697
698
699
# File 'lib/httpclient/auth.rb', line 697

def verifier
  @verifier
end

#versionObject

Returns the value of attribute version.



695
696
697
# File 'lib/httpclient/auth.rb', line 695

def version
  @version
end