Package org.apache.turbine.om.security

Examples of org.apache.turbine.om.security.Group


                {
                    throw new DataBackendException(
                            "Internal error - query returned "
                            + results.size() + " rows");
                }
                Group newGroup = (Group) results.get(0);
                // add the group to system-wide cache
                getAllGroups().add(newGroup);
                // return the object with correct id
                return newGroup;
            }
View Full Code Here


     */
    public Group getGroup( String name )
        throws DataBackendException, UnknownEntityException
    {
        GroupSet groups = getAllGroups();
        Group group = groups.getGroup(name);
        if(group != null)
        {
            return group;
        }
        else
View Full Code Here

            // foreach group in the system
            Iterator groupsIterator = getAllGroups().elements();
            while(groupsIterator.hasNext())
            {
                Group group = (Group)groupsIterator.next();
                // get roles of user in the group
                RoleSet groupRoles = RolePeer.retrieveSet( user, group );
                // put the Set into roles(group)
                roles.put(group, groupRoles);
                // collect all permissoins in this group
View Full Code Here

                {
                    throw new DataBackendException(
                        "Internal error - query returned " +
                        results.size() + " rows");
                }
                Group newGroup = (Group)results.get(0);
                // add the group to system-wide cache
                getAllGroups().add(newGroup);
                // return the object with correct id
                return newGroup;
            }
View Full Code Here

        Vector results = new Vector();

        // Populate the object(s).
        for ( int i=0; i<rows.size(); i++ )
        {
            Group obj = TurbineSecurity.getNewGroup(null);
            Record row = (Record)rows.elementAt(i);
            ((SecurityObject)obj).setPrimaryKey( row.getValue(1).asInt() );
            ((SecurityObject)obj).setName( row.getValue(2).asString() );
            byte[] objectData = (byte[])row.getValue(3).asBytes();
            Map temp = (Map)ObjectUtils.deserialize(objectData);
View Full Code Here

            return false;
        }
        Iterator groups = groupset.elements();
        while(groups.hasNext())
        {
            Group group = (Group)groups.next();
            RoleSet roles = getRoles(group);
            if(roles != null)
            {
                if(roles.contains(role))
                {
View Full Code Here

            return false;
        }
        Iterator groups = groupset.elements();
        while(groups.hasNext())
        {
            Group group = (Group)groups.next();
            RoleSet roles = getRoles(group);
            if(roles != null)
            {
                if(roles.contains(role))
                {
View Full Code Here

            return false;
        }
        Iterator groups = groupset.elements();
        while(groups.hasNext())
        {
            Group group = (Group)groups.next();
            PermissionSet permissions = getPermissions(group);
            if(permissions != null)
            {
                if(permissions.contains(permission))
                {
View Full Code Here

            return false;
        }
        Iterator groups = groupset.elements();
        while(groups.hasNext())
        {
            Group group = (Group)groups.next();
            PermissionSet permissions = getPermissions(group);
            if(permissions != null)
            {
                if(permissions.contains(permission))
                {
View Full Code Here

    public boolean contains(String groupName)
    {
        Iterator iter = set.iterator();
        while ( iter.hasNext() )
        {
            Group group = (Group)iter.next();
            if ( groupName != null  &&
                 groupName.equals( group.getName() ) )
            {
                return true;
            }
        }
        return false;
View Full Code Here

TOP

Related Classes of org.apache.turbine.om.security.Group

Copyright © 2018 www.massapicom. 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.