Package io.micronaut.http.client
Interface RawHttpClientFactory
- All Known Implementing Classes:
JdkHttpClientFactory
,NettyHttpClientFactory
public interface RawHttpClientFactory
Factory for creating
RawHttpClient
s without an application context.- Since:
- 4.7.0
- Author:
- Jonas Konrad
-
Method Summary
Modifier and TypeMethodDescriptiondefault @NonNull RawHttpClient
createRawClient
(@Nullable URI url) Create a newRawHttpClient
.createRawClient
(@Nullable URI url, @NonNull HttpClientConfiguration configuration) Create a newRawHttpClient
with the specified configuration.
-
Method Details
-
createRawClient
Create a newRawHttpClient
. Note that this method should only be used outside the context of an application. Within Micronaut useInject
to inject a client instead- Parameters:
url
- The base URL- Returns:
- The client
-
createRawClient
@NonNull @NonNull RawHttpClient createRawClient(@Nullable @Nullable URI url, @NonNull @NonNull HttpClientConfiguration configuration) Create a newRawHttpClient
with the specified configuration. Note that this method should only be used outside the context of an application. Within Micronaut useInject
to inject a client instead- Parameters:
url
- The base URLconfiguration
- the client configuration- Returns:
- The client
-