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

java.lang.Objectorg.acs.damsel.srvr.user.UserMgr
- public class UserMgr
- extends java.lang.Object
Class Name: UserMgr
Description: This class contains methods to manage the UserTable. It can be used to set or retrieve users in the DB, as well as update and retrieve specific fields of the UserTable.
- Version:
- 1.1
| Field Summary | |
private org.acs.damsel.srvr.db.AssetDB |
assetDB
|
private static org.apache.log4j.Logger |
log
|
| Constructor Summary | |
UserMgr()
|
|
| Method Summary | |
int |
addAssetToFavorites(org.acs.damsel.srvr.asset.Asset asset,
User user)
Method will take the specified asset and add it to the usersfavorites table in the database along with the username. |
int |
addUser(User user)
Method to add the specified User object to the UserTable of the db. |
java.util.Vector |
getAllUserNames()
Method to return a vector of Strings containing all the user names stored in the UserTable of the db. |
SlideShow |
getSlideShow(java.lang.String ownerName,
java.lang.String slideShowName)
Method will take in a slideShowName and ownerName and fetch a slideShow from the database matching slideShowName. |
java.util.Vector |
getSlideShowAssetFileNames(java.lang.String slideShowName)
This method returns a vector of strings containing all of the names of the assets in the specified slideshow |
java.util.Vector |
getSlideShowNames(User user)
Method returns a vector of strings containing all of the slide shows in the SlideShowTable for the specified User. |
User |
getUserFromName(java.lang.String userName)
Method to return a User object from the specified username String |
org.acs.damsel.srvr.db.Table |
getUserInfo()
Method to return a table containing all the columns in the UsersTable except for the password column. |
java.util.Vector |
getUsersCollections(User user)
Method to return a vector of strings containing the names of all of the collections that can be viewed by the specified user. |
org.acs.damsel.srvr.collection.CollectionView |
getUsersFavorites(User user)
Method will take in a user object and return the associated assets stored in the usersfavorites table in the db as a CollectionView. |
java.util.Vector |
getUsersGroups(java.lang.String userName)
Method to retrieve all of the groups to which the specified user belongs. |
boolean |
isAssetInFavorites(org.acs.damsel.srvr.asset.Asset asset,
User user)
Method will check if the asset is in the user's myFavorites. |
boolean |
isUserInDB(User user)
Method to determine if specified User exists in the db. |
int |
removeAssetFromFavorites(org.acs.damsel.srvr.asset.Asset asset,
User user)
Method will remove the specified asset belonging to the specified user from the userscollections table in the database. |
int |
removeSlideShowAssetFromDB(java.lang.String slideShowName,
java.lang.String assetFileName,
java.lang.String owner)
|
int |
updateUser(User user)
Method to update all of the field in the userstable for the specified user |
| 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 |
UserMgr
public UserMgr()
| Method Detail |
getUserInfo
public org.acs.damsel.srvr.db.Table getUserInfo()
- Method to return a table containing all the columns in the UsersTable
except for the password column.
getAllUserNames
public java.util.Vector getAllUserNames()
- Method to return a vector of Strings containing all the user names stored
in the UserTable of the db.
addUser
public int addUser(User user) throws java.sql.SQLException
- Method to add the specified User object to the UserTable of the db.
isUserInDB
public boolean isUserInDB(User user) throws java.sql.SQLException
- Method to determine if specified User exists in the db.
getUsersCollections
public java.util.Vector getUsersCollections(User user)
- Method to return a vector of strings containing the names of all of the
collections that can be viewed by the specified user.
getUsersFavorites
public org.acs.damsel.srvr.collection.CollectionView getUsersFavorites(User user)
- Method will take in a user object and return the associated assets
stored in the usersfavorites table in the db as a CollectionView.
addAssetToFavorites
public int addAssetToFavorites(org.acs.damsel.srvr.asset.Asset asset, User user)
- Method will take the specified asset and add it to the usersfavorites
table in the database along with the username.
removeAssetFromFavorites
public int removeAssetFromFavorites(org.acs.damsel.srvr.asset.Asset asset, User user)
- Method will remove the specified asset belonging to the specified user
from the userscollections table in the database.
removeSlideShowAssetFromDB
public int removeSlideShowAssetFromDB(java.lang.String slideShowName, java.lang.String assetFileName, java.lang.String owner)
getSlideShow
public SlideShow getSlideShow(java.lang.String ownerName, java.lang.String slideShowName)
- Method will take in a slideShowName and ownerName and fetch a slideShow
from the database matching slideShowName.
getSlideShowNames
public java.util.Vector getSlideShowNames(User user)
- Method returns a vector of strings containing all of the slide shows in the
SlideShowTable for the specified User.
getSlideShowAssetFileNames
public java.util.Vector getSlideShowAssetFileNames(java.lang.String slideShowName)
- This method returns a vector of strings containing all of the names of the
assets in the specified slideshow
isAssetInFavorites
public boolean isAssetInFavorites(org.acs.damsel.srvr.asset.Asset asset, User user)
- Method will check if the asset is in the user's myFavorites.
getUserFromName
public User getUserFromName(java.lang.String userName) throws java.sql.SQLException
- Method to return a User object from the specified username String
updateUser
public int updateUser(User user) throws java.sql.SQLException
- Method to update all of the field in the userstable for the specified
user
getUsersGroups
public java.util.Vector getUsersGroups(java.lang.String userName)
- Method to retrieve all of the groups to which the specified user belongs.
|
|||||||||
| Home >> All >> org >> acs >> damsel >> srvr >> [ user overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC
org.acs.damsel.srvr.user.UserMgr