com.atlassian.jira.util
Interface BaseUrl
- All Known Implementing Classes:
- DefaultBaseUrl
public interface BaseUrl
- Since:
- v5.2
getBaseUrl
@Nonnull
String getBaseUrl()
- Returns:
- The base URL for this instance, also known as the context path. If running in the context of a web request, this will return a url relative
to the server root (ie "/jira/"). If running via email, it will return an absolute URL (eg. "http://example.com/jira/").
getCanonicalBaseUrl
@Nonnull
String getCanonicalBaseUrl()
- Returns:
- The canonical base URL for this instance. It will return an absolute URL (eg. "http://example.com/jira/").
runWithStaticBaseUrl
@Nullable
<I,O> O runWithStaticBaseUrl(@Nullable
I input,
@Nonnull
com.google.common.base.Function<I,O> runnable)
- Run the passed function in an environment where JIRA's configured
baseURL
is always used. This basically
makes the passed function ignore any smart baseURL
that can be generated from the request associated
with the calling thread.
- Parameters:
input
- input to pass to the function.runnable
- the function to execute.
- Returns:
- the result of the function.
- Since:
- 6.3.1
Copyright © 2002-2014 Atlassian. All Rights Reserved.