java.lang.Object
io.smallrye.mutiny.groups.UniMemoize<T>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionDeprecated, for removal: This API element is subject to removal in a future version.forFixedDuration(Duration duration) Memoize the received item or failure for a duration after the upstream subscription has been received.Memoize the received item or failure indefinitely.until(BooleanSupplier invalidationGuard) Memoize the received item or failure as long as the provided boolean supplier evaluates tofalse.
-
Constructor Details
-
UniMemoize
-
-
Method Details
-
until
Memoize the received item or failure as long as the provided boolean supplier evaluates tofalse.New subscribers will receive the memoized item or failure. When the boolean supplier evaluates to
truethen a new upstream subscription happens and the next subscribers get a chance to observe new values.- API Note:
- This is an experimental API
- Parameters:
invalidationGuard- the invalidation guard, which evaluates tofalsefor as long as the item or failure must be memoized, must not benull- Returns:
- a new
Uni
-
atLeast
Deprecated, for removal: This API element is subject to removal in a future version.useforFixedDuration(Duration)instead.Memoize the received item or failure for a duration after the upstream subscription has been received.New subscribers will receive the memoized item or failure. When duration has elapsed then the first subscription causes a new upstream subscription, and the next subscribers get a chance to observe new values.
- API Note:
- This is an experimental API
- Parameters:
duration- the memoization duration after having received the subscription from upstream, must not benull, must be strictly positive- Returns:
- a new
Uni
-
forFixedDuration
Memoize the received item or failure for a duration after the upstream subscription has been received.New subscribers will receive the memoized item or failure. When duration has elapsed then the first subscription causes a new upstream subscription, and the next subscribers get a chance to observe new values.
- API Note:
- This is an experimental API
- Parameters:
duration- the memoization duration after having received the subscription from upstream, must not benull, must be strictly positive- Returns:
- a new
Uni
-
indefinitely
Memoize the received item or failure indefinitely.- API Note:
- This is an experimental API
- Returns:
- a new
Uni
-
forFixedDuration(Duration)instead.