Class: SiteHealth::Checkers::XMLPage
- Inherits:
-
Object
- Object
- SiteHealth::Checkers::XMLPage
- Defined in:
- lib/site_health/checkers/xml_page.rb
Instance Attribute Summary collapse
-
#page ⇒ Object
readonly
Returns the value of attribute page.
-
#url ⇒ Object
readonly
Returns the value of attribute url.
Class Method Summary collapse
Instance Method Summary collapse
- #check ⇒ Object
-
#initialize(page) ⇒ XMLPage
constructor
A new instance of XMLPage.
Constructor Details
#initialize(page) ⇒ XMLPage
Returns a new instance of XMLPage.
11 12 13 14 |
# File 'lib/site_health/checkers/xml_page.rb', line 11 def initialize(page) @page = page @url = page.url end |
Instance Attribute Details
#page ⇒ Object (readonly)
Returns the value of attribute page.
8 9 10 |
# File 'lib/site_health/checkers/xml_page.rb', line 8 def page @page end |
#url ⇒ Object (readonly)
Returns the value of attribute url.
8 9 10 |
# File 'lib/site_health/checkers/xml_page.rb', line 8 def url @url end |
Class Method Details
.check(page) ⇒ Object
4 5 6 |
# File 'lib/site_health/checkers/xml_page.rb', line 4 def self.check(page) new(page).check end |
Instance Method Details
#check ⇒ Object
16 17 18 |
# File 'lib/site_health/checkers/xml_page.rb', line 16 def check XMLJournal.new(url: url, page: page, errors: page.doc.errors) end |