Skip to content

Commit

Permalink
fix javadoc to deploy
Browse files Browse the repository at this point in the history
  • Loading branch information
dyc87112 committed Aug 22, 2021
1 parent e3d3eb0 commit 08277d0
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 21 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@

/**
* Used to change the initialization order of the starter
* Created on 2021/8/13
*
* @author llin6025
* @Create 2021/8/13
* @since 2.0.0
*/
@ConditionalOnProperty(value = "springfox.documentation.enabled", havingValue = "true", matchIfMissing = true)
Expand Down
9 changes: 5 additions & 4 deletions src/main/java/com/spring4all/swagger/DocketConfiguration.java
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,11 @@
import springfox.documentation.spring.web.plugins.Docket;

/**
* @author 翟永超
* @Create date:2017/8/7.
* @Update date:2021/8/13
* @My blog: http://blog.didispace.com
* @author 程序猿DD
* @author andi.lin
*
* Created on 2017/8/7
* Update on 2021/8/13
*/
@Configuration
@EnableConfigurationProperties(SwaggerProperties.class)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,9 @@ public SwaggerAuthorizationConfiguration(SwaggerAuthorizationProperties swaggerA
this.swaggerAuthorizationProperties = swaggerAuthorizationProperties;
}

/**
* 配置默认的全局鉴权策略的开关,以及通过正则表达式进行匹配;默认 ^.*$ 匹配所有URL
* 其中 securityReferences 为配置启用的鉴权策略
*
* @return
*/
public SecurityContext securityContext() {
// 配置默认的全局鉴权策略的开关,以及通过正则表达式进行匹配;默认 ^.*$ 匹配所有URL
// 其中 securityReferences 为配置启用的鉴权策略
AuthorizationScope authorizationScope = new AuthorizationScope("global", "accessEverything");
AuthorizationScope[] authorizationScopes = new AuthorizationScope[1];
authorizationScopes[0] = authorizationScope;
Expand All @@ -50,23 +46,15 @@ public SecurityContext securityContext() {
.build();
}

/**
* 配置基于 ApiKey 的鉴权对象
*
* @return
*/
public ApiKey apiKey() {
// 配置基于 ApiKey 的鉴权对象
return new ApiKey(swaggerAuthorizationProperties.getName(),
swaggerAuthorizationProperties.getKeyName(),
ApiKeyVehicle.HEADER.getValue());
}

/**
* 配置基于 BasicAuth 的鉴权对象
*
* @return
*/
public BasicAuth basicAuth() {
// 配置基于 BasicAuth 的鉴权对象
return new BasicAuth(swaggerAuthorizationProperties.getName());
}

Expand Down

0 comments on commit 08277d0

Please sign in to comment.