com.parse
Class ParseAnonymousUtils

Object
  extended by com.parse.ParseAnonymousUtils

public final class ParseAnonymousUtils
extends Object

Provides utility functions for working with Anonymously logged-in users. Anonymous users have some unique characteristics:


Method Summary
static boolean isLinked(ParseUser user)
          Whether the user is logged in anonymously.
static void logIn(LogInCallback callback)
          Creates an anonymous user in the background.
static bolts.Task<ParseUser> logInInBackground()
          Creates an anonymous user in the background.
 
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

isLinked

public static boolean isLinked(ParseUser user)
Whether the user is logged in anonymously.

Parameters:
user - User to check for anonymity. The user must be logged in on this device.
Returns:
True if the user is anonymous. False if the user is not the current user or is not anonymous.

logInInBackground

public static bolts.Task<ParseUser> logInInBackground()
Creates an anonymous user in the background.

Returns:
A Task that will be resolved when logging in is completed.

logIn

public static void logIn(LogInCallback callback)
Creates an anonymous user in the background.

Parameters:
callback - The callback to execute when anonymous user creation is complete.