Class: StringIO
- Inherits:
-
Object
- Object
- StringIO
- Defined in:
- lib/live_api.rb
Overview
Extend the StringIO to have a skip method
Instance Method Summary collapse
-
#skip(n) ⇒ Object
Skip n bytes.
-
#skip_padding ⇒ Object
Skip the OSC 4 byte alinged padding.
Instance Method Details
#skip(n) ⇒ Object
Skip n bytes
16 17 18 |
# File 'lib/live_api.rb', line 16 def skip(n) self.seek(n, IO::SEEK_CUR) end |
#skip_padding ⇒ Object
Skip the OSC 4 byte alinged padding
22 23 24 |
# File 'lib/live_api.rb', line 22 def skip_padding self.skip((4-pos)%4) end |