Package com.atlassian.bamboo.security
Class ImpersonationHelper
- java.lang.Object
-
- com.atlassian.bamboo.security.ImpersonationHelper
-
public class ImpersonationHelper extends Object
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
escalateCurrentThreadToSystemAuthority()
static Runnable
makeRunnableWithSystemAuthority(Runnable runnable)
static void
newAuthenticationForCurrentThread(org.acegisecurity.Authentication authentication)
static <E1 extends Throwable,E2 extends Throwable,E3 extends Throwable>
voidrunAs(@NotNull BambooUser user, BambooRunnables.ThrowingX<E1,E2,E3> runnable)
static <E1 extends Throwable,E2 extends Throwable,E3 extends Throwable>
voidrunWith(@NotNull org.acegisecurity.Authentication authentication, BambooRunnables.ThrowingX<E1,E2,E3> runnable)
static <E1 extends Throwable,E2 extends Throwable,E3 extends Throwable>
voidrunWithSystemAuthority(BambooRunnables.ThrowingX<E1,E2,E3> runnable)
-
-
-
Method Detail
-
runWithSystemAuthority
public static <E1 extends Throwable,E2 extends Throwable,E3 extends Throwable> void runWithSystemAuthority(@NotNull BambooRunnables.ThrowingX<E1,E2,E3> runnable) throws E2 extends Throwable, E1 extends Throwable, E3 extends Throwable
- Throws:
E2 extends Throwable
-
runWith
public static <E1 extends Throwable,E2 extends Throwable,E3 extends Throwable> void runWith(@NotNull @NotNull org.acegisecurity.Authentication authentication, @NotNull BambooRunnables.ThrowingX<E1,E2,E3> runnable) throws E2 extends Throwable, E1 extends Throwable, E3 extends Throwable
- Throws:
E2 extends Throwable
-
newAuthenticationForCurrentThread
public static void newAuthenticationForCurrentThread(org.acegisecurity.Authentication authentication)
-
makeRunnableWithSystemAuthority
public static Runnable makeRunnableWithSystemAuthority(Runnable runnable)
-
escalateCurrentThreadToSystemAuthority
public static void escalateCurrentThreadToSystemAuthority()
-
runAs
public static <E1 extends Throwable,E2 extends Throwable,E3 extends Throwable> void runAs(@NotNull @NotNull BambooUser user, @NotNull BambooRunnables.ThrowingX<E1,E2,E3> runnable) throws E2 extends Throwable, E1 extends Throwable, E3 extends Throwable
- Throws:
E2 extends Throwable
-
-