Class: ReVIEW::Book::PageMetric
- Defined in:
- lib/review/book/page_metric.rb
Defined Under Namespace
Classes: MetricData
Constant Summary collapse
Instance Attribute Summary collapse
-
#list ⇒ Object
readonly
Returns the value of attribute list.
-
#page_per_kbyte ⇒ Object
readonly
Returns the value of attribute page_per_kbyte.
-
#text ⇒ Object
readonly
Returns the value of attribute text.
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#initialize(list_lines, list_columns, text_lines, text_columns, page_per_kbyte) ⇒ PageMetric
constructor
A new instance of PageMetric.
Constructor Details
#initialize(list_lines, list_columns, text_lines, text_columns, page_per_kbyte) ⇒ PageMetric
Returns a new instance of PageMetric.
14 15 16 17 18 |
# File 'lib/review/book/page_metric.rb', line 14 def initialize(list_lines, list_columns, text_lines, text_columns, page_per_kbyte) @list = MetricData.new(list_lines, list_columns) @text = MetricData.new(text_lines, text_columns) @page_per_kbyte = page_per_kbyte end |
Instance Attribute Details
#list ⇒ Object (readonly)
Returns the value of attribute list.
23 24 25 |
# File 'lib/review/book/page_metric.rb', line 23 def list @list end |
#page_per_kbyte ⇒ Object (readonly)
Returns the value of attribute page_per_kbyte.
25 26 27 |
# File 'lib/review/book/page_metric.rb', line 25 def page_per_kbyte @page_per_kbyte end |
#text ⇒ Object (readonly)
Returns the value of attribute text.
24 25 26 |
# File 'lib/review/book/page_metric.rb', line 24 def text @text end |
Instance Method Details
#==(other) ⇒ Object
27 28 29 |
# File 'lib/review/book/page_metric.rb', line 27 def ==(other) self.list == other.list && self.text == other.text && self.page_per_kbyte == other.page_per_kbyte end |