1 require_dependency "locmare/profiler/header"
2 require_dependency "locmare/profiler/column"
3 require_dependency "locmare/profiler/association"
7 attr :profiler_manifest, :item_name, :item, :operators, :template_dir,
8 :header, :columns, :associations
9 def initialize item_name, item, operators
10 @item_name = item_name
12 @operators = operators
13 @profiler_manifest = LocalManifest.manifest.profilers[@item_name]
14 @template_dir = 'templates/r/profiler/'
15 @header = Header.new self
16 @columns = @profiler_manifest.column_names.map {|column_name|
17 Column.new self, column_name
19 @associations = Association.new self, @profiler_manifest.associations
23 ::Manifest::item_name_to_model @item_name
26 def template_file_name
31 self.template_dir + self.template_file_name
34 def header_template_file_name
38 def header_template_name
39 self.template_dir + self.header_template_file_name
42 def columns_template_file_name
46 def columns_template_name
47 self.template_dir + self.columns_template_file_name
50 def associations_template_file_name
54 def associations_template_name
55 self.template_dir + self.associations_template_file_name