Class: Cinch::Plugins::Notes::Note
- Inherits:
-
Object
- Object
- Cinch::Plugins::Notes::Note
- Defined in:
- lib/cinch/plugins/notes/note.rb
Overview
Object to store note information
Instance Attribute Summary collapse
-
#from ⇒ Object
Returns the value of attribute from.
-
#message ⇒ Object
Returns the value of attribute message.
-
#sent ⇒ Object
Returns the value of attribute sent.
-
#time ⇒ Object
Returns the value of attribute time.
-
#to ⇒ Object
Returns the value of attribute to.
Instance Method Summary collapse
-
#initialize(from, to, message) ⇒ Note
constructor
A new instance of Note.
- #mark_sent ⇒ Object
Constructor Details
#initialize(from, to, message) ⇒ Note
Returns a new instance of Note.
9 10 11 12 13 14 15 |
# File 'lib/cinch/plugins/notes/note.rb', line 9 def initialize(from, to, ) @from = from @to = to @message = @sent = false @time = Time.now end |
Instance Attribute Details
#from ⇒ Object
Returns the value of attribute from.
7 8 9 |
# File 'lib/cinch/plugins/notes/note.rb', line 7 def from @from end |
#message ⇒ Object
Returns the value of attribute message.
7 8 9 |
# File 'lib/cinch/plugins/notes/note.rb', line 7 def @message end |
#sent ⇒ Object
Returns the value of attribute sent.
7 8 9 |
# File 'lib/cinch/plugins/notes/note.rb', line 7 def sent @sent end |
#time ⇒ Object
Returns the value of attribute time.
7 8 9 |
# File 'lib/cinch/plugins/notes/note.rb', line 7 def time @time end |
#to ⇒ Object
Returns the value of attribute to.
7 8 9 |
# File 'lib/cinch/plugins/notes/note.rb', line 7 def to @to end |
Instance Method Details
#mark_sent ⇒ Object
17 18 19 |
# File 'lib/cinch/plugins/notes/note.rb', line 17 def mark_sent @sent = true end |