Class: Brick::AirtableApiCaller::AirtableTable

Inherits:
Object
  • Object
show all
Defined in:
lib/generators/brick/airtable_api_caller.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(id, name, primary_key = nil, fields = nil, views = nil, base_id = nil) ⇒ AirtableTable

Returns a new instance of AirtableTable.



154
155
156
157
158
159
160
161
162
163
# File 'lib/generators/brick/airtable_api_caller.rb', line 154

def initialize(id, name,
               primary_key = nil, fields = nil, views = nil, base_id = nil)
  self.id = id
  self.name = name
  self.primary_key = primary_key
  self.fields = fields
  self.views = views
  self.base_id = base_id
  self.objects = {}
end

Instance Attribute Details

#base_idObject

Returns the value of attribute base_id.



153
154
155
# File 'lib/generators/brick/airtable_api_caller.rb', line 153

def base_id
  @base_id
end

#fieldsObject

Returns the value of attribute fields.



153
154
155
# File 'lib/generators/brick/airtable_api_caller.rb', line 153

def fields
  @fields
end

#idObject

Returns the value of attribute id.



153
154
155
# File 'lib/generators/brick/airtable_api_caller.rb', line 153

def id
  @id
end

#nameObject

Returns the value of attribute name.



153
154
155
# File 'lib/generators/brick/airtable_api_caller.rb', line 153

def name
  @name
end

#objectsObject

Returns the value of attribute objects.



153
154
155
# File 'lib/generators/brick/airtable_api_caller.rb', line 153

def objects
  @objects
end

#primary_keyObject

Returns the value of attribute primary_key.



153
154
155
# File 'lib/generators/brick/airtable_api_caller.rb', line 153

def primary_key
  @primary_key
end

#viewsObject

Returns the value of attribute views.



153
154
155
# File 'lib/generators/brick/airtable_api_caller.rb', line 153

def views
  @views
end

Instance Method Details

#to_sObject



165
166
167
# File 'lib/generators/brick/airtable_api_caller.rb', line 165

def to_s
  name
end