Class: Pangrid::RedditFilled

Inherits:
Plugin
  • Object
show all
Includes:
RedditWriter
Defined in:
lib/pangrid/plugins/reddit.rb

Constant Summary collapse

DESCRIPTION =
"Reddit format (with filled squares)"

Constants inherited from Plugin

Plugin::FAILED, Plugin::MISSING_DEPS, Plugin::REGISTRY

Instance Method Summary collapse

Methods included from RedditWriter

#format_clues, #write_clues, #write_line, #write_table, #write_xw

Methods inherited from Plugin

class_to_name, get, inherited, list_all, load_all, load_plugin

Methods included from PluginUtils

#check

Instance Method Details

#grid(xw) ⇒ Object



43
44
45
46
47
# File 'lib/pangrid/plugins/reddit.rb', line 43

def grid(xw)
  xw.to_array({:black => '*.*', :null => ' '}) do |c|
    c.to_char.upcase + (c.number ? "^#{c.number}" : '')
  end
end

#write(xw) ⇒ Object



39
40
41
# File 'lib/pangrid/plugins/reddit.rb', line 39

def write(xw)
  write_xw(xw)
end