Class: Storm::ExecutorSpecificStats
- Inherits:
-
Thrift::Union
- Object
- Thrift::Union
- Storm::ExecutorSpecificStats
- Includes:
- Thrift::Struct_Union
- Defined in:
- lib/storm/thrift/storm_types.rb
Constant Summary collapse
- BOLT =
1
- SPOUT =
2
- FIELDS =
{ BOLT => {:type => ::Thrift::Types::STRUCT, :name => 'bolt', :class => BoltStats}, SPOUT => {:type => ::Thrift::Types::STRUCT, :name => 'spout', :class => SpoutStats} }
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.bolt(val) ⇒ Object
588 589 590 |
# File 'lib/storm/thrift/storm_types.rb', line 588 def bolt(val) ExecutorSpecificStats.new(:bolt, val) end |
.spout(val) ⇒ Object
592 593 594 |
# File 'lib/storm/thrift/storm_types.rb', line 592 def spout(val) ExecutorSpecificStats.new(:spout, val) end |
Instance Method Details
#struct_fields ⇒ Object
605 |
# File 'lib/storm/thrift/storm_types.rb', line 605 def struct_fields; FIELDS; end |
#validate ⇒ Object
607 608 609 |
# File 'lib/storm/thrift/storm_types.rb', line 607 def validate raise(StandardError, 'Union fields are not set.') if get_set_field.nil? || get_value.nil? end |