Class BambooWebResourceIntegration
- All Implemented Interfaces:
com.atlassian.plugin.webresource.WebResourceIntegration
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
com.atlassian.sal.api.ApplicationProperties
Returns the base URL for this application.getBaseUrl
(com.atlassian.webresource.api.UrlMode urlMode) Returns the base URL for this application in either relative or absolute format, depending on the value ofurlMode
.com.atlassian.plugin.webresource.cdn.CDNStrategy
@Nullable com.atlassian.sal.api.features.DarkFeatureManager
@NotNull com.atlassian.event.api.EventPublisher
@NotNull String
getI18nRawText
(Locale locale, String s) getI18nText
(Locale locale, String s) com.atlassian.plugin.PluginAccessor
Applications must implement this method to get access to the application's PluginAccessorcom.atlassian.plugin.event.PluginEventManager
This must be a thread-local cache that will be accessible from both the page, and the decoratorSuperbatch resource path will contain value returned byWebResourceIntegration.getSystemCounter()
, hence there's no need to return different value for dev mode or when caches are disabled.Represents the last time the system was updated.void
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.atlassian.plugin.webresource.WebResourceIntegration
getSyncWebResourceKeys, getSystemCounter, isCompiledResourceEnabled, isCtCdnMappingEnabled, isDeferJsAttributeEnabled, isIncrementalCacheEnabled, usePluginInstallTimeInsteadOfTheVersionForSnapshotPlugins
-
Constructor Details
-
BambooWebResourceIntegration
-
-
Method Details
-
getPluginAccessor
public com.atlassian.plugin.PluginAccessor getPluginAccessor()Applications must implement this method to get access to the application's PluginAccessor- Specified by:
getPluginAccessor
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
getRequestCache
This must be a thread-local cache that will be accessible from both the page, and the decorator- Specified by:
getRequestCache
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
getResourceUrlPrefix
- Specified by:
getResourceUrlPrefix
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
rebuildResourceUrlPrefix
public void rebuildResourceUrlPrefix()- Specified by:
rebuildResourceUrlPrefix
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
getSystemBuildNumber
Represents the last time the system was updated. This is generally obtained from BuildUtils or similar.- Specified by:
getSystemBuildNumber
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
getBaseUrl
Returns the base URL for this application. This method may return either an absolute or a relative URL. Implementations are free to determine which mode to use based on any criteria of their choosing. For example, an implementation may choose to return a relative URL if it detects that it is running in the context of an HTTP request, and an absolute URL if it detects that it is not. Or it may choose to always return an absolute URL, or always return a relative URL. Callers should only use this method when they are sure that either an absolute or a relative URL will be appropriate, and should not rely on any particular observed behavior regarding how this value is interpreted, which may vary across different implementations.In general, the behavior of this method should be equivalent to calling
getBaseUrl(com.atlassian.webresource.api.UrlMode)
with aurlMode
value ofUrlMode.AUTO
.- Specified by:
getBaseUrl
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
- Returns:
- the string value of the base URL of this application
-
getBaseUrl
Returns the base URL for this application in either relative or absolute format, depending on the value ofurlMode
.If {@code urlMode == {@link UrlMode#ABSOLUTE}, this method returns an absolute URL, with URL scheme, hostname, port (if non-standard for the scheme), and context path. <p> If {@code urlMode == {@link UrlMode#RELATIVE}, this method returns a relative URL containing just the context path. <p> If {@code urlMode == {@link UrlMode#AUTO}, this method may return either an absolute or a relative URL. Implementations are free to determine which mode to use based on any criteria of their choosing. For example, an implementation may choose to return a relative URL if it detects that it is running in the context of an HTTP request, and an absolute URL if it detects that it is not. Or it may choose to always return an absolute URL, or always return a relative URL. Callers should only use {@code WebResourceManager.UrlMode#AUTO} when they are sure that either an absolute or a relative URL will be appropriate, and should not rely on any particular observed behavior regarding how this value is interpreted, which may vary across different implementations. @param urlMode specifies whether to use absolute URLs, relative URLs, or allow the concrete implementation to decide @return the string value of the base URL of this application @since 2.3.0
- Specified by:
getBaseUrl
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
getSuperBatchVersion
Superbatch resource path will contain value returned byWebResourceIntegration.getSystemCounter()
, hence there's no need to return different value for dev mode or when caches are disabled.- Specified by:
getSuperBatchVersion
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
getTemporaryDirectory
- Specified by:
getTemporaryDirectory
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
allowedCondition1Keys
- Specified by:
allowedCondition1Keys
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
allowedTransform1Keys
- Specified by:
allowedTransform1Keys
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
forbidCondition1AndTransformer1
public boolean forbidCondition1AndTransformer1()- Specified by:
forbidCondition1AndTransformer1
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
getAdministrationConfiguration
-
getStaticResourceLocale
- Specified by:
getStaticResourceLocale
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
getCDNStrategy
public com.atlassian.plugin.webresource.cdn.CDNStrategy getCDNStrategy()- Specified by:
getCDNStrategy
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
getLocale
- Specified by:
getLocale
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
getI18nRawText
- Specified by:
getI18nRawText
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
getI18nText
- Specified by:
getI18nText
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
getPluginEventManager
public com.atlassian.plugin.event.PluginEventManager getPluginEventManager()- Specified by:
getPluginEventManager
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
getHostApplicationVersion
- Specified by:
getHostApplicationVersion
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
getApplicationProperties
public com.atlassian.sal.api.ApplicationProperties getApplicationProperties()- Specified by:
getApplicationProperties
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
getI18nStateHash
- Specified by:
getI18nStateHash
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
getSupportedLocales
- Specified by:
getSupportedLocales
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
getEventPublisher
@NotNull public @NotNull com.atlassian.event.api.EventPublisher getEventPublisher()- Specified by:
getEventPublisher
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-
getDarkFeatureManager
@Nullable public @Nullable com.atlassian.sal.api.features.DarkFeatureManager getDarkFeatureManager()- Specified by:
getDarkFeatureManager
in interfacecom.atlassian.plugin.webresource.WebResourceIntegration
-