Examples of removeMember()


Examples of org.apache.catalina.tribes.membership.Membership.removeMember()

        Membership merged = new Membership(local,AbsoluteOrder.comp,true);
        Arrays.fill(merged,msg.getMembers());
        Arrays.fill(merged,getMembers());
        Member[] diff = Arrays.diff(merged,membership,local);
        for ( int i=0; i<diff.length; i++ ) {
            if (!alive(diff[i])) merged.removeMember((MemberImpl)diff[i]);
            else memberAdded(diff[i],false);
        }
        fireInterceptorEvent(new CoordinationEvent(CoordinationEvent.EVT_POST_MERGE,this,"Post merge"));
        return merged;
    }
View Full Code Here

Examples of org.apache.cocoon.components.repository.PrincipalProvider.removeMember()

            Principal caller = new Principal(caller_principal_name, caller_principal_password);
            PrincipalGroup principalgroup = new PrincipalGroup(principal_group_name);
            Principal principal = new Principal(principal_name);

            principalprovider.removeMember(caller, principalgroup, principal);

        } catch (ComponentException ce) {
            if (getLogger().isDebugEnabled())
                getLogger().debug("Could not lookup for component.", ce);
            throw new ProcessingException("Could not lookup for component.", ce);
View Full Code Here

Examples of org.apache.felix.useradmin.impl.role.GroupImpl.removeMember()

        assertTrue(group.addRequiredMember(role2));

        assertEquals(1, group.getMembers().length);
        assertEquals(1, group.getRequiredMembers().length);
       
        assertTrue(group.removeMember(role1));

        assertNull(group.getMembers());
        assertEquals(1, group.getRequiredMembers().length);
    }
View Full Code Here

Examples of org.apache.felix.useradmin.impl.role.GroupImpl.removeMember()

        assertTrue(group.addRequiredMember(role2));

        assertEquals(1, group.getMembers().length);
        assertEquals(1, group.getRequiredMembers().length);
       
        assertTrue(group.removeMember(role2));

        assertEquals(1, group.getMembers().length);
        assertNull(group.getRequiredMembers());
    }
View Full Code Here

Examples of org.apache.felix.useradmin.impl.role.GroupImpl.removeMember()

        assertTrue(group.addRequiredMember(role2));

        assertEquals(1, group.getMembers().length);
        assertEquals(1, group.getRequiredMembers().length);
       
        assertFalse(group.removeMember(role3));

        assertEquals(1, group.getMembers().length);
        assertEquals(1, group.getRequiredMembers().length);
    }
}
View Full Code Here

Examples of org.apache.jackrabbit.api.security.user.Group.removeMember()

            if (membersToDelete != null) {
                for (String member : membersToDelete) {
                   
                    Authorizable memberAuthorizable = getAuthorizable(baseResource, member,userManager,resolver);
                    if (memberAuthorizable != null) {
                        group.removeMember(memberAuthorizable);
                        changed = true;
                    }

                }
            }
View Full Code Here

Examples of org.apache.jackrabbit.api.security.user.Group.removeMember()

        } finally {
            if (newUserId != null) {
                Authorizable u = userMgr.getAuthorizable(newUserId);
                if (u != null) {
                    if (newGroup != null) {
                        newGroup.removeMember(u);
                    }
                    u.remove();
                }
            }
            if (newGroup != null) {
View Full Code Here

Examples of org.apache.jackrabbit.api.security.user.Group.removeMember()

            Authorizable a = userMgr.getAuthorizable(otherUID);
            if (a != null) {
                for (Iterator<Group> it = a.memberOf(); it.hasNext();) {
                    Group gr = it.next();
                    if (!gr.getPrincipal().equals(EveryonePrincipal.getInstance())) {
                        gr.removeMember(a);
                    }
                }
                a.remove();
            }
            a = userMgr.getAuthorizable(uID);
View Full Code Here

Examples of org.apache.jackrabbit.api.security.user.Group.removeMember()

                        }
                    }

                    // 2. adjust members of the group
                    for (Authorizable m : toRemove.values()) {
                        if (!gr.removeMember(m)) {
                            handleFailure("Failed remove existing member (" + m + ") from " + gr);
                        }
                    }
                    for (Authorizable m : toAdd) {
                        if (!gr.addMember(m)) {
View Full Code Here

Examples of org.apache.jackrabbit.api.security.user.Group.removeMember()

        // adding and removing the test user as member of a group must succeed.
        try {
            assertTrue("Modifying group membership requires GroupAdmin membership.",gr.addMember(cU));
            save(uSession);
        } finally {
            gr.removeMember(cU);
            save(uSession);
        }
    }

    public void testAddToGroup2() throws RepositoryException, NotExecutableException {
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.