Class SessionInfoLogger
java.lang.Object
org.apache.jackrabbit.spi.commons.logging.AbstractLogger
org.apache.jackrabbit.spi.commons.logging.SessionInfoLogger
- All Implemented Interfaces:
SessionInfo
Log wrapper for a
SessionInfo.-
Constructor Summary
ConstructorsConstructorDescriptionSessionInfoLogger(SessionInfo sessionInfo, LogWriter writer) Create a new instance for the givensessionInfowhich useswriterfor persisting log messages. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddLockToken(String lockToken) Add the given lock token to thisSessionInfo.String[]Returns the lock tokens present on thisSessionInfo.Returns the user id.Returns the workspace name.voidremoveLockToken(String lockToken) Removes the given lock token from thisSessionInfo.voidsetUserData(String userData) Sets the user data used forEvent.getUserData().
-
Constructor Details
-
SessionInfoLogger
Create a new instance for the givensessionInfowhich useswriterfor persisting log messages.- Parameters:
sessionInfo-writer-
-
-
Method Details
-
getSessionInfo
- Returns:
- the wrapped SessionInfo
-
getUserID
Description copied from interface:SessionInfoReturns the user id.- Specified by:
getUserIDin interfaceSessionInfo- Returns:
- The user identification.
- See Also:
-
getWorkspaceName
Description copied from interface:SessionInfoReturns the workspace name.- Specified by:
getWorkspaceNamein interfaceSessionInfo- Returns:
- The name of the
workspacethis SessionInfo has been built for. - See Also:
-
getLockTokens
Description copied from interface:SessionInfoReturns the lock tokens present on thisSessionInfo.- Specified by:
getLockTokensin interfaceSessionInfo- Returns:
- lock tokens present on this
SessionInfo. - Throws:
RepositoryException- If another error occurs.
-
addLockToken
Description copied from interface:SessionInfoAdd the given lock token to thisSessionInfo. The token will enable the SessionInfo to operate on Items that are affected by the lock identified by the given token.- Specified by:
addLockTokenin interfaceSessionInfo- Parameters:
lockToken- to be added.- Throws:
RepositoryException- If another error occurs.
-
removeLockToken
Description copied from interface:SessionInfoRemoves the given lock token from thisSessionInfo. This must happen if the associated Session successfully removes the Lock from a Node or if the token is removed from the Session itself by callingSession.removeLockToken(String). Consequently allRepositoryServiceoperations affected by a lock will fail with LockException provided the lock hasn't been released.- Specified by:
removeLockTokenin interfaceSessionInfo- Parameters:
lockToken- to be removed.- Throws:
RepositoryException- If another error occurs.
-
setUserData
Description copied from interface:SessionInfoSets the user data used forEvent.getUserData().- Specified by:
setUserDatain interfaceSessionInfo- Parameters:
userData-- Throws:
RepositoryException- See Also:
-