Class: LittleGhost::WorkflowBuilder
- Inherits:
-
AssemblyBuilder
- Object
- AssemblyBuilder
- LittleGhost::WorkflowBuilder
- Defined in:
- lib/little_ghost/assembly_builder.rb
Overview
Builds a Workflow whose Ruby composition block is supplied at runtime.
Use a named Workflow subclass's to_builder when the class supplies the
composition and runtime configuration supplies its identity or description.
perform supplies the underlying dynamic form for trusted application code.
Instance Attribute Summary
Attributes inherited from AssemblyBuilder
Class Method Summary collapse
-
.assembly_kind ⇒ Object
:nodoc:.
Instance Method Summary collapse
-
#perform(&block) ⇒ Object
Declares the Ruby composition body for dynamic Workflow executions.
Methods inherited from AssemblyBuilder
#as_tool, #ask, #assembly_id, #assembly_kind, #build, #call, #definition, #description, #initialize, #start_execution, #stream, #stream_ask, #validate!
Constructor Details
This class inherits a constructor from LittleGhost::AssemblyBuilder
Class Method Details
.assembly_kind ⇒ Object
:nodoc:
345 |
# File 'lib/little_ghost/assembly_builder.rb', line 345 def assembly_kind = :workflow |
Instance Method Details
#perform(&block) ⇒ Object
Declares the Ruby composition body for dynamic Workflow executions.
349 350 351 352 353 354 |
# File 'lib/little_ghost/assembly_builder.rb', line 349 def perform(&block) raise ArgumentError, "perform requires a block" unless block @mutex.synchronize { @performer = block } self end |