小编Jay*_*ram的帖子

元数据组件需要嵌套在af:metadata标签中.建议:在<f:metadata>中包含必要的组件

我经历了不同的来源,如:

似乎问题已在jsf 2.2.1中得到修复,其中当我尝试使用时,我面临问题,下面是我的配置:

所引用:

<!DOCTYPE html>
<html lang="#{languageBean.language}"
    xmlns="http://www.w3.org/1999/xhtml"
    xmlns:f="http://xmlns.jcp.org/jsf/core"
    xmlns:h="http://xmlns.jcp.org/jsf/html"
    xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
    xmlns:c="http://xmlns.jcp.org/jsp/jstl/core"
    xmlns:fn="http://xmlns.jcp.org/jsp/jstl/functions"
    xmlns:p="http://primefaces.org/ui" xmlns:o="http://omnifaces.org/ui"
    xmlns:of="http://omnifaces.org/functions">
<!-- Enables CTRL+SHIFT+D for activating Facelets debug window -->
<ui:debug />
<f:view locale="#{languageBean.language}" encoding="UTF-8" contentType="text/html">
<!-- Client templates can insert f:metadata here, and this will NOT show up in the showcase page source code -->
<ui:insert name="meta" />

<c:set var="contextPath" value="${pageContext.request.contextPath}"
    scope="application" />
<f:loadBundle var="messageResource" basename="MessageResource" />
<h:head>
    <meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
    <meta http-equiv="X-UA-Compatible"
        content="EmulateIE8,IE=edge,chrome=1" />
    <meta http-equiv="pragma" content="no-cache" />
    <meta …
Run Code Online (Sandbox Code Playgroud)

jsf viewparams jsf-2.2

7
推荐指数
1
解决办法
3566
查看次数

Swagger 无法为 HTTP“PATCH”生成文档

我已关注以下
博客条目:http : //kingsfleet.blogspot.co.uk/2014/02/transparent-patch-support-in-jax-rs-20.html
https://github.com/jersey/jersey /tree/2.6/examples/http-patch
在 Jersey 2.6 依赖版本中创建端点以支持 HTTP“PATCH”方法:

-Jersey: 2.6
-swagger-jersey2-jaxrs_2.10: 1.3.12
Run Code Online (Sandbox Code Playgroud)

题? 为什么Patch端点没有被列为 swagger ui 文档的一部分?

分析:

如果我使用此注释进行注释,则会生成该端点的文档,但不会生成交互。

@com.wordnik.swagger.jaxrs.PATCH
Run Code Online (Sandbox Code Playgroud)

配置

JerssyApplicationInitializer

packages(true, "com.test.account.endpoint", "com.wordnik.swagger.jaxrs.json");
        //Swagger Configuration
        register(new ApiListingResourceJSON(), 10);
        register(JerseyApiDeclarationProvider.class);
        register(JerseyResourceListingProvider.class);

        //Genson Converter
        register(GensonJsonConverter.class, 1);
        register(createMoxyJsonResolver());
Run Code Online (Sandbox Code Playgroud)

我不确定,如果我遗漏了什么,任何帮助或指南都会有所帮助。

补丁方法文档:

 public static final String PATCH_MEDIA_TYPE = "application/json-patch+json";
    @PATCH
        //@com.wordnik.swagger.jaxrs.PATCH
        @PreAuthorize(userAuthenticationRequire=true)
        @Consumes(PATCH_MEDIA_TYPE)
        @Path("{id: .\\d+}")
        @ApiOperation(value = "Update Client Details in UIM System."
                    , response = State.class
                    , notes="Requesting User, should be the owner of the Client." …
Run Code Online (Sandbox Code Playgroud)

java swagger swagger-ui

6
推荐指数
1
解决办法
5986
查看次数

标签 统计

java ×1

jsf ×1

jsf-2.2 ×1

swagger ×1

swagger-ui ×1

viewparams ×1