Class: Julewire::Core::RuntimeState
- Inherits:
-
Data
- Object
- Data
- Julewire::Core::RuntimeState
- Defined in:
- lib/julewire/core/runtime_state.rb
Instance Attribute Summary collapse
-
#configuration ⇒ Object
readonly
Returns the value of attribute configuration.
-
#pipeline ⇒ Object
readonly
Returns the value of attribute pipeline.
-
#pipeline_closed ⇒ Object
readonly
Returns the value of attribute pipeline_closed.
-
#pipeline_generation ⇒ Object
readonly
Returns the value of attribute pipeline_generation.
Class Method Summary collapse
Instance Method Summary collapse
Instance Attribute Details
#configuration ⇒ Object (readonly)
Returns the value of attribute configuration
5 6 7 |
# File 'lib/julewire/core/runtime_state.rb', line 5 def configuration @configuration end |
#pipeline ⇒ Object (readonly)
Returns the value of attribute pipeline
5 6 7 |
# File 'lib/julewire/core/runtime_state.rb', line 5 def pipeline @pipeline end |
#pipeline_closed ⇒ Object (readonly)
Returns the value of attribute pipeline_closed
5 6 7 |
# File 'lib/julewire/core/runtime_state.rb', line 5 def pipeline_closed @pipeline_closed end |
#pipeline_generation ⇒ Object (readonly)
Returns the value of attribute pipeline_generation
5 6 7 |
# File 'lib/julewire/core/runtime_state.rb', line 5 def pipeline_generation @pipeline_generation end |
Class Method Details
.default(invalid_severity_reporter: Diagnostics::InvalidSeverityReporter.counter) ⇒ Object
12 13 14 15 16 17 18 19 20 21 22 |
# File 'lib/julewire/core/runtime_state.rb', line 12 def default(invalid_severity_reporter: Diagnostics::InvalidSeverityReporter.counter) configuration = Configuration.new.snapshot pipeline = configuration.build_pipeline(invalid_severity_reporter: invalid_severity_reporter) new( configuration: configuration, pipeline: pipeline, pipeline_closed: false, pipeline_generation: 0 ) end |
Instance Method Details
#closed ⇒ Object
25 26 27 |
# File 'lib/julewire/core/runtime_state.rb', line 25 def closed with(pipeline_closed: true) end |
#next_generation(configuration:, pipeline:) ⇒ Object
29 30 31 32 33 34 35 36 |
# File 'lib/julewire/core/runtime_state.rb', line 29 def next_generation(configuration:, pipeline:) self.class.new( configuration: configuration, pipeline: pipeline, pipeline_closed: false, pipeline_generation: pipeline_generation + 1 ) end |