Class: Webhookdb::Message::Recipient
- Inherits:
-
Object
- Object
- Webhookdb::Message::Recipient
- Defined in:
- lib/webhookdb/message.rb
Overview
Presents a homogeneous interface for a given ‘to’ value (email vs. customer, for example). .to will always be a plain object, and .customer will be a Webhookdb::Customer
if present.
Instance Attribute Summary collapse
-
#customer ⇒ Object
readonly
Returns the value of attribute customer.
-
#to ⇒ Object
readonly
Returns the value of attribute to.
Instance Method Summary collapse
-
#initialize(to, customer) ⇒ Recipient
constructor
A new instance of Recipient.
Constructor Details
#initialize(to, customer) ⇒ Recipient
Returns a new instance of Recipient.
168 169 170 171 |
# File 'lib/webhookdb/message.rb', line 168 def initialize(to, customer) @to = to @customer = customer end |
Instance Attribute Details
#customer ⇒ Object (readonly)
Returns the value of attribute customer.
166 167 168 |
# File 'lib/webhookdb/message.rb', line 166 def customer @customer end |
#to ⇒ Object (readonly)
Returns the value of attribute to.
166 167 168 |
# File 'lib/webhookdb/message.rb', line 166 def to @to end |