Class: PipeLineDealer::Client
- Inherits:
-
Object
- Object
- PipeLineDealer::Client
- Defined in:
- lib/pipe_line_dealer/client.rb,
lib/pipe_line_dealer/client/connection.rb
Defined Under Namespace
Classes: Connection
Instance Attribute Summary collapse
-
#connection ⇒ Object
readonly
Returns the value of attribute connection.
Instance Method Summary collapse
- #companies ⇒ Object
- #custom_company_fields ⇒ Object
- #custom_person_fields ⇒ Object
-
#initialize(api_key, options = {}) ⇒ Client
constructor
A new instance of Client.
- #people ⇒ Object
Constructor Details
#initialize(api_key, options = {}) ⇒ Client
Returns a new instance of Client.
7 8 9 |
# File 'lib/pipe_line_dealer/client.rb', line 7 def initialize(api_key, = {}) @connection = Connection.new(api_key, ) end |
Instance Attribute Details
#connection ⇒ Object (readonly)
Returns the value of attribute connection.
5 6 7 |
# File 'lib/pipe_line_dealer/client.rb', line 5 def connection @connection end |
Instance Method Details
#companies ⇒ Object
11 12 13 |
# File 'lib/pipe_line_dealer/client.rb', line 11 def companies Collection.new(self, klass: Company) end |
#custom_company_fields ⇒ Object
15 16 17 |
# File 'lib/pipe_line_dealer/client.rb', line 15 def custom_company_fields CustomField::Collection.new(self, klass: Company::CustomField) end |
#custom_person_fields ⇒ Object
23 24 25 |
# File 'lib/pipe_line_dealer/client.rb', line 23 def custom_person_fields CustomField::Collection.new(self, klass: Person::CustomField) end |
#people ⇒ Object
19 20 21 |
# File 'lib/pipe_line_dealer/client.rb', line 19 def people Collection.new(self, klass: Person) end |