A - the type of service addressesS - the type of service stubsP - the type of service proxiespublic abstract class AbstractSingletonBuilder<A,S,P> extends AbstractBuilder<A,S,P> implements SingletonBuilderAPI.Builder<A,P>, SingletonBuilderAPI.SecondClause<P>, SingletonBuilderAPI.FinalClause<P>
defaultTimeout| Modifier | Constructor and Description |
|---|---|
protected |
AbstractSingletonBuilder(ProxyPlugin<A,S,P> plugin,
EndpointCache<A> cache,
Property<?>... properties)
Constructs an instance with a given
ProxyPlugin, and EndpointCache, and zero or more default Propertys. |
| Modifier and Type | Method and Description |
|---|---|
SingletonBuilderAPI.SecondClause<P> |
at(String host,
int port)
Configures the address of a given service instance.
|
SingletonBuilderAPI.SecondClause<P> |
at(URI address)
Configures the address of a given service endpoint.
|
SingletonBuilderAPI.SecondClause<P> |
at(URL address)
Configures the address of a given service endpoint.
|
SingletonBuilderAPI.SecondClause<P> |
matching(Query<A> query)
Configures a query for service instances.
|
SingletonBuilderAPI.SecondClause<P> |
with(Property<?> property)
Set a configuration property for the proxy.
|
<T> SingletonBuilderAPI.SecondClause<P> |
with(String name,
T value)
Set a configuration property for the proxy.
|
SingletonBuilderAPI.FinalClause<P> |
withTimeout(int duration,
TimeUnit unit)
Configures the timeout for the proxy.
|
addProperty, build, contextPath, convertAddress, plugin, setAddress, setQuery, setTimeoutclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitbuildbuildprotected AbstractSingletonBuilder(ProxyPlugin<A,S,P> plugin, EndpointCache<A> cache, Property<?>... properties)
ProxyPlugin, and EndpointCache, and zero or more default Propertys.plugin - the pluginplugin - the cacheproperties - the propertiespublic SingletonBuilderAPI.SecondClause<P> matching(Query<A> query)
SingletonBuilderAPI.Buildermatching in interface SingletonBuilderAPI.Builder<A,P>query - the querypublic SingletonBuilderAPI.SecondClause<P> at(String host, int port)
SingletonBuilderAPI.Builderat in interface SingletonBuilderAPI.Builder<A,P>public SingletonBuilderAPI.SecondClause<P> at(URL address)
SingletonBuilderAPI.Builderat in interface SingletonBuilderAPI.Builder<A,P>address - the address of the endpointpublic SingletonBuilderAPI.SecondClause<P> at(URI address)
SingletonBuilderAPI.Builderat in interface SingletonBuilderAPI.Builder<A,P>address - the address of the endpointpublic SingletonBuilderAPI.FinalClause<P> withTimeout(int duration, TimeUnit unit)
SingletonBuilderAPI.SecondClausewithTimeout in interface SingletonBuilderAPI.SecondClause<P>duration - the duration of the timeoutunit - the time unit of the timeoutpublic SingletonBuilderAPI.SecondClause<P> with(Property<?> property)
SingletonBuilderAPI.SecondClausewith in interface SingletonBuilderAPI.SecondClause<P>public <T> SingletonBuilderAPI.SecondClause<P> with(String name, T value)
SingletonBuilderAPI.SecondClausewith in interface SingletonBuilderAPI.SecondClause<P>T - the type of the property valuename - the name of the propertyvalue - the value of the propertyCopyright © 2017. All Rights Reserved.