Class SimpleEndpoint<RequestT,ResponseT>
java.lang.Object
co.elastic.clients.transport.endpoints.EndpointBase<RequestT,ResponseT>
co.elastic.clients.transport.endpoints.SimpleEndpoint<RequestT,ResponseT>
- All Implemented Interfaces:
Endpoint<RequestT,,ResponseT, ErrorResponse> JsonEndpoint<RequestT,ResponseT, ErrorResponse>
- Direct Known Subclasses:
SimpleJsonEndpoint
public class SimpleEndpoint<RequestT,ResponseT>
extends EndpointBase<RequestT,ResponseT>
implements JsonEndpoint<RequestT,ResponseT,ErrorResponse>
-
Field Summary
Fields inherited from class co.elastic.clients.transport.endpoints.EndpointBase
hasRequestBody, headers, id, method, queryParameters, requestUrl -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionemptyMap()Returns a function that always returns an empty String to String map.errorDeserializer(int statusCode) The entity parser for the error response body.static RuntimeExceptionnoPathTemplateFound(String what) static voidpathEncode(String src, StringBuilder dest) The entity parser for the response body.<NewResponseT>
SimpleEndpoint<RequestT,NewResponseT> withResponseDeserializer(JsonpDeserializer<NewResponseT> newResponseParser) Methods inherited from class co.elastic.clients.transport.endpoints.EndpointBase
hasRequestBody, headers, id, isError, method, queryParameters, requestUrlMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface co.elastic.clients.transport.Endpoint
hasRequestBody, headers, id, isError, method, queryParameters, requestUrl
-
Constructor Details
-
SimpleEndpoint
-
-
Method Details
-
emptyMap
Returns a function that always returns an empty String to String map. Useful to avoid creating lots of duplicate lambdas in endpoints that don't have headers or parameters. -
responseDeserializer
Description copied from interface:JsonEndpointThe entity parser for the response body.- Specified by:
responseDeserializerin interfaceJsonEndpoint<RequestT,ResponseT, ErrorResponse>
-
errorDeserializer
Description copied from interface:EndpointThe entity parser for the error response body. Can benullto indicate that there's no error body.- Specified by:
errorDeserializerin interfaceEndpoint<RequestT,ResponseT, ErrorResponse> - Overrides:
errorDeserializerin classEndpointBase<RequestT,ResponseT>
-
withResponseDeserializer
public <NewResponseT> SimpleEndpoint<RequestT,NewResponseT> withResponseDeserializer(JsonpDeserializer<NewResponseT> newResponseParser) - Overrides:
withResponseDeserializerin classEndpointBase<RequestT,ResponseT>
-
noPathTemplateFound
-
pathEncode
-