Class: GaussianParser::Processors::ResultsProcessor
- Inherits:
-
Object
- Object
- GaussianParser::Processors::ResultsProcessor
- Defined in:
- lib/gaussian_parser/processors/results_processor.rb
Instance Method Summary collapse
-
#initialize(results_raw) ⇒ ResultsProcessor
constructor
results.
- #process ⇒ Object
Constructor Details
#initialize(results_raw) ⇒ ResultsProcessor
results
[‘! R1 R(1,7) 2.273 -DE/DX = 0.0 !’,
'! R2 R(1,12) 2.2968 -DE/DX = 0.0 !',
'! R3 R(1,13) 2.2494 -DE/DX = 0.0 !']
10 11 12 |
# File 'lib/gaussian_parser/processors/results_processor.rb', line 10 def initialize(results_raw) @results_raw = results_raw end |
Instance Method Details
#process ⇒ Object
14 15 16 17 18 19 |
# File 'lib/gaussian_parser/processors/results_processor.rb', line 14 def process @results_raw.map do |line| line.gsub!(/\s*!\s*/,'') line.split(/\s+/)[0..2] end end |