Class: Packnga::YARDTask
- Inherits:
-
Object
- Object
- Packnga::YARDTask
- Includes:
- Rake::DSL
- Defined in:
- lib/packnga/yard-task.rb
Overview
This class creates YARD task. YARD task generates references by YARD.
Instance Attribute Summary collapse
-
#base_dir ⇒ String
This attribute is used to set path of base directory of document.
-
#options ⇒ Array<String>
Custom yardoc command line options.
-
#readme ⇒ String
This attribute is used to set README file to yardoc task.
-
#source_files ⇒ Array<String>
This attribute is used to set source files for document.
- #text_files ⇒ Object
Instance Method Summary collapse
-
#before_define(&hook) ⇒ Object
Regists yardoc parameters with block.
- #define ⇒ Object
-
#initialize(spec) ⇒ YARDTask
constructor
A new instance of YARDTask.
Constructor Details
#initialize(spec) ⇒ YARDTask
Returns a new instance of YARDTask.
49 50 51 52 53 54 55 56 57 |
# File 'lib/packnga/yard-task.rb', line 49 def initialize(spec) @spec = spec @hooks = [] @readme = nil @text_files = nil @base_dir = nil @options = [] @source_files = nil end |
Instance Attribute Details
#base_dir ⇒ String
This attribute is used to set path of base directory of document.
35 36 37 |
# File 'lib/packnga/yard-task.rb', line 35 def base_dir @base_dir end |
#options ⇒ Array<String>
Returns custom yardoc command line options.
46 47 48 |
# File 'lib/packnga/yard-task.rb', line 46 def @options end |
#readme ⇒ String
This attribute is used to set README file to yardoc task.
31 32 33 |
# File 'lib/packnga/yard-task.rb', line 31 def readme @readme end |
#source_files ⇒ Array<String>
This attribute is used to set source files for document.
39 40 41 |
# File 'lib/packnga/yard-task.rb', line 39 def source_files @source_files end |
#text_files ⇒ Object
43 44 45 |
# File 'lib/packnga/yard-task.rb', line 43 def text_files @text_files end |
Instance Method Details
#before_define(&hook) ⇒ Object
Regists yardoc parameters with block.
71 72 73 |
# File 'lib/packnga/yard-task.rb', line 71 def before_define(&hook) @hooks << hook end |
#define ⇒ Object
65 66 67 68 |
# File 'lib/packnga/yard-task.rb', line 65 def define set_default_values define_tasks end |