All Downloads are FREE. Search and download functionalities are using the official Maven repository.

restx.endpoint.mappers.legacy.LegacyEndpointParameterMapperFactory Maven / Gradle / Ivy

There is a newer version: 1.2.0-rc2
Show newest version
package restx.endpoint.mappers.legacy;

import com.google.common.base.Optional;
import restx.endpoint.EndpointParamDef;
import restx.endpoint.mappers.EndpointParameterMapper;
import restx.endpoint.mappers.EndpointParameterMapperFactory;
import restx.factory.Component;

/**
 * @author fcamblor
 */
@Component(priority = 1000)
public class LegacyEndpointParameterMapperFactory implements EndpointParameterMapperFactory {

    private final LegacyEndpointParameterMapper legacyEndpointParameterMapper;

    public LegacyEndpointParameterMapperFactory(LegacyEndpointParameterMapper legacyEndpointParameterMapper) {
        this.legacyEndpointParameterMapper = legacyEndpointParameterMapper;
    }

    @Override
    public Optional getEndpointParameterMapperFor(EndpointParamDef endpointParamDef) {
        return Optional.of(legacyEndpointParameterMapper);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy