Class: Rubycritic::BaseGenerator
- Inherits:
-
Object
- Object
- Rubycritic::BaseGenerator
show all
- Defined in:
- lib/rubycritic/report_generators/base_generator.rb
Constant Summary
collapse
- REPORT_DIR =
File.expand_path("tmp/rubycritic", Dir.getwd)
- TEMPLATES_DIR =
File.expand_path("../templates", __FILE__)
Instance Method Summary
collapse
Instance Method Details
#file_directory ⇒ Object
11
12
13
|
# File 'lib/rubycritic/report_generators/base_generator.rb', line 11
def file_directory
raise NotImplementedError.new("You must implement the file_directory method.")
end
|
#file_name ⇒ Object
15
16
17
|
# File 'lib/rubycritic/report_generators/base_generator.rb', line 15
def file_name
raise NotImplementedError.new("You must implement the file_name method.")
end
|
#file_pathname ⇒ Object
7
8
9
|
# File 'lib/rubycritic/report_generators/base_generator.rb', line 7
def file_pathname
File.join(file_directory, file_name)
end
|
#get_binding ⇒ Object
31
32
33
|
# File 'lib/rubycritic/report_generators/base_generator.rb', line 31
def get_binding
binding
end
|
#index_path ⇒ Object
27
28
29
|
# File 'lib/rubycritic/report_generators/base_generator.rb', line 27
def index_path
File.join(REPORT_DIR, "index.html")
end
|
#render ⇒ Object
19
20
21
|
# File 'lib/rubycritic/report_generators/base_generator.rb', line 19
def render
raise NotImplementedError.new("You must implement the render file_name method.")
end
|
#stylesheet_path ⇒ Object
23
24
25
|
# File 'lib/rubycritic/report_generators/base_generator.rb', line 23
def stylesheet_path
File.join(REPORT_DIR, "assets/stylesheets/application.css")
end
|