Package com.aquima.web.rest.v1.converter
Class MetadataConverter
java.lang.Object
com.aquima.web.rest.v1.converter.MetadataConverter
- All Implemented Interfaces:
IResourceConverter<com.aquima.interactions.portal.ds.ProjectMetadata,
Metadata>
public class MetadataConverter
extends Object
implements IResourceConverter<com.aquima.interactions.portal.ds.ProjectMetadata,Metadata>
Converts project metadata to metadata REST resources.
- Since:
- 9.6
- Author:
- m.van.tilburg
-
Constructor Summary
ConstructorsConstructorDescriptionMetadataConverter
(com.aquima.interactions.foundation.connectivity.IConnectionManager connectionManager, IResourceFactory factory, IResourceLinker<Metadata> linker) MetadataConverter
(com.aquima.interactions.foundation.connectivity.IConnectionManager connectionManager, IResourceFactory resourceFactory, IResourceLinker<Metadata> metadataLinker, IResourceLinker<Webservice> webserviceLinker) -
Method Summary
Modifier and TypeMethodDescriptionvoid
Converts a source domain model to a destination REST resource.Converts multiple source domain models into destination REST resources.
-
Constructor Details
-
MetadataConverter
public MetadataConverter(com.aquima.interactions.foundation.connectivity.IConnectionManager connectionManager, IResourceFactory factory, IResourceLinker<Metadata> linker) - Parameters:
connectionManager
- the connection manager containing the configured endpointsfactory
- the factory used to create metadata (sub)resourceslinker
- a linker capable of adding HATEOAS links to metadata resources
-
MetadataConverter
public MetadataConverter(com.aquima.interactions.foundation.connectivity.IConnectionManager connectionManager, IResourceFactory resourceFactory, IResourceLinker<Metadata> metadataLinker, IResourceLinker<Webservice> webserviceLinker) - Parameters:
connectionManager
- the connection manager containing the configured endpointsresourceFactory
- the factory used to create metadata (sub)resourcesmetadataLinker
- a linker capable of adding HATEOAS links to metadata resourceswebserviceLinker
- a linker capable of adding HATEOAS links to webservice resources
-
-
Method Details
-
convert
Description copied from interface:IResourceConverter
Converts a source domain model to a destination REST resource. Also adds HATEOAS links.- Specified by:
convert
in interfaceIResourceConverter<com.aquima.interactions.portal.ds.ProjectMetadata,
Metadata> - Parameters:
source
- the source domain modelresult
- the destination REST resource
-
convert
Description copied from interface:IResourceConverter
Converts multiple source domain models into destination REST resources. Also adds HATEOAS links to all converted resources.- Specified by:
convert
in interfaceIResourceConverter<com.aquima.interactions.portal.ds.ProjectMetadata,
Metadata> - Parameters:
source
- a list of domain models, must not be null- Returns:
- list of converted REST resources, never null
-