class Lintron::ViolationLine

Represents one line of the lint results. Exists so that (1) We can use dot syntax to access members instead of [] (2) I can define file_and_line which is used for display and sorting

Public Instance Methods

file_and_line(padTo = 0) click to toggle source
# File lib/lintron/api.rb, line 45
def file_and_line(padTo = 0)
  file_and_line = "#{path}:#{format '%03i', line}    "

  if padTo > file_and_line.length
    file_and_line += ' ' * (padTo - file_and_line.length)
  end

  file_and_line
end