Class: RubynCode::Output::DiffRenderer::DiffLine
- Inherits:
-
Data
- Object
- Data
- RubynCode::Output::DiffRenderer::DiffLine
- Defined in:
- lib/rubyn_code/output/diff_renderer.rb
Overview
Represents a single diff line with its type and content.
Instance Attribute Summary collapse
-
#content ⇒ Object
readonly
Returns the value of attribute content.
-
#type ⇒ Object
readonly
Returns the value of attribute type.
Instance Method Summary collapse
Instance Attribute Details
#content ⇒ Object (readonly)
Returns the value of attribute content
12 13 14 |
# File 'lib/rubyn_code/output/diff_renderer.rb', line 12 def content @content end |
#type ⇒ Object (readonly)
Returns the value of attribute type
12 13 14 |
# File 'lib/rubyn_code/output/diff_renderer.rb', line 12 def type @type end |
Instance Method Details
#addition? ⇒ Boolean
13 |
# File 'lib/rubyn_code/output/diff_renderer.rb', line 13 def addition? = type == :add |
#context? ⇒ Boolean
15 |
# File 'lib/rubyn_code/output/diff_renderer.rb', line 15 def context? = type == :context |
#deletion? ⇒ Boolean
14 |
# File 'lib/rubyn_code/output/diff_renderer.rb', line 14 def deletion? = type == :delete |