Class: Abbu::Contact
- Inherits:
-
Object
- Object
- Abbu::Contact
- Defined in:
- lib/abbu/contact.rb
Instance Attribute Summary collapse
-
#addresses ⇒ Object
Returns the value of attribute addresses.
-
#anniversary ⇒ Object
Returns the value of attribute anniversary.
-
#birthday ⇒ Object
Returns the value of attribute birthday.
-
#company ⇒ Object
Returns the value of attribute company.
-
#dates ⇒ Object
Returns the value of attribute dates.
-
#department ⇒ Object
Returns the value of attribute department.
-
#emails ⇒ Object
Returns the value of attribute emails.
-
#first_name ⇒ Object
Returns the value of attribute first_name.
-
#groups ⇒ Object
Returns the value of attribute groups.
-
#instant_messages ⇒ Object
Returns the value of attribute instant_messages.
-
#job_title ⇒ Object
Returns the value of attribute job_title.
-
#last_name ⇒ Object
Returns the value of attribute last_name.
-
#lunar_birthday ⇒ Object
Returns the value of attribute lunar_birthday.
-
#maiden_name ⇒ Object
Returns the value of attribute maiden_name.
-
#middle_name ⇒ Object
Returns the value of attribute middle_name.
-
#nickname ⇒ Object
Returns the value of attribute nickname.
-
#notes ⇒ Object
Returns the value of attribute notes.
-
#phones ⇒ Object
Returns the value of attribute phones.
-
#phonetic_company ⇒ Object
Returns the value of attribute phonetic_company.
-
#phonetic_first_name ⇒ Object
Returns the value of attribute phonetic_first_name.
-
#phonetic_last_name ⇒ Object
Returns the value of attribute phonetic_last_name.
-
#phonetic_middle_name ⇒ Object
Returns the value of attribute phonetic_middle_name.
-
#prefix ⇒ Object
Returns the value of attribute prefix.
-
#pronouns ⇒ Object
Returns the value of attribute pronouns.
-
#related_names ⇒ Object
Returns the value of attribute related_names.
-
#ringtone ⇒ Object
Returns the value of attribute ringtone.
-
#social_profiles ⇒ Object
Returns the value of attribute social_profiles.
-
#suffix ⇒ Object
Returns the value of attribute suffix.
-
#texttone ⇒ Object
Returns the value of attribute texttone.
-
#urls ⇒ Object
Returns the value of attribute urls.
-
#verification_code ⇒ Object
Returns the value of attribute verification_code.
Instance Method Summary collapse
- #full_name ⇒ Object
-
#initialize ⇒ Contact
constructor
A new instance of Contact.
- #inspect ⇒ Object
- #to_s ⇒ Object
Constructor Details
#initialize ⇒ Contact
Returns a new instance of Contact.
15 16 17 18 19 20 21 22 23 24 25 26 |
# File 'lib/abbu/contact.rb', line 15 def initialize @emails = [] @phones = [] @addresses = [] @groups = [] @urls = [] @notes = [] @related_names = [] @social_profiles = [] @dates = [] @instant_messages = [] end |
Instance Attribute Details
#addresses ⇒ Object
Returns the value of attribute addresses.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def addresses @addresses end |
#anniversary ⇒ Object
Returns the value of attribute anniversary.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def anniversary @anniversary end |
#birthday ⇒ Object
Returns the value of attribute birthday.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def birthday @birthday end |
#company ⇒ Object
Returns the value of attribute company.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def company @company end |
#dates ⇒ Object
Returns the value of attribute dates.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def dates @dates end |
#department ⇒ Object
Returns the value of attribute department.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def department @department end |
#emails ⇒ Object
Returns the value of attribute emails.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def emails @emails end |
#first_name ⇒ Object
Returns the value of attribute first_name.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def first_name @first_name end |
#groups ⇒ Object
Returns the value of attribute groups.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def groups @groups end |
#instant_messages ⇒ Object
Returns the value of attribute instant_messages.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def @instant_messages end |
#job_title ⇒ Object
Returns the value of attribute job_title.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def job_title @job_title end |
#last_name ⇒ Object
Returns the value of attribute last_name.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def last_name @last_name end |
#lunar_birthday ⇒ Object
Returns the value of attribute lunar_birthday.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def lunar_birthday @lunar_birthday end |
#maiden_name ⇒ Object
Returns the value of attribute maiden_name.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def maiden_name @maiden_name end |
#middle_name ⇒ Object
Returns the value of attribute middle_name.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def middle_name @middle_name end |
#nickname ⇒ Object
Returns the value of attribute nickname.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def nickname @nickname end |
#notes ⇒ Object
Returns the value of attribute notes.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def notes @notes end |
#phones ⇒ Object
Returns the value of attribute phones.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def phones @phones end |
#phonetic_company ⇒ Object
Returns the value of attribute phonetic_company.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def phonetic_company @phonetic_company end |
#phonetic_first_name ⇒ Object
Returns the value of attribute phonetic_first_name.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def phonetic_first_name @phonetic_first_name end |
#phonetic_last_name ⇒ Object
Returns the value of attribute phonetic_last_name.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def phonetic_last_name @phonetic_last_name end |
#phonetic_middle_name ⇒ Object
Returns the value of attribute phonetic_middle_name.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def phonetic_middle_name @phonetic_middle_name end |
#prefix ⇒ Object
Returns the value of attribute prefix.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def prefix @prefix end |
#pronouns ⇒ Object
Returns the value of attribute pronouns.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def pronouns @pronouns end |
#related_names ⇒ Object
Returns the value of attribute related_names.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def @related_names end |
#ringtone ⇒ Object
Returns the value of attribute ringtone.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def ringtone @ringtone end |
#social_profiles ⇒ Object
Returns the value of attribute social_profiles.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def @social_profiles end |
#suffix ⇒ Object
Returns the value of attribute suffix.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def suffix @suffix end |
#texttone ⇒ Object
Returns the value of attribute texttone.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def texttone @texttone end |
#urls ⇒ Object
Returns the value of attribute urls.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def urls @urls end |
#verification_code ⇒ Object
Returns the value of attribute verification_code.
6 7 8 |
# File 'lib/abbu/contact.rb', line 6 def verification_code @verification_code end |
Instance Method Details
#full_name ⇒ Object
28 29 30 31 |
# File 'lib/abbu/contact.rb', line 28 def full_name quoted_nickname = nickname ? "\"#{nickname}\"" : nil [prefix, first_name, middle_name, quoted_nickname, last_name, suffix].compact.join(' ') end |
#inspect ⇒ Object
38 39 40 |
# File 'lib/abbu/contact.rb', line 38 def inspect to_s end |
#to_s ⇒ Object
33 34 35 36 |
# File 'lib/abbu/contact.rb', line 33 def to_s "#<Abbu::Contact first_name=#{first_name.inspect} last_name=#{last_name.inspect} " \ "emails=#{emails.inspect} phones=#{phones.inspect}>" end |