Package org.apache.storm.tuple
Interface Tuple
- All Superinterfaces:
- ITuple
- All Known Implementing Classes:
- ClojureTuple,- TupleImpl
The tuple is the main data structure in Storm. A tuple is a named list of values, where each value can be any type. Tuples are
 dynamically typed -- the types of the fields do not need to be declared. Tuples have helper methods like getInteger and getString to get
 field values without having to cast the result.
 
Storm needs to know how to serialize all the values in a tuple. By default, Storm knows how to serialize the primitive types, strings, and byte arrays. If you want to use another type, you'll need to implement and register a serializer for that type.
- See Also:
- 
Method SummaryModifier and TypeMethodDescriptionGets the topology context associated with the tuple.Gets the message id that associated with this tuple.Gets the id of the component that created this tuple.Returns the global stream id (component + stream) of this tuple.Gets the id of the stream that this tuple was emitted to.intGets the id of the task that created this tuple.Methods inherited from interface org.apache.storm.tuple.ITuplecontains, fieldIndex, getBinary, getBinaryByField, getBoolean, getBooleanByField, getByte, getByteByField, getDouble, getDoubleByField, getFields, getFloat, getFloatByField, getInteger, getIntegerByField, getLong, getLongByField, getShort, getShortByField, getString, getStringByField, getValue, getValueByField, getValues, select, size
- 
Method Details- 
getSourceGlobalStreamIdGlobalStreamId getSourceGlobalStreamId()Returns the global stream id (component + stream) of this tuple.
- 
getSourceComponentString getSourceComponent()Gets the id of the component that created this tuple.
- 
getSourceTaskint getSourceTask()Gets the id of the task that created this tuple.
- 
getSourceStreamIdString getSourceStreamId()Gets the id of the stream that this tuple was emitted to.
- 
getMessageIdMessageId getMessageId()Gets the message id that associated with this tuple.
- 
getContextGeneralTopologyContext getContext()Gets the topology context associated with the tuple.
 
-