public final class DatabaseUserHome extends Object
| Modifier and Type | Method and Description |
|---|---|
static boolean |
checkPassword(String strLogin,
String strPassword,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Check the password for a DatabaseUser
|
static int |
countUserPasswordHistoryFromDate(Timestamp minDate,
int nUserId,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Get the number of password change done by a user since the given date.
|
static DatabaseUser |
create(DatabaseUser databaseUser,
String strPassword,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Creation of an instance of databaseUser
|
static List<Integer> |
findAllExpiredUserId(fr.paris.lutece.portal.service.plugin.Plugin plugin)
Get the list of id of user with the expired status.
|
static DatabaseUser |
findByPrimaryKey(int nKey,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Returns an instance of a DatabaseUser whose identifier is specified in
parameter
|
static int |
findDatabaseUserIdFromLogin(String strLogin,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Get a user id from his login
|
static Collection<DatabaseUser> |
findDatabaseUsersList(fr.paris.lutece.portal.service.plugin.Plugin plugin)
Returns a collection of DatabaseUser objects
|
static List<DatabaseUser> |
findDatabaseUsersListByFilter(DatabaseUserFilter duFilter,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Find DatabaseUsers by filter
|
static Collection<DatabaseUser> |
findDatabaseUsersListForEmail(String strEmail,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Returns a collection of DatabaseUser objects for a email
|
static Collection<DatabaseUser> |
findDatabaseUsersListForLogin(String strLogin,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Returns a collection of DatabaseUser objects for a login
|
static String |
findPasswordByPrimaryKey(int nKey,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Returns the password of the specified user
|
static List<Integer> |
getIdUsersToSendFirstAlert(Timestamp firstAlertMaxDate,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Get the list of id of users that need to receive their first alert
|
static List<Integer> |
getIdUsersToSendOtherAlert(Timestamp alertMaxDate,
Timestamp timeBetweenAlerts,
int maxNumberAlerts,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Get the list of id of users that need to receive their first alert
|
static List<Integer> |
getIdUsersWithExpiredLifeTimeList(Timestamp currentTimestamp,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Get the list of id of users that have an expired time life but not the
expired status
|
static List<Integer> |
getIdUsersWithExpiredPasswordsList(Timestamp currentTimestamp,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Get the list of id of users that have an expired password but not the
change password flag
|
static int |
getNbAccountLifeTimeNotification(int nIdUser,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Get the number of notification send to a user to warn him about the
expiration of his account
|
static void |
insertNewPasswordInHistory(String strPassword,
int nUserId,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Log a password change in the password history
|
static void |
remove(DatabaseUser databaseUser,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Remove the databaseUser whose identifier is specified in parameter
|
static void |
removeAllPasswordHistoryForUser(int nUserId,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Remove every password saved in the password history for a user.
|
static List<String> |
selectUserPasswordHistory(int nUserID,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Gets the history of password of the given user
|
static DatabaseUser |
update(DatabaseUser databaseUser,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Update of the databaseUser which is specified in parameter
|
static void |
updateChangePassword(List<Integer> listIdUser,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Set the "change password" flag of users to true
|
static void |
updateNbAlert(List<Integer> listIdUser,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Increment the number of alert send to users by 1
|
static DatabaseUser |
updatePassword(DatabaseUser databaseUser,
String strNewPassword,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Update of the databaseUser which is specified in parameter
|
static DatabaseUser |
updateResetPassword(DatabaseUser user,
boolean bNewValue,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Update of the databaseUser which is specified in parameter
|
static void |
updateUserExpirationDate(int nIdUser,
Timestamp newExpirationDate,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Update the user expiration date with the new values.
|
static void |
updateUserLastLoginDate(String strLogin,
Date dateLastLogin,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Update a user last login date
|
static void |
updateUserStatus(List<Integer> listIdUser,
int nNewStatus,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
Update status of a list of user accounts
|
public static DatabaseUser create(DatabaseUser databaseUser, String strPassword, fr.paris.lutece.portal.service.plugin.Plugin plugin)
databaseUser - The instance of the DatabaseUser which contains the
informations to storestrPassword - The user's passwordplugin - The current plugin using this methodpublic static DatabaseUser update(DatabaseUser databaseUser, fr.paris.lutece.portal.service.plugin.Plugin plugin)
databaseUser - The instance of the DatabaseUser which contains the
data to storeplugin - The current plugin using this methodpublic static DatabaseUser updatePassword(DatabaseUser databaseUser, String strNewPassword, fr.paris.lutece.portal.service.plugin.Plugin plugin)
databaseUser - The instance of the DatabaseUser which contains the
data to storestrNewPassword - The new password to storeplugin - The current plugin using this methodpublic static DatabaseUser updateResetPassword(DatabaseUser user, boolean bNewValue, fr.paris.lutece.portal.service.plugin.Plugin plugin)
user - The instance of the DatabaseUser which contains the data to
storebNewValue - The new value of the reset password attributeplugin - The current plugin using this methodpublic static void remove(DatabaseUser databaseUser, fr.paris.lutece.portal.service.plugin.Plugin plugin)
databaseUser - The DatabaseUser object to removeplugin - The current plugin using this methodpublic static DatabaseUser findByPrimaryKey(int nKey, fr.paris.lutece.portal.service.plugin.Plugin plugin)
nKey - The Primary key of the databaseUserplugin - The current plugin using this methodpublic static Collection<DatabaseUser> findDatabaseUsersList(fr.paris.lutece.portal.service.plugin.Plugin plugin)
plugin - The current plugin using this methodpublic static Collection<DatabaseUser> findDatabaseUsersListForLogin(String strLogin, fr.paris.lutece.portal.service.plugin.Plugin plugin)
strLogin - The login of the databseUserplugin - The current plugin using this methodpublic static Collection<DatabaseUser> findDatabaseUsersListForEmail(String strEmail, fr.paris.lutece.portal.service.plugin.Plugin plugin)
strEmail - The email of the databseUserplugin - The current plugin using this methodpublic static String findPasswordByPrimaryKey(int nKey, fr.paris.lutece.portal.service.plugin.Plugin plugin)
nKey - The Primary key of the databaseUserplugin - The current plugin using this methodpublic static boolean checkPassword(String strLogin, String strPassword, fr.paris.lutece.portal.service.plugin.Plugin plugin)
strLogin - The user login of DatabaseUserstrPassword - The password of DatabaseUserplugin - The Plugin using this data access servicepublic static List<DatabaseUser> findDatabaseUsersListByFilter(DatabaseUserFilter duFilter, fr.paris.lutece.portal.service.plugin.Plugin plugin)
duFilter - filterplugin - The pluginpublic static int findDatabaseUserIdFromLogin(String strLogin, fr.paris.lutece.portal.service.plugin.Plugin plugin)
strLogin - The login of the userplugin - The pluginpublic static List<String> selectUserPasswordHistory(int nUserID, fr.paris.lutece.portal.service.plugin.Plugin plugin)
nUserID - Id of the userplugin - The pluginpublic static int countUserPasswordHistoryFromDate(Timestamp minDate, int nUserId, fr.paris.lutece.portal.service.plugin.Plugin plugin)
minDate - Minimum date to consider.nUserId - Id of the userplugin - The pluginpublic static void insertNewPasswordInHistory(String strPassword, int nUserId, fr.paris.lutece.portal.service.plugin.Plugin plugin)
strPassword - New password of the usernUserId - Id of the userplugin - The pluginpublic static void removeAllPasswordHistoryForUser(int nUserId,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
nUserId - Id of the userplugin - The pluginpublic static List<Integer> findAllExpiredUserId(fr.paris.lutece.portal.service.plugin.Plugin plugin)
plugin - The pluginpublic static List<Integer> getIdUsersWithExpiredLifeTimeList(Timestamp currentTimestamp, fr.paris.lutece.portal.service.plugin.Plugin plugin)
currentTimestamp - Timestamp describing the current time.plugin - The pluginpublic static List<Integer> getIdUsersToSendFirstAlert(Timestamp firstAlertMaxDate, fr.paris.lutece.portal.service.plugin.Plugin plugin)
firstAlertMaxDate - The maximum expiration date to send first alert.plugin - The pluginpublic static List<Integer> getIdUsersToSendOtherAlert(Timestamp alertMaxDate, Timestamp timeBetweenAlerts, int maxNumberAlerts, fr.paris.lutece.portal.service.plugin.Plugin plugin)
alertMaxDate - The maximum date to send alerts.timeBetweenAlerts - Timestamp describing the time between two
alerts.maxNumberAlerts - Maximum number of alerts to send to a userplugin - The pluginpublic static List<Integer> getIdUsersWithExpiredPasswordsList(Timestamp currentTimestamp, fr.paris.lutece.portal.service.plugin.Plugin plugin)
currentTimestamp - Timestamp describing the current time.plugin - The pluginpublic static void updateUserStatus(List<Integer> listIdUser, int nNewStatus, fr.paris.lutece.portal.service.plugin.Plugin plugin)
listIdUser - List of user accounts to updatenNewStatus - New status of the userplugin - The pluginpublic static void updateNbAlert(List<Integer> listIdUser, fr.paris.lutece.portal.service.plugin.Plugin plugin)
listIdUser - The list of users to updateplugin - The pluginpublic static void updateChangePassword(List<Integer> listIdUser, fr.paris.lutece.portal.service.plugin.Plugin plugin)
listIdUser - The list of users to updateplugin - The pluginpublic static void updateUserExpirationDate(int nIdUser,
Timestamp newExpirationDate,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
nIdUser - Id of the user to updatenewExpirationDate - Id of the user to updateplugin - The pluginpublic static int getNbAccountLifeTimeNotification(int nIdUser,
fr.paris.lutece.portal.service.plugin.Plugin plugin)
nIdUser - Id of the userplugin - The pluginpublic static void updateUserLastLoginDate(String strLogin, Date dateLastLogin, fr.paris.lutece.portal.service.plugin.Plugin plugin)
strLogin - Login of the user to updatedateLastLogin - date of the last login of the userplugin - The pluginCopyright © 2016 City of Paris. All rights reserved.