Class ComponentModelDelegateRegistryImpl
- java.lang.Object
-
- com.inductiveautomation.perspective.gateway.model.ComponentModelDelegateRegistryImpl
-
- All Implemented Interfaces:
ComponentModelDelegateRegistry
public class ComponentModelDelegateRegistryImpl extends java.lang.Object implements ComponentModelDelegateRegistry
BasicComponentModelDelegateRegistry
implementation, backed by concurrent collection types for safety.
-
-
Constructor Summary
Constructors Constructor Description ComponentModelDelegateRegistryImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Optional<ComponentModelDelegateFactory>
find(java.lang.String typeId)
Fetch theComponentModelDelegateFactory
registered with the given typeIdvoid
register(java.lang.String type, ComponentModelDelegateFactory factory)
Register aComponentModelDelegateFactory
with its type IDvoid
remove(java.lang.String componentTypeId)
Removes the delegate registered with the id from the set of those registered.
-
-
-
Method Detail
-
register
public void register(java.lang.String type, ComponentModelDelegateFactory factory)
Description copied from interface:ComponentModelDelegateRegistry
Register aComponentModelDelegateFactory
with its type ID- Specified by:
register
in interfaceComponentModelDelegateRegistry
- Parameters:
type
- The component type ID associated with the factoryfactory
- The factory to register
-
find
public java.util.Optional<ComponentModelDelegateFactory> find(@Nonnull java.lang.String typeId)
Description copied from interface:ComponentModelDelegateRegistry
Fetch theComponentModelDelegateFactory
registered with the given typeId- Specified by:
find
in interfaceComponentModelDelegateRegistry
- Parameters:
typeId
- The component type ID- Returns:
- An
Optional
containing theComponentModelDelegateFactory
registered with the given typeId or an empty Optional if no such factory is registered with the given type ID
-
remove
public void remove(@Nonnull java.lang.String componentTypeId)
Description copied from interface:ComponentModelDelegateRegistry
Removes the delegate registered with the id from the set of those registered.- Specified by:
remove
in interfaceComponentModelDelegateRegistry
- Parameters:
componentTypeId
- the id of the component type whose delegate should be removed from the registry.
-
-