Package org.apache.camel.support
Class SimpleRegistry
- All Implemented Interfaces:
Closeable,Serializable,AutoCloseable,Cloneable,Map<String,,Map<Class<?>, Object>> org.apache.camel.spi.BeanRepository,org.apache.camel.spi.Registry
- Direct Known Subclasses:
SupplierRegistry
public class SimpleRegistry
extends LinkedHashMap<String,Map<Class<?>,Object>>
implements org.apache.camel.spi.Registry, Closeable
A
Map-based registry.
Favour using DefaultRegistry instead of this.- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K extends Object,V extends Object>, AbstractMap.SimpleImmutableEntry<K extends Object, V extends Object> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidvoidbindAsPrototype(String id, Class<?> type, Supplier<Object> bean) voidclose()<T> Set<T>findByType(Class<T> type) findByTypeWithName(Class<T> type) lookupByName(String name) <T> TlookupByNameAndType(String name, Class<T> type) voidMethods inherited from class java.util.LinkedHashMap
clear, containsValue, entrySet, forEach, get, getOrDefault, keySet, removeEldestEntry, replaceAll, valuesMethods inherited from class java.util.HashMap
clone, compute, computeIfAbsent, computeIfPresent, containsKey, isEmpty, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, sizeMethods inherited from class java.util.AbstractMap
equals, hashCode, toStringMethods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.apache.camel.spi.BeanRepository
findSingleByType, unwrapMethods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, containsKey, equals, hashCode, isEmpty, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, sizeMethods inherited from interface org.apache.camel.spi.Registry
bind, wrap
-
Constructor Details
-
SimpleRegistry
public SimpleRegistry()
-
-
Method Details
-
lookupByName
- Specified by:
lookupByNamein interfaceorg.apache.camel.spi.BeanRepository
-
lookupByNameAndType
- Specified by:
lookupByNameAndTypein interfaceorg.apache.camel.spi.BeanRepository
-
findByTypeWithName
- Specified by:
findByTypeWithNamein interfaceorg.apache.camel.spi.BeanRepository
-
findByType
- Specified by:
findByTypein interfaceorg.apache.camel.spi.BeanRepository
-
bind
- Specified by:
bindin interfaceorg.apache.camel.spi.Registry
-
bind
- Specified by:
bindin interfaceorg.apache.camel.spi.Registry
-
bindAsPrototype
- Specified by:
bindAsPrototypein interfaceorg.apache.camel.spi.Registry
-
unbind
- Specified by:
unbindin interfaceorg.apache.camel.spi.Registry
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Throws:
IOException
-