Class: Archive::Tar::Minitar::Writer::RestrictedStream
- Defined in:
- lib/amp/dependencies/minitar.rb
Overview
A stream wrapper that can only be written to. Any attempt to read from this restricted stream will result in a NameError being thrown.
Direct Known Subclasses
Instance Method Summary collapse
-
#initialize(anIO) ⇒ RestrictedStream
constructor
A new instance of RestrictedStream.
- #write(data) ⇒ Object
Constructor Details
#initialize(anIO) ⇒ RestrictedStream
Returns a new instance of RestrictedStream.
251 252 253 |
# File 'lib/amp/dependencies/minitar.rb', line 251 def initialize(anIO) @io = anIO end |
Instance Method Details
#write(data) ⇒ Object
255 256 257 |
# File 'lib/amp/dependencies/minitar.rb', line 255 def write(data) @io.write(data) end |