Class CustomProvider.Builder

java.lang.Object
cloud.opencode.base.oauth2.provider.CustomProvider.Builder
Enclosing class:
CustomProvider

public static class CustomProvider.Builder extends Object
CustomProvider Builder CustomProvider 构建器
Since:
JDK 25, opencode-base-oauth2 V1.0.0
Author:
Leon Soo www.LeonSoo.com
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • name

      public CustomProvider.Builder name(String name)
      Set the provider name 设置 Provider 名称
      Parameters:
      name - the name | 名称
      Returns:
      this builder | 此构建器
    • authorizationEndpoint

      public CustomProvider.Builder authorizationEndpoint(String authorizationEndpoint)
      Set the authorization endpoint 设置授权端点
      Parameters:
      authorizationEndpoint - the authorization endpoint | 授权端点
      Returns:
      this builder | 此构建器
    • tokenEndpoint

      public CustomProvider.Builder tokenEndpoint(String tokenEndpoint)
      Set the token endpoint 设置 Token 端点
      Parameters:
      tokenEndpoint - the token endpoint | Token 端点
      Returns:
      this builder | 此构建器
    • userInfoEndpoint

      public CustomProvider.Builder userInfoEndpoint(String userInfoEndpoint)
      Set the user info endpoint 设置用户信息端点
      Parameters:
      userInfoEndpoint - the user info endpoint | 用户信息端点
      Returns:
      this builder | 此构建器
    • revocationEndpoint

      public CustomProvider.Builder revocationEndpoint(String revocationEndpoint)
      Set the revocation endpoint 设置撤销端点
      Parameters:
      revocationEndpoint - the revocation endpoint | 撤销端点
      Returns:
      this builder | 此构建器
    • deviceAuthorizationEndpoint

      public CustomProvider.Builder deviceAuthorizationEndpoint(String deviceAuthorizationEndpoint)
      Set the device authorization endpoint 设置设备授权端点
      Parameters:
      deviceAuthorizationEndpoint - the device authorization endpoint | 设备授权端点
      Returns:
      this builder | 此构建器
    • jwksUri

      public CustomProvider.Builder jwksUri(String jwksUri)
      Set the JWKS URI 设置 JWKS URI
      Parameters:
      jwksUri - the JWKS URI | JWKS URI
      Returns:
      this builder | 此构建器
    • issuer

      public CustomProvider.Builder issuer(String issuer)
      Set the issuer 设置发行者
      Parameters:
      issuer - the issuer | 发行者
      Returns:
      this builder | 此构建器
    • defaultScopes

      public CustomProvider.Builder defaultScopes(String... scopes)
      Set the default scopes 设置默认范围
      Parameters:
      scopes - the default scopes | 默认范围
      Returns:
      this builder | 此构建器
    • defaultScopes

      public CustomProvider.Builder defaultScopes(Set<String> scopes)
      Set the default scopes 设置默认范围
      Parameters:
      scopes - the default scopes | 默认范围
      Returns:
      this builder | 此构建器
    • addScope

      public CustomProvider.Builder addScope(String scope)
      Add a default scope 添加默认范围
      Parameters:
      scope - the scope to add | 要添加的范围
      Returns:
      this builder | 此构建器
    • build

      public CustomProvider build()
      Build the CustomProvider 构建 CustomProvider
      Returns:
      the provider | Provider