class ProxyFS::File
Public Class Methods
binread(name, length=nil, offset=nil)
click to toggle source
# File lib/proxyfs.rb, line 49 def self.binread name, length=nil, offset=nil f = self.new name f.binmode f.seek offset if offset f.read *([length].compact) end
binwrite(name, string, offset=nil)
click to toggle source
# File lib/proxyfs.rb, line 56 def self.binwrite name, string, offset=nil f = self.new name f.binmode f.seek offset if offset f.write string end
new(path)
click to toggle source
# File lib/proxyfs.rb, line 21 def initialize path @path = path @entry = fs.entry(@path) if Array === @entry @file = @entry[0].new(*@entry[1..(-1)]) elsif Hash === e else @file = @entry end end