Class: Application
- Inherits:
-
BaseObject
- Object
- BaseObject
- Application
- Defined in:
- lib/html_compilation/classes/objects/app.rb
Instance Attribute Summary collapse
-
#application_name ⇒ Object
Returns the value of attribute application_name.
-
#env ⇒ Object
Returns the value of attribute env.
-
#graph ⇒ Object
Returns the value of attribute graph.
-
#pages ⇒ Object
Returns the value of attribute pages.
-
#values ⇒ Object
Returns the value of attribute values.
Instance Method Summary collapse
Methods inherited from BaseObject
Constructor Details
This class inherits a constructor from BaseObject
Instance Attribute Details
#application_name ⇒ Object
Returns the value of attribute application_name.
4 5 6 |
# File 'lib/html_compilation/classes/objects/app.rb', line 4 def application_name @application_name end |
#env ⇒ Object
Returns the value of attribute env.
4 5 6 |
# File 'lib/html_compilation/classes/objects/app.rb', line 4 def env @env end |
#graph ⇒ Object
Returns the value of attribute graph.
4 5 6 |
# File 'lib/html_compilation/classes/objects/app.rb', line 4 def graph @graph end |
#pages ⇒ Object
Returns the value of attribute pages.
4 5 6 |
# File 'lib/html_compilation/classes/objects/app.rb', line 4 def pages @pages end |
#values ⇒ Object
Returns the value of attribute values.
4 5 6 |
# File 'lib/html_compilation/classes/objects/app.rb', line 4 def values @values end |
Instance Method Details
#calculate_app_score ⇒ Object
6 7 8 9 10 11 12 |
# File 'lib/html_compilation/classes/objects/app.rb', line 6 def calculate_app_score counter = 0 pages.each do |page| counter += page.score end counter end |
#calculate_total_errors ⇒ Object
14 15 16 17 18 19 20 |
# File 'lib/html_compilation/classes/objects/app.rb', line 14 def calculate_total_errors counter = 0 pages.each do |page| counter += page.rows.length end counter end |
#remove_duplicates ⇒ Object
22 23 24 25 26 |
# File 'lib/html_compilation/classes/objects/app.rb', line 22 def remove_duplicates pages.reverse.each do |page| page.remove_duplicates(self) end end |