Class: ConnectWiseRest::Configuration
- Inherits:
-
Object
- Object
- ConnectWiseRest::Configuration
- Defined in:
- lib/connect_wise_rest/configuration.rb
Instance Attribute Summary collapse
-
#company_id ⇒ Object
Returns the value of attribute company_id.
-
#debug ⇒ Object
Returns the value of attribute debug.
-
#logger ⇒ Object
Returns the value of attribute logger.
-
#private_key ⇒ Object
Returns the value of attribute private_key.
-
#proxy_host ⇒ Object
Returns the value of attribute proxy_host.
-
#proxy_password ⇒ Object
Returns the value of attribute proxy_password.
-
#proxy_port ⇒ Object
Returns the value of attribute proxy_port.
-
#proxy_user ⇒ Object
Returns the value of attribute proxy_user.
-
#public_key ⇒ Object
Returns the value of attribute public_key.
-
#request_options ⇒ Object
Returns the value of attribute request_options.
-
#url_prefix ⇒ Object
Returns the value of attribute url_prefix.
-
#version ⇒ Object
Returns the value of attribute version.
Instance Method Summary collapse
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
- #set(options = {}) ⇒ Object
- #to_hash ⇒ Object
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
19 20 21 22 23 |
# File 'lib/connect_wise_rest/configuration.rb', line 19 def initialize @version = '3.0' @debug = false @logger = $stdout end |
Instance Attribute Details
#company_id ⇒ Object
Returns the value of attribute company_id.
16 17 18 |
# File 'lib/connect_wise_rest/configuration.rb', line 16 def company_id @company_id end |
#debug ⇒ Object
Returns the value of attribute debug.
16 17 18 |
# File 'lib/connect_wise_rest/configuration.rb', line 16 def debug @debug end |
#logger ⇒ Object
Returns the value of attribute logger.
16 17 18 |
# File 'lib/connect_wise_rest/configuration.rb', line 16 def logger @logger end |
#private_key ⇒ Object
Returns the value of attribute private_key.
16 17 18 |
# File 'lib/connect_wise_rest/configuration.rb', line 16 def private_key @private_key end |
#proxy_host ⇒ Object
Returns the value of attribute proxy_host.
16 17 18 |
# File 'lib/connect_wise_rest/configuration.rb', line 16 def proxy_host @proxy_host end |
#proxy_password ⇒ Object
Returns the value of attribute proxy_password.
16 17 18 |
# File 'lib/connect_wise_rest/configuration.rb', line 16 def proxy_password @proxy_password end |
#proxy_port ⇒ Object
Returns the value of attribute proxy_port.
16 17 18 |
# File 'lib/connect_wise_rest/configuration.rb', line 16 def proxy_port @proxy_port end |
#proxy_user ⇒ Object
Returns the value of attribute proxy_user.
16 17 18 |
# File 'lib/connect_wise_rest/configuration.rb', line 16 def proxy_user @proxy_user end |
#public_key ⇒ Object
Returns the value of attribute public_key.
16 17 18 |
# File 'lib/connect_wise_rest/configuration.rb', line 16 def public_key @public_key end |
#request_options ⇒ Object
Returns the value of attribute request_options.
16 17 18 |
# File 'lib/connect_wise_rest/configuration.rb', line 16 def end |
#url_prefix ⇒ Object
Returns the value of attribute url_prefix.
16 17 18 |
# File 'lib/connect_wise_rest/configuration.rb', line 16 def url_prefix @url_prefix end |
#version ⇒ Object
Returns the value of attribute version.
16 17 18 |
# File 'lib/connect_wise_rest/configuration.rb', line 16 def version @version end |
Instance Method Details
#set(options = {}) ⇒ Object
25 26 27 |
# File 'lib/connect_wise_rest/configuration.rb', line 25 def set( = {}) .each { |k, v| self.send("#{k.to_s}=", v) } end |
#to_hash ⇒ Object
29 30 31 32 33 |
# File 'lib/connect_wise_rest/configuration.rb', line 29 def to_hash hash = {} instance_variables.each { |var| hash[var.to_s.delete('@').to_sym] = instance_variable_get(var) } hash end |