Class SimpleProjectionMetadataRegistry
java.lang.Object
nl.datasteel.crudcraft.projection.mapping.SimpleProjectionMetadataRegistry
- All Implemented Interfaces:
ProjectionMetadataRegistry
Simple in-memory registry for projection metadata. In a real application
the entries would be generated at compile time.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<D> ProjectionMetadata
<D> getMetadata
(Class<D> dtoType) Retrieves the metadata for a given DTO type.<D> void
register
(ProjectionMetadata<D> projectionMetadata) Registers new projection metadata.
-
Constructor Details
-
SimpleProjectionMetadataRegistry
public SimpleProjectionMetadataRegistry()
-
-
Method Details
-
register
Registers new projection metadata.- Parameters:
projectionMetadata
- the metadata to register
-
getMetadata
Retrieves the metadata for a given DTO type.- Specified by:
getMetadata
in interfaceProjectionMetadataRegistry
- Type Parameters:
D
- the type of the DTO- Parameters:
dtoType
- the class type of the DTO- Returns:
- the projection metadata for the specified DTO type, or null if not found
-