Class: Datafiniti::Products

Inherits:
Api
  • Object
show all
Defined in:
lib/datafiniti/products.rb

Instance Attribute Summary collapse

Attributes inherited from Api

#conn, #status, #token

Instance Method Summary collapse

Methods inherited from Api

#default_to_csv, #default_to_json, #download, #method_missing, #solr_query, #where

Constructor Details

#initialize(args = {}) ⇒ Products

Returns a new instance of Products.



13
14
15
16
# File 'lib/datafiniti/products.rb', line 13

def initialize(args={})
  @format = "json"
  super(args)
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class Datafiniti::Api

Instance Attribute Details

#formatObject

Returns the value of attribute format.



7
8
9
# File 'lib/datafiniti/products.rb', line 7

def format
  @format
end

#previewObject (readonly)

Returns the value of attribute preview.



11
12
13
# File 'lib/datafiniti/products.rb', line 11

def preview
  @preview
end

#recordsObject (readonly)

Returns the value of attribute records.



9
10
11
# File 'lib/datafiniti/products.rb', line 9

def records
  @records
end

#responseObject

Returns the value of attribute response.



8
9
10
# File 'lib/datafiniti/products.rb', line 8

def response
  @response
end

#totalObject (readonly)

Returns the value of attribute total.



10
11
12
# File 'lib/datafiniti/products.rb', line 10

def total
  @total
end