Modifier and Type | Method and Description |
---|---|
void |
callResetPasswordFunction(String email,
String newPassword,
Object... args)
Call the reset password function configured to the
Credentials.Provider#EMAIL_PASSWORD provider. |
RealmAsyncTask |
callResetPasswordFunctionAsync(String email,
String newPassword,
Object[] args,
App.Callback<Void> callback)
Call the reset password function configured to the
Credentials.Provider#EMAIL_PASSWORD provider. |
void |
confirmUser(String token,
String tokenId)
Confirms a user with the given token and token id.
|
RealmAsyncTask |
confirmUserAsync(String token,
String tokenId,
App.Callback<Void> callback)
Confirms a user with the given token and token id.
|
void |
registerUser(String email,
String password)
Registers a new user with the given email and password.
|
RealmAsyncTask |
registerUserAsync(String email,
String password,
App.Callback<Void> callback)
Registers a new user with the given email and password.
|
void |
resendConfirmationEmail(String email)
Resend the confirmation for a user to the given email.
|
RealmAsyncTask |
resendConfirmationEmailAsync(String email,
App.Callback<Void> callback)
Resend the confirmation for a user to the given email.
|
void |
resetPassword(String token,
String tokenId,
String newPassword)
Resets the password of a user with the given token, token id, and new password.
|
RealmAsyncTask |
resetPasswordAsync(String token,
String tokenId,
String newPassword,
App.Callback<Void> callback)
Resets the newPassword of a user with the given token, token id, and new password.
|
void |
retryCustomConfirmation(String email)
Retries the custom confirmation on a user for a given email.
|
RealmAsyncTask |
retryCustomConfirmationAsync(String email,
App.Callback<Void> callback)
Retries the custom confirmation on a user for a given email.
|
void |
sendResetPasswordEmail(String email)
Sends a user a password reset email for the given email.
|
RealmAsyncTask |
sendResetPasswordEmailAsync(String email,
App.Callback<Void> callback)
Sends a user a password reset email for the given email.
|
public void registerUser(String email, String password) throws AppException
email
- the email to register with. This will be the username used during log in.password
- the password to associate with the email. The password must be between
6 and 128 characters long.AppException
- if the server failed to register the user.public RealmAsyncTask registerUserAsync(String email, String password, App.Callback<Void> callback)
email
- the email to register with. This will be the username used during log in.password
- the password to associated with the email. The password must be between
6 and 128 characters long.callback
- callback when registration has completed or failed. The callback will always
happen on the same thread as this method is called on.IllegalStateException
- if called from a non-looper thread.AppException
- if the server failed to register the user.public void confirmUser(String token, String tokenId) throws AppException
token
- the confirmation token.tokenId
- the id of the confirmation token.AppException
- if the server failed to confirm the user.public RealmAsyncTask confirmUserAsync(String token, String tokenId, App.Callback<Void> callback)
token
- the confirmation token.tokenId
- the id of the confirmation token.callback
- callback when confirmation has completed or failed. The callback will always
happen on the same thread as this method is called on.IllegalStateException
- if called from a non-looper thread.public void resendConfirmationEmail(String email) throws AppException
email
- the email of the user.AppException
- if the server failed to confirm the user.public RealmAsyncTask resendConfirmationEmailAsync(String email, App.Callback<Void> callback)
email
- the email of the user.callback
- callback when resending the email has completed or failed. The callback will
always happen on the same thread as this method is called on.IllegalStateException
- if called from a non-looper thread.public void retryCustomConfirmation(String email) throws AppException
email
- the email of the user.AppException
- if the server failed to confirm the user.public RealmAsyncTask retryCustomConfirmationAsync(String email, App.Callback<Void> callback)
email
- the email of the user.callback
- callback when retrying the custom confirmation has completed or failed. The callback will
always happen on the same thread as this method is called on.IllegalStateException
- if called from a non-looper thread.public void sendResetPasswordEmail(String email) throws AppException
email
- the email of the user.AppException
- if the server failed to confirm the user.public RealmAsyncTask sendResetPasswordEmailAsync(String email, App.Callback<Void> callback)
email
- the email of the user.callback
- callback when sending the email has completed or failed. The callback will
always happen on the same thread as this method is called on.AppException
- if the server failed to confirm the user.public void callResetPasswordFunction(String email, String newPassword, Object... args) throws AppException
Credentials.Provider#EMAIL_PASSWORD
provider.email
- the email of the user.newPassword
- the new password of the user.args
- any additional arguments provided to the reset function. All arguments must
be able to be converted to JSON compatible values using toString()
.AppException
- if the server failed to confirm the user.public RealmAsyncTask callResetPasswordFunctionAsync(String email, String newPassword, Object[] args, App.Callback<Void> callback)
Credentials.Provider#EMAIL_PASSWORD
provider.email
- the email of the user.newPassword
- the new password of the user.args
- any additional arguments provided to the reset function. All arguments must
be able to be converted to JSON compatible values using toString()
.callback
- callback when the reset has completed or failed. The callback will always
happen on the same thread as this this method is called on.IllegalStateException
- if called from a non-looper thread.public void resetPassword(String token, String tokenId, String newPassword) throws AppException
token
- the reset password token.tokenId
- the id of the reset password token.newPassword
- the new password for the user identified by the token
. The password
must be between 6 and 128 characters long.AppException
- if the server failed to confirm the user.public RealmAsyncTask resetPasswordAsync(String token, String tokenId, String newPassword, App.Callback<Void> callback)
token
- the reset password token.tokenId
- the id of the reset password token.newPassword
- the new password for the user identified by the token
. The password
must be between 6 and 128 characters long.callback
- callback when the reset has completed or failed. The callback will always
happen on the same thread as this this method is called on.IllegalStateException
- if called from a non-looper thread.