|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface Manager
Description:
TODO: Class Description
| Method Summary | |
|---|---|
void |
addIdentityToSecurityGroup(Identity identity,
SecurityGroup secGroup)
|
int |
countIdentitiesOfSecurityGroup(SecurityGroup secGroup)
|
java.lang.Long |
countUniqueUserLoginsSince(java.util.Date lastLoginLimit)
get number of users with last login greater than lastLoginLimit |
Authentication |
createAndPersistAuthentication(Identity identity,
java.lang.String provider,
java.lang.String authUsername,
java.lang.String credential)
|
Identity |
createAndPersistIdentity(java.lang.String username,
User user,
java.lang.String provider,
java.lang.String authusername,
java.lang.String credential)
|
Identity |
createAndPersistIdentityAndUser(java.lang.String username,
User user,
java.lang.String provider,
java.lang.String authusername,
java.lang.String credential)
|
SecurityGroup |
createAndPersistNamedSecurityGroup(java.lang.String groupName)
create only makes no sense, since there are no attibutes to set |
Policy |
createAndPersistPolicy(SecurityGroup secGroup,
java.lang.String permission,
OLATResourceable olatResourceable)
the olatResourceable is not required to have some persisted implementation, but the manager will use the OLATResource to persist it. |
Policy |
createAndPersistPolicyWithResource(SecurityGroup secGroup,
java.lang.String permission,
OLATResource olatResource)
Creates and persist a policy for certain OLAT-resource (instead of OLAT-resourceable) |
SecurityGroup |
createAndPersistSecurityGroup()
create only makes no sense, since there are no attibutes to set |
void |
deleteAuthentication(Authentication authentication)
|
void |
deletePolicy(SecurityGroup secGroup,
java.lang.String permission,
OLATResourceable olatResourceable)
|
void |
deleteSecurityGroup(SecurityGroup secGroup)
removes the group with all the idendities contained in it, the idenities itself are of course not deleted. |
Authentication |
findAuthentication(Identity identity,
java.lang.String provider)
|
Authentication |
findAuthenticationByAuthusername(java.lang.String authusername,
java.lang.String provider)
|
Identity |
findIdentityByName(java.lang.String identityName)
Find an identity by its name. |
SecurityGroup |
findSecurityGroupByName(java.lang.String securityGroupName)
|
Identity |
getAndUpdateAnonymousUserForLanguage(java.util.Locale locale)
Returns the anonymous identity for a given locale, normally used to log in as guest user |
java.util.List<Authentication> |
getAuthentications(Identity identity)
Return the List of associated Authentications. |
java.util.List<SecurityGroup> |
getGroupsWithPermissionOnOlatResourceable(java.lang.String permission,
OLATResourceable olatResourceable)
use for testing ONLY. |
java.util.List<Identity> |
getIdentitiesAndDateOfSecurityGroup(SecurityGroup secGroup)
|
java.util.List<java.lang.Object[]> |
getIdentitiesAndDateOfSecurityGroup(SecurityGroup secGroup,
boolean sortedByAddDate)
|
java.util.List<Identity> |
getIdentitiesByPowerSearch(java.lang.String login,
java.util.Map<java.lang.String,java.lang.String> userProperties,
boolean userPropertiesAsIntersectionSearch,
SecurityGroup[] groups,
PermissionOnResourceable[] permissionOnResources,
java.lang.String[] authProviders,
java.util.Date createdAfter,
java.util.Date createdBefore,
java.lang.Integer status)
Get a list of identities that match the following conditions. |
java.util.List<Identity> |
getIdentitiesOfSecurityGroup(SecurityGroup secGroup)
search |
java.util.List<Identity> |
getIdentitiesWithPermissionOnOlatResourceable(java.lang.String permission,
OLATResourceable olatResourceable)
use for testing ONLY. |
java.util.List<Identity> |
getPoliciesOfIdentity(Identity identity)
for debugging and info by the olat admins: |
java.util.List<Policy> |
getPoliciesOfSecurityGroup(SecurityGroup secGroup)
|
Roles |
getRoles(Identity identity)
Get the identity's roles |
java.util.Date |
getSecurityGroupJoinDateForIdentity(SecurityGroup secGroup,
Identity identity)
Get date where identity joined a security group |
java.util.List |
getSecurityGroupsForIdentity(Identity identity)
Get all SecurtityGroups an Identity is in |
java.util.List<Identity> |
getVisibleIdentitiesByPowerSearch(java.lang.String login,
java.util.Map<java.lang.String,java.lang.String> userProperties,
boolean userPropertiesAsIntersectionSearch,
SecurityGroup[] groups,
PermissionOnResourceable[] permissionOnResources,
java.lang.String[] authProviders,
java.util.Date createdAfter,
java.util.Date createdBefore)
Get a list of identities that match the following conditions. |
void |
init()
|
boolean |
isIdentityInSecurityGroup(Identity identity,
SecurityGroup secGroup)
use only if really needed. |
boolean |
isIdentityPermittedOnResourceable(Identity identity,
java.lang.String permission,
OLATResourceable olatResourceable)
is allowed to.... |
boolean |
isIdentityPermittedOnResourceable(Identity identity,
java.lang.String permission,
OLATResourceable olatResourceable,
boolean checkTypeRight)
|
boolean |
isIdentityVisible(java.lang.String identityName)
Check if identity is visible. |
Identity |
loadIdentityByKey(java.lang.Long identityKey)
find an identity by the key instead of the username. |
Identity |
loadIdentityByKey(java.lang.Long identityKey,
boolean strict)
find an identity by the key. |
void |
removeIdentityFromSecurityGroup(Identity identity,
SecurityGroup secGroup)
Removes the identity from this security group or does nothing if the identity is not in the group at all. |
void |
saveIdentityStatus(Identity identity,
java.lang.Integer status)
Save an identity |
| Method Detail |
|---|
void init()
boolean isIdentityPermittedOnResourceable(Identity identity,
java.lang.String permission,
OLATResourceable olatResourceable)
identity - permission - olatResourceable -
Roles getRoles(Identity identity)
identity -
boolean isIdentityPermittedOnResourceable(Identity identity,
java.lang.String permission,
OLATResourceable olatResourceable,
boolean checkTypeRight)
identity - permission - olatResourceable - checkTypeRight -
boolean isIdentityInSecurityGroup(Identity identity,
SecurityGroup secGroup)
identity - secGroup -
java.util.List<Identity> getIdentitiesOfSecurityGroup(SecurityGroup secGroup)
secGroup -
java.util.List<Identity> getIdentitiesAndDateOfSecurityGroup(SecurityGroup secGroup)
secGroup -
java.util.List<java.lang.Object[]> getIdentitiesAndDateOfSecurityGroup(SecurityGroup secGroup,
boolean sortedByAddDate)
sortedByAddDate - true= return list of idenities sorted by added dategetIdentitiesAndDateOfSecurityGroup(org.olat.basesecurity.SecurityGroup)
java.util.Date getSecurityGroupJoinDateForIdentity(SecurityGroup secGroup,
Identity identity)
secGroup - identity -
SecurityGroup findSecurityGroupByName(java.lang.String securityGroupName)
securityGroupName -
Identity findIdentityByName(java.lang.String identityName)
Be aware that this method does not check the identities status! This method returns identities with any state, also deleted identities!
identityName -
Identity loadIdentityByKey(java.lang.Long identityKey)
identityKey - the key of the identity to load; may not be null or zero
Identity loadIdentityByKey(java.lang.Long identityKey,
boolean strict)
identityKey - the key of the identity to load; may not be null or zerostrict - if true equivalent to @see org.olat.basesecurity.Manager#loadIdentityByKey(java.lang.Long), if false return null if not found
java.lang.Long countUniqueUserLoginsSince(java.util.Date lastLoginLimit)
lastLoginLimit -
int countIdentitiesOfSecurityGroup(SecurityGroup secGroup)
secGroup -
Identity createAndPersistIdentity(java.lang.String username,
User user,
java.lang.String provider,
java.lang.String authusername,
java.lang.String credential)
username - the usernameuser - the unpresisted Userprovider - the provider of the authentication ("OLAT" or "AAI"). If
null, no authentication token is generated.authusername - the username used as authentication credential
(=username for provider "OLAT")credential - the credentials or null if not used
Identity createAndPersistIdentityAndUser(java.lang.String username,
User user,
java.lang.String provider,
java.lang.String authusername,
java.lang.String credential)
username - the usernameuser - the unpresisted Userprovider - the provider of the authentication ("OLAT" or "AAI"). If
null, no authentication token is generated.authusername - the username used as authentication credential
(=username for provider "OLAT")credential - the credentials or null if not used
java.util.List<Authentication> getAuthentications(Identity identity)
identity -
Authentication findAuthentication(Identity identity,
java.lang.String provider)
identity - provider -
Authentication createAndPersistAuthentication(Identity identity,
java.lang.String provider,
java.lang.String authUsername,
java.lang.String credential)
identity - provider - authUsername - credential -
void deleteAuthentication(Authentication authentication)
authentication - SecurityGroup createAndPersistSecurityGroup()
SecurityGroup createAndPersistNamedSecurityGroup(java.lang.String groupName)
groupName -
void deleteSecurityGroup(SecurityGroup secGroup)
secGroup -
void addIdentityToSecurityGroup(Identity identity,
SecurityGroup secGroup)
identity - secGroup -
void removeIdentityFromSecurityGroup(Identity identity,
SecurityGroup secGroup)
identity - secGroup -
Policy createAndPersistPolicy(SecurityGroup secGroup,
java.lang.String permission,
OLATResourceable olatResourceable)
secGroup - permission - olatResourceable -
Policy createAndPersistPolicyWithResource(SecurityGroup secGroup,
java.lang.String permission,
OLATResource olatResource)
secGroup - permission - olatResource -
void deletePolicy(SecurityGroup secGroup,
java.lang.String permission,
OLATResourceable olatResourceable)
secGroup - permission - olatResourceable - java.util.List<Policy> getPoliciesOfSecurityGroup(SecurityGroup secGroup)
secGroup -
java.util.List<SecurityGroup> getGroupsWithPermissionOnOlatResourceable(java.lang.String permission,
OLATResourceable olatResourceable)
permission - olatResourceable -
java.util.List<Identity> getIdentitiesWithPermissionOnOlatResourceable(java.lang.String permission,
OLATResourceable olatResourceable)
permission - olatResourceable -
java.util.List<Identity> getPoliciesOfIdentity(Identity identity)
identity -
Authentication findAuthenticationByAuthusername(java.lang.String authusername,
java.lang.String provider)
authusername - provider -
java.util.List<Identity> getVisibleIdentitiesByPowerSearch(java.lang.String login,
java.util.Map<java.lang.String,java.lang.String> userProperties,
boolean userPropertiesAsIntersectionSearch,
SecurityGroup[] groups,
PermissionOnResourceable[] permissionOnResources,
java.lang.String[] authProviders,
java.util.Date createdAfter,
java.util.Date createdBefore)
login - userPropertyHandlers - Map of user properties that needs to be
matched.userPropertiesAsIntersectionSearch - true: user properties and login
name are combined with an AND query; false: user properties and
login name are combined with an OR querygroups - Array of SecurityGroups the user participates in. Search
machtches if user is in any of the groups (OR query)permissionOnResources - Array of resource permissions the user has.
Search machtches if user has any of the permissions (OR query)authProviders - Array of authenticaton providers the user has. Search
machtches if user has any of the authProviders (OR query)createdAfter - date after which the user has been createdcreatedBefore - date before which the user has been created
java.util.List<Identity> getIdentitiesByPowerSearch(java.lang.String login,
java.util.Map<java.lang.String,java.lang.String> userProperties,
boolean userPropertiesAsIntersectionSearch,
SecurityGroup[] groups,
PermissionOnResourceable[] permissionOnResources,
java.lang.String[] authProviders,
java.util.Date createdAfter,
java.util.Date createdBefore,
java.lang.Integer status)
login - userPropertyHandlers - Map of user properties that needs to be
matched.userPropertiesAsIntersectionSearch - true: user properties and login
name are combined with an AND query; false: user properties and
login name are combined with an OR querygroups - Array of SecurityGroups the user participates in. Search
machtches if user is in any of the groups (OR query)permissionOnResources - Array of resource permissions the user has.
Search machtches if user has any of the permissions (OR query)authProviders - Array of authenticaton providers the user has. Search
machtches if user has any of the authProviders (OR query)createdAfter - date after which the user has been createdcreatedBefore - date before which the user has been createdstatus - identity status, define in interface Identity e.g. ACTIV,
LOGIN_DENIED, DELETED
void saveIdentityStatus(Identity identity,
java.lang.Integer status)
identity - Save this identityboolean isIdentityVisible(java.lang.String identityName)
identityName -
java.util.List getSecurityGroupsForIdentity(Identity identity)
identity -
Identity getAndUpdateAnonymousUserForLanguage(java.util.Locale locale)
locale -
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||