Class: UICov::MemberData
- Inherits:
-
Object
- Object
- UICov::MemberData
- Defined in:
- lib/uicov/coverage/member_data.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#display_name ⇒ Object
readonly
Returns the value of attribute display_name.
-
#hits ⇒ Object
readonly
Returns the value of attribute hits.
Instance Method Summary collapse
- #hit(increment = 1) ⇒ Object
-
#initialize(name) ⇒ MemberData
constructor
A new instance of MemberData.
Constructor Details
#initialize(name) ⇒ MemberData
Returns a new instance of MemberData.
8 9 10 11 |
# File 'lib/uicov/coverage/member_data.rb', line 8 def initialize(name) @display_name = name @hits = 0 end |
Instance Attribute Details
#display_name ⇒ Object (readonly)
Returns the value of attribute display_name.
7 8 9 |
# File 'lib/uicov/coverage/member_data.rb', line 7 def display_name @display_name end |
#hits ⇒ Object (readonly)
Returns the value of attribute hits.
7 8 9 |
# File 'lib/uicov/coverage/member_data.rb', line 7 def hits @hits end |
Instance Method Details
#hit(increment = 1) ⇒ Object
13 14 15 |
# File 'lib/uicov/coverage/member_data.rb', line 13 def hit(increment=1) @hits += increment end |