Class: Candidate
- Inherits:
-
Data
- Object
- Data
- Candidate
- Defined in:
- lib/ruby_duplicates/cli.rb
Instance Attribute Summary collapse
-
#end_line ⇒ Object
readonly
Returns the value of attribute end_line.
-
#file ⇒ Object
readonly
Returns the value of attribute file.
-
#fingerprints ⇒ Object
readonly
Returns the value of attribute fingerprints.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#node_count ⇒ Object
readonly
Returns the value of attribute node_count.
-
#start_line ⇒ Object
readonly
Returns the value of attribute start_line.
Instance Method Summary collapse
Instance Attribute Details
#end_line ⇒ Object (readonly)
Returns the value of attribute end_line
10 11 12 |
# File 'lib/ruby_duplicates/cli.rb', line 10 def end_line @end_line end |
#file ⇒ Object (readonly)
Returns the value of attribute file
10 11 12 |
# File 'lib/ruby_duplicates/cli.rb', line 10 def file @file end |
#fingerprints ⇒ Object (readonly)
Returns the value of attribute fingerprints
10 11 12 |
# File 'lib/ruby_duplicates/cli.rb', line 10 def fingerprints @fingerprints end |
#name ⇒ Object (readonly)
Returns the value of attribute name
10 11 12 |
# File 'lib/ruby_duplicates/cli.rb', line 10 def name @name end |
#node_count ⇒ Object (readonly)
Returns the value of attribute node_count
10 11 12 |
# File 'lib/ruby_duplicates/cli.rb', line 10 def node_count @node_count end |
#start_line ⇒ Object (readonly)
Returns the value of attribute start_line
10 11 12 |
# File 'lib/ruby_duplicates/cli.rb', line 10 def start_line @start_line end |
Instance Method Details
#line_count ⇒ Object
11 12 13 |
# File 'lib/ruby_duplicates/cli.rb', line 11 def line_count end_line - start_line + 1 end |
#location ⇒ Object
15 16 17 |
# File 'lib/ruby_duplicates/cli.rb', line 15 def location "#{file}:#{start_line}-#{end_line}" end |