- 使用 Spring Initializr 创建 Spring Boot 应用程序
- 在Spring Boot中配置Cassandra
- 在 Spring Boot 上配置 Tomcat 连接池
- 将Camel消息路由到嵌入WildFly的Artemis上
本文整理了Java中com.jetdrone.vertx.yoke.middleware.YokeRequest.params()
方法的一些代码示例,展示了YokeRequest.params()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。YokeRequest.params()
方法的具体详情如下:
包路径:com.jetdrone.vertx.yoke.middleware.YokeRequest
类名称:YokeRequest
方法名:params
暂无
代码示例来源:origin: pmlopes/yoke
/** Allow getting parameters in a generified way.
*
* @param name The key to get
* @return {List} The found object
*/
public List<String> getParameterList(@NotNull final String name) {
return params().getAll(name);
}
代码示例来源:origin: pmlopes/yoke
@Override
public void handle(@NotNull final YokeRequest request, @NotNull final Handler<Object> next) {
if (!regex.matcher(request.params().get(paramName)).matches()) {
// Bad Request
next.handle(400);
return;
}
next.handle(null);
}
});
代码示例来源:origin: pmlopes/yoke
@Override
public Map<String, String[]> getRequestParameters() {
final Map<String, String[]> map = new HashMap<>();
if (request.params().get("pac4jFormAttributes") != null) {
for (String name : request.formAttributes().names()) {
map.put(name, request.formAttributes().getAll(name).toArray(new String[0]));
}
}
for (String name : request.params().names()) {
map.put(name, request.params().getAll(name).toArray(new String[0]));
}
return map;
}
代码示例来源:origin: pmlopes/yoke
@Override
public String getRequestParameter(String name) {
String param = request.params().get(name);
if (param == null & request.params().get("pac4jFormAttributes") != null) {
param = request.formAttributes().get(name);
if (param != null) {
// FIX for Vert.x
param = param.replaceAll("\\s", "+");
}
}
return param;
}
代码示例来源:origin: pmlopes/yoke
@Override
public void handle(@NotNull final YokeRequest request, @NotNull final Handler<Object> next) {
// get the real id from the params multimap
final String id = request.params().get(idName);
store.delete(idName, id, new AsyncResultHandler<Number>() {
@Override
public void handle(AsyncResult<Number> event) {
if (event.failed()) {
next.handle(event.cause());
return;
}
if (event.result().intValue() == 0) {
next.handle(404);
} else {
request.response().setStatusCode(204);
request.response().end();
}
}
});
}
};
代码示例来源:origin: pmlopes/yoke
@Override
public void handle(@NotNull final YokeRequest request, @NotNull final Handler<Object> next) {
JsonObject item = request.body();
if (item == null) {
next.handle("Body must be JSON");
return;
}
// get the real id from the params multimap
String id = request.params().get(idName);
store.update(idName, id, item, new AsyncResultHandler<Number>() {
@Override
public void handle(AsyncResult<Number> event) {
if (event.failed()) {
next.handle(event.cause());
return;
}
if (event.result().intValue() == 0) {
// nothing was updated
next.handle(404);
} else {
request.response().setStatusCode(204);
request.response().end();
}
}
});
}
};
代码示例来源:origin: pmlopes/yoke
@Override
public void handle(@NotNull final YokeRequest request, @NotNull final Handler<Object> next) {
// content negotiation
if (request.accepts("application/json") == null) {
// Not Acceptable (we only talk json)
next.handle(406);
return;
}
// get the real id from the params multimap
String id = request.params().get(idName);
store.read(idName, id, new AsyncResultHandler<JsonObject>() {
@Override
public void handle(AsyncResult<JsonObject> event) {
if (event.failed()) {
next.handle(event.cause());
return;
}
if (event.result() == null) {
// does not exist, returns 404
next.handle(404);
} else {
request.response().end(event.result());
}
}
});
}
};
代码示例来源:origin: pmlopes/yoke
final String id = request.params().get(key);
代码示例来源:origin: pmlopes/yoke
for (Map.Entry<String, String> entry : request.params()) {
String[] sortArgs;
代码示例来源:origin: pmlopes/yoke
@Override
public void handle(@NotNull final YokeRequest request, @NotNull final Handler<Object> next) {
final String id = request.params().get(idName);
代码示例来源:origin: pmlopes/yoke
for (Map.Entry<String, String> entry : request.params()) {
String[] sortArgs;
代码示例来源:origin: pmlopes/yoke
String id = request.params().get(key);
代码示例来源:origin: pmlopes/yoke
final String id = request.params().get(key);
代码示例来源:origin: pmlopes/yoke
final String id = request.params().get(key);
代码示例来源:origin: pmlopes/yoke
final MultiMap params = request.params();
代码示例来源:origin: pmlopes/yoke
@Override
public String handle(YokeRequest request) {
String token = request.formAttributes().get(key);
if (token == null) {
token = request.params().get(key);
if (token == null) {
token = request.headers().get("x-csrf-token");
}
}
return token;
}
};
代码示例来源:origin: pmlopes/yoke
public HtmlFileTransport(Vertx vertx, Router router, LocalMap<String, SockJSSession> sessions, SockJSHandlerOptions options,
Handler<SockJSSocket> sockHandler) {
super(vertx, sessions, options);
String htmlFileRE = COMMON_PATH_ELEMENT_RE + "htmlfile.*";
router.get(Pattern.compile(htmlFileRE), (request, next) -> {
if (log.isTraceEnabled()) log.trace("HtmlFile, get: " + request.uri());
String callback = request.getParam("callback");
if (callback == null) {
callback = request.getParam("c");
if (callback == null) {
request.response().setStatusCode(500).end("\"callback\" parameter required\n");
return;
}
}
String sessionID = request.params().get("param0");
SockJSSession session = getSession(request, options.getSessionTimeout(), options.getHeartbeatInterval(), sessionID, sockHandler);
session.setInfo(request.localAddress(), request.remoteAddress(), request.uri(), request.headers());
session.register(new HtmlFileListener(options.getMaxBytesStreaming(), request, callback, session));
});
}
代码示例来源:origin: pmlopes/yoke
String sessionID = request.params().get("param0");
SockJSSession session = getSession(request, options.getSessionTimeout(), options.getHeartbeatInterval(), sessionID, sockHandler);
session.setInfo(request.localAddress(), request.remoteAddress(), request.uri(), request.headers());
本文整理了Java中com.jetdrone.vertx.yoke.Yoke类的一些代码示例,展示了Yoke类的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平
本文整理了Java中com.jetdrone.vertx.yoke.YokeSecurity类的一些代码示例,展示了YokeSecurity类的具体用法。这些代码示例主要来源于Github/Stack
本文整理了Java中com.jetdrone.vertx.yoke.middleware.YokeResponse类的一些代码示例,展示了YokeResponse类的具体用法。这些代码示例主要来源于G
本文整理了Java中com.jetdrone.vertx.yoke.middleware.YokeRequest类的一些代码示例,展示了YokeRequest类的具体用法。这些代码示例主要来源于Git
本文整理了Java中com.jetdrone.vertx.yoke.core.YokeAsyncResult类的一些代码示例,展示了YokeAsyncResult类的具体用法。这些代码示例主要来源于G
本文整理了Java中com.jetdrone.vertx.yoke.Yoke.security()方法的一些代码示例,展示了Yoke.security()的具体用法。这些代码示例主要来源于Github
本文整理了Java中com.jetdrone.vertx.yoke.Yoke.()方法的一些代码示例,展示了Yoke.()的具体用法。这些代码示例主要来源于Github/Stackoverflow/M
本文整理了Java中com.jetdrone.vertx.yoke.Yoke.vertx()方法的一些代码示例,展示了Yoke.vertx()的具体用法。这些代码示例主要来源于Github/Stack
本文整理了Java中com.jetdrone.vertx.yoke.Yoke.use()方法的一些代码示例,展示了Yoke.use()的具体用法。这些代码示例主要来源于Github/Stackover
本文整理了Java中com.jetdrone.vertx.yoke.Yoke.listen()方法的一些代码示例,展示了Yoke.listen()的具体用法。这些代码示例主要来源于Github/Sta
本文整理了Java中com.jetdrone.vertx.yoke.middleware.YokeResponse.putHeader()方法的一些代码示例,展示了YokeResponse.putHe
本文整理了Java中com.jetdrone.vertx.yoke.middleware.YokeResponse.redirect()方法的一些代码示例,展示了YokeResponse.redire
本文整理了Java中com.jetdrone.vertx.yoke.middleware.YokeResponse.end()方法的一些代码示例,展示了YokeResponse.end()的具体用法。
本文整理了Java中com.jetdrone.vertx.yoke.middleware.YokeResponse.setContentType()方法的一些代码示例,展示了YokeResponse.
本文整理了Java中com.jetdrone.vertx.yoke.middleware.YokeResponse.headers()方法的一些代码示例,展示了YokeResponse.headers
本文整理了Java中com.jetdrone.vertx.yoke.middleware.YokeResponse.setStatusCode()方法的一些代码示例,展示了YokeResponse.s
本文整理了Java中com.jetdrone.vertx.yoke.middleware.YokeResponse.setStatusMessage()方法的一些代码示例,展示了YokeRespons
本文整理了Java中com.jetdrone.vertx.yoke.middleware.YokeRequest.formAttributes()方法的一些代码示例,展示了YokeRequest.fo
本文整理了Java中com.jetdrone.vertx.yoke.middleware.YokeRequest.method()方法的一些代码示例,展示了YokeRequest.method()的具
本文整理了Java中com.jetdrone.vertx.yoke.middleware.YokeRequest.getHeader()方法的一些代码示例,展示了YokeRequest.getHead
我是一名优秀的程序员,十分优秀!