class DataExporter::ExampleExportModel
Public Class Methods
new(example)
click to toggle source
# File data_exporter/lib/data_exporter/example_export_model.rb, line 3 def initialize(example) @example = example end
Public Instance Methods
export()
click to toggle source
# File data_exporter/lib/data_exporter/example_export_model.rb, line 11 def export [code, name, random_number, created_at, updated_at] end
export_header()
click to toggle source
# File data_exporter/lib/data_exporter/example_export_model.rb, line 7 def export_header ['Code', 'Name', 'Random Number', 'Created At', 'Updated At'] end
Private Instance Methods
code()
click to toggle source
# File data_exporter/lib/data_exporter/example_export_model.rb, line 17 def code @example.code end
created_at()
click to toggle source
# File data_exporter/lib/data_exporter/example_export_model.rb, line 29 def created_at @example.created_at end
name()
click to toggle source
# File data_exporter/lib/data_exporter/example_export_model.rb, line 21 def name @example.name end
random_number()
click to toggle source
# File data_exporter/lib/data_exporter/example_export_model.rb, line 25 def random_number @example.random_number end
updated_at()
click to toggle source
# File data_exporter/lib/data_exporter/example_export_model.rb, line 33 def updated_at @example.updated_at end