Class: PacketViaDMEM::Header::Sent
- Inherits:
-
Object
- Object
- PacketViaDMEM::Header::Sent
- Defined in:
- lib/packet_via_dmem/header/sent.rb
Instance Attribute Summary collapse
-
#color ⇒ Object
Returns the value of attribute color.
-
#decrement_reference ⇒ Object
Returns the value of attribute decrement_reference.
-
#drop_hash ⇒ Object
Returns the value of attribute drop_hash.
-
#fragment_info ⇒ Object
Returns the value of attribute fragment_info.
-
#increment_reference ⇒ Object
Returns the value of attribute increment_reference.
-
#life ⇒ Object
Returns the value of attribute life.
-
#magic1 ⇒ Object
Returns the value of attribute magic1.
-
#magic2 ⇒ Object
Returns the value of attribute magic2.
-
#magic3 ⇒ Object
Returns the value of attribute magic3.
-
#msg_type ⇒ Object
Returns the value of attribute msg_type.
-
#offset ⇒ Object
Returns the value of attribute offset.
-
#port ⇒ Object
Returns the value of attribute port.
-
#prequeue_priority ⇒ Object
Returns the value of attribute prequeue_priority.
-
#queue_drop_opcode ⇒ Object
Returns the value of attribute queue_drop_opcode.
-
#queue_number ⇒ Object
Returns the value of attribute queue_number.
-
#queue_system ⇒ Object
Returns the value of attribute queue_system.
-
#statistics ⇒ Object
Returns the value of attribute statistics.
-
#table ⇒ Object
Returns the value of attribute table.
-
#type ⇒ Object
Returns the value of attribute type.
Instance Method Summary collapse
Instance Attribute Details
#color ⇒ Object
Returns the value of attribute color.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def color @color end |
#decrement_reference ⇒ Object
Returns the value of attribute decrement_reference.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def decrement_reference @decrement_reference end |
#drop_hash ⇒ Object
Returns the value of attribute drop_hash.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def drop_hash @drop_hash end |
#fragment_info ⇒ Object
Returns the value of attribute fragment_info.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def fragment_info @fragment_info end |
#increment_reference ⇒ Object
Returns the value of attribute increment_reference.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def increment_reference @increment_reference end |
#life ⇒ Object
Returns the value of attribute life.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def life @life end |
#magic1 ⇒ Object
Returns the value of attribute magic1.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def magic1 @magic1 end |
#magic2 ⇒ Object
Returns the value of attribute magic2.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def magic2 @magic2 end |
#magic3 ⇒ Object
Returns the value of attribute magic3.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def magic3 @magic3 end |
#msg_type ⇒ Object
Returns the value of attribute msg_type.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def msg_type @msg_type end |
#offset ⇒ Object
Returns the value of attribute offset.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def offset @offset end |
#port ⇒ Object
Returns the value of attribute port.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def port @port end |
#prequeue_priority ⇒ Object
Returns the value of attribute prequeue_priority.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def prequeue_priority @prequeue_priority end |
#queue_drop_opcode ⇒ Object
Returns the value of attribute queue_drop_opcode.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def queue_drop_opcode @queue_drop_opcode end |
#queue_number ⇒ Object
Returns the value of attribute queue_number.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def queue_number @queue_number end |
#queue_system ⇒ Object
Returns the value of attribute queue_system.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def queue_system @queue_system end |
#statistics ⇒ Object
Returns the value of attribute statistics.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def statistics @statistics end |
#table ⇒ Object
Returns the value of attribute table.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def table @table end |
#type ⇒ Object
Returns the value of attribute type.
4 5 6 |
# File 'lib/packet_via_dmem/header/sent.rb', line 4 def type @type end |
Instance Method Details
#to_s(packet_number = 1) ⇒ Object
24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 |
# File 'lib/packet_via_dmem/header/sent.rb', line 24 def to_s(packet_number=1) str = '' str << '# TX %03d # ' % packet_number str << (statistics ? 'S' : 's') str << (increment_reference ? 'I' : 'i') str << (fragment_info ? 'F' : 'f') str << (drop_hash ? 'H' : 'h') str << (decrement_reference ? 'D' : 'd') str << (prequeue_priority ? 'P' : 'p') str << ' # ' str << 'port: %x (%s) # ' % [port, port.divmod(64).join('/')] str << 'type: %x # ' % type str << 'QoS: %d@%d # ' % [queue_number, queue_system] str << "QueueDropOp: %d\n" % [queue_drop_opcode] str << '# ' str << 'color: %d # ' % color str << 'offset: %d # ' % offset str << 'table: %d # ' % table str << 'life: %d # ' % life str << 'magic: ' str << '%x/%x' % [magic1, magic2] if magic1 str << '/%x' % magic3 if magic3 str end |