Class: Whatsapp::Webhook::Message::Contacts::Org
- Inherits:
-
Object
- Object
- Whatsapp::Webhook::Message::Contacts::Org
- Defined in:
- lib/ruby/whatsapp/webhook/message/contacts/org.rb
Overview
The organization details of an inbound contact card.
Instance Attribute Summary collapse
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(company: nil, department: nil, title: nil) ⇒ Org
constructor
A new instance of Org.
Constructor Details
#initialize(company: nil, department: nil, title: nil) ⇒ Org
Returns a new instance of Org.
21 22 23 24 25 |
# File 'lib/ruby/whatsapp/webhook/message/contacts/org.rb', line 21 def initialize(company: nil, department: nil, title: nil) @company = company @department = department @title = title end |
Instance Attribute Details
#company ⇒ String?
11 12 13 |
# File 'lib/ruby/whatsapp/webhook/message/contacts/org.rb', line 11 def company @company end |
#department ⇒ String?
15 16 17 |
# File 'lib/ruby/whatsapp/webhook/message/contacts/org.rb', line 15 def department @department end |
#title ⇒ String?
19 20 21 |
# File 'lib/ruby/whatsapp/webhook/message/contacts/org.rb', line 19 def title @title end |
Class Method Details
.deserialize(data) ⇒ Org
30 31 32 33 34 |
# File 'lib/ruby/whatsapp/webhook/message/contacts/org.rb', line 30 def deserialize(data) data ||= {} new(company: data["company"], department: data["department"], title: data["title"]) end |