org.eclipse.edc.http.spi.FallbackFactory Maven / Gradle / Ivy
/*
* Copyright (c) 2022 Bayerische Motoren Werke Aktiengesellschaft (BMW AG)
*
* This program and the accompanying materials are made available under the
* terms of the Apache License, Version 2.0 which is available at
* https://www.apache.org/licenses/LICENSE-2.0
*
* SPDX-License-Identifier: Apache-2.0
*
* Contributors:
* Bayerische Motoren Werke Aktiengesellschaft (BMW AG) - initial API and implementation
*
*/
package org.eclipse.edc.http.spi;
import dev.failsafe.Fallback;
import okhttp3.Request;
import okhttp3.Response;
/**
* Factory for {@link Fallback} instances given a {@link Request}
*/
public interface FallbackFactory {
/**
* Create a {@link Fallback} from a {@link Request}
*
* @param request the {@link Request}
* @return a {@link Fallback} instance
*/
Fallback create(Request request);
}