Class: Contacts::Contact::Twitter

Inherits:
Struct
  • Object
show all
Defined in:
lib/contacts/contact/twitter.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#image_urlObject

Returns the value of attribute image_url

Returns:

  • (Object)

    the current value of image_url



1
2
3
# File 'lib/contacts/contact/twitter.rb', line 1

def image_url
  @image_url
end

#nameObject

Returns the value of attribute name

Returns:

  • (Object)

    the current value of name



1
2
3
# File 'lib/contacts/contact/twitter.rb', line 1

def name
  @name
end

#screen_nameObject

Returns the value of attribute screen_name

Returns:

  • (Object)

    the current value of screen_name



1
2
3
# File 'lib/contacts/contact/twitter.rb', line 1

def screen_name
  @screen_name
end

#uidObject

Returns the value of attribute uid

Returns:

  • (Object)

    the current value of uid



1
2
3
# File 'lib/contacts/contact/twitter.rb', line 1

def uid
  @uid
end

Class Method Details

.parse(hash) ⇒ Object



3
4
5
# File 'lib/contacts/contact/twitter.rb', line 3

def self.parse hash
  new hash['id'].to_s, hash['screen_name'], hash['name'], hash['profile_image_url']
end