Package io.vertigo.core.node.definition
Interface DefinitionSpace
- All Known Implementing Classes:
DefinitionSpaceWritable
public interface DefinitionSpace
DefinitionSpace represents a space for managing and resolving definitions.
It is not thread-safe.
Definitions within this space can be checked, resolved, and retrieved based on their names and types.
- Author:
- mlaroche
-
Method Summary
Modifier and TypeMethodDescriptionbooleanChecks if this container contains a definition with the specified name.<C extends Definition>
Set<C> Gets an ordered set of all objects for a specified definition type.Set<Class<? extends Definition>> Gets a list of all types of definitions managed within this space.<D extends Definition>
DResolves a definition from its name and class type.
-
Method Details
-
contains
Checks if this container contains a definition with the specified name.- Parameters:
name- the name of the definition to check- Returns:
- true if the definition is already registered, false otherwise
-
resolve
Resolves a definition from its name and class type.- Type Parameters:
D- Type of the definition- Parameters:
name- the name of the definition to resolveclazz- the class type of the definition- Returns:
- the resolved definition
-
getAllTypes
Set<Class<? extends Definition>> getAllTypes()Gets a list of all types of definitions managed within this space.- Returns:
- a set of classes representing the types of definitions
-
getAll
Gets an ordered set of all objects for a specified definition type.- Type Parameters:
C- Type of the definition- Parameters:
clazz- the class type of the definition- Returns:
- an ordered set of all objects for the specified definition type
-