module Feedjira::FeedUtilities::ClassMethods
Public Instance Methods
Source
# File lib/feedjira/feed_utilities.rb, line 15 def parse(xml, &block) xml = strip_whitespace(xml) xml = preprocess(xml) if preprocess_xml super xml, &block end
Calls superclass method
Source
# File lib/feedjira/feed_utilities.rb, line 21 def preprocess(xml) # noop xml end
Source
# File lib/feedjira/feed_utilities.rb, line 30 def preprocess_xml @preprocess_xml end
Source
# File lib/feedjira/feed_utilities.rb, line 26 def preprocess_xml=(value) @preprocess_xml = value end
Source
# File lib/feedjira/feed_utilities.rb, line 34 def strip_whitespace(xml) if Feedjira.strip_whitespace xml.strip else xml.lstrip end end