Class: RDoc::Generator::R2DOC
- Inherits:
-
HTML
- Object
- HTML
- RDoc::Generator::R2DOC
- Includes:
- ERB::Util, R2Doc::Generator, R2Doc::TemplateUtil
- Defined in:
- lib/r2doc/rdoc_v2_generator.rb
Overview
R2Doc generator for RDoc v2
Class Method Summary collapse
-
.for(options) ⇒ Object
Factory method.
Instance Method Summary collapse
-
#complete_method_list ⇒ Object
Return a list of all defined methods.
-
#create_class_context(context, file, options) ⇒ Object
Create a new class object for this RDoc version.
-
#create_file_context(context, options) ⇒ Object
Create a new file object for this RDoc version.
-
#generate_prep ⇒ Object
Perform version-specific initialization.
-
#get_toplevels ⇒ Object
Return the list of top level objects for this RDoc version.
-
#initialize(*args) ⇒ R2DOC
constructor
Constructor.
-
#template_name ⇒ Object
Return the name of the template.
Methods included from R2Doc::Generator
Methods included from R2Doc::TemplateUtil
#content_tag, gen_url, #link_to, #path_to, #render_partial, #stripe_class
Constructor Details
#initialize(*args) ⇒ R2DOC
Constructor
73 74 75 76 |
# File 'lib/r2doc/rdoc_v2_generator.rb', line 73 def initialize(*args) super build_static_file_list end |
Class Method Details
.for(options) ⇒ Object
Factory method
68 69 70 |
# File 'lib/r2doc/rdoc_v2_generator.rb', line 68 def R2DOC.for() R2DOC.new() end |
Instance Method Details
#complete_method_list ⇒ Object
Return a list of all defined methods
104 105 106 |
# File 'lib/r2doc/rdoc_v2_generator.rb', line 104 def complete_method_list Method.all_methods end |
#create_class_context(context, file, options) ⇒ Object
Create a new class object for this RDoc version
99 100 101 |
# File 'lib/r2doc/rdoc_v2_generator.rb', line 99 def create_class_context(context, file, ) Class.new(@template_cache, context, file, CLASS_DIR, ) end |
#create_file_context(context, options) ⇒ Object
Create a new file object for this RDoc version
94 95 96 |
# File 'lib/r2doc/rdoc_v2_generator.rb', line 94 def create_file_context(context, ) File.new(@template_cache, context, , FILE_DIR) end |
#generate_prep ⇒ Object
Perform version-specific initialization
79 80 81 |
# File 'lib/r2doc/rdoc_v2_generator.rb', line 79 def generate_prep @template_cache = Cache.instance end |
#get_toplevels ⇒ Object
Return the list of top level objects for this RDoc version
89 90 91 |
# File 'lib/r2doc/rdoc_v2_generator.rb', line 89 def get_toplevels TopLevel end |
#template_name ⇒ Object
Return the name of the template
84 85 86 |
# File 'lib/r2doc/rdoc_v2_generator.rb', line 84 def template_name @options.template || 'r2doc' end |