Class: Policial::Line
- Inherits:
-
Object
- Object
- Policial::Line
- Defined in:
- lib/policial/line.rb
Overview
Public: a changed line in a commit file.
Instance Attribute Summary collapse
-
#content ⇒ Object
readonly
Returns the value of attribute content.
-
#number ⇒ Object
readonly
Returns the value of attribute number.
-
#patch_position ⇒ Object
readonly
Returns the value of attribute patch_position.
Instance Method Summary collapse
- #changed? ⇒ Boolean
-
#initialize(number, content, patch_position) ⇒ Line
constructor
A new instance of Line.
Constructor Details
#initialize(number, content, patch_position) ⇒ Line
Returns a new instance of Line.
8 9 10 11 12 |
# File 'lib/policial/line.rb', line 8 def initialize(number, content, patch_position) @number = number @content = content @patch_position = patch_position end |
Instance Attribute Details
#content ⇒ Object (readonly)
Returns the value of attribute content.
6 7 8 |
# File 'lib/policial/line.rb', line 6 def content @content end |
#number ⇒ Object (readonly)
Returns the value of attribute number.
6 7 8 |
# File 'lib/policial/line.rb', line 6 def number @number end |
#patch_position ⇒ Object (readonly)
Returns the value of attribute patch_position.
6 7 8 |
# File 'lib/policial/line.rb', line 6 def patch_position @patch_position end |
Instance Method Details
#changed? ⇒ Boolean
14 15 16 |
# File 'lib/policial/line.rb', line 14 def changed? true end |