Class StreamInfo.XInfoConsumers
java.lang.Object
org.springframework.data.redis.connection.stream.StreamInfo.XInfoConsumers
- All Implemented Interfaces:
Iterable<StreamInfo.XInfoConsumer>
,Supplier<Stream<StreamInfo.XInfoConsumer>>
,org.springframework.data.util.Streamable<StreamInfo.XInfoConsumer>
- Enclosing class:
- StreamInfo
public static class StreamInfo.XInfoConsumers
extends Object
implements org.springframework.data.util.Streamable<StreamInfo.XInfoConsumer>
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
forEach
(Consumer<? super StreamInfo.XInfoConsumer> action) Performs the given action on every availableStreamInfo.XInfoConsumer
of thisStreamInfo.XInfoConsumers
.static StreamInfo.XInfoConsumers
get
(int index) Returns theStreamInfo.XInfoConsumer
element at the given index.int
Total number of consumers in the consumer group.boolean
isEmpty()
iterator()
Returns an iterator over theStreamInfo.XInfoConsumer
elements.int
size()
Returns the number ofStreamInfo.XInfoConsumer
available.stream()
Returns a sequentialStream
ofStreamInfo.XInfoConsumer
.toString()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.lang.Iterable
spliterator
Methods inherited from interface org.springframework.data.util.Streamable
and, and, and, and, filter, flatMap, get, map, toList, toSet
-
Constructor Details
-
XInfoConsumers
-
-
Method Details
-
fromList
-
getConsumerCount
public int getConsumerCount()Total number of consumers in the consumer group.- Returns:
- zero if none available.
-
size
public int size()Returns the number ofStreamInfo.XInfoConsumer
available.- Returns:
- zero if none available.
- See Also:
-
isEmpty
public boolean isEmpty()- Specified by:
isEmpty
in interfaceorg.springframework.data.util.Streamable<StreamInfo.XInfoConsumer>
- Returns:
- true if no groups associated.
-
iterator
Returns an iterator over theStreamInfo.XInfoConsumer
elements.- Specified by:
iterator
in interfaceIterable<StreamInfo.XInfoConsumer>
- Returns:
-
get
Returns theStreamInfo.XInfoConsumer
element at the given index.- Returns:
- the element at the specified position.
- Throws:
IndexOutOfBoundsException
- if the index is out of range.
-
stream
Returns a sequentialStream
ofStreamInfo.XInfoConsumer
.- Specified by:
stream
in interfaceorg.springframework.data.util.Streamable<StreamInfo.XInfoConsumer>
- Returns:
-
forEach
Performs the given action on every availableStreamInfo.XInfoConsumer
of thisStreamInfo.XInfoConsumers
.- Specified by:
forEach
in interfaceIterable<StreamInfo.XInfoConsumer>
- Parameters:
action
-
-
toString
-