A RestrictedStream that also has a size limit.
The maximum number of bytes that may be written to this data stream.
The current total number of bytes written to this data stream.
(Not documented)
# File vendor/path/minitar.rb, line 272 def initialize(io, limit) @io = io @limit = limit @written = 0 end
# File vendor/path/minitar.rb, line 278 def write(data) raise FileOverflow if (data.size + @written) > @limit @io.write(data) @written += data.size data.size end
Disabled; run with --debug to generate this.