Examples of findSecurityGroupByName()


Examples of org.olat.basesecurity.Manager.findSecurityGroupByName()

    if (usersSyncedAtStartup) {
      try {
        //create user but with different attributes - must fail since user already exists
        User user = UserManager.getInstance().createUser("klaus", "Meier", "klaus@meier.ch");
        Identity identity = securityManager.createAndPersistIdentityAndUser("kmeier", user, "LDAP", "kmeier", null);
        SecurityGroup secGroup = securityManager.findSecurityGroupByName(LDAPConstants.SECURITY_GROUP_LDAP);
        securityManager.addIdentityToSecurityGroup(identity, secGroup);
       
        // simulate closed session (user adding from startup job)
        DBFactory.getInstance().intermediateCommit();
        fail("Expected constrant violation becaus of doupliate entry");     
View Full Code Here

Examples of org.olat.basesecurity.Manager.findSecurityGroupByName()

      assertNull(changedAttrMap);
    } else {
      //create user but with different attributes - must fail since user already exists
      User user = UserManager.getInstance().createUser("klaus", "Meier", "klaus@meier.ch");
      Identity identity = securityManager.createAndPersistIdentityAndUser("kmeier", user, "LDAP", "kmeier", null);
      SecurityGroup secGroup = securityManager.findSecurityGroupByName(LDAPConstants.SECURITY_GROUP_LDAP);
      securityManager.addIdentityToSecurityGroup(identity, secGroup);
      // simulate closed session (user adding from startup job)
      DBFactory.getInstance().intermediateCommit();
     
      //changedAttrMap has 2 changes and uid as entrys (Klaus!=klaus, klaus@olat.org!=klaus@meier.ch)
View Full Code Here

Examples of org.olat.basesecurity.Manager.findSecurityGroupByName()

    DBFactory.getInstance().intermediateCommit();
   
    //create some users in LDAPSecurityGroup
    User user = UserManager.getInstance().createUser("grollia", "wa", "gorrila@olat.org");
    Identity identity = securityManager.createAndPersistIdentityAndUser("gorilla", user, "LDAP", "gorrila", null);
    SecurityGroup secGroup1 = securityManager.findSecurityGroupByName(LDAPConstants.SECURITY_GROUP_LDAP);
    securityManager.addIdentityToSecurityGroup(identity, secGroup1);
    user = UserManager.getInstance().createUser("wer", "immer", "immer@olat.org");
    identity = securityManager.createAndPersistIdentityAndUser("der", user, "LDAP", "der", null);
    securityManager.addIdentityToSecurityGroup(identity, secGroup1);
    user = UserManager.getInstance().createUser("die", "da", "chaspi@olat.org");
View Full Code Here

Examples of org.olat.basesecurity.Manager.findSecurityGroupByName()

   

    //create Users in LDAP Group only existing in OLAT
    User user1 = UserManager.getInstance().createUser("hansi", "hürlima", "hansi@hansli.com");
    Identity identity1 = securityManager.createAndPersistIdentityAndUser("hansi", user1, "LDAP", "hansi", null);
    SecurityGroup secGroup1 = securityManager.findSecurityGroupByName(LDAPConstants.SECURITY_GROUP_LDAP);
    securityManager.addIdentityToSecurityGroup(identity1, secGroup1);
    user1 = UserManager.getInstance().createUser("chaspi", "meier", "chaspi@hansli.com");
    identity1 = securityManager.createAndPersistIdentityAndUser("chaspi", user1, "LDAP", "chaspi", null);
    securityManager.addIdentityToSecurityGroup(identity1, secGroup1);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.