public class ConsulRegistry extends Object implements org.apache.camel.spi.Registry
| Modifier and Type | Class and Description |
|---|---|
static class |
ConsulRegistry.Builder |
| Constructor and Description |
|---|
ConsulRegistry(String hostname) |
ConsulRegistry(String hostname,
int port) |
| Modifier and Type | Method and Description |
|---|---|
void |
bind(String id,
Class<?> type,
Supplier<Object> bean) |
void |
bind(String id,
Class type,
Object bean) |
void |
bindAsPrototype(String id,
Class<?> type,
Supplier<Object> bean) |
<T> Set<T> |
findByType(Class<T> type) |
<T> Map<String,T> |
findByTypeWithName(Class<T> type) |
String |
getHostname() |
int |
getPort() |
Object |
lookupByName(String key) |
<T> T |
lookupByNameAndType(String name,
Class<T> type) |
void |
put(String key,
Object object) |
void |
remove(String key) |
void |
setHostname(String hostname) |
void |
setPort(int port) |
public ConsulRegistry(String hostname)
public ConsulRegistry(String hostname, int port)
public Object lookupByName(String key)
lookupByName in interface org.apache.camel.spi.BeanRepositorypublic <T> T lookupByNameAndType(String name, Class<T> type)
lookupByNameAndType in interface org.apache.camel.spi.BeanRepositorypublic <T> Map<String,T> findByTypeWithName(Class<T> type)
findByTypeWithName in interface org.apache.camel.spi.BeanRepositorypublic <T> Set<T> findByType(Class<T> type)
findByType in interface org.apache.camel.spi.BeanRepositorypublic void bind(String id, Class type, Object bean) throws org.apache.camel.RuntimeCamelException
bind in interface org.apache.camel.spi.Registryorg.apache.camel.RuntimeCamelExceptionpublic void bind(String id, Class<?> type, Supplier<Object> bean) throws org.apache.camel.RuntimeCamelException
bind in interface org.apache.camel.spi.Registryorg.apache.camel.RuntimeCamelExceptionpublic void bindAsPrototype(String id, Class<?> type, Supplier<Object> bean) throws org.apache.camel.RuntimeCamelException
bindAsPrototype in interface org.apache.camel.spi.Registryorg.apache.camel.RuntimeCamelExceptionpublic void remove(String key)
public String getHostname()
public void setHostname(String hostname)
public int getPort()
public void setPort(int port)
Apache Camel