Class StreamInfo.XInfoGroups
java.lang.Object
org.springframework.data.redis.connection.stream.StreamInfo.XInfoGroups
- All Implemented Interfaces:
Iterable<StreamInfo.XInfoGroup>,Supplier<Stream<StreamInfo.XInfoGroup>>,Streamable<StreamInfo.XInfoGroup>
- Enclosing class:
- StreamInfo
public static class StreamInfo.XInfoGroups
extends Object
implements Streamable<StreamInfo.XInfoGroup>
Value object holding general information about consumer groups associated with a
Redis Stream.
- Author:
- Christoph Strobl
-
Method Summary
Modifier and TypeMethodDescriptionvoidforEach(Consumer<? super StreamInfo.XInfoGroup> action) Performs the given action on every availableStreamInfo.XInfoGroupof thisStreamInfo.XInfoGroups.static StreamInfo.XInfoGroupsFactory method to create a new instance ofStreamInfo.XInfoGroups.get(int index) Returns theStreamInfo.XInfoGroupelement at the given index.intTotal number of associated consumer groups.booleanisEmpty()iterator()Returns an iterator over theStreamInfo.XInfoGroupelements.intsize()Returns the number ofStreamInfo.XInfoGroupavailable.stream()Returns a sequentialStreamofStreamInfo.XInfoGroup.toString()Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface java.lang.Iterable
spliterator
-
Method Details
-
fromList
Factory method to create a new instance ofStreamInfo.XInfoGroups.- Parameters:
source- the raw value source.- Returns:
-
groupCount
public int groupCount()Total number of associated consumer groups.- Returns:
- zero if none available.
-
size
public int size()Returns the number ofStreamInfo.XInfoGroupavailable.- Returns:
- zero if none available.
- See Also:
-
isEmpty
public boolean isEmpty()- Specified by:
isEmptyin interfaceStreamable<StreamInfo.XInfoGroup>- Returns:
- true if no groups associated.
-
iterator
Returns an iterator over theStreamInfo.XInfoGroupelements.- Specified by:
iteratorin interfaceIterable<StreamInfo.XInfoGroup>- Returns:
-
get
Returns theStreamInfo.XInfoGroupelement at the given index.- Returns:
- the element at the specified position.
- Throws:
IndexOutOfBoundsException- if the index is out of range.
-
stream
Returns a sequentialStreamofStreamInfo.XInfoGroup.- Specified by:
streamin interfaceStreamable<StreamInfo.XInfoGroup>- Returns:
-
forEach
Performs the given action on every availableStreamInfo.XInfoGroupof thisStreamInfo.XInfoGroups.- Specified by:
forEachin interfaceIterable<StreamInfo.XInfoGroup>- Parameters:
action-
-
toString
-