Class: Af::QThread::Message
- Inherits:
-
Object
- Object
- Af::QThread::Message
- Defined in:
- lib/fiksu-af/q_thread/message.rb
Instance Attribute Summary collapse
-
#data ⇒ Object
Returns the value of attribute data.
-
#from ⇒ Object
Returns the value of attribute from.
-
#msg_id ⇒ Object
Returns the value of attribute msg_id.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(data, from = Thread.current) ⇒ Message
constructor
A new instance of Message.
Constructor Details
#initialize(data, from = Thread.current) ⇒ Message
Returns a new instance of Message.
4 5 6 7 8 |
# File 'lib/fiksu-af/q_thread/message.rb', line 4 def initialize(data, from = Thread.current) @from = from @data = data @msg_id = self.class.new_msg_id end |
Instance Attribute Details
#data ⇒ Object
Returns the value of attribute data.
3 4 5 |
# File 'lib/fiksu-af/q_thread/message.rb', line 3 def data @data end |
#from ⇒ Object
Returns the value of attribute from.
3 4 5 |
# File 'lib/fiksu-af/q_thread/message.rb', line 3 def from @from end |
#msg_id ⇒ Object
Returns the value of attribute msg_id.
3 4 5 |
# File 'lib/fiksu-af/q_thread/message.rb', line 3 def msg_id @msg_id end |
Class Method Details
.new_msg_id ⇒ Object
10 11 12 |
# File 'lib/fiksu-af/q_thread/message.rb', line 10 def self.new_msg_id return UUID.new end |