Interface IConsumer<K, V, TJVMK, TJVMV>
KNet extension of IConsumer<K, V>
public interface IConsumer<K, V, TJVMK, TJVMV> : IConsumer<TJVMK, TJVMV>, IConsumer, IJVMBridgeBase, IJVMBridgeDefinition, IDisposable, ICloseable, IAutoCloseable
Type Parameters
K
The key type
V
The value type
TJVMK
The JVM type of
K
TJVMV
The JVM type of
V
- Inherited Members
-
IJVMBridgeBase.MonitorEnter()IJVMBridgeBase.MonitorExit()IJVMBridgeBase.IsInstanceOf(IJavaType)IJVMBridgeBase.IsInstanceOf<T>()IJVMBridgeBase.RuntimeIsInstanceOf<T>()IJVMBridgeBase.CastTo<TNewClass>()IJVMBridgeBase.CastDirect<TNewClass>()IJVMBridgeBase.DynBridgeInstanceIJVMBridgeBase.BridgeInstanceIJVMBridgeDefinition.BridgeClassNameIJVMBridgeDefinition.IsBridgeInterfaceIJVMBridgeDefinition.IsBridgeAbstractIJVMBridgeDefinition.IsBridgeStaticIJVMBridgeDefinition.IsBridgeCloseableIJVMBridgeDefinition.IsBridgeListener
- Extension Methods
Properties
IsCompleting
true if the IConsumer<K, V, TJVMK, TJVMV> instance is completing async operation
bool IsCompleting { get; }
Property Value
IsEmpty
true if the IConsumer<K, V, TJVMK, TJVMV> instance has an empty set of items in async operation
bool IsEmpty { get; }
Property Value
WaitingMessages
Number of messages in the IConsumer<K, V, TJVMK, TJVMV> instance waiting to be processed in async operation
int WaitingMessages { get; }
Property Value
Methods
Consume(long, Action<ConsumerRecord<K, V, TJVMK, TJVMV>>)
KNet sync extension for Poll(Duration)
void Consume(long timeoutMs, Action<ConsumerRecord<K, V, TJVMK, TJVMV>> callback)
Parameters
timeoutMs
longTimeout in milliseconds
callback
Action<ConsumerRecord<K, V, TJVMK, TJVMV>>The Action<T> where receives ConsumerRecord<K, V, TJVMK, TJVMV>
ConsumeAsync(long)
KNet async extension for Poll(Duration)
bool ConsumeAsync(long timeoutMs)
Parameters
timeoutMs
longTimeout in milliseconds
Returns
Poll(long)
KNet extension for Poll(Duration)
ConsumerRecords<K, V, TJVMK, TJVMV> Poll(long timeoutMs)
Parameters
timeoutMs
longTimeout in milliseconds
Returns
- ConsumerRecords<K, V, TJVMK, TJVMV>
Poll(TimeSpan)
KNet extension for Poll(Duration)
ConsumerRecords<K, V, TJVMK, TJVMV> Poll(TimeSpan timeout)
Parameters
Returns
- ConsumerRecords<K, V, TJVMK, TJVMV>
SetCallback(Action<ConsumerRecord<K, V, TJVMK, TJVMV>>)
Sets the Action<T> to use to receive ConsumerRecord<K, V, TJVMK, TJVMV>
void SetCallback(Action<ConsumerRecord<K, V, TJVMK, TJVMV>> cb)
Parameters
cb
Action<ConsumerRecord<K, V, TJVMK, TJVMV>>The callback Action<T>