Class: Yardstick::Processor
- Inherits:
-
Object
- Object
- Yardstick::Processor
- Defined in:
- lib/yardstick/processor.rb
Overview
Handle procesing a docstring or path of files
Instance Method Summary collapse
-
#initialize(config) ⇒ undefined
constructor
private
Initializes new Processor instance.
-
#process ⇒ Yardstick::MeasurementSet
private
Measure files specified in the config.
-
#process_string(string) ⇒ Yardstick::MeasurementSet
private
Measure string provided.
Constructor Details
#initialize(config) ⇒ undefined
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Initializes new Processor instance
14 15 16 |
# File 'lib/yardstick/processor.rb', line 14 def initialize(config) @config = config end |
Instance Method Details
#process ⇒ Yardstick::MeasurementSet
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Measure files specified in the config
24 25 26 |
# File 'lib/yardstick/processor.rb', line 24 def process Parser.parse_paths(paths).measure(@config) end |
#process_string(string) ⇒ Yardstick::MeasurementSet
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Measure string provided
37 38 39 |
# File 'lib/yardstick/processor.rb', line 37 def process_string(string) Parser.parse_string(string).measure(@config) end |