Package org.wildfly.security.auth.server
Interface Scoped
- 
- All Known Implementing Classes:
 FlexibleIdentityAssociation,SecurityIdentity
public interface ScopedAn identity configuration which can be applied on a scoped basis.- Author:
 - David M. Lloyd
 
 
- 
- 
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default voidrunAs(Runnable action)Run an action under this identity.default <T> TrunAs(Callable<T> action)Run an action under this identity.default <R> RrunAsAction(PrivilegedAction<R> action)Run an action under this identity.default <T,U>
booleanrunAsBiPredicate(BiPredicate<T,U> predicate, T param1, U param2)Run an action under this identity.<T,U>
voidrunAsConsumer(BiConsumer<T,U> action, T parameter1, U parameter2)Run an action under this identity.default <T> voidrunAsConsumer(Consumer<T> action, T parameter)Run an action under this identity.<T,U,E extends Exception>
voidrunAsConsumerEx(org.wildfly.common.function.ExceptionBiConsumer<T,U,E> action, T parameter1, U parameter2)Run an action under this identity.default <T,E extends Exception>
voidrunAsConsumerEx(org.wildfly.common.function.ExceptionConsumer<T,E> action, T parameter)Run an action under this identity.default <T,U,E extends Exception>
booleanrunAsExBiPredicate(org.wildfly.common.function.ExceptionBiPredicate<T,U,E> predicate, T param1, U param2)Run an action under this identity.default <R> RrunAsExceptionAction(PrivilegedExceptionAction<R> action)Run an action under this identity.default <T,E extends Exception>
TrunAsExIntFunction(org.wildfly.common.function.ExceptionIntFunction<T,E> action, int value)Run an action under this identity.default <T,E extends Exception>
TrunAsExLongFunction(org.wildfly.common.function.ExceptionLongFunction<T,E> action, long value)Run an action under this identity.default <T,E extends Exception>
booleanrunAsExPredicate(org.wildfly.common.function.ExceptionPredicate<T,E> predicate, T param)Run an action under this identity.<T,U,R>
RrunAsFunction(BiFunction<T,U,R> action, T parameter1, U parameter2)Run an action under this identity.default <T,R>
RrunAsFunction(Function<T,R> action, T parameter)Run an action under this identity.<T,U,R,E extends Exception>
RrunAsFunctionEx(org.wildfly.common.function.ExceptionBiFunction<T,U,R,E> action, T parameter1, U parameter2)Run an action under this identity.default <T,R,E extends Exception>
RrunAsFunctionEx(org.wildfly.common.function.ExceptionFunction<T,R,E> action, T parameter)Run an action under this identity.default <T> TrunAsIntFunction(IntFunction<T> action, int value)Run an action under this identity.default <T> TrunAsLongFunction(LongFunction<T> action, long value)Run an action under this identity.<T> voidrunAsObjIntConsumer(ObjIntConsumer<T> action, T parameter1, int parameter2)Run an action under this identity.<T,E extends Exception>
voidrunAsObjIntConsumerEx(org.wildfly.common.function.ExceptionObjIntConsumer<T,E> action, T parameter1, int parameter2)Run an action under this identity.default <T> booleanrunAsPredicate(Predicate<T> predicate, T param)Run an action under this identity.default <T> TrunAsSupplier(Supplier<T> action)Run an action under this identity.default <T,E extends Exception>
TrunAsSupplierEx(org.wildfly.common.function.ExceptionSupplier<T,E> action)Run an action under this identity. 
 - 
 
- 
- 
Method Detail
- 
runAs
default void runAs(Runnable action)
Run an action under this identity.- Parameters:
 action- the action to run
 
- 
runAs
default <T> T runAs(Callable<T> action) throws Exception
Run an action under this identity.- Type Parameters:
 T- the action return type- Parameters:
 action- the action to run- Returns:
 - the action result (may be 
null) - Throws:
 Exception- if the action fails
 
- 
runAsFunction
default <T,R> R runAsFunction(Function<T,R> action, T parameter)
Run an action under this identity.- Type Parameters:
 R- the action return typeT- the action parameter type- Parameters:
 parameter- the parameter to pass to the actionaction- the action to run- Returns:
 - the action result (may be 
null) 
 
- 
runAsFunction
<T,U,R> R runAsFunction(BiFunction<T,U,R> action, T parameter1, U parameter2)
Run an action under this identity.- Type Parameters:
 R- the action return typeT- the action first parameter typeU- the action second parameter type- Parameters:
 parameter1- the first parameter to pass to the actionparameter2- the second parameter to pass to the actionaction- the action to run- Returns:
 - the action result (may be 
null) 
 
- 
runAsConsumer
default <T> void runAsConsumer(Consumer<T> action, T parameter)
Run an action under this identity.- Type Parameters:
 T- the action parameter type- Parameters:
 parameter- the parameter to pass to the actionaction- the action to run
 
- 
runAsConsumer
<T,U> void runAsConsumer(BiConsumer<T,U> action, T parameter1, U parameter2)
Run an action under this identity.- Type Parameters:
 T- the action first parameter typeU- the action second parameter type- Parameters:
 parameter1- the first parameter to pass to the actionparameter2- the second parameter to pass to the actionaction- the action to run
 
- 
runAsObjIntConsumer
<T> void runAsObjIntConsumer(ObjIntConsumer<T> action, T parameter1, int parameter2)
Run an action under this identity.- Type Parameters:
 T- the action first parameter type- Parameters:
 parameter1- the first parameter to pass to the actionparameter2- the second parameter to pass to the actionaction- the action to run
 
- 
runAsSupplier
default <T> T runAsSupplier(Supplier<T> action)
Run an action under this identity.- Type Parameters:
 T- the action return type- Parameters:
 action- the action to run- Returns:
 - the action result (may be 
null) 
 
- 
runAsFunctionEx
default <T,R,E extends Exception> R runAsFunctionEx(org.wildfly.common.function.ExceptionFunction<T,R,E> action, T parameter) throws E extends Exception
Run an action under this identity.- Type Parameters:
 R- the action return typeT- the action parameter typeE- the action exception type- Parameters:
 parameter- the parameter to pass to the actionaction- the action to run- Returns:
 - the action result (may be 
null) - Throws:
 E- if the action throws this exceptionE extends Exception
 
- 
runAsFunctionEx
<T,U,R,E extends Exception> R runAsFunctionEx(org.wildfly.common.function.ExceptionBiFunction<T,U,R,E> action, T parameter1, U parameter2) throws E extends Exception
Run an action under this identity.- Type Parameters:
 R- the action return typeT- the action first parameter typeU- the action second parameter typeE- the action exception type- Parameters:
 parameter1- the first parameter to pass to the actionparameter2- the second parameter to pass to the actionaction- the action to run- Returns:
 - the action result (may be 
null) - Throws:
 E- if the action throws this exceptionE extends Exception
 
- 
runAsConsumerEx
default <T,E extends Exception> void runAsConsumerEx(org.wildfly.common.function.ExceptionConsumer<T,E> action, T parameter) throws E extends Exception
Run an action under this identity.- Type Parameters:
 T- the action parameter typeE- the action exception type- Parameters:
 parameter- the parameter to pass to the actionaction- the action to run- Throws:
 E- if the action throws this exceptionE extends Exception
 
- 
runAsConsumerEx
<T,U,E extends Exception> void runAsConsumerEx(org.wildfly.common.function.ExceptionBiConsumer<T,U,E> action, T parameter1, U parameter2) throws E extends Exception
Run an action under this identity.- Type Parameters:
 T- the action first parameter typeU- the action second parameter typeE- the action exception type- Parameters:
 parameter1- the first parameter to pass to the actionparameter2- the second parameter to pass to the actionaction- the action to run- Throws:
 E- if the action throws this exceptionE extends Exception
 
- 
runAsObjIntConsumerEx
<T,E extends Exception> void runAsObjIntConsumerEx(org.wildfly.common.function.ExceptionObjIntConsumer<T,E> action, T parameter1, int parameter2) throws E extends Exception
Run an action under this identity.- Type Parameters:
 T- the action first parameter typeE- the action exception type- Parameters:
 parameter1- the first parameter to pass to the actionparameter2- the second parameter to pass to the actionaction- the action to run- Throws:
 E- if the action throws this exceptionE extends Exception
 
- 
runAsSupplierEx
default <T,E extends Exception> T runAsSupplierEx(org.wildfly.common.function.ExceptionSupplier<T,E> action) throws E extends Exception
Run an action under this identity.- Type Parameters:
 T- the action return typeE- the action exception type- Parameters:
 action- the action to run- Returns:
 - the action result (may be 
null) - Throws:
 E- if the action throws this exceptionE extends Exception
 
- 
runAsAction
default <R> R runAsAction(PrivilegedAction<R> action)
Run an action under this identity.- Type Parameters:
 R- the return value type- Parameters:
 action- the task to run (must not benull)- Returns:
 - the action return value
 
 
- 
runAsExceptionAction
default <R> R runAsExceptionAction(PrivilegedExceptionAction<R> action) throws PrivilegedActionException
Run an action under this identity.- Type Parameters:
 R- the return value type- Parameters:
 action- the task to run (must not benull)- Returns:
 - the action return value
 - Throws:
 PrivilegedActionException- if the action fails with an exception
 
- 
runAsBiPredicate
default <T,U> boolean runAsBiPredicate(BiPredicate<T,U> predicate, T param1, U param2)
Run an action under this identity.- Type Parameters:
 T- the first parameter typeU- the second parameter type- Parameters:
 predicate- the task to run (must not benull)param1- the first parameter to pass to the taskparam2- the second parameter to pass to the task- Returns:
 - the action return value
 - Throws:
 UnsupportedOperationException- if this operation is not implemented
 
- 
runAsExBiPredicate
default <T,U,E extends Exception> boolean runAsExBiPredicate(org.wildfly.common.function.ExceptionBiPredicate<T,U,E> predicate, T param1, U param2) throws E extends Exception
Run an action under this identity.- Type Parameters:
 T- the first parameter typeU- the second parameter typeE- the exception type- Parameters:
 predicate- the task to run (must not benull)param1- the first parameter to pass to the taskparam2- the second parameter to pass to the task- Returns:
 - the action return value
 - Throws:
 E- if an exception occurs in the taskUnsupportedOperationException- if this operation is not implementedE extends Exception
 
- 
runAsPredicate
default <T> boolean runAsPredicate(Predicate<T> predicate, T param)
Run an action under this identity.- Type Parameters:
 T- the first parameter type- Parameters:
 predicate- the task to run (must not benull)param- the parameter to pass to the task- Returns:
 - the action return value
 
 
- 
runAsExPredicate
default <T,E extends Exception> boolean runAsExPredicate(org.wildfly.common.function.ExceptionPredicate<T,E> predicate, T param) throws E extends Exception
Run an action under this identity.- Type Parameters:
 T- the first parameter typeE- the exception type- Parameters:
 predicate- the task to run (must not benull)param- the parameter to pass to the task- Returns:
 - the action return value
 - Throws:
 E- if an exception occurs in the taskE extends Exception
 
- 
runAsIntFunction
default <T> T runAsIntFunction(IntFunction<T> action, int value)
Run an action under this identity.- Type Parameters:
 T- the return value type- Parameters:
 action- the task to run (must not benull)value- the parameter to pass to the task- Returns:
 - the action return value
 
 
- 
runAsExIntFunction
default <T,E extends Exception> T runAsExIntFunction(org.wildfly.common.function.ExceptionIntFunction<T,E> action, int value) throws E extends Exception
Run an action under this identity.- Type Parameters:
 T- the return value typeE- the exception type- Parameters:
 action- the task to run (must not benull)value- the parameter to pass to the task- Returns:
 - the action return value
 - Throws:
 E- if an exception occurs in the taskE extends Exception
 
- 
runAsLongFunction
default <T> T runAsLongFunction(LongFunction<T> action, long value)
Run an action under this identity.- Type Parameters:
 T- the return value type- Parameters:
 action- the task to run (must not benull)value- the parameter to pass to the task- Returns:
 - the action return value
 
 
- 
runAsExLongFunction
default <T,E extends Exception> T runAsExLongFunction(org.wildfly.common.function.ExceptionLongFunction<T,E> action, long value) throws E extends Exception
Run an action under this identity.- Type Parameters:
 T- the return value typeE- the exception type- Parameters:
 action- the task to run (must not benull)value- the parameter to pass to the task- Returns:
 - the action return value
 - Throws:
 E- if an exception occurs in the taskE extends Exception
 
 - 
 
 -