@Singleton
public class AuthActionApiToken
extends java.lang.Object
User and the
ApiToken objects are put in the RequestScope for later use during request processing.| Modifier and Type | Class and Description |
|---|---|
static class |
auth.gui.AuthAction.IAuth.AuthResult
Result for an auth attempt.
|
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
API_TOKEN |
| Modifier and Type | Method and Description |
|---|---|
auth.gui.AuthAction.IAuth.AuthResult |
authenticate(play.mvc.Http.Request request,
User.Role role) |
public static final java.lang.String API_TOKEN
public auth.gui.AuthAction.IAuth.AuthResult authenticate(play.mvc.Http.Request request,
User.Role role)
request - This action's Http.Request objectrole - Role the user must have to access the resourceResult only if auth was unsuccessful. Otherwise, the Optional is empty.