public class RouterBuilder extends Object
InputTrustHandler
. Because of this, all handlers of type PLATFORM,
SECURITY_POLICY, BODY and AUTHENTICATION must be mounted as root handlers if required.
OpenAPIRoute
in the same order as they are
added to the route.
OpenAPIRoute
in the same order as they are
added to the route.
original
non RX-ified interface using Vert.x codegen.Modifier and Type | Field and Description |
---|---|
static io.vertx.lang.rx.TypeArg<RouterBuilder> |
__TYPE_ARG |
static String |
KEY_META_DATA_OPERATION |
static String |
KEY_META_DATA_VALIDATED_REQUEST |
Constructor and Description |
---|
RouterBuilder(Object delegate) |
RouterBuilder(RouterBuilder delegate) |
Modifier and Type | Method and Description |
---|---|
static RouterBuilder |
create(Vertx vertx,
OpenAPIContract contract)
Create a new
RouterBuilder . |
static RouterBuilder |
create(Vertx vertx,
OpenAPIContract contract,
RequestExtractor extractor)
Create a new
RouterBuilder . |
Router |
createRouter()
Construct a new router based on the related OpenAPI contract.
|
boolean |
equals(Object o) |
RouterBuilder |
getDelegate() |
OpenAPIRoute |
getRoute(String operationId)
Access to a route defined in the contract with
operationId |
List<OpenAPIRoute> |
getRoutes() |
int |
hashCode() |
static RouterBuilder |
newInstance(RouterBuilder arg) |
RouterBuilder |
rootHandler(Handler<RoutingContext> rootHandler)
Add global handler to be applied prior to being generated.
|
String |
toString() |
public static final io.vertx.lang.rx.TypeArg<RouterBuilder> __TYPE_ARG
public static final String KEY_META_DATA_OPERATION
public static final String KEY_META_DATA_VALIDATED_REQUEST
public RouterBuilder(RouterBuilder delegate)
public RouterBuilder(Object delegate)
public RouterBuilder getDelegate()
public static RouterBuilder create(Vertx vertx, OpenAPIContract contract)
RouterBuilder
. Like create(io.vertx.reactivex.core.Vertx, io.vertx.reactivex.openapi.contract.OpenAPIContract)
but uses a default
implementation for the extractor.vertx
- the related Vert.x instancecontract
- the contract that describes the endpointRouterBuilder
public static RouterBuilder create(Vertx vertx, OpenAPIContract contract, RequestExtractor extractor)
RouterBuilder
.vertx
- the related Vert.x instancecontract
- the contract that describes the endpointextractor
- the extractor is used to extract and transform the parameters and body of the related request in a format that can be validated by the RequestValidator
.RouterBuilder
public OpenAPIRoute getRoute(String operationId)
operationId
operationId
- the id of the operationpublic List<OpenAPIRoute> getRoutes()
public RouterBuilder rootHandler(Handler<RoutingContext> rootHandler)
rootHandler
- the root handler to addpublic Router createRouter()
public static RouterBuilder newInstance(RouterBuilder arg)
Copyright © 2024 Eclipse. All rights reserved.