cascading.flow.stream
Class MemorySpliceGate
java.lang.Object
cascading.flow.stream.Duct<Incoming,Outgoing>
cascading.flow.stream.Gate<TupleEntry,Grouping<TupleEntry,TupleEntryIterator>>
cascading.flow.stream.SpliceGate
cascading.flow.stream.MemorySpliceGate
- All Implemented Interfaces:
- Collapsing, ElementDuct
- Direct Known Subclasses:
- MemoryCoGroupGate, MemoryHashJoinGate
public abstract class MemorySpliceGate
- extends SpliceGate
Fields inherited from class cascading.flow.stream.SpliceGate |
flowProcess, grouping, incomingScopes, keyBuilder, keyEntry, keyFields, orderedPrevious, outgoingScopes, role, sortBuilder, sortFields, splice, tupleEntryIterator, valuesBuilder, valuesFields |
Fields inherited from class cascading.flow.stream.Duct |
next |
Methods inherited from class cascading.flow.stream.SpliceGate |
addIncomingScope, addOutgoingScope, cleanup, createNarrowBuilder, createNulledBuilder, equals, getBranchNames, getFlowElement, getIncomingScopes, getOutgoingScopes, handleException, handleReThrowableException, hashCode, hasTrapHandler, makePosMap, orderDucts, setBranchNames, setTrapHandler, toString |
posMap
protected final Map<Duct,Integer> posMap
groupComparators
protected Comparator<Tuple>[] groupComparators
valueComparators
protected Comparator<Tuple>[] valueComparators
groupHasher
protected TupleHasher groupHasher
nullsAreNotEqual
protected boolean nullsAreNotEqual
keys
protected Set<Tuple> keys
keyValues
protected Map<Tuple,Collection<Tuple>>[] keyValues
closure
protected MemoryCoGroupClosure closure
numIncomingPaths
protected int numIncomingPaths
count
protected final AtomicInteger count
MemorySpliceGate
public MemorySpliceGate(FlowProcess flowProcess,
Splice splice)
bind
public void bind(StreamGraph streamGraph)
- Overrides:
bind
in class Gate<TupleEntry,Grouping<TupleEntry,TupleEntryIterator>>
createDefaultNarrowBuilder
protected TupleBuilder createDefaultNarrowBuilder(Fields incomingFields,
Fields narrowFields)
- Overrides:
createDefaultNarrowBuilder
in class SpliceGate
initialize
public void initialize()
- Description copied from class:
Duct
- Called immediately after bind
- Overrides:
initialize
in class SpliceGate
prepare
public void prepare()
- Overrides:
prepare
in class Duct<TupleEntry,Grouping<TupleEntry,TupleEntryIterator>>
getKeyComparator
protected Comparator getKeyComparator()
createKeySet
protected Set<Tuple> createKeySet()
createKeyValuesArray
protected Map<Tuple,Collection<Tuple>>[] createKeyValuesArray()
- This lets us just replace an old map and let the gc cleanup, vs clearing each map
- Returns:
- of type Map
createTupleMap
protected Map<Tuple,Collection<Tuple>> createTupleMap()
getDelegatedTuple
protected final Tuple getDelegatedTuple(Tuple object)
- This allows the tuple to honor the hasher and comparators, if any
- Parameters:
object
- the tuple to wrap
- Returns:
- a DelegatedTuple instance
isBlockingStreamed
protected abstract boolean isBlockingStreamed()
Copyright © 2007-2014 Concurrent, Inc. All Rights Reserved.