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.
15 16 17 |
# File 'lib/peddler/xml_parser.rb', line 15 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.
23 24 25 26 |
# File 'lib/peddler/xml_parser.rb', line 23 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.
19 20 21 |
# File 'lib/peddler/xml_parser.rb', line 19 def xml MultiXml.parse(body) end |