Class: Montague::Reporter::Publishers
- Inherits:
-
Object
- Object
- Montague::Reporter::Publishers
- Defined in:
- lib/montague/reporter/publishers.rb
Overview
Publishers reporter
Instance Method Summary collapse
-
#initialize(response) ⇒ Publishers
constructor
A new instance of Publishers.
- #report ⇒ Montague::Model::PublishersReport
Constructor Details
#initialize(response) ⇒ Publishers
Returns a new instance of Publishers.
7 8 9 10 11 |
# File 'lib/montague/reporter/publishers.rb', line 7 def initialize(response) @response = response @header_extractor = Montague::XMLExtractor::Header.new response.to_s @publisher_extractor = Montague::XMLExtractor::Publisher.new response.to_s end |
Instance Method Details
#report ⇒ Montague::Model::PublishersReport
14 15 16 17 18 19 20 |
# File 'lib/montague/reporter/publishers.rb', line 14 def report h = Montague::Model::PublishersReport.new h.http_response = @response h.header = @header_extractor.model h.publishers = @publisher_extractor.models h end |