Class: RubyCritic::Generator::Html::CodeIndex
- Defined in:
- lib/rubycritic/generators/html/code_index.rb
Constant Summary collapse
- TEMPLATE =
erb_template('code_index.html.erb')
Constants inherited from Base
Base::LAYOUT_TEMPLATE, Base::TEMPLATES_DIR
Instance Method Summary collapse
- #file_name ⇒ Object
-
#initialize(analysed_modules) ⇒ CodeIndex
constructor
A new instance of CodeIndex.
- #render ⇒ Object
Methods inherited from Base
erb_template, #file_directory, #file_href, #file_pathname
Methods included from ViewHelpers
#asset_path, #file_path, #image_path, #javascript_tag, #smell_location_path, #stylesheet_path, #timeago_tag
Constructor Details
#initialize(analysed_modules) ⇒ CodeIndex
Returns a new instance of CodeIndex.
10 11 12 |
# File 'lib/rubycritic/generators/html/code_index.rb', line 10 def initialize(analysed_modules) @analysed_modules = analysed_modules end |
Instance Method Details
#file_name ⇒ Object
14 15 16 |
# File 'lib/rubycritic/generators/html/code_index.rb', line 14 def file_name 'code_index.html' end |
#render ⇒ Object
18 19 20 21 |
# File 'lib/rubycritic/generators/html/code_index.rb', line 18 def render index_body = TEMPLATE.result(get_binding) LAYOUT_TEMPLATE.result(get_binding { index_body }) end |