Class: Homebrew::Style::LineLocation Private
- Inherits:
-
Object
- Object
- Homebrew::Style::LineLocation
- Defined in:
- style.rb
Overview
This class is part of a private API. This class may only be used in the Homebrew/brew repository. Third parties should avoid using this class if possible, as it may be removed or changed without warning.
Source location of a style offense.
Instance Attribute Summary collapse
-
#column ⇒ Object
readonly
private
-
#line ⇒ Object
readonly
private
Instance Method Summary collapse
-
#initialize(json) ⇒ LineLocation
constructor
private
A new instance of LineLocation.
-
#to_s ⇒ String
private
Constructor Details
#initialize(json) ⇒ LineLocation
This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.
Returns a new instance of LineLocation.
340 341 342 343 |
# File 'style.rb', line 340 def initialize(json) @line = json["line"] @column = json["column"] end |
Instance Attribute Details
#column ⇒ Object (readonly)
This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.
338 339 340 |
# File 'style.rb', line 338 def column @column end |
#line ⇒ Object (readonly)
This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.
338 339 340 |
# File 'style.rb', line 338 def line @line end |
Instance Method Details
#to_s ⇒ String
This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.
346 347 348 |
# File 'style.rb', line 346 def to_s "#{line}: col #{column}" end |