Class: SiSU_XML_Fictionbook::Source
- Inherits:
-
Object
- Object
- SiSU_XML_Fictionbook::Source
- Defined in:
- lib/sisu/xml_fictionbook2.rb
Direct Known Subclasses
Defined Under Namespace
Classes: Scroll
Instance Method Summary collapse
-
#initialize(opt) ⇒ Source
constructor
A new instance of Source.
- #read ⇒ Object
Constructor Details
#initialize(opt) ⇒ Source
Returns a new instance of Source.
68 69 70 71 |
# File 'lib/sisu/xml_fictionbook2.rb', line 68 def initialize(opt) @opt=opt @particulars=SiSU_Particulars::CombinedSingleton.instance.get_all(opt) end |
Instance Method Details
#read ⇒ Object
72 73 74 75 76 77 78 79 80 81 82 83 84 85 |
# File 'lib/sisu/xml_fictionbook2.rb', line 72 def read begin @md,@ao_array=@particulars.md,@particulars.ao_array @env=@particulars.env report SiSU_XML_Fictionbook::Source::Scroll.new(@ao_array,@md).songsheet rescue SiSU_Errors::Rescued.new($!,$@,@opt.selections.str,@opt.fns).location do __LINE__.to_s + ':' + __FILE__ end ensure Dir.chdir(@opt.f_pth[:pth]) end end |