class ERBLint::Reporter

Attributes

autocorrect[R]
stats[R]

Public Class Methods

available_format?(format) click to toggle source
# File lib/erb_lint/reporter.rb, line 12
def self.available_format?(format)
  available_formats.include?(format.to_s)
end
available_formats() click to toggle source
# File lib/erb_lint/reporter.rb, line 16
def self.available_formats
  descendants
    .map(&:to_s)
    .map(&:demodulize)
    .map(&:underscore)
    .map { |klass_name| klass_name.sub("_reporter", "") }
    .sort
end
create_reporter(format, *args) click to toggle source
# File lib/erb_lint/reporter.rb, line 7
def self.create_reporter(format, *args)
  reporter_klass = "#{ERBLint::Reporters}::#{format.to_s.camelize}Reporter".constantize
  reporter_klass.new(*args)
end
new(stats, autocorrect) click to toggle source
# File lib/erb_lint/reporter.rb, line 25
def initialize(stats, autocorrect)
  @stats = stats
  @autocorrect = autocorrect
end

Public Instance Methods

preview() click to toggle source
# File lib/erb_lint/reporter.rb, line 30
def preview; end
show() click to toggle source
# File lib/erb_lint/reporter.rb, line 32
def show; end