Skip to main content

opensocial.Person


Method​

opensocial.Person.getId​

String getId()
Parameter​

None

Return value​
TypeDescription
StringID
Sample​
var id = viewer.getId();

opensocial.Person.getDisplayName​

String getDisplayName()

Acquires the individual's text display name. If the VIEWER cannot be identified, "Guest" is returned.

Parameter​

None

Return value​
TypeDescription
StringDisplay name
Sample​
var name = viewer.getDisplayName();

opensocial.Person.getField​

Acquires data for the Person linked to the specified key.

String getField(key, opt_params)
Parameter​
NameTypeDescription
keyStringKey for acquiring data. Refer to the Field class for possible values.
opt_paramsMap.<opensocial.DataRequest.DataRequestFieldsObject>
Return value​
TypeDescription
StringData
Sample​
var profileUrl = viewer.getField(opensocial.Person.Field.PROFILE_URL);

opensocial.Person.isViewer​

Returns whether or not this person is a logged-in user.

Boolean isViewer()
Parameter​

None

Return value​
TypeDescription
Boolean"True" if the person is a logged-in user, "false" if not.
Sample​
if (user.isViewer()) {
// ...
} else {
// ...
}

opensocial.Person.isOwner​

Returns whether or not the person is the owner of the current page.

Boolean isOwner()
Parameter​

None

Return value​
TypeDescription
Boolean"True" if the person is the owner of the current page, "false" if not.
Sample​
if (user.isOwner()) {
// ...
} else {
// ...
}

opensocial.Person.Field​

opensocial.Person.Field.ID​

User ID. If the VIEWER cannot be identified, "-1" is returned.

opensocial.Person.Field.NAME​

Not supported.

opensocial.Person.Field.NICKNAME​

The user’s nickname.

opensocial.Person.Field.THUMBNAIL_URL​

The URL of the user’s thumbnail image. This is the URL of the avatar on the profile page. If the VIEWER cannot be identified, a null character is returned. This URL may be changed.

opensocial.Person.Field.PROFILE_URL​

The URL of the user’s profile page.

opensocial.Person.Field.CURRENT_LOCATION​

Not supported.

opensocial.Person.Field.ADDRESSES​

The location of the user. Prefecture only.

opensocial.Person.Field.EMAILS​

Not supported.

opensocial.Person.Field.PHONE_NUMBERS​

Not supported.

opensocial.Person.Field.ABOUT_ME​

The user’s personal introduction.

opensocial.Person.Field.STATUS​

Not supported.

opensocial.Person.Field.PROFILE_SONG​

Not supported.

opensocial.Person.Field.PROFILE_VIDEO​

Not supported.

opensocial.Person.Field.GENDER​

The user’s gender.

opensocial.Person.Field.SEXUAL_ORIENTATION​

Not supported.

opensocial.Person.Field.RELATIONSHIP_STATUS​

Not supported.

opensocial.Person.Field.AGE​

The user’s age.

opensocial.Person.Field.DATE_OF_BIRTH​

The user’s date of birth.

opensocial.Person.Field.BODY_TYPE​

Not supported.

opensocial.Person.Field.ETHNICITY​

Not supported.

opensocial.Person.Field.SMOKER​

Not supported.

opensocial.Person.Field.DRINKER​

Not supported.

opensocial.Person.Field.CHILDREN​

Not supported.

opensocial.Person.Field.PETS​

Not supported.

opensocial.Person.Field.LIVING_ARRANGEMENT​

Not supported.

opensocial.Person.Field.TIME_ZONE​

Not supported.

opensocial.Person.Field.LANGUAGES_SPOKEN​

Not supported.

opensocial.Person.Field.JOBS​

Not supported.

opensocial.Person.Field.JOB_INTERESTS​

Not supported.

opensocial.Person.Field.SCHOOLS​

Not supported.

opensocial.Person.Field.INTERESTS​

The user’s interests.

opensocial.Person.Field.URLS​

Not supported.

opensocial.Person.Field.MUSIC​

Not supported.

opensocial.Person.Field.MOVIES​

Not supported.

opensocial.Person.Field.TV_SHOWS​

Not supported.

opensocial.Person.Field.BOOKS​

Not supported.

opensocial.Person.Field.ACTIVITIES​

Not supported.

opensocial.Person.Field.SPORTS​

Not supported.

opensocial.Person.Field.HEROES​

Not supported.

opensocial.Person.Field.QUOTES​

Not supported.

opensocial.Person.Field.CARS​

Not supported.

opensocial.Person.Field.FOOD​

Not supported.

opensocial.Person.Field.TURN_ONS​

Not supported.

opensocial.Person.Field.TURN_OFFS​

Not supported.

opensocial.Person.Field.TAGS​

Not supported.

opensocial.Person.Field.ROMANCE​

Not supported.

opensocial.Person.Field.SCARED_OF​

Not supported.

opensocial.Person.Field.HAPPIEST_WHEN​

Not supported.

opensocial.Person.Field.FASHION​

Not supported.

opensocial.Person.Field.HUMOR​

Not supported.

opensocial.Person.Field.LOOKING_FOR​

Not supported.

opensocial.Person.Field.RELIGION​

Not supported.

opensocial.Person.Field.POLITICAL_VIEWS​

Not supported.

opensocial.Person.Field.HAS_APP​

Whether or not the application has finished installing.

opensocial.Person.Field.NETWORK_PRESENCE​

mbga.Person.Field​

mbga.Person.Field.JOB_TYPE​

The user’s occupation.

mbga.Person.Field.BLOOD_TYPE​

The user’s blood type.

Revision History​

  • 12/2010
    • Initial Release.