Class: Crunchbase::Founder
- Defined in:
- lib/crunchbase/founder.rb
Constant Summary collapse
- RESOURCE_LIST =
'founders'
Constants inherited from CBEntity
Instance Attribute Summary collapse
-
#created_at ⇒ Object
readonly
Returns the value of attribute created_at.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#path ⇒ Object
readonly
Returns the value of attribute path.
-
#permalink ⇒ Object
readonly
Returns the value of attribute permalink.
-
#type_name ⇒ Object
readonly
Returns the value of attribute type_name.
-
#updated_at ⇒ Object
readonly
Returns the value of attribute updated_at.
Instance Method Summary collapse
-
#initialize(json) ⇒ Founder
constructor
A new instance of Founder.
Methods inherited from CBEntity
array_from_list, category_lists_by_permalink, #fetch, get, list, lists_for_permalink, lists_for_person_permalink, parsing_from_list, search, total_items_from_list
Constructor Details
#initialize(json) ⇒ Founder
Returns a new instance of Founder.
12 13 14 15 16 17 18 19 |
# File 'lib/crunchbase/founder.rb', line 12 def initialize(json) @type_name = json['type'] @name = json['name'] @path = json['path'] @permalink = (json['path'] && json['path'].gsub('person/', '')) @created_at = Time.at(json['created_at']).utc @updated_at = Time.at(json['updated_at']).utc end |
Instance Attribute Details
#created_at ⇒ Object (readonly)
Returns the value of attribute created_at.
10 11 12 |
# File 'lib/crunchbase/founder.rb', line 10 def created_at @created_at end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
10 11 12 |
# File 'lib/crunchbase/founder.rb', line 10 def name @name end |
#path ⇒ Object (readonly)
Returns the value of attribute path.
10 11 12 |
# File 'lib/crunchbase/founder.rb', line 10 def path @path end |
#permalink ⇒ Object (readonly)
Returns the value of attribute permalink.
10 11 12 |
# File 'lib/crunchbase/founder.rb', line 10 def permalink @permalink end |
#type_name ⇒ Object (readonly)
Returns the value of attribute type_name.
10 11 12 |
# File 'lib/crunchbase/founder.rb', line 10 def type_name @type_name end |
#updated_at ⇒ Object (readonly)
Returns the value of attribute updated_at.
10 11 12 |
# File 'lib/crunchbase/founder.rb', line 10 def updated_at @updated_at end |