Class: Caboose::Message
- Inherits:
-
Object
- Object
- Caboose::Message
- Extended by:
- ActiveModel::Naming
- Includes:
- ActiveModel::Conversion, ActiveModel::Validations
- Defined in:
- app/models/caboose/message.rb
Instance Attribute Summary collapse
-
#body ⇒ Object
Returns the value of attribute body.
-
#email ⇒ Object
Returns the value of attribute email.
-
#name ⇒ Object
Returns the value of attribute name.
Instance Method Summary collapse
-
#initialize(attributes = {}) ⇒ Message
constructor
A new instance of Message.
- #persisted? ⇒ Boolean
Constructor Details
#initialize(attributes = {}) ⇒ Message
Returns a new instance of Message.
12 13 14 |
# File 'app/models/caboose/message.rb', line 12 def initialize(attributes={}) attributes.each { |name, value| send("#{name}=", value) } end |
Instance Attribute Details
#body ⇒ Object
Returns the value of attribute body.
7 8 9 |
# File 'app/models/caboose/message.rb', line 7 def body @body end |
#email ⇒ Object
Returns the value of attribute email.
7 8 9 |
# File 'app/models/caboose/message.rb', line 7 def email @email end |
#name ⇒ Object
Returns the value of attribute name.
7 8 9 |
# File 'app/models/caboose/message.rb', line 7 def name @name end |
Instance Method Details
#persisted? ⇒ Boolean
16 17 18 |
# File 'app/models/caboose/message.rb', line 16 def persisted? false end |