Method: CueChapter::CueChapter#initialize
- Defined in:
- lib/cuechapter.rb
#initialize(cuesheet, xml_file = nil, image_file = nil, link = nil) ⇒ CueChapter
Returns a new instance of CueChapter.
6 7 8 9 10 11 12 13 14 15 16 17 18 |
# File 'lib/cuechapter.rb', line 6 def initialize(cuesheet, xml_file=nil, image_file=nil, link=nil) super(File.read(cuesheet)) parse! if @xml_file.nil? @xml_file=File.path(cuesheet).gsub(File.extname(cuesheet),".xml") else @xml_file = xml_file end @image_file = image_file @link = link end |