public abstract class StreamAdapter<T,K,V> extends Object
IgniteDataStreamer
.
Two types of tuple extractors are supported:
setTupleExtractor(StreamTupleExtractor)
.Map
. See setMultipleTupleExtractor(StreamMultipleTupleExtractor)
.Modifier | Constructor and Description |
---|---|
protected |
StreamAdapter()
Empty constructor.
|
protected |
StreamAdapter(IgniteDataStreamer<K,V> stmr,
StreamMultipleTupleExtractor<T,K,V> extractor)
Stream adapter.
|
protected |
StreamAdapter(IgniteDataStreamer<K,V> stmr,
StreamSingleTupleExtractor<T,K,V> extractor)
Stream adapter.
|
Modifier and Type | Method and Description |
---|---|
protected void |
addMessage(T msg)
Converts given message to 1 or many tuples (depending on the type of extractor) and adds it/them to the
underlying streamer.
|
Ignite |
getIgnite() |
StreamMultipleTupleExtractor<T,K,V> |
getMultipleTupleExtractor() |
StreamSingleTupleExtractor<T,K,V> |
getSingleTupleExtractor() |
IgniteDataStreamer<K,V> |
getStreamer() |
StreamTupleExtractor<T,K,V> |
getTupleExtractor()
Deprecated.
|
void |
setIgnite(Ignite ignite) |
void |
setMultipleTupleExtractor(StreamMultipleTupleExtractor<T,K,V> multipleTupleExtractor) |
void |
setSingleTupleExtractor(StreamSingleTupleExtractor<T,K,V> singleTupleExtractor) |
void |
setStreamer(IgniteDataStreamer<K,V> stmr) |
void |
setTupleExtractor(StreamTupleExtractor<T,K,V> extractor)
Deprecated.
|
protected Ignite ignite
protected StreamAdapter()
protected StreamAdapter(IgniteDataStreamer<K,V> stmr, StreamSingleTupleExtractor<T,K,V> extractor)
stmr
- Streamer.extractor
- Tuple extractor (1:1).protected StreamAdapter(IgniteDataStreamer<K,V> stmr, StreamMultipleTupleExtractor<T,K,V> extractor)
stmr
- Streamer.extractor
- Tuple extractor (1:n).public IgniteDataStreamer<K,V> getStreamer()
public void setStreamer(IgniteDataStreamer<K,V> stmr)
stmr
- Ignite data streamer.@Deprecated public StreamTupleExtractor<T,K,V> getTupleExtractor()
getSingleTupleExtractor()
@Deprecated public void setTupleExtractor(StreamTupleExtractor<T,K,V> extractor)
extractor
- Extractor for a single key-value tuple from the message.setSingleTupleExtractor(StreamSingleTupleExtractor)
public StreamSingleTupleExtractor<T,K,V> getSingleTupleExtractor()
public void setSingleTupleExtractor(StreamSingleTupleExtractor<T,K,V> singleTupleExtractor)
singleTupleExtractor
- Extractor for key-value tuples from messages.public StreamMultipleTupleExtractor<T,K,V> getMultipleTupleExtractor()
public void setMultipleTupleExtractor(StreamMultipleTupleExtractor<T,K,V> multipleTupleExtractor)
multipleTupleExtractor
- Extractor for 1:n tuple extraction.protected void addMessage(T msg)
msg
- Message to convert.
Follow @ApacheIgnite
Ignite Database and Caching Platform : ver. 2.16.0 Release Date : December 15 2023