public interface UserWorkspaceService extends Serializable
Modifier and Type | Method and Description |
---|---|
DocumentModel |
getCurrentUserPersonalWorkspace(CoreSession userCoreSession)
Gets the current user personal workspace.
|
DocumentModel |
getCurrentUserPersonalWorkspace(CoreSession userCoreSession,
DocumentModel context)
Deprecated.
since 9.3. User personal workspaces have always been stored in default domain. The context is
useless. Simply use
getCurrentUserPersonalWorkspace(CoreSession) . |
DocumentModel |
getCurrentUserPersonalWorkspace(String userName,
DocumentModel currentDocument)
Gets the current user personal workspace from a lower level.
|
DocumentModel |
getUserPersonalWorkspace(NuxeoPrincipal principal,
DocumentModel context)
Gets a detached user workspace of a specified user depending of the passed principal.
|
DocumentModel |
getUserPersonalWorkspace(String userName,
DocumentModel context)
Gets a detached user workspace of a specified user.
|
void |
invalidate()
Invalidates the user workspace service and force re-computation of user workspace root location.
|
boolean |
isUnderUserWorkspace(Principal principal,
String username,
DocumentModel doc)
Checks whether the passed document is under the user's workspace (or is the workspace itself).
|
DocumentModel getCurrentUserPersonalWorkspace(CoreSession userCoreSession)
If this personal workspace does not exist then a new one will be created for the user owning the core session.
userCoreSession
- the user core sessionDocumentModel getCurrentUserPersonalWorkspace(String userName, DocumentModel currentDocument)
If this personal workspace does not exist then a new one will be created for the user who is represented by first argument.
userName
- the current usercurrentDocument
- the current document on which the user was on@Deprecated DocumentModel getCurrentUserPersonalWorkspace(CoreSession userCoreSession, DocumentModel context)
getCurrentUserPersonalWorkspace(CoreSession)
.DocumentModel getUserPersonalWorkspace(String userName, DocumentModel context)
userName
- is the username of the wanted user's workspace ownercontext
- is a document to determine the domainDocumentModel getUserPersonalWorkspace(NuxeoPrincipal principal, DocumentModel context)
principal
- of the wanted user's workspace ownercontext
- is a document to determine the domainboolean isUnderUserWorkspace(Principal principal, String username, DocumentModel doc)
principal
- the userusername
- the username, if principal is not availabledoc
- the documenttrue
if the document is under the user's workspacevoid invalidate()
Copyright © 2018 Nuxeo. All rights reserved.