Package org.restheart.mongodb
Class MongoService
java.lang.Object
org.restheart.mongodb.MongoService
- All Implemented Interfaces:
CORSHeaders,ConfigurablePlugin,ExchangeTypeResolver<MongoRequest,,MongoResponse> HandlingPlugin<MongoRequest,,MongoResponse> Plugin,Service<MongoRequest,MongoResponse>
The Service that handles requests to mongodb resources
- Author:
- Andrea Di Cesare <andrea@softinstigate.com>
-
Field Summary
Fields inherited from interface org.restheart.exchange.CORSHeaders
ACCESS_CONTROL_ALLOW_CREDENTIAL, ACCESS_CONTROL_ALLOW_HEADERS, ACCESS_CONTROL_ALLOW_METHODS, ACCESS_CONTROL_ALLOW_ORIGIN, ACCESS_CONTROL_EXPOSE_HEADERS, DEFAULT_ACCESS_CONTROL_ALLOW_CREDENTIALS, DEFAULT_ACCESS_CONTROL_ALLOW_HEADERS, DEFAULT_ACCESS_CONTROL_ALLOW_METHODS, DEFAULT_ACCESS_CONTROL_ALLOW_ORIGIN, DEFAULT_ACCESS_CONTROL_EXPOSE_HEADERS -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidhandle(MongoRequest request, MongoResponse response) voidinit()Function<io.undertow.server.HttpServerExchange,MongoRequest> request()Consumer<io.undertow.server.HttpServerExchange>Return the MongoRequest initializerFunction<io.undertow.server.HttpServerExchange,MongoResponse> response()Consumer<io.undertow.server.HttpServerExchange>Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.restheart.plugins.ConfigurablePlugin
arg, argOrDefaultMethods inherited from interface org.restheart.exchange.CORSHeaders
accessControlAllowCredentials, accessControlAllowHeaders, accessControlAllowMethods, accessControlAllowOrigin, accessControlExposeHeadersMethods inherited from interface org.restheart.plugins.ExchangeTypeResolver
requestType, responseTypeMethods inherited from interface org.restheart.plugins.Service
handle, handleOptions, handleOptions
-
Constructor Details
-
MongoService
public MongoService()
-
-
Method Details
-
init
public void init() -
handle
- Specified by:
handlein interfaceService<MongoRequest,MongoResponse> - Throws:
Exception
-
requestInitializer
Return the MongoRequest initializer- Specified by:
requestInitializerin interfaceService<MongoRequest,MongoResponse> - Returns:
-
responseInitializer
- Specified by:
responseInitializerin interfaceService<MongoRequest,MongoResponse>
-
request
- Specified by:
requestin interfaceService<MongoRequest,MongoResponse>
-
response
- Specified by:
responsein interfaceService<MongoRequest,MongoResponse>
-