1
0
mirror of synced 2026-02-08 18:47:47 +08:00

justauth-spring-boot-starter 完成~

This commit is contained in:
Yangkai.Shen
2019-07-22 15:23:07 +08:00
commit 78d8dccad8
9 changed files with 581 additions and 0 deletions

View File

@@ -0,0 +1,27 @@
package com.xkcoding.justauth;
import com.xkcoding.justauth.properties.JustAuthProperties;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
/**
* <p>
* JustAuth 自动装配类
* </p>
*
* @author yangkai.shen
* @date Created in 2019-07-22 10:52
*/
@Configuration
@EnableConfigurationProperties(JustAuthProperties.class)
public class JustAuthAutoConfiguration {
@Bean
@ConditionalOnProperty(prefix = "justauth", value = "enabled", havingValue = "true", matchIfMissing = true)
public AuthRequestFactory authRequestFactory(JustAuthProperties properties) {
return new AuthRequestFactory(properties);
}
}