|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object | +--blackboard.platform.security.SecurityDbUtil
A utility class that encapsulates database operations that are frequently performed by blackboard.platform.security classes and/or classes within its sub-package. SecurityDbUtil
| Constructor Summary | |
SecurityDbUtil()
|
|
| Method Summary | |
static boolean |
getCreateAccountAllowed(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
getCreateAccountAllowed() Convenience method to determine whether users may create new accounts. |
static EntitlementDbLoader |
getEntitlementDbLoader()
Returns the EntitlementDbLoader instance associated with
the default instance of the database BbPersistenceManager.
|
static java.lang.String |
getForgotPasswordUrl()
getForgotPasswordUrl() Convenience method to determine whether users may request their password. |
static java.lang.String |
getGlobalKey(javax.servlet.http.HttpServletRequest request,
java.lang.String name)
getGlobalKey |
static boolean |
getGuestAllowed(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
getGuestAllowed() Convenience method to determine whether guests may access Blackboard installation. |
static Id |
getId(java.sql.ResultSet rs,
java.lang.String col1,
java.lang.String col2,
DataType dataType,
Container container)
Load the Id given the Resultset and the Container |
static java.lang.String |
getPassportHrefUrl(javax.servlet.http.HttpServletRequest request)
getPassportHrefUrl Returns the URL for the HREF tag |
static java.lang.String |
getPassportImgUrl(javax.servlet.http.HttpServletRequest request)
getPassportImgUrl Returns the URL for the IMG tags |
static java.lang.String |
getPassportLogoTag(javax.servlet.http.HttpServletRequest request)
getPassportLogoTag Returns the HREF and IMG tags, stored in the SESSION_INDS table, concatenated together in a single String. |
static boolean |
getPortalDirectEntry(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse res)
getPortalDirectEntry() Convenience method to determine whether guests may access Blackboard installation |
static boolean |
getRetrievePasswordAllowed(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
getRetrievePasswordAllowed() Convenience method to determine whether users may request their password. |
static java.lang.String |
getSoftwareTitle(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse res)
getSoftwareTitle() Convenience method to determine the proper name for this Blackboard system |
static Id |
getUserId(java.sql.ResultSet rs)
Load the Id given the Resultset |
static Id |
getUserId(java.sql.ResultSet rs,
Container container)
Load the Id given the Resultset and the Container
using USER_DATA_TYPE and default connection |
static void |
setGlobalKey(javax.servlet.http.HttpServletRequest request,
java.lang.String name,
java.lang.String value)
setGlobalKey |
static void |
setPassportLogoTag(javax.servlet.http.HttpServletRequest request)
setPassportLogoTag Parses the "passport-logo-tag" header into separate variables and sets the values. |
static void |
setUserId(java.sql.CallableStatement stmt,
int pk1ColNum,
int pk2ColNum,
Id targetId)
setUserId |
static void |
setUserId(java.sql.PreparedStatement ps,
int pk1ColNum,
int pk2ColNum,
Id targetId)
setUserId |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public SecurityDbUtil()
| Method Detail |
public static EntitlementDbLoader getEntitlementDbLoader()
EntitlementDbLoader instance associated with
the default instance of the database BbPersistenceManager.
BbPersistenceManager bbPm = BbServiceManager.getPersistenceService().getDbPersistenceManager(); entitlementLoader = (EntitlementDbLoader) bbPm.getLoader ( EntitlementDbLoader.TYPE );
EntitlementDbLoader instance associated with the
default database persistence manager
PersistenceException - if an error occurs when trying to retrieve
the EntitlementDbLoader instancepublic static Id getUserId(java.sql.ResultSet rs)
Id given the Resultset
rs - the ResultSet of the Id to be loaded
public static Id getUserId(java.sql.ResultSet rs,
Container container)
Id given the Resultset and the Container
using USER_DATA_TYPE and default connection
rs - the ResultSet of the Id to be loadedcontainer - the Container from which the Id is be loaded
public static Id getId(java.sql.ResultSet rs,
java.lang.String col1,
java.lang.String col2,
DataType dataType,
Container container)
Id given the Resultset and the Container
rs - the ResultSet of the Id to be loadedcol1 - the field name used when unmarshalling the rscol2 - the field name used when unmarshalling the rsdataType - to use when unmarshalling the rscontainer - the Container from which the Id is be loaded
public static void setUserId(java.sql.PreparedStatement ps,
int pk1ColNum,
int pk2ColNum,
Id targetId)
throws java.sql.SQLException
ps - the PreparedStatement used to set the Id userIdpk1ColNum - the column number used in the PreparedStatementpk2ColNum - the column number used in the PreparedStatementtargetId - to use in the PreparedStatement
java.sql.SQLException
public static void setUserId(java.sql.CallableStatement stmt,
int pk1ColNum,
int pk2ColNum,
Id targetId)
throws java.sql.SQLException
stmt - the Callable used to set the Id userIdpk1ColNum - the column number used in the PreparedStatementpk2ColNum - the column number used in the PreparedStatementtargetId - to use in the PreparedStatement
java.sql.SQLException
public static void setGlobalKey(javax.servlet.http.HttpServletRequest request,
java.lang.String name,
java.lang.String value)
throws PersistenceException
request - the HttpServletRequest where the info is storedname - the name of the session variablevalue - the value of the session variable
PersistenceException
public static java.lang.String getGlobalKey(javax.servlet.http.HttpServletRequest request,
java.lang.String name)
throws PersistenceException
request - the HttpServletRequest where the info is storedname - the name of the session variable
String
PersistenceException
public static void setPassportLogoTag(javax.servlet.http.HttpServletRequest request)
throws PersistenceException
request - the HttpServletRequest where the session info is stored
PersistenceException
public static java.lang.String getPassportLogoTag(javax.servlet.http.HttpServletRequest request)
throws PersistenceException
request - the HttpServletRequest where the info is stored
PersistenceException
public static java.lang.String getPassportHrefUrl(javax.servlet.http.HttpServletRequest request)
throws PersistenceException
request - the HttpServletRequest where the info is stored
PersistenceException
public static java.lang.String getPassportImgUrl(javax.servlet.http.HttpServletRequest request)
throws PersistenceException
request - the HttpServletRequest where the info is stored
PersistenceException
public static java.lang.String getSoftwareTitle(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse res)
req - the HttpServletRequestres - the HttpServletResponse
public static boolean getPortalDirectEntry(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse res)
req - the HttpServletRequestres - the HttpServletResponse
public static boolean getGuestAllowed(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
request - the HttpServletRequestresponse - the HttpServletResponse
public static boolean getCreateAccountAllowed(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
public static boolean getRetrievePasswordAllowed(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
public static java.lang.String getForgotPasswordUrl()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||