Package org.nuxeo.ecm.permissions
Class TransientUserPermissionHelper
java.lang.Object
org.nuxeo.ecm.permissions.TransientUserPermissionHelper
- Since:
- 8.1
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic String
acquireToken
(String username, DocumentModel doc, String permission) Deprecated.since 10.3.static void
Adds a token for the givenusername
.static String
Returns the token linked to the given transientusername
, ornull
if no token can be found.protected static boolean
hasOtherPermission
(String username, DocumentModel doc) Returnstrue
if the givenusername
has a non-archived ACE on another document thandoc
,false
otherwise.static void
revokeToken
(String username, DocumentModel doc)
-
Field Details
-
OTHER_DOCUMENT_WITH_PENDING_OR_EFFECTIVE_ACL_QUERY
- Since:
- 10.3
- See Also:
-
TRANSIENT_APP_NAME
- Since:
- 10.3
- See Also:
-
TRANSIENT_DEVICE_ID
- Since:
- 10.3
- See Also:
-
TRANSIENT_PERMISSION
- Since:
- 10.3
- See Also:
-
-
Method Details
-
acquireToken
@Deprecated public static String acquireToken(String username, DocumentModel doc, String permission) Deprecated.since 10.3. UseaddToken(String)
instead. -
addToken
Adds a token for the givenusername
.Does nothing if
username
is not a transient username or if a token already exists.- Since:
- 10.3
-
getToken
Returns the token linked to the given transientusername
, ornull
if no token can be found.- Since:
- 10.3
-
revokeToken
-
hasOtherPermission
Returnstrue
if the givenusername
has a non-archived ACE on another document thandoc
,false
otherwise.Always returns
false
if the configuration propertyNuxeoPrincipal.TRANSIENT_USERNAME_UNIQUE_PROP
istrue
.- Since:
- 10.3
-