class WORF::DebugStrings
Public Class Methods
new(io, section, head_pos)
click to toggle source
# File lib/worf.rb, line 153 def initialize io, section, head_pos @io = io @section = section @head_pos = head_pos end
Public Instance Methods
string_at(offset)
click to toggle source
# File lib/worf.rb, line 159 def string_at offset pos = @io.pos @io.seek @head_pos + @section.offset + offset, IO::SEEK_SET @io.readline("\x00").b.delete("\x00") ensure @io.seek pos, IO::SEEK_SET end