Sha256: 853bf02c705d24e5f9b3a795cb827f4853760cee9418a39d68eb8c2b7735ae10
Contents?: true
Size: 632 Bytes
Versions: 21
Compression:
Stored size: 632 Bytes
Contents
module CC module Analyzer module Formatters autoload :Formatter, "cc/analyzer/formatters/formatter" autoload :JSONFormatter, "cc/analyzer/formatters/json_formatter" autoload :PlainTextFormatter, "cc/analyzer/formatters/plain_text_formatter" autoload :Spinner, "cc/analyzer/formatters/spinner" FORMATTERS = { json: JSONFormatter, text: PlainTextFormatter, }.freeze def self.resolve(name) FORMATTERS[name.to_sym] or raise InvalidFormatterError, "'#{name}' is not a valid formatter. Valid options are: #{FORMATTERS.keys.join(', ')}" end end end end
Version data entries
21 entries across 21 versions & 1 rubygems