Class ClientUriSuppliers.RoundRobinSupplier
java.lang.Object
io.helidon.webclient.grpc.ClientUriSuppliers.RoundRobinSupplier
- All Implemented Interfaces:
ClientUriSupplier, Iterable<ClientUri>, Iterator<ClientUri>
- Enclosing class:
ClientUriSuppliers
public static class ClientUriSuppliers.RoundRobinSupplier
extends Object
implements ClientUriSupplier
Supplies a neven-ending iterator that returns URIs chosen using
a round-robin strategy.
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedRoundRobinSupplier(ClientUri[] clientUris) Creates a round-robin supplier. -
Method Summary
Modifier and TypeMethodDescriptionCreates a round-robin supplier.create(Collection<ClientUri> clientUris) Creates a round-robin supplier.booleanhasNext()next()Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface ClientUriSupplier
iteratorMethods inherited from interface Iterable
forEach, spliteratorMethods inherited from interface Iterator
forEachRemaining, remove
-
Constructor Details
-
RoundRobinSupplier
Creates a round-robin supplier.- Parameters:
clientUris- URIs to cycle through
-
-
Method Details
-
create
Creates a round-robin supplier.- Parameters:
clientUris- array of client URIs- Returns:
- new supplier
-
create
Creates a round-robin supplier.- Parameters:
clientUris- collection of client URIs- Returns:
- new supplier
-
hasNext
-
next
-