@PublicApi
public interface ReadOnlyApplicationLink
ApplicationLink, this one cannot be modified. Nevertheless, it is not advised to persist any instance
returned by this class - if really needed use the ApplicationId instead an listen for
ApplicationLinksIDChangedEvents.| Modifier and Type | Method and Description |
|---|---|
ApplicationLinkRequestFactory |
createAuthenticatedRequestFactory()
The
ApplicationLinkRequestFactory returned by this method will choose a single
AuthenticationProvider for automatically authenticating created Request objects. |
ApplicationLinkRequestFactory |
createAuthenticatedRequestFactory(Class<? extends AuthenticationProvider> providerClass)
This method returns a
ApplicationLinkRequestFactory initialised by the specified
AuthenticationProvider. |
ApplicationLinkRequestFactory |
createImpersonatingAuthenticatedRequestFactory()
Creates a request factory for impersonating requests (see
ImpersonatingAuthenticationProvider). |
ApplicationLinkRequestFactory |
createNonImpersonatingAuthenticatedRequestFactory()
Creates a request factory for non-impersonating requests (see
NonImpersonatingAuthenticationProvider). |
URI |
getDisplayUrl() |
ApplicationId |
getId()
This
ApplicationId is subject to change if an administrator:
upgrades the remote application to use Unified Application Links (and this link was created prior to the upgrade); or
the remote application does not have Unified Application Links deployed, and its RPC URL changes.
If you are storing the ApplicationId for any reason, your plugin should listen for the
ApplicationLinksIDChangedEvent. |
String |
getName() |
URI |
getRpcUrl() |
ApplicationType |
getType()
See the
com.atlassian.applinks.api.application package for a list of ApplicationTypes bundled
with the Unified Application Links plugin. |
boolean |
isPrimary() |
boolean |
isSystem() |
ApplicationId getId()
ApplicationId is subject to change if an administrator:
ApplicationId for any reason, your plugin should listen for the
ApplicationLinksIDChangedEvent.ApplicationType getType()
com.atlassian.applinks.api.application package for a list of ApplicationTypes bundled
with the Unified Application Links plugin. Additional types can be added via the extension APIs in the
applinks-spi module.JiraApplicationTypeString getName()
URI getDisplayUrl()
URI returned by this
method will have no trailing slash. e.g. "https://mydomain.com/jira"URI getRpcUrl()
URI will have no trailing slash.
e.g. "http://localhost:8080/jira"boolean isPrimary()
ApplicationLink of its type, false otherwiseboolean isSystem()
ApplicationLinkRequestFactory createAuthenticatedRequestFactory()
ApplicationLinkRequestFactory returned by this method will choose a single
AuthenticationProvider for automatically authenticating created Request objects. The selection
algorithm is as follows:
UserManager.getRemoteUsername()),
the request will be unauthenticated, and processed in the remote application anonymously.ImpersonatingAuthenticationProviders are configured (for example, OAuth or Trusted
Applications), one will be used. Trusted Applications will be returned in preference to OAuth if both are configured;NonImpersonatingAuthenticationProviders are configured (for example,
Basic Auth), one will be usedAuthenticationProviders can be implemented via the extension APIs in the
applinks-spi module.
If your feature only supports a single authentication method, you should use
createAuthenticatedRequestFactory(Class)}.ApplicationLinkRequestFactory for creating requests that are authenticated for this
ApplicationLink.ApplicationLinkRequestFactory,
ImpersonatingAuthenticationProvider,
NonImpersonatingAuthenticationProvider,
createAuthenticatedRequestFactory(Class)ApplicationLinkRequestFactory createAuthenticatedRequestFactory(Class<? extends AuthenticationProvider> providerClass)
ApplicationLinkRequestFactory initialised by the specified
AuthenticationProvider. You should use this method only if your feature requires a specific
AuthenticationProvider implementation. Note that this method will return null if an administrator
of the local application has not configured the specified AuthenticationProvider for this
ApplicationLink.providerClass - the AuthenticationProvider type to use for the RequestFactoryRequestFactory for creating requests that are authenticated for this ApplicationLink
using an AuthenticationProvider implementation that conforms to the supplied providerClass, or
null if no AuthenticationProvider is configured for this ApplicationLink. If the supplied
providerClass is AuthenticationProvider.class this method will bind the RequestFactory
to any available AuthenticationProvider, or return null if there are no
AuthenticationProviders configured. This method will only return an unauthenticated
RequestFactory if the supplied providerClass is Anonymous.createAuthenticatedRequestFactory()ApplicationLinkRequestFactory createImpersonatingAuthenticatedRequestFactory()
ImpersonatingAuthenticationProvider).
The authentication providers will be considered in the strict order given in the following list. The first
authentication mode supported by the product and configured on this link will be returned.
- TrustedAppsAuthenticationProvider
- TwoLeggedOAuthWithImpersonationAuthenticationProvider
- OAuthAuthenticationProviderApplicationLinkRequestFactory createNonImpersonatingAuthenticatedRequestFactory()
NonImpersonatingAuthenticationProvider).
The authentication providers will be considered in the strict order given in the following list. The first
authentication mode supported by the product and configured on this link will be returned.
- TwoLeggedOAuthAuthenticationProvider
- BasicAuthenticationProviderCopyright © 2020 Atlassian. All rights reserved.