1 require_dependency "manifest/local/view/profiler/header"
2 require_dependency "manifest/local/view/profiler/column"
3 require_dependency "manifest/local/view/profiler/association"
8 attr :profiler_manifest, :item_name, :item, :operators, :template_dir,
9 :header, :columns, :associations
10 def initialize item_name, item, operators
11 @item_name = item_name
13 @operators = operators
14 @profiler_manifest = Manifest.manifest.profilers[@item_name]
15 @template_dir = 'templates/r/profiler/'
16 @header = Header.new self
17 @columns = @profiler_manifest.column_names.map {|column_name|
18 Column.new self, column_name
20 @associations = Association.new self, @profiler_manifest.associations
24 ::Manifest::item_name_to_model @item_name
27 def template_file_name
32 self.template_dir + self.template_file_name
35 def header_template_file_name
39 def header_template_name
40 self.template_dir + self.header_template_file_name
43 def columns_template_file_name
47 def columns_template_name
48 self.template_dir + self.columns_template_file_name
51 def associations_template_file_name
55 def associations_template_name
56 self.template_dir + self.associations_template_file_name