Class: HTOTConv::Parser::Opml
Defined Under Namespace
Classes: ListDoc
Instance Attribute Summary
Attributes inherited from Base
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from Base
Constructor Details
This class inherits a constructor from HTOTConv::Parser::Base
Class Method Details
.option_help ⇒ Object
7 8 9 10 11 12 13 14 15 |
# File 'lib/htot_conv/parser/opml.rb', line 7 def self.option_help { :key_header => { :default => [], :pat => Array, :desc => "key header", }, } end |
Instance Method Details
#parse(input) ⇒ Object
17 18 19 20 21 22 23 24 25 26 |
# File 'lib/htot_conv/parser/opml.rb', line 17 def parse(input) outline = HTOTConv::Outline.new outline.key_header = @option[:key_header] outline.value_header = [] parser = Nokogiri::XML::SAX::Parser.new(ListDoc.new(outline)) parser.parse(input) outline end |