Package org.postgresql.hostchooser
Class SingleHostChooser
- java.lang.Object
-
- org.postgresql.hostchooser.SingleHostChooser
-
- All Implemented Interfaces:
java.lang.Iterable<CandidateHost>
,HostChooser
class SingleHostChooser extends java.lang.Object implements HostChooser
Host chooser that returns the single host.
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.Collection<CandidateHost>
candidateHost
-
Constructor Summary
Constructors Constructor Description SingleHostChooser(HostSpec hostSpec, HostRequirement targetServerType)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Iterator<CandidateHost>
iterator()
Lists connection hosts in preferred order.
-
-
-
Field Detail
-
candidateHost
private final java.util.Collection<CandidateHost> candidateHost
-
-
Constructor Detail
-
SingleHostChooser
SingleHostChooser(HostSpec hostSpec, HostRequirement targetServerType)
-
-
Method Detail
-
iterator
public java.util.Iterator<CandidateHost> iterator()
Description copied from interface:HostChooser
Lists connection hosts in preferred order.- Specified by:
iterator
in interfaceHostChooser
- Specified by:
iterator
in interfacejava.lang.Iterable<CandidateHost>
- Returns:
- connection hosts in preferred order.
-
-