Class: Crunchbase::ServiceProvider

Inherits:
CB_Object
  • Object
show all
Defined in:
lib/crunchbase/service_provider.rb

Constant Summary collapse

ENT_NAME =
"service-provider"
ENT_PLURAL =
"service-providers"

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from CB_Object

#===, #aliases, all, find, get, #tags

Constructor Details

#initialize(json) ⇒ ServiceProvider

Returns a new instance of ServiceProvider.



12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# File 'lib/crunchbase/service_provider.rb', line 12

def initialize(json)
  @name = json["name"]
  @permalink = json["permalink"]
  @crunchbase_url = json["crunchbase_url"]
  @homepage_url = json["homepage_url"]
  @phone_number = json["phone_number"]
  @tag_list = json["tag_list"]
  @alias_list = json["alias_list"]
  @created_at = DateTime.parse(json["created_at"])
  @updated_at = DateTime.parse(json["updated_at"])
  @overview = json["overview"]
  @image = json["image"]
  @offices = json["offices"]
  @providerships = Relationship.array_from_relationship_list(json["providerships"]) if json["providerships"]
  @external_links = json["external_links"]
end

Instance Attribute Details

#created_atObject (readonly)

Returns the value of attribute created_at.



8
9
10
# File 'lib/crunchbase/service_provider.rb', line 8

def created_at
  @created_at
end

#crunchbase_urlObject (readonly)

Returns the value of attribute crunchbase_url.



8
9
10
# File 'lib/crunchbase/service_provider.rb', line 8

def crunchbase_url
  @crunchbase_url
end

Returns the value of attribute external_links.



8
9
10
# File 'lib/crunchbase/service_provider.rb', line 8

def external_links
  @external_links
end

#homepage_urlObject (readonly)

Returns the value of attribute homepage_url.



8
9
10
# File 'lib/crunchbase/service_provider.rb', line 8

def homepage_url
  @homepage_url
end

#imageObject (readonly)

Returns the value of attribute image.



8
9
10
# File 'lib/crunchbase/service_provider.rb', line 8

def image
  @image
end

#nameObject (readonly)

Returns the value of attribute name.



8
9
10
# File 'lib/crunchbase/service_provider.rb', line 8

def name
  @name
end

#officesObject (readonly)

Returns the value of attribute offices.



8
9
10
# File 'lib/crunchbase/service_provider.rb', line 8

def offices
  @offices
end

#overviewObject (readonly)

Returns the value of attribute overview.



8
9
10
# File 'lib/crunchbase/service_provider.rb', line 8

def overview
  @overview
end

Returns the value of attribute permalink.



8
9
10
# File 'lib/crunchbase/service_provider.rb', line 8

def permalink
  @permalink
end

#phone_numberObject (readonly)

Returns the value of attribute phone_number.



8
9
10
# File 'lib/crunchbase/service_provider.rb', line 8

def phone_number
  @phone_number
end

#providershipsObject (readonly)

Returns the value of attribute providerships.



8
9
10
# File 'lib/crunchbase/service_provider.rb', line 8

def providerships
  @providerships
end

#updated_atObject (readonly)

Returns the value of attribute updated_at.



8
9
10
# File 'lib/crunchbase/service_provider.rb', line 8

def updated_at
  @updated_at
end