Class Mapping
java.lang.Object
services.moleculer.web.router.Mapping
- All Implemented Interfaces:
HttpConstants, RequestProcessor
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final Stringprotected final CallProcessorprotected final CallProcessorprotected final io.datatree.Treeprotected final intprotected final Stringprotected final Set<HttpMiddleware> protected final booleanprotected RequestProcessorprotected final Stringprotected final Stringprotected final Patternprotected final RouteFields inherited from interface HttpConstants
ACCEPT, ACCEPT_ENCODING, AUTHORIZATION, CACHE_CONTROL, CHUNKED, CLOSE, CONNECT, CONNECTION, CONTENT_ENCODING, CONTENT_LENGTH, CONTENT_TYPE, CONTENT_TYPE_HTML, CONTENT_TYPE_JSON, COOKIE, DEFLATE, DELETE, ETAG, GET, GZIP, HEAD, IF_NONE_MATCH, KEEP_ALIVE, LOCATION, META_CONTENT_TYPE, META_HEADERS, META_LOCALE, META_LOCATION, META_SESSION, META_STATUS, META_TEMPLATE, NO_CACHE, OPTIONS, PATCH, POST, PROPERTY_COOKIES, PROPERTY_SESSION_ID, PROPERTY_USER, PUT, SET_COOKIE, TRACE, TRANSFER_ENCODING, WWW_AUTHENTICATE, X_FORWARDED_FOR -
Constructor Summary
ConstructorsConstructorDescriptionMapping(services.moleculer.ServiceBroker broker, String httpMethod, String pathPattern, String actionName, services.moleculer.context.CallOptions.Options opts, AbstractTemplateEngine templateEngine, Route route, CallProcessor beforeCall, CallProcessor afterCall, ExecutorService executor) -
Method Summary
Modifier and TypeMethodDescriptionbooleanprotected io.datatree.TreegetActionConfig(RequestProcessor parent) Returns the next RequestProcessor in the invocation chain.inthashCode()booleanisStatic()booleanvoidservice(WebRequest req, WebResponse rsp) Handles request of the HTTP client.voiduse(Collection<HttpMiddleware> middlewares)
-
Field Details
-
httpMethod
-
actionName
-
config
protected final io.datatree.Tree config -
route
-
beforeCall
-
afterCall
-
lastProcessor
-
isStatic
protected final boolean isStatic -
pathPrefix
-
pathPattern
-
hashCode
protected final int hashCode -
pattern
-
cache
-
installedMiddlewares
-
-
Constructor Details
-
Mapping
public Mapping(services.moleculer.ServiceBroker broker, String httpMethod, String pathPattern, String actionName, services.moleculer.context.CallOptions.Options opts, AbstractTemplateEngine templateEngine, Route route, CallProcessor beforeCall, CallProcessor afterCall, ExecutorService executor)
-
-
Method Details
-
matches
-
use
-
getActionConfig
-
service
Handles request of the HTTP client.- Specified by:
servicein interfaceRequestProcessor- Parameters:
req- WebRequest object that contains the request the client made of the ApiGatewayrsp- WebResponse object that contains the response the ApiGateway returns to the client- Throws:
Exception- if an input or output error occurs while the ApiGateway is handling the HTTP request
-
getParent
Description copied from interface:RequestProcessorReturns the next RequestProcessor in the invocation chain.- Specified by:
getParentin interfaceRequestProcessor- Returns:
- parent processor
-
isStatic
public boolean isStatic() -
getPathPrefix
-
getHttpMethod
-
getPathPattern
-
hashCode
-
equals
-