Class: Crunchbase::Model::Person
- Defined in:
- lib/crunchbase/model/person.rb
Direct Known Subclasses
Constant Summary collapse
- RESOURCE_LIST =
RESOURCE_NAME = 'people'
Instance Attribute Summary collapse
-
#advisory_roles ⇒ Object
readonly
Returns the value of attribute advisory_roles.
-
#advisory_roles_total_items ⇒ Object
readonly
Returns the value of attribute advisory_roles_total_items.
-
#also_known_as ⇒ Object
readonly
Returns the value of attribute also_known_as.
-
#api_path ⇒ Object
readonly
Returns the value of attribute api_path.
-
#api_url ⇒ Object
readonly
Returns the value of attribute api_url.
-
#bio ⇒ Object
readonly
Returns the value of attribute bio.
-
#born_on ⇒ Object
readonly
Returns the value of attribute born_on.
-
#born_on_trust_code ⇒ Object
readonly
Returns the value of attribute born_on_trust_code.
-
#created_at ⇒ Object
readonly
Returns the value of attribute created_at.
-
#degrees ⇒ Object
readonly
Returns the value of attribute degrees.
-
#degrees_total_items ⇒ Object
readonly
Returns the value of attribute degrees_total_items.
-
#died_on ⇒ Object
readonly
Returns the value of attribute died_on.
-
#died_on_trust_code ⇒ Object
readonly
Returns the value of attribute died_on_trust_code.
-
#first_name ⇒ Object
readonly
Returns the value of attribute first_name.
-
#founded_companies ⇒ Object
readonly
Returns the value of attribute founded_companies.
-
#founded_companies_total_items ⇒ Object
readonly
Returns the value of attribute founded_companies_total_items.
-
#gender ⇒ Object
readonly
Returns the value of attribute gender.
-
#images ⇒ Object
readonly
Returns the value of attribute images.
-
#images_total_items ⇒ Object
readonly
Returns the value of attribute images_total_items.
-
#investments ⇒ Object
readonly
Returns the value of attribute investments.
-
#investments_total_items ⇒ Object
readonly
Returns the value of attribute investments_total_items.
-
#is_deceased ⇒ Object
readonly
Returns the value of attribute is_deceased.
-
#jobs ⇒ Object
readonly
Returns the value of attribute jobs.
-
#jobs_total_items ⇒ Object
readonly
Returns the value of attribute jobs_total_items.
-
#last_name ⇒ Object
readonly
Returns the value of attribute last_name.
-
#memberships ⇒ Object
readonly
Returns the value of attribute memberships.
-
#memberships_total_items ⇒ Object
readonly
Returns the value of attribute memberships_total_items.
-
#news ⇒ Object
readonly
Returns the value of attribute news.
-
#news_total_items ⇒ Object
readonly
Returns the value of attribute news_total_items.
-
#permalink ⇒ Object
readonly
Returns the value of attribute permalink.
-
#permalink_aliases ⇒ Object
readonly
Returns the value of attribute permalink_aliases.
-
#primary_affiliation ⇒ Object
readonly
Returns the value of attribute primary_affiliation.
-
#primary_affiliation_total_items ⇒ Object
readonly
Returns the value of attribute primary_affiliation_total_items.
-
#primary_image ⇒ Object
readonly
Returns the value of attribute primary_image.
-
#primary_image_total_items ⇒ Object
readonly
Returns the value of attribute primary_image_total_items.
-
#primary_location ⇒ Object
readonly
Returns the value of attribute primary_location.
-
#primary_location_total_items ⇒ Object
readonly
Returns the value of attribute primary_location_total_items.
-
#profile_image_url ⇒ Object
readonly
Returns the value of attribute profile_image_url.
-
#rank ⇒ Object
readonly
Returns the value of attribute rank.
-
#role_investor ⇒ Object
readonly
Returns the value of attribute role_investor.
-
#updated_at ⇒ Object
readonly
Returns the value of attribute updated_at.
-
#videos ⇒ Object
readonly
Returns the value of attribute videos.
-
#videos_total_items ⇒ Object
readonly
Returns the value of attribute videos_total_items.
-
#web_path ⇒ Object
readonly
Returns the value of attribute web_path.
-
#websites ⇒ Object
readonly
Returns the value of attribute websites.
-
#websites_total_items ⇒ Object
readonly
Returns the value of attribute websites_total_items.
Attributes inherited from Entity
Instance Method Summary collapse
- #date_keys ⇒ Object
-
#initialize(json) ⇒ Person
constructor
A new instance of Person.
-
#name ⇒ Object
custom name from first name and last name.
- #property_keys ⇒ Object
- #relationship_lists ⇒ Object
Methods inherited from Entity
#convert_date!, #fetch, #instance_multi_relationship_objects, #instance_relationships_object, #instance_timestamps, #one_to_many, #one_to_one, #parse_hash_items, #set_relationships_object, #set_variables, #setup_relationships_data!, #special_relationship, #verify_item?
Methods included from Request::Client
#api, #array_from_list, #funding_rounds_lists, #get, #kclass_name, #list, #organization_lists, #parsing_from_list, #person_lists, #total_items_from_list
Constructor Details
#initialize(json) ⇒ Person
Returns a new instance of Person.
22 23 24 |
# File 'lib/crunchbase/model/person.rb', line 22 def initialize(json) super(json) end |
Instance Attribute Details
#advisory_roles ⇒ Object (readonly)
Returns the value of attribute advisory_roles.
13 14 15 |
# File 'lib/crunchbase/model/person.rb', line 13 def advisory_roles @advisory_roles end |
#advisory_roles_total_items ⇒ Object (readonly)
Returns the value of attribute advisory_roles_total_items.
16 17 18 |
# File 'lib/crunchbase/model/person.rb', line 16 def advisory_roles_total_items @advisory_roles_total_items end |
#also_known_as ⇒ Object (readonly)
Returns the value of attribute also_known_as.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def also_known_as @also_known_as end |
#api_path ⇒ Object (readonly)
Returns the value of attribute api_path.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def api_path @api_path end |
#api_url ⇒ Object (readonly)
Returns the value of attribute api_url.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def api_url @api_url end |
#bio ⇒ Object (readonly)
Returns the value of attribute bio.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def bio @bio end |
#born_on ⇒ Object (readonly)
Returns the value of attribute born_on.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def born_on @born_on end |
#born_on_trust_code ⇒ Object (readonly)
Returns the value of attribute born_on_trust_code.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def born_on_trust_code @born_on_trust_code end |
#created_at ⇒ Object (readonly)
Returns the value of attribute created_at.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def created_at @created_at end |
#degrees ⇒ Object (readonly)
Returns the value of attribute degrees.
13 14 15 |
# File 'lib/crunchbase/model/person.rb', line 13 def degrees @degrees end |
#degrees_total_items ⇒ Object (readonly)
Returns the value of attribute degrees_total_items.
16 17 18 |
# File 'lib/crunchbase/model/person.rb', line 16 def degrees_total_items @degrees_total_items end |
#died_on ⇒ Object (readonly)
Returns the value of attribute died_on.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def died_on @died_on end |
#died_on_trust_code ⇒ Object (readonly)
Returns the value of attribute died_on_trust_code.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def died_on_trust_code @died_on_trust_code end |
#first_name ⇒ Object (readonly)
Returns the value of attribute first_name.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def first_name @first_name end |
#founded_companies ⇒ Object (readonly)
Returns the value of attribute founded_companies.
13 14 15 |
# File 'lib/crunchbase/model/person.rb', line 13 def founded_companies @founded_companies end |
#founded_companies_total_items ⇒ Object (readonly)
Returns the value of attribute founded_companies_total_items.
16 17 18 |
# File 'lib/crunchbase/model/person.rb', line 16 def founded_companies_total_items @founded_companies_total_items end |
#gender ⇒ Object (readonly)
Returns the value of attribute gender.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def gender @gender end |
#images ⇒ Object (readonly)
Returns the value of attribute images.
13 14 15 |
# File 'lib/crunchbase/model/person.rb', line 13 def images @images end |
#images_total_items ⇒ Object (readonly)
Returns the value of attribute images_total_items.
16 17 18 |
# File 'lib/crunchbase/model/person.rb', line 16 def images_total_items @images_total_items end |
#investments ⇒ Object (readonly)
Returns the value of attribute investments.
13 14 15 |
# File 'lib/crunchbase/model/person.rb', line 13 def investments @investments end |
#investments_total_items ⇒ Object (readonly)
Returns the value of attribute investments_total_items.
16 17 18 |
# File 'lib/crunchbase/model/person.rb', line 16 def investments_total_items @investments_total_items end |
#is_deceased ⇒ Object (readonly)
Returns the value of attribute is_deceased.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def is_deceased @is_deceased end |
#jobs ⇒ Object (readonly)
Returns the value of attribute jobs.
13 14 15 |
# File 'lib/crunchbase/model/person.rb', line 13 def jobs @jobs end |
#jobs_total_items ⇒ Object (readonly)
Returns the value of attribute jobs_total_items.
16 17 18 |
# File 'lib/crunchbase/model/person.rb', line 16 def jobs_total_items @jobs_total_items end |
#last_name ⇒ Object (readonly)
Returns the value of attribute last_name.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def last_name @last_name end |
#memberships ⇒ Object (readonly)
Returns the value of attribute memberships.
13 14 15 |
# File 'lib/crunchbase/model/person.rb', line 13 def memberships @memberships end |
#memberships_total_items ⇒ Object (readonly)
Returns the value of attribute memberships_total_items.
16 17 18 |
# File 'lib/crunchbase/model/person.rb', line 16 def memberships_total_items @memberships_total_items end |
#news ⇒ Object (readonly)
Returns the value of attribute news.
13 14 15 |
# File 'lib/crunchbase/model/person.rb', line 13 def news @news end |
#news_total_items ⇒ Object (readonly)
Returns the value of attribute news_total_items.
16 17 18 |
# File 'lib/crunchbase/model/person.rb', line 16 def news_total_items @news_total_items end |
#permalink ⇒ Object (readonly)
Returns the value of attribute permalink.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def permalink @permalink end |
#permalink_aliases ⇒ Object (readonly)
Returns the value of attribute permalink_aliases.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def permalink_aliases @permalink_aliases end |
#primary_affiliation ⇒ Object (readonly)
Returns the value of attribute primary_affiliation.
13 14 15 |
# File 'lib/crunchbase/model/person.rb', line 13 def primary_affiliation @primary_affiliation end |
#primary_affiliation_total_items ⇒ Object (readonly)
Returns the value of attribute primary_affiliation_total_items.
16 17 18 |
# File 'lib/crunchbase/model/person.rb', line 16 def primary_affiliation_total_items @primary_affiliation_total_items end |
#primary_image ⇒ Object (readonly)
Returns the value of attribute primary_image.
13 14 15 |
# File 'lib/crunchbase/model/person.rb', line 13 def primary_image @primary_image end |
#primary_image_total_items ⇒ Object (readonly)
Returns the value of attribute primary_image_total_items.
16 17 18 |
# File 'lib/crunchbase/model/person.rb', line 16 def primary_image_total_items @primary_image_total_items end |
#primary_location ⇒ Object (readonly)
Returns the value of attribute primary_location.
13 14 15 |
# File 'lib/crunchbase/model/person.rb', line 13 def primary_location @primary_location end |
#primary_location_total_items ⇒ Object (readonly)
Returns the value of attribute primary_location_total_items.
16 17 18 |
# File 'lib/crunchbase/model/person.rb', line 16 def primary_location_total_items @primary_location_total_items end |
#profile_image_url ⇒ Object (readonly)
Returns the value of attribute profile_image_url.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def profile_image_url @profile_image_url end |
#rank ⇒ Object (readonly)
Returns the value of attribute rank.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def rank @rank end |
#role_investor ⇒ Object (readonly)
Returns the value of attribute role_investor.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def role_investor @role_investor end |
#updated_at ⇒ Object (readonly)
Returns the value of attribute updated_at.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def updated_at @updated_at end |
#videos ⇒ Object (readonly)
Returns the value of attribute videos.
13 14 15 |
# File 'lib/crunchbase/model/person.rb', line 13 def videos @videos end |
#videos_total_items ⇒ Object (readonly)
Returns the value of attribute videos_total_items.
16 17 18 |
# File 'lib/crunchbase/model/person.rb', line 16 def videos_total_items @videos_total_items end |
#web_path ⇒ Object (readonly)
Returns the value of attribute web_path.
8 9 10 |
# File 'lib/crunchbase/model/person.rb', line 8 def web_path @web_path end |
#websites ⇒ Object (readonly)
Returns the value of attribute websites.
13 14 15 |
# File 'lib/crunchbase/model/person.rb', line 13 def websites @websites end |
#websites_total_items ⇒ Object (readonly)
Returns the value of attribute websites_total_items.
16 17 18 |
# File 'lib/crunchbase/model/person.rb', line 16 def websites_total_items @websites_total_items end |
Instance Method Details
#date_keys ⇒ Object
53 54 55 |
# File 'lib/crunchbase/model/person.rb', line 53 def date_keys %w[born_on died_on] end |
#name ⇒ Object
custom name from first name and last name
58 59 60 |
# File 'lib/crunchbase/model/person.rb', line 58 def name [first_name, last_name].compact.join(' ') end |
#property_keys ⇒ Object
44 45 46 47 48 49 50 51 |
# File 'lib/crunchbase/model/person.rb', line 44 def property_keys %w[ permalink permalink_aliases api_path api_url web_path rank first_name last_name gender also_known_as bio profile_image_url role_investor born_on born_on_trust_code is_deceased died_on died_on_trust_code created_at updated_at ] end |
#relationship_lists ⇒ Object
26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 |
# File 'lib/crunchbase/model/person.rb', line 26 def relationship_lists { 'primary_affiliation' => PrimaryAffiliation, 'primary_location' => PrimaryLocation, 'primary_image' => PrimaryImage, 'websites' => Website, 'degrees' => Degree, 'jobs' => Job, 'advisory_roles' => AdvisoryRole, 'founded_companies' => FoundedCompany, 'investments' => Investment, 'memberships' => Membership, 'images' => Image, 'videos' => Video, 'news' => New } end |