Class IdUCommandContext
java.lang.Object
com.io7m.idstore.server.internal.command_exec.IdCommandContext<IdUResponseType>
com.io7m.idstore.server.internal.user.IdUCommandContext
The command context for user API commands.
-
Constructor Summary
ConstructorsConstructorDescriptionIdUCommandContext(IdServiceDirectoryType inServices, IdServerStrings inStrings, UUID inRequestId, IdDatabaseTransactionType inTransaction, IdServerClock inClock, IdUser inUser, IdUserSession inSession, String remoteHost, String remoteUserAgent) The context for execution of a command (or set of commands in a transaction). -
Method Summary
Modifier and TypeMethodDescriptionstatic IdUCommandContextcreate(IdServiceDirectoryType services, IdDatabaseTransactionType transaction, jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpSession session, IdUser user) Create a new command context from the given objects.protected IdUResponseErrorerror(UUID id, IdErrorCode errorCode, String message) user()Methods inherited from class com.io7m.idstore.server.internal.command_exec.IdCommandContext
fail, failDatabase, failFormatted, failMail, failPassword, failProtocol, failSecurity, failValidity, now, remoteHost, remoteUserAgent, requestId, securityCheck, services, tracer, transaction, userSession
-
Constructor Details
-
IdUCommandContext
public IdUCommandContext(IdServiceDirectoryType inServices, IdServerStrings inStrings, UUID inRequestId, IdDatabaseTransactionType inTransaction, IdServerClock inClock, IdUser inUser, IdUserSession inSession, String remoteHost, String remoteUserAgent) The context for execution of a command (or set of commands in a transaction).- Parameters:
inServices- The service directoryinStrings- The string resourcesinRequestId- The request IDinTransaction- The transactioninClock- The clockinUser- The user executing the commandinSession- The user sessionremoteHost- The remote hostremoteUserAgent- The remote user agent
-
-
Method Details
-
user
- Returns:
- The user executing the command.
-
create
public static IdUCommandContext create(IdServiceDirectoryType services, IdDatabaseTransactionType transaction, jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpSession session, IdUser user) Create a new command context from the given objects.- Parameters:
services- The service directorytransaction- The database transactionrequest- The requestsession- The HTTP sessionuser- The current user- Returns:
- A context
-
error
- Specified by:
errorin classIdCommandContext<IdUResponseType>
-