|
|||||||||
| Home >> All >> org >> acs >> damsel >> srvr >> [ group overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
org.acs.damsel.srvr.group
Class GroupMgr

java.lang.Objectorg.acs.damsel.srvr.group.GroupMgr
- public class GroupMgr
- extends java.lang.Object
Title: GroupMgr
Description: The GroupMgr class provides access to user groups. It can be used to create and remove groups in the database, as well as add and delete users from groups, get a list of all of the groups in the data base, and retrieve the permissions associated with a particular group.
- Version:
- 1.0
| Field Summary | |
private org.acs.damsel.srvr.db.AssetDB |
assetDB
|
private static org.apache.log4j.Logger |
log
|
| Constructor Summary | |
GroupMgr()
Default constructor, throws a SQLException if the UserMgr is not created. |
|
| Method Summary | |
int |
addGroup(Group group)
Method adds the specified group to the database. |
void |
addUserToGroup(java.lang.String userName,
java.lang.String groupName)
Method adds the specified user to the specified group. |
int |
deleteGroup(java.lang.String groupName)
Method deletes the group with the specified name. |
void |
deleteMultipleUsersFromGroup(java.lang.String groupName)
Method deletes all instances of the group name sent from the usersgroupstable. |
Group |
getGroup(java.lang.String groupName)
Method returns a Group object representing the group specified by the input string containing the group name |
java.util.Vector |
getGroupPermissions(java.lang.String groupName)
Method returns the permissions associated with the specified group |
java.util.Vector |
getUsersInGroup(java.lang.String groupName)
Gets all the users in a specified group. |
java.util.Vector |
groupNames()
Method returns a vector of all groups stored in the groupstable of the database. |
boolean |
isGroupInDB(Group ug)
Method returns true if the group exists in the database, false otherwise. |
void |
updateGroup(java.util.Vector updateNames,
java.util.Vector updateValues,
java.lang.String groupName)
Method updates all of the fields in the updateNames with all of the values in the updateValues for the group specified by the groupName. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
assetDB
private org.acs.damsel.srvr.db.AssetDB assetDB
log
private static org.apache.log4j.Logger log
| Constructor Detail |
GroupMgr
public GroupMgr()
- Default constructor, throws a SQLException if the UserMgr is not created.
| Method Detail |
isGroupInDB
public boolean isGroupInDB(Group ug)
- Method returns true if the group exists in the database, false otherwise.
addGroup
public int addGroup(Group group)
- Method adds the specified group to the database.
groupNames
public java.util.Vector groupNames()
- Method returns a vector of all groups stored in the groupstable of the
database.
updateGroup
public void updateGroup(java.util.Vector updateNames, java.util.Vector updateValues, java.lang.String groupName)
- Method updates all of the fields in the updateNames with all of the
values in the updateValues for the group specified by the groupName.
getUsersInGroup
public java.util.Vector getUsersInGroup(java.lang.String groupName)
- Gets all the users in a specified group.
getGroup
public Group getGroup(java.lang.String groupName) throws java.sql.SQLException
- Method returns a Group object representing the group specified by the
input string containing the group name
deleteMultipleUsersFromGroup
public void deleteMultipleUsersFromGroup(java.lang.String groupName)
- Method deletes all instances of the group name sent from the
usersgroupstable. The group will still exist in the groupstable. The
group will not exist in the usersgroupstable. This function is used when
you add and remove users from a group. To make sure you get all users
removed from a group you first must delete everyone in that group and then
add only the ones that you want to be in that group
addUserToGroup
public void addUserToGroup(java.lang.String userName, java.lang.String groupName) throws java.sql.SQLException
- Method adds the specified user to the specified group. Throws an
exception if the user is not added successfully.
deleteGroup
public int deleteGroup(java.lang.String groupName) throws java.sql.SQLException
- Method deletes the group with the specified name.
getGroupPermissions
public java.util.Vector getGroupPermissions(java.lang.String groupName)
- Method returns the permissions associated with the specified group
|
|||||||||
| Home >> All >> org >> acs >> damsel >> srvr >> [ group overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC
org.acs.damsel.srvr.group.GroupMgr