Class: RedStorm::DSL::InputBoltDefinition
- Inherits:
-
Topology::BoltDefinition
- Object
- Configurator
- Topology::ComponentDefinition
- Topology::BoltDefinition
- RedStorm::DSL::InputBoltDefinition
- Defined in:
- lib/red_storm/dsl/drpc_topology.rb
Instance Attribute Summary collapse
-
#grouping(grouping) ⇒ Object
Returns the value of attribute grouping.
Attributes inherited from Topology::BoltDefinition
Attributes inherited from Topology::ComponentDefinition
#clazz, #constructor_args, #id, #parallelism
Attributes inherited from Configurator
Instance Method Summary collapse
- #define_grouping(declarer) ⇒ Object
-
#initialize(*args) ⇒ InputBoltDefinition
constructor
A new instance of InputBoltDefinition.
Methods inherited from Topology::BoltDefinition
Methods inherited from Topology::ComponentDefinition
Methods inherited from Configurator
Constructor Details
#initialize(*args) ⇒ InputBoltDefinition
Returns a new instance of InputBoltDefinition.
11 12 13 14 |
# File 'lib/red_storm/dsl/drpc_topology.rb', line 11 def initialize(*args) super @grouping = :none end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class RedStorm::Configurator
Instance Attribute Details
#grouping(grouping) ⇒ Object
Returns the value of attribute grouping.
9 10 11 |
# File 'lib/red_storm/dsl/drpc_topology.rb', line 9 def grouping @grouping end |
Instance Method Details
#define_grouping(declarer) ⇒ Object
20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/red_storm/dsl/drpc_topology.rb', line 20 def define_grouping(declarer) case @grouping when :fields declarer.fieldsGrouping(Fields.new(*([params].flatten.map(&:to_s)))) when :global declarer.globalGrouping() when :shuffle declarer.shuffleGrouping() when :local_or_shuffle declarer.localOrShuffleGrouping() when :none declarer.noneGrouping() when :all declarer.allGrouping() when :direct declarer.directGrouping() else raise("unknown grouper=#{grouper.inspect}") end end |