Class GHEOAuthProvider
- java.lang.Object
-
- jetbrains.buildServer.serverSide.oauth.OAuthProvider
-
- jetbrains.buildServer.serverSide.oauth.github.GitHubOAuthProviderBase
-
- jetbrains.buildServer.serverSide.oauth.github.GHEOAuthProvider
-
- All Implemented Interfaces:
ConnectionProvider,ServerExtension,TeamCityExtension
public class GHEOAuthProvider extends GitHubOAuthProviderBase
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class jetbrains.buildServer.serverSide.oauth.OAuthProvider
OAuthProvider.CapabilityResolver
-
-
Field Summary
Fields Modifier and Type Field Description static StringTYPEstatic StringURL_TYPE-
Fields inherited from class jetbrains.buildServer.serverSide.oauth.github.GitHubOAuthProviderBase
DEFAULT_SCOPE
-
Fields inherited from class jetbrains.buildServer.serverSide.oauth.OAuthProvider
COMPOUND_STORAGE_ID_PREFIX, myCapabilityResolvers, NOPE
-
-
Constructor Summary
Constructors Constructor Description GHEOAuthProvider()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringdescribeConnection(OAuthConnectionDescriptor connection)StringgetDisplayName()StringgetEditParametersUrl()PropertiesProcessorgetPropertiesProcessor()StringgetProviderTypeForUniqueRedirect()Returns the provider type to be included in unique redirect URLs.StringgetTokenPopupPath()StringgetTokenStorageId(OAuthConnectionDescriptor connection)Returns an id of the token storage used by connection.StringgetType()StringgetTypeForUrl()booleanisAcquiringTokenSupported()Whether acquiring tokens is supported for this provider.booleanisUniqueRedirectsSupported()Whether this provider supports the creation of unique redirect URLs.-
Methods inherited from class jetbrains.buildServer.serverSide.oauth.github.GitHubOAuthProviderBase
getFallbackRedirectPath, getScopeForIntent, getSupportedTokenIntentTypes, isSuitableToken
-
Methods inherited from class jetbrains.buildServer.serverSide.oauth.OAuthProvider
applyAccessibleEntities, buildCompoundTokenStorageId, connectionHasCapability, connectionIsHidden, describeConnectionForUI, getAccessibleEntitiesEndpoint, getAdditionalUIConnectionDescription, getCapabilitiesUrl, getCapabilityResolver, getDefaultProperties, getScope, getTokenStorageParameters, getTokenUsageParamsForVcsRoot, isAccessibleEntitiesSupported, isAcquiringTokenSupportedForConnection, isAvailable, isCapabilitiesEnabledForProject, isCapabilitiesSupported, isTokenRefreshSupported, refreshToken, registerCapabilityResolver, testConnection
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface jetbrains.buildServer.serverSide.connections.ConnectionProvider
describeConnection, getDisplayOrderRank
-
-
-
-
Field Detail
-
TYPE
public static final String TYPE
- See Also:
- Constant Field Values
-
URL_TYPE
public static final String URL_TYPE
- See Also:
- Constant Field Values
-
-
Method Detail
-
getType
@NotNull public String getType()
- Returns:
- String used to identify the Connection Provider type. All Connection features store this property in parameters.
-
getTypeForUrl
public String getTypeForUrl()
-
getDisplayName
@NotNull public String getDisplayName()
- Returns:
- human friendly provider name
-
describeConnection
@NotNull public String describeConnection(@NotNull OAuthConnectionDescriptor connection)
- Overrides:
describeConnectionin classOAuthProvider- Returns:
- human friendly description of OAuth connection
-
getTokenStorageId
@NotNull public String getTokenStorageId(@NotNull OAuthConnectionDescriptor connection)
Description copied from class:OAuthProviderReturns an id of the token storage used by connection. Depending on the connection type multiple connections can use the same token storage. In case of OAuth2 apps, this id may be based on the client/application id of the OAuth2 app configured in a third party system.- Overrides:
getTokenStorageIdin classOAuthProvider- Parameters:
connection- descriptor- Returns:
- token storage id
-
getPropertiesProcessor
@Nullable public PropertiesProcessor getPropertiesProcessor()
- Specified by:
getPropertiesProcessorin interfaceConnectionProvider- Overrides:
getPropertiesProcessorin classOAuthProvider- Returns:
- processor for connection provider parameters. Properties processor performs validation function and is called when connection is edited or created.
-
getEditParametersUrl
@Nullable public String getEditParametersUrl()
- Specified by:
getEditParametersUrlin interfaceConnectionProvider- Overrides:
getEditParametersUrlin classOAuthProvider- Returns:
- URL to edit connection parameters page
-
getTokenPopupPath
public String getTokenPopupPath()
- Overrides:
getTokenPopupPathin classOAuthProvider
-
isAcquiringTokenSupported
public boolean isAcquiringTokenSupported()
Description copied from class:OAuthProviderWhether acquiring tokens is supported for this provider. See also: JSP Tag oauth:obtainToken- Overrides:
isAcquiringTokenSupportedin classOAuthProvider- Returns:
- true, if supported
-
isUniqueRedirectsSupported
public boolean isUniqueRedirectsSupported()
Description copied from class:OAuthProviderWhether this provider supports the creation of unique redirect URLs. Providers wanting to support this feature should return true here and ensure that the respective access token controllers are registered viaBaseAccessTokenController.registerController(WebControllerManager, String). Also, the two related methodsOAuthProvider.getProviderTypeForUniqueRedirect()andOAuthProvider.getFallbackRedirectPath()must be implemented.- Overrides:
isUniqueRedirectsSupportedin classOAuthProvider- Returns:
- false, by default
-
getProviderTypeForUniqueRedirect
@NotNull public String getProviderTypeForUniqueRedirect()
Description copied from class:OAuthProviderReturns the provider type to be included in unique redirect URLs.- Overrides:
getProviderTypeForUniqueRedirectin classOAuthProvider- Returns:
- URL-compatible provider type
- See Also:
OAuthProvider.isUniqueRedirectsSupported()
-
-