Module: ProgramTV
- Defined in:
- lib/program-tv.rb,
lib/program-tv/parser.rb,
lib/program-tv/writer.rb
Defined Under Namespace
Constant Summary collapse
- VERSION =
"0.0.3"- SUMMARY =
"TV Channel parser"- DESCRIPTION =
"Downloads TV channel list in XML format"
Class Method Summary collapse
- .gem_root ⇒ Object
-
.run!(options = {}) ⇒ Object
Initilizes Runner which controls all the magic stuff.
- .selected_channels ⇒ Object
Class Method Details
.gem_root ⇒ Object
26 27 28 |
# File 'lib/program-tv.rb', line 26 def self.gem_root File. '../..', __FILE__ end |
.run!(options = {}) ⇒ Object
Initilizes Runner which controls all the magic stuff.
18 19 20 21 22 |
# File 'lib/program-tv.rb', line 18 def self.run!( = {}) = data = Parser.new.run puts Writer.new(data).run end |
.selected_channels ⇒ Object
30 31 32 |
# File 'lib/program-tv.rb', line 30 def self.selected_channels @channels ||= YAML::load(File.open([:channel_list] || File.join(gem_root, 'channels.yml'))) end |