Class: KineticSdk::CustomHttp
- Inherits:
-
Object
- Object
- KineticSdk::CustomHttp
- Includes:
- Utils::KineticHttpUtils
- Defined in:
- lib/kinetic_sdk/utils/kinetic-http.rb
Overview
The CustomHttp class provides functionality to make generic HTTP requests utilizing the functionality of the KineticSdk.
Instance Attribute Summary collapse
-
#logger ⇒ Object
Returns the value of attribute logger.
-
#options ⇒ Object
Returns the value of attribute options.
-
#password ⇒ Object
Returns the value of attribute password.
-
#username ⇒ Object
Returns the value of attribute username.
Instance Method Summary collapse
-
#initialize(opts = {}) ⇒ CustomHttp
constructor
Constructor.
Methods included from Utils::KineticHttpUtils
#default_headers, default_headers, #default_jwt_headers, default_jwt_headers, #delete, #encode, #gateway_retry_delay, #gateway_retry_limit, #get, #head, #header_accept_json, header_accept_json, #header_basic_auth, header_basic_auth, header_bearer_auth, #header_bearer_auth, #header_content_json, header_content_json, header_user_agent, #header_user_agent, #max_redirects, #mimetype, #patch, #post, #post_multipart, #put, #redirect_url, #stream_download_to_file
Constructor Details
#initialize(opts = {}) ⇒ CustomHttp
Constructor
831 832 833 834 835 836 837 838 |
# File 'lib/kinetic_sdk/utils/kinetic-http.rb', line 831 def initialize(opts={}) @username = opts[:username] @password = opts[:password] @options = opts.delete(:options) || {} log_level = @options[:log_level] || @options["log_level"] log_output = @options[:log_output] || @options["log_output"] @logger = KineticSdk::Utils::KLogger.new(log_level, log_output) end |
Instance Attribute Details
#logger ⇒ Object
Returns the value of attribute logger.
816 817 818 |
# File 'lib/kinetic_sdk/utils/kinetic-http.rb', line 816 def logger @logger end |
#options ⇒ Object
Returns the value of attribute options.
816 817 818 |
# File 'lib/kinetic_sdk/utils/kinetic-http.rb', line 816 def @options end |
#password ⇒ Object
Returns the value of attribute password.
816 817 818 |
# File 'lib/kinetic_sdk/utils/kinetic-http.rb', line 816 def password @password end |
#username ⇒ Object
Returns the value of attribute username.
816 817 818 |
# File 'lib/kinetic_sdk/utils/kinetic-http.rb', line 816 def username @username end |