Package com.rabbitmq.stream
Interface SubscriptionListener.SubscriptionContext
-
- Enclosing interface:
- SubscriptionListener
public static interface SubscriptionListener.SubscriptionContext
Context object for the subscription.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description OffsetSpecification
offsetSpecification()
The offset specification computed by the library.void
offsetSpecification(OffsetSpecification offsetSpecification)
Set the offset specification to use for the subscription.String
stream()
The stream involved.
-
-
-
Method Detail
-
offsetSpecification
OffsetSpecification offsetSpecification()
The offset specification computed by the library.If the consumer has no name, the value is the value set with
ConsumerBuilder.offset(OffsetSpecification)
on the first subscription and the offset of the last dispatched message on subsequent calls (e.g. when the client re-subscribes after a disconnection).If the consumer has a name, the value is the last stored if any.
- Returns:
- the computed offset specification
- See Also:
ConsumerBuilder.name(String)
-
offsetSpecification
void offsetSpecification(OffsetSpecification offsetSpecification)
Set the offset specification to use for the subscription.It overrides the value computed by the client.
- Parameters:
offsetSpecification
- the offset specification to use
-
stream
String stream()
The stream involved.- Returns:
- the stream
-
-