Class: Sed::Runner
- Inherits:
-
Object
- Object
- Sed::Runner
- Defined in:
- lib/sed/runner.rb
Instance Attribute Summary collapse
-
#input_file_path ⇒ Object
readonly
Returns the value of attribute input_file_path.
-
#opts ⇒ Object
readonly
Returns the value of attribute opts.
Instance Method Summary collapse
-
#initialize(input_file_path, opts = {}, &blk) ⇒ Runner
constructor
A new instance of Runner.
- #replace(expression, replacement) ⇒ Object
Constructor Details
#initialize(input_file_path, opts = {}, &blk) ⇒ Runner
Returns a new instance of Runner.
6 7 8 9 10 11 |
# File 'lib/sed/runner.rb', line 6 def initialize(input_file_path, opts = {}, &blk) @input_file_path = input_file_path @opts = opts instance_eval(&blk) if block_given? end |
Instance Attribute Details
#input_file_path ⇒ Object (readonly)
Returns the value of attribute input_file_path.
4 5 6 |
# File 'lib/sed/runner.rb', line 4 def input_file_path @input_file_path end |
#opts ⇒ Object (readonly)
Returns the value of attribute opts.
4 5 6 |
# File 'lib/sed/runner.rb', line 4 def opts @opts end |