In ParseUser class there is method with name "logInInBackground" which provides a login API to ther user.
This method contains three parameter "username", "password" and "LogInCallback" interface.
ParseUser.logInInBackground("username", "password", new LogInCallback() {
public void done(ParseUser user, ParseException e) {
if (user != null) {
// Hooray! The user is logged in.
// User logged in successfully
// call Home Activity
Intent intent = new Intent(LoginActivity.this, HomeActivity.class);
startActivity(intent);
} else {
// Signup failed. Look at the ParseException to see what happened.
// Show Alert of exception
}
}
});
0 Comment(s)