Class CustomProvider.Builder
java.lang.Object
cloud.opencode.base.oauth2.provider.CustomProvider.Builder
- Enclosing class:
CustomProvider
CustomProvider Builder
CustomProvider 构建器
- Since:
- JDK 25, opencode-base-oauth2 V1.0.0
- Author:
- Leon Soo www.LeonSoo.com
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionAdd a default scope 添加默认范围authorizationEndpoint(String authorizationEndpoint) Set the authorization endpoint 设置授权端点build()Build the CustomProvider 构建 CustomProviderdefaultScopes(String... scopes) Set the default scopes 设置默认范围defaultScopes(Set<String> scopes) Set the default scopes 设置默认范围deviceAuthorizationEndpoint(String deviceAuthorizationEndpoint) Set the device authorization endpoint 设置设备授权端点Set the issuer 设置发行者Set the JWKS URI 设置 JWKS URISet the provider name 设置 Provider 名称revocationEndpoint(String revocationEndpoint) Set the revocation endpoint 设置撤销端点tokenEndpoint(String tokenEndpoint) Set the token endpoint 设置 Token 端点userInfoEndpoint(String userInfoEndpoint) Set the user info endpoint 设置用户信息端点
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
name
Set the provider name 设置 Provider 名称- Parameters:
name- the name | 名称- Returns:
- this builder | 此构建器
-
authorizationEndpoint
Set the authorization endpoint 设置授权端点- Parameters:
authorizationEndpoint- the authorization endpoint | 授权端点- Returns:
- this builder | 此构建器
-
tokenEndpoint
Set the token endpoint 设置 Token 端点- Parameters:
tokenEndpoint- the token endpoint | Token 端点- Returns:
- this builder | 此构建器
-
userInfoEndpoint
Set the user info endpoint 设置用户信息端点- Parameters:
userInfoEndpoint- the user info endpoint | 用户信息端点- Returns:
- this builder | 此构建器
-
revocationEndpoint
Set the revocation endpoint 设置撤销端点- Parameters:
revocationEndpoint- the revocation endpoint | 撤销端点- Returns:
- this builder | 此构建器
-
deviceAuthorizationEndpoint
Set the device authorization endpoint 设置设备授权端点- Parameters:
deviceAuthorizationEndpoint- the device authorization endpoint | 设备授权端点- Returns:
- this builder | 此构建器
-
jwksUri
Set the JWKS URI 设置 JWKS URI- Parameters:
jwksUri- the JWKS URI | JWKS URI- Returns:
- this builder | 此构建器
-
issuer
Set the issuer 设置发行者- Parameters:
issuer- the issuer | 发行者- Returns:
- this builder | 此构建器
-
defaultScopes
Set the default scopes 设置默认范围- Parameters:
scopes- the default scopes | 默认范围- Returns:
- this builder | 此构建器
-
defaultScopes
Set the default scopes 设置默认范围- Parameters:
scopes- the default scopes | 默认范围- Returns:
- this builder | 此构建器
-
addScope
Add a default scope 添加默认范围- Parameters:
scope- the scope to add | 要添加的范围- Returns:
- this builder | 此构建器
-
build
Build the CustomProvider 构建 CustomProvider- Returns:
- the provider | Provider
-