public class AccountManager
extends java.lang.Object
| Modifier | Constructor and Description |
|---|---|
protected |
AccountManager()
Protected Constructor
|
| Modifier and Type | Method and Description |
|---|---|
static void |
deleteToken(Context context,
java.lang.String token)
Delete token.
|
static java.lang.String |
getEmail(Context context,
java.lang.String token)
Return the e-mail address referred to by a token, or null if email
address can't be found ignores expiration of token
|
static EPerson |
getEPerson(Context context,
java.lang.String token)
Return the EPerson corresponding to token, where token was emailed to the
person by either the sendRegistrationInfo or sendForgotPasswordInfo
methods.
|
static void |
sendForgotPasswordInfo(Context context,
java.lang.String email)
Email forgot password info to the given email address.
|
protected static TableRow |
sendInfo(Context context,
java.lang.String email,
boolean isRegister,
boolean send) |
static void |
sendRegistrationInfo(Context context,
java.lang.String email)
Email registration info to the given email address.
|
public static void sendRegistrationInfo(Context context, java.lang.String email) throws java.sql.SQLException, java.io.IOException, javax.mail.MessagingException, AuthorizeException
context - DSpace contextemail - Email address to send the registration email tojava.sql.SQLExceptionjava.io.IOExceptionjavax.mail.MessagingExceptionAuthorizeExceptionpublic static void sendForgotPasswordInfo(Context context, java.lang.String email) throws java.sql.SQLException, java.io.IOException, javax.mail.MessagingException, AuthorizeException
context - DSpace contextemail - Email address to send the forgot-password email tojava.sql.SQLExceptionjava.io.IOExceptionjavax.mail.MessagingExceptionAuthorizeExceptionpublic static EPerson getEPerson(Context context, java.lang.String token) throws java.sql.SQLException, AuthorizeException
Return the EPerson corresponding to token, where token was emailed to the person by either the sendRegistrationInfo or sendForgotPasswordInfo methods.
If the token is not found return null.
context - DSpace contexttoken - Account tokenjava.sql.SQLException - If the token or eperson cannot be retrieved from the
database.AuthorizeExceptionpublic static java.lang.String getEmail(Context context, java.lang.String token) throws java.sql.SQLException
context - DSpace contexttoken - Account tokenjava.sql.SQLExceptionpublic static void deleteToken(Context context, java.lang.String token) throws java.sql.SQLException
context - DSpace contexttoken - The token to deletejava.sql.SQLException - If a database error occursprotected static TableRow sendInfo(Context context, java.lang.String email, boolean isRegister, boolean send) throws java.sql.SQLException, java.io.IOException, javax.mail.MessagingException, AuthorizeException
java.sql.SQLExceptionjava.io.IOExceptionjavax.mail.MessagingExceptionAuthorizeExceptionCopyright © 2018 DuraSpace. All Rights Reserved.