Class: TFTP::Packet::DATA
- Inherits:
-
Object
- Object
- TFTP::Packet::DATA
- Defined in:
- lib/tftp/tftp.rb
Instance Method Summary collapse
-
#last? ⇒ Boolean
Check if this is the last data packet for this session.
- #to_str ⇒ Object
Instance Method Details
#last? ⇒ Boolean
Check if this is the last data packet for this session.
40 |
# File 'lib/tftp/tftp.rb', line 40 def last?; self.data.length < 512; end |
#to_str ⇒ Object
38 |
# File 'lib/tftp/tftp.rb', line 38 def to_str; "\x00\x03" + [self.seq].pack('n') + self.data; end |