Class: Peddler::XMLParser Private
- Inherits:
-
SimpleDelegator
- Object
- SimpleDelegator
- Peddler::XMLParser
- Extended by:
- Forwardable
- Includes:
- Headers
- Defined in:
- lib/peddler/xml_parser.rb
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Direct Known Subclasses
Instance Method Summary collapse
- #parse ⇒ Object private
- #valid? ⇒ Boolean private
- #xml ⇒ Object private
Methods included from Headers
#quota, #request_id, #response_context, #timestamp
Instance Method Details
#parse ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
17 18 19 |
# File 'lib/peddler/xml_parser.rb', line 17 def parse @data ||= find_data end |
#valid? ⇒ Boolean
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
25 26 27 28 |
# File 'lib/peddler/xml_parser.rb', line 25 def valid? return unless headers['Content-Length'] headers['Content-Length'].to_i == body.size end |
#xml ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
21 22 23 |
# File 'lib/peddler/xml_parser.rb', line 21 def xml MultiXml.parse(body) end |