Package co.elastic.clients
Class ApiClient<T extends Transport,Self extends ApiClient<T,Self>>
java.lang.Object
co.elastic.clients.ApiClient<T,Self>
- All Implemented Interfaces:
Closeable,AutoCloseable
- Direct Known Subclasses:
ElasticsearchAsyncClient,ElasticsearchAsyncSearchAsyncClient,ElasticsearchAsyncSearchClient,ElasticsearchAutoscalingAsyncClient,ElasticsearchAutoscalingClient,ElasticsearchCatAsyncClient,ElasticsearchCatClient,ElasticsearchCcrAsyncClient,ElasticsearchCcrClient,ElasticsearchClient,ElasticsearchClusterAsyncClient,ElasticsearchClusterClient,ElasticsearchConnectorAsyncClient,ElasticsearchConnectorClient,ElasticsearchDanglingIndicesAsyncClient,ElasticsearchDanglingIndicesClient,ElasticsearchEnrichAsyncClient,ElasticsearchEnrichClient,ElasticsearchEqlAsyncClient,ElasticsearchEqlClient,ElasticsearchEsqlAsyncClient,ElasticsearchEsqlClient,ElasticsearchFeaturesAsyncClient,ElasticsearchFeaturesClient,ElasticsearchFleetAsyncClient,ElasticsearchFleetClient,ElasticsearchGraphAsyncClient,ElasticsearchGraphClient,ElasticsearchIlmAsyncClient,ElasticsearchIlmClient,ElasticsearchIndicesAsyncClient,ElasticsearchIndicesClient,ElasticsearchInferenceAsyncClient,ElasticsearchInferenceClient,ElasticsearchIngestAsyncClient,ElasticsearchIngestClient,ElasticsearchLicenseAsyncClient,ElasticsearchLicenseClient,ElasticsearchLogstashAsyncClient,ElasticsearchLogstashClient,ElasticsearchMigrationAsyncClient,ElasticsearchMigrationClient,ElasticsearchMlAsyncClient,ElasticsearchMlClient,ElasticsearchMonitoringAsyncClient,ElasticsearchMonitoringClient,ElasticsearchNodesAsyncClient,ElasticsearchNodesClient,ElasticsearchProjectAsyncClient,ElasticsearchProjectClient,ElasticsearchQueryRulesAsyncClient,ElasticsearchQueryRulesClient,ElasticsearchRollupAsyncClient,ElasticsearchRollupClient,ElasticsearchSearchableSnapshotsAsyncClient,ElasticsearchSearchableSnapshotsClient,ElasticsearchSearchApplicationAsyncClient,ElasticsearchSearchApplicationClient,ElasticsearchSecurityAsyncClient,ElasticsearchSecurityClient,ElasticsearchShutdownAsyncClient,ElasticsearchShutdownClient,ElasticsearchSimulateAsyncClient,ElasticsearchSimulateClient,ElasticsearchSlmAsyncClient,ElasticsearchSlmClient,ElasticsearchSnapshotAsyncClient,ElasticsearchSnapshotClient,ElasticsearchSqlAsyncClient,ElasticsearchSqlClient,ElasticsearchSslAsyncClient,ElasticsearchSslClient,ElasticsearchStreamsAsyncClient,ElasticsearchStreamsClient,ElasticsearchSynonymsAsyncClient,ElasticsearchSynonymsClient,ElasticsearchTasksAsyncClient,ElasticsearchTasksClient,ElasticsearchTextStructureAsyncClient,ElasticsearchTextStructureClient,ElasticsearchTransformAsyncClient,ElasticsearchTransformClient,ElasticsearchWatcherAsyncClient,ElasticsearchWatcherClient,ElasticsearchXpackAsyncClient,ElasticsearchXpackClient
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedApiClient(T transport, TransportOptions transportOptions) -
Method Summary
Modifier and TypeMethodDescriptionGet the JSON mapper used to map API objects to/from JSON.Get the transport used by this client to handle communication with the server.Get the transport options used for this client.voidclose()Close this client and associated resources, including the underlyingTransportobject.protected <V> JsonpDeserializer<V>getDeserializer(Type type) abstract SelfwithTransportOptions(TransportOptions transportOptions) Creates a new client with some request optionsCreates a new client with additional request options
-
Field Details
-
transport
-
transportOptions
-
-
Constructor Details
-
ApiClient
-
-
Method Details
-
getDeserializer
-
withTransportOptions
Creates a new client with some request options -
withTransportOptions
Creates a new client with additional request options- Parameters:
fn- a lambda expression that takes the current options as input
-
_transport
Get the transport used by this client to handle communication with the server. -
_transportOptions
Get the transport options used for this client. If the client has no custom options, falls back to the transport's options. -
_jsonpMapper
Get the JSON mapper used to map API objects to/from JSON.Shortcut for
_transport().jsonpMapper() -
close
Close this client and associated resources, including the underlyingTransportobject.If the underlying
Transportobject is shared with other API client objects, these objects will also become unavailable.- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Throws:
IOException
-