This class represents a basic Facebook profile.
拡張: | Object |
実装: | Parcelable |
パッケージ: | facebook |
Profile(String, String, String, String, String, Uri)
Contructor.
public Profile(String id, String firstName, String middleName, String lastName, String name, Uri linkUri)
パラメーター | 説明 |
---|---|
id | The id of the profile. |
firstName | The first name of the profile. Can be null. |
middleName | The middle name of the profile. Can be null. |
lastName | The last name of the profile. Can be null. |
name | The name of the profile. Can be null. |
linkUri | The link for this profile. Can be null. |
getCurrentProfile()
Getter for the profile that is currently logged in to the application.
public static Profile getCurrentProfile()
setCurrentProfile(Profile)
Setter for the profile that is currently logged in to the application. If the access token is invalidated, the current profile will not be updated. It's only updated when there is an explicit logout, login or when permissions change via the LoginManager.
public static void setCurrentProfile(Profile profile)
パラメーター | 説明 |
---|---|
profile | The profile that is currently logged in to the application. |
fetchProfileForCurrentAccessToken()
Fetches and sets the current profile from the current access token.
This should only be called from the UI thread.
public static void fetchProfileForCurrentAccessToken()
getProfilePictureUri(int, int)
Getter for the Uri of the profile picture.
public Uri getProfilePictureUri(int width, int height)
パラメーター | 説明 |
---|---|
width | The desired width for the profile picture. |
height | The desired height for the profile picture. |
getId()
Getter for the id of the profile.
public String getId()
getFirstName()
Getter for the first name of the profile.
public String getFirstName()
getMiddleName()
Getter for the middle name of the profile.
public String getMiddleName()
getLastName()
Getter for the last name of the profile.
public String getLastName()
getName()
Getter for the name of the profile.
public String getName()
getLinkUri()
Getter for the link of the profile.
public Uri getLinkUri()
describeContents()
Describe the kinds of special objects contained in this Parcelable's marshalled representation.
public int describeContents()
describeContents()
public int describeContents()
writeToParcel(Parcel, int)
Flatten this object in to a Parcel.
public void writeToParcel(Parcel dest, int flags)
パラメーター | 説明 |
---|---|
dest | The Parcel in which the object should be written. |
flags | Additional flags about how the object should be written. May be 0 or Parcelable.PARCELABLE_WRITE_RETURN_VALUE. |
writeToParcel(Parcel, int)
public void writeToParcel(Parcel dest, int flags)
パラメーター | 説明 |
---|---|
dest | |
flags |
CREATOR
public static final Creator CREATOR