Class FbUser
Represents a Facebook user. Contains parsed user fields from a Facebook API response, and additional methods to retrieve mode data based on current model state like for example generate user avatar url, etc
Inheritance
Inherited Members
Namespace: StansAssets.Facebook
Assembly: cs.temp.dll.dll
Syntax
public class FbUser
Properties
AgeRange
The age segment for this person expressed as a minimum and maximum age. For example, more than 18, less than 21.
Declaration
public string AgeRange { get; set; }
Property Value
Type | Description |
---|---|
System.String |
Birthday
The person's birthday.
Declaration
public DateTime Birthday { get; set; }
Property Value
Type | Description |
---|---|
DateTime |
The User's primary email address listed on their profile. This field value is System.String.Empty if no valid email address is available.
Declaration
public string Email { get; set; }
Property Value
Type | Description |
---|---|
System.String |
FirstName
The person's first name.
Declaration
public string FirstName { get; set; }
Property Value
Type | Description |
---|---|
System.String |
Gender
The gender selected by this person, Male or Female. If the gender is set to a custom value, this value will be based off of the preferred pronoun; it will be omitted if the preferred pronoun is neutral. Use RawGenderString if you need more details.
Declaration
public FbGender Gender { get; set; }
Property Value
Type | Description |
---|---|
FbGender |
Id
The ID of this person's user account. This ID is unique to each app and cannot be used across different apps.
Declaration
public string Id { get; set; }
Property Value
Type | Description |
---|---|
System.String |
LastName
The person's last name.
Declaration
public string LastName { get; set; }
Property Value
Type | Description |
---|---|
System.String |
Location
The person's current location as entered by them on their profile. This field requires the user_location
permission.
Declaration
public string Location { get; set; }
Property Value
Type | Description |
---|---|
System.String |
Name
Used for test accounts only. Name for this account
Declaration
public string Name { get; set; }
Property Value
Type | Description |
---|---|
System.String |
PictureUrl
The profile picture URL of the Messenger user. The URL will expire.
Declaration
public string PictureUrl { get; set; }
Property Value
Type | Description |
---|---|
System.String |
ProfileUrl
A link to the person's Timeline. The link will only resolve if the person clicking the link is logged into Facebook and is a friend of the person whose profile is being viewed.
Declaration
public string ProfileUrl { get; set; }
Property Value
Type | Description |
---|---|
System.String |
RawGenderString
Raw gender string value.
Declaration
public string RawGenderString { get; set; }
Property Value
Type | Description |
---|---|
System.String |
Methods
GetProfileImage(FbProfileImageSize, Action<Texture2D>)
Download user profile image of a given size
Declaration
public void GetProfileImage(FbProfileImageSize size, Action<Texture2D> callback)
Parameters
Type | Name | Description |
---|---|---|
FbProfileImageSize | size | Requested profile image size |
Action<Texture2D> | callback | Callback with user Texture2D profile image |
GetProfileUrl(FbProfileImageSize, Action<String>)
Generates user profile image URL
Declaration
public void GetProfileUrl(FbProfileImageSize size, Action<string> callback)
Parameters
Type | Name | Description |
---|---|---|
FbProfileImageSize | size | Requested profile image size. |
Action<System.String> | callback | Request callback. |