Package com.aquima.web.rest.v1.converter
Interface IResourceConverter<S,D>
- Type Parameters:
S
- the source domain model typeD
- the destination REST resource type
- All Known Implementing Classes:
CaseConverter
,CaseEventConverter
,MetadataConverter
,ProjectConverter
,TaskConverter
public interface IResourceConverter<S,D>
Converts domain models to REST resources.
- Since:
- 9.6
- Author:
- Petru Galanton
-
Method Details
-
convert
Converts a source domain model to a destination REST resource. Also adds HATEOAS links.- Parameters:
source
- the source domain modelresult
- the destination REST resource
-
convert
Converts multiple source domain models into destination REST resources. Also adds HATEOAS links to all converted resources.- Parameters:
source
- a list of domain models, must not be null- Returns:
- list of converted REST resources, never null
-