Uses of Class
com.soklet.Request
Packages that use Request
-
Uses of Request in com.soklet
Methods in com.soklet that return RequestModifier and TypeMethodDescriptionRequest.PathBuilder.build()Request.RawBuilder.build()Request.Copier.finish()Methods in com.soklet that return types with arguments of type RequestModifier and TypeMethodDescriptionLogEvent.getRequest()The request associated with this log event, if available.Methods in com.soklet with parameters of type RequestModifier and TypeMethodDescriptionAuthorizes a non-preflight CORS request.CorsAuthorizer.authorizePreflight(Request request, CorsPreflight corsPreflight, Map<HttpMethod, ResourceMethod> availableResourceMethodsByHttpMethod) Authorizes a CORS preflight request.default voidLifecycleInterceptor.didEstablishServerSentEventConnection(Request request, ResourceMethod resourceMethod) Called immediately after a Server-Sent Event connection of indefinite duration to the client is opened.default voidLifecycleInterceptor.didFinishRequestHandling(Request request, ResourceMethod resourceMethod, MarshaledResponse marshaledResponse, Duration processingDuration, List<Throwable> throwables) Called after a request has fully completed processing and a response has been sent to the client.default voidLifecycleInterceptor.didFinishResponseWriting(Request request, ResourceMethod resourceMethod, MarshaledResponse marshaledResponse, Duration responseWriteDuration, Throwable throwable) Called after the response is sent to the client.default voidLifecycleInterceptor.didFinishServerSentEventWriting(Request request, ResourceMethod resourceMethod, ServerSentEvent serverSentEvent, Duration writeDuration, Throwable throwable) Called after a Server-Sent Event is sent to the client.default voidLifecycleInterceptor.didStartRequestHandling(Request request, ResourceMethod resourceMethod) Called as soon as a request is received and a Resource Method has been resolved to handle it.default voidLifecycleInterceptor.didTerminateServerSentEventConnection(Request request, ResourceMethod resourceMethod, Duration connectionDuration, Throwable throwable) Called immediately after a Server-Sent Event connection to the client is terminated.MultipartParser.extractMultipartFields(Request request) Given a request, detect all HTML form fields withmultipart/form-dataencoding and parse their values.ResponseMarshaler.forContentTooLarge(Request request, ResourceMethod resourceMethod) Prepares a response for a request that triggers an HTTP 413 Content Too Large.ResponseMarshaler.forCorsAllowed(Request request, Cors cors, CorsResponse corsResponse, MarshaledResponse marshaledResponse) Applies "CORS is permitted for this request" data to a response.ResponseMarshaler.forCorsPreflightAllowed(Request request, CorsPreflight corsPreflight, CorsPreflightResponse corsPreflightResponse) Prepares a response for "CORS preflight allowed" scenario when yourCorsAuthorizerapproves a preflight request.ResponseMarshaler.forCorsPreflightRejected(Request request, CorsPreflight corsPreflight) Prepares a response for "CORS preflight rejected" scenario when yourCorsAuthorizerdenies a preflight request.ResponseMarshaler.forHead(Request request, MarshaledResponse getMethodMarshaledResponse) Prepares a response for an HTTPHEADrequest.ResponseMarshaler.forMethodNotAllowed(Request request, Set<HttpMethod> allowedHttpMethods) Prepares a response for a request that triggers an HTTP 405 Method Not Allowed.ResponseMarshaler.forNotFound(Request request) Prepares a response for a request that does not have a matching Resource Method, which triggers an HTTP 404 Not Found.ResponseMarshaler.forOptions(Request request, Set<HttpMethod> allowedHttpMethods) Prepares a response for an HTTPOPTIONSrequest.ResponseMarshaler.forOptionsSplat(Request request) Prepares a response for an HTTPOPTIONS *(colloquially, "OPTIONSSplat") request.ResponseMarshaler.forResourceMethod(Request request, Response response, ResourceMethod resourceMethod) Prepares a response for a request that was matched to a Resource Method and returned normally (i.e., without throwing an exception).ResponseMarshaler.forThrowable(Request request, Throwable throwable, ResourceMethod resourceMethod) Prepares a response for scenarios in which an uncaught exception is encountered.ResponseMarshaler.Builder.ContentTooLargeHandler.handle(Request request, ResourceMethod resourceMethod) Prepares a response for a request that triggers an HTTP 413 Content Too Large.ResponseMarshaler.Builder.CorsAllowedHandler.handle(Request request, Cors cors, CorsResponse corsResponse, MarshaledResponse marshaledResponse) Applies "CORS is permitted for this request" data to a response.ResponseMarshaler.Builder.CorsPreflightAllowedHandler.handle(Request request, CorsPreflight corsPreflight, CorsPreflightResponse corsPreflightResponse) Prepares a response for "CORS preflight allowed" scenario when yourCorsAuthorizerapproves a preflight request.ResponseMarshaler.Builder.CorsPreflightRejectedHandler.handle(Request request, CorsPreflight corsPreflight) Prepares a response for "CORS preflight rejected" scenario when yourCorsAuthorizerdenies a preflight request.ResponseMarshaler.Builder.HeadHandler.handle(Request request, MarshaledResponse getMethodMarshaledResponse) Prepares a response for an HTTPHEADrequest.ResponseMarshaler.Builder.MethodNotAllowedHandler.handle(Request request, Set<HttpMethod> allowedHttpMethods) Prepares a response for a request that triggers an HTTP 405 Method Not Allowed.Prepares a response for a request that triggers an HTTP 404 Not Found.ResponseMarshaler.Builder.OptionsHandler.handle(Request request, Set<HttpMethod> allowedHttpMethods) Prepares a response for an HTTPOPTIONSrequest.Prepares a response for an HTTPOPTIONS *(colloquially, "OPTIONSSplat") request.ResponseMarshaler.Builder.ResourceMethodHandler.handle(Request request, Response response, ResourceMethod resourceMethod) Prepares a response for the scenario in which the request was matched to a Resource Method and executed non-exceptionally.ResponseMarshaler.Builder.ThrowableHandler.handle(Request request, Throwable throwable, ResourceMethod resourceMethod) Prepares a response for scenarios in which an uncaught exception is encountered.voidServer.RequestHandler.handleRequest(Request request, Consumer<RequestResult> requestResultConsumer) Callback to be invoked by aServerimplementation after it has received an HTTP request but prior to writing an HTTP response.voidServerSentEventServer.RequestHandler.handleRequest(Request request, Consumer<RequestResult> requestResultConsumer) Callback to be invoked by aServerSentEventServerimplementation after it has received a Server-Sent Event Source HTTP request but prior to writing initial data to the HTTP response.default voidLifecycleInterceptor.interceptRequest(Request request, ResourceMethod resourceMethod, Function<Request, MarshaledResponse> responseProducer, Consumer<MarshaledResponse> responseWriter) Supports alteration of the request processing flow by enabling programmatic control over its two key phases: acquiring a response and writing the response to the client.RequestBodyMarshaler.marshalRequestBody(Request request, ResourceMethod resourceMethod, Parameter parameter, Type requestBodyType) Given a request, the Resource Method that will handle it, and aRequestBody-annotated parameter + its type, convert the request body bytes into an instance of typerequestBodyType.ResourceMethodParameterProvider.parameterValuesForResourceMethod(Request request, ResourceMethod resourceMethod) For the givenrequestandresourceMethod, vends the list of parameters to use when invoking the underlying Java method located atResourceMethod.getMethod().Simulator.performRequest(Request request) Given a request that would normally be handled by your standardServer, process it and return response data (both logicalResponse, if present, and theMarshaledResponsebytes to be sent over the wire) as well as the matching Resource Method, if available.Simulator.performServerSentEventRequest(Request request) Given a request that would normally be handled by yourServerSentEventServer(that is, for a Resource Method decorated with theServerSentEventSourceannotation), process it and return response data (ServerSentEventRequestResult.HandshakeAccepted,ServerSentEventRequestResult.HandshakeRejected, orServerSentEventRequestResult.RequestFailed);ResourceMethodResolver.resourceMethodForRequest(Request request, ServerType serverType) Given an HTTP request, provide a matching Resource Method to invoke.default voidLifecycleInterceptor.willEstablishServerSentEventConnection(Request request, ResourceMethod resourceMethod) Called immediately before a Server-Sent Event connection of indefinite duration to the client is opened.default voidLifecycleInterceptor.willStartResponseWriting(Request request, ResourceMethod resourceMethod, MarshaledResponse marshaledResponse) Called before the response is sent to the client.default voidLifecycleInterceptor.willStartServerSentEventWriting(Request request, ResourceMethod resourceMethod, ServerSentEvent serverSentEvent) Called before a Server-Sent Event is sent to the client.default voidLifecycleInterceptor.willTerminateServerSentEventConnection(Request request, ResourceMethod resourceMethod, Throwable throwable) Called immediately before a Server-Sent Event connection to the client is terminated.default voidLifecycleInterceptor.wrapRequest(Request request, ResourceMethod resourceMethod, Consumer<Request> requestProcessor) Wraps around the whole "outside" of the entire request-handling flow.Method parameters in com.soklet with type arguments of type RequestModifier and TypeMethodDescriptiondefault voidLifecycleInterceptor.interceptRequest(Request request, ResourceMethod resourceMethod, Function<Request, MarshaledResponse> responseProducer, Consumer<MarshaledResponse> responseWriter) Supports alteration of the request processing flow by enabling programmatic control over its two key phases: acquiring a response and writing the response to the client.default voidLifecycleInterceptor.wrapRequest(Request request, ResourceMethod resourceMethod, Consumer<Request> requestProcessor) Wraps around the whole "outside" of the entire request-handling flow.