Class: Datacraft::Context
- Inherits:
-
Object
- Object
- Datacraft::Context
- Defined in:
- lib/datacraft/context.rb
Instance Method Summary collapse
- #consumers ⇒ Object
-
#initialize ⇒ Context
constructor
A new instance of Context.
- #options ⇒ Object
- #post_hooks ⇒ Object
- #pre_hooks ⇒ Object
- #providers ⇒ Object
- #tweakers ⇒ Object
Constructor Details
#initialize ⇒ Context
Returns a new instance of Context.
3 4 5 6 7 |
# File 'lib/datacraft/context.rb', line 3 def initialize [:parallel] = false [:benchmark] = false [:n_threads] = 8 end |
Instance Method Details
#consumers ⇒ Object
13 14 15 |
# File 'lib/datacraft/context.rb', line 13 def consumers @consumers ||= ConsumerRegistry.new end |
#options ⇒ Object
29 30 31 |
# File 'lib/datacraft/context.rb', line 29 def @options ||= {} end |
#post_hooks ⇒ Object
25 26 27 |
# File 'lib/datacraft/context.rb', line 25 def post_hooks @post_hooks ||= HookRegistry.new end |
#pre_hooks ⇒ Object
21 22 23 |
# File 'lib/datacraft/context.rb', line 21 def pre_hooks @pre_hooks ||= HookRegistry.new end |
#providers ⇒ Object
9 10 11 |
# File 'lib/datacraft/context.rb', line 9 def providers @providers ||= ProviderRegistry.new end |
#tweakers ⇒ Object
17 18 19 |
# File 'lib/datacraft/context.rb', line 17 def tweakers @tweakers ||= TweakerRegistry.new end |