Class: Mumuki::Classroom::Reports::Formats

Inherits:
Object
  • Object
show all
Defined in:
lib/mumuki/classroom/reports/formats.rb

Defined Under Namespace

Modules: Csv, Json, Table

Class Method Summary collapse

Class Method Details

.format_for(key) ⇒ Object



28
29
30
# File 'lib/mumuki/classroom/reports/formats.rb', line 28

def self.format_for(key)
  "Mumuki::Classroom::Reports::Formats::#{key.capitalize}".constantize
end

.format_report(key, stats) ⇒ Object



32
33
34
# File 'lib/mumuki/classroom/reports/formats.rb', line 32

def self.format_report(key, stats)
  format_for(key).format_report(stats)
end