class ResponseStatusMapper extends AbstractParameterMapper<ResponseStatus> implements CustomConverter {

    @SuppressWarnings("unchecked")
    @Override
    public Object convert(Object destination, Object source, Class<?> destinationClass, Class<?> sourceClass) {
        if (source == null) {
            return null;
        }

        if (source instanceof Map<?, ?>) {

            ResponseStatus responseStatus = destination != null ? (ResponseStatus) destination : new ResponseStatus();
            return fromParameters((Map<String, Object>) source, responseStatus);
        }

        if (source instanceof ResponseStatus) {
            ResponseStatus responseStatus = (ResponseStatus) source;
            Map<String, Object> map = destination != null ? (Map<String, Object>) destination : new HashMap<>();
            return toParameters(responseStatus, map);
        }

        throw new IllegalArgumentException(buildIllegalArgumentExceptionMessage(source, destination));
    }

    public  ResponseStatusMapper();

}