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