Class: Rsirts::Renderer

Inherits:
Object
  • Object
show all
Defined in:
lib/rsirts/renderer.rb

Constant Summary collapse

PATTERN_CHARS =
('!'..'~').to_a
DEFAULT_PATTERN_LENGTH =
12

Instance Method Summary collapse

Constructor Details

#initialize(zmap_lines) ⇒ Renderer

Returns a new instance of Renderer.



53
54
55
56
# File 'lib/rsirts/renderer.rb', line 53

def initialize zmap_lines
  @zmap_lines = zmap_lines
  @width = zmap_lines[0].size
end

Instance Method Details

#generateObject



58
59
60
61
62
# File 'lib/rsirts/renderer.rb', line 58

def generate
  zmap_lines.map do |line|
    translate_line line
  end
end