public class Identity extends Object implements Parcelable
Identity
represents a member.
You could put member token
in Identity(String)
to get the Identity
that represents the member.
Parcelable.ClassLoaderCreator<T>, Parcelable.Creator<T>
Modifier and Type | Field and Description |
---|---|
static Parcelable.Creator<Identity> |
CREATOR |
static Identity |
GUEST
Identity represents a guest. |
CONTENTS_FILE_DESCRIPTOR, PARCELABLE_WRITE_RETURN_VALUE
Modifier | Constructor and Description |
---|---|
protected |
Identity() |
|
Identity(String token)
Put member token
in to get the
Identity represents the user. |
Modifier and Type | Method and Description |
---|---|
int |
describeContents() |
String |
getToken()
Gets user token.
|
boolean |
isGuest()
Shows if the
Identity is a guest. |
void |
resetToken(String token)
Reset the member token
of this
Identity . |
String |
toString() |
void |
writeToParcel(Parcel dest,
int flags) |
public static final Parcelable.Creator<Identity> CREATOR
public Identity(@NonNull String token)
Identity
represents the user.token
- Member token.GUEST
protected Identity()
public String getToken()
public boolean isGuest()
Identity
is a guest.Identity
is a guest.public void resetToken(String token)
Identity
.token
- Member token.public int describeContents()
describeContents
in interface Parcelable
public void writeToParcel(Parcel dest, int flags)
writeToParcel
in interface Parcelable