Class: Xero::Configuration
- Inherits:
-
Object
- Object
- Xero::Configuration
- Defined in:
- lib/xero/configuration.rb
Instance Attribute Summary collapse
-
#consumer_key ⇒ Object
Returns the value of attribute consumer_key.
-
#consumer_secret ⇒ Object
Returns the value of attribute consumer_secret.
-
#invoice_due_days ⇒ Object
Returns the value of attribute invoice_due_days.
-
#logger ⇒ Object
Returns the value of attribute logger.
-
#private_key_path ⇒ Object
Returns the value of attribute private_key_path.
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ Configuration
constructor
A new instance of Configuration.
- #xero_url ⇒ Object
Constructor Details
#initialize(options = {}) ⇒ Configuration
Returns a new instance of Configuration.
7 8 9 10 11 |
# File 'lib/xero/configuration.rb', line 7 def initialize( = {}) = { invoice_due_days: 30 }.merge() .each { |key, value| self.send("#{key}=", value) } self end |
Instance Attribute Details
#consumer_key ⇒ Object
Returns the value of attribute consumer_key.
4 5 6 |
# File 'lib/xero/configuration.rb', line 4 def consumer_key @consumer_key end |
#consumer_secret ⇒ Object
Returns the value of attribute consumer_secret.
4 5 6 |
# File 'lib/xero/configuration.rb', line 4 def consumer_secret @consumer_secret end |
#invoice_due_days ⇒ Object
Returns the value of attribute invoice_due_days.
4 5 6 |
# File 'lib/xero/configuration.rb', line 4 def invoice_due_days @invoice_due_days end |
#logger ⇒ Object
Returns the value of attribute logger.
4 5 6 |
# File 'lib/xero/configuration.rb', line 4 def logger @logger end |
#private_key_path ⇒ Object
Returns the value of attribute private_key_path.
4 5 6 |
# File 'lib/xero/configuration.rb', line 4 def private_key_path @private_key_path end |
Instance Method Details
#xero_url ⇒ Object
17 18 19 |
# File 'lib/xero/configuration.rb', line 17 def xero_url 'https://api.xero.com/api.xro/2.0' end |