Class StreamInfo.XInfoGroups
java.lang.Object
org.springframework.data.redis.connection.stream.StreamInfo.XInfoGroups
- Enclosing class:
- StreamInfo
Value object holding general information about consumer groups associated with a
Redis Stream.
- Author:
- Christoph Strobl
-
Method Summary
Modifier and TypeMethodDescriptionvoid
forEach
(Consumer<? super StreamInfo.XInfoGroup> action) Performs the given action on every availableStreamInfo.XInfoGroup
of thisStreamInfo.XInfoGroups
.static StreamInfo.XInfoGroups
Factory method to create a new instance ofStreamInfo.XInfoGroups
.get
(int index) Returns theStreamInfo.XInfoGroup
element at the given index.int
Total number of associated consumer groups.boolean
isEmpty()
iterator()
Returns an iterator over theStreamInfo.XInfoGroup
elements.int
size()
Returns the number ofStreamInfo.XInfoGroup
available.stream()
Returns a sequentialStream
ofStreamInfo.XInfoGroup
.toString()
-
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.XInfoGroup
available.- Returns:
- zero if none available.
- See Also:
-
isEmpty
public boolean isEmpty()- Returns:
- true if no groups associated.
-
iterator
Returns an iterator over theStreamInfo.XInfoGroup
elements.- Returns:
-
get
Returns theStreamInfo.XInfoGroup
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.XInfoGroup
.- Returns:
-
forEach
Performs the given action on every availableStreamInfo.XInfoGroup
of thisStreamInfo.XInfoGroups
.- Parameters:
action
-
-
toString
-