Opensocial.Person (v0.9)

Opensocial.Person (v0.9)

NeedsExamples

opensocial.Person

Base interface for all person objects.

Methods

opensocial.Person.getAppData

;String getAppData(key)

Parameters
NameTypeDescription |

Returns
TypeDescription |

Description
Gets the app data for this person that is associated with the specified key.

opensocial.Person.getDisplayName

;String getDisplayName()

Returns
TypeDescription |

Description
Gets a text display name for this person; guaranteed to return a useful string.

opensocial.Person.getField

;String getField(key, opt_params)

Parameters
NameTypeDescription |

Returns
TypeDescription |

Description
Gets data for this person that is associated with the specified key.

opensocial.Person.getId

;String getId()

Returns
TypeDescription |

Description
Gets an ID that can be permanently associated with this person.

opensocial.Person.isOwner

;Boolean isOwner()

Returns
TypeDescription |

Description
Returns true if this person object represents the owner of the current page.

opensocial.Person.isViewer

;Boolean isViewer()

Returns
TypeDescription |

Description
Returns true if this person object represents the currently logged in user.

opensocial.Person.Field

All of the fields that a person has. These are the supported keys for the Person.getField() method.

opensocial.Person.Field.ABOUT_ME

A general statement about the person, specified as a string. Container support for this field is OPTIONAL. This field may be used interchangeably with the string 'aboutMe'.

opensocial.Person.Field.ACTIVITIES

Person's favorite activities, specified as an Array of strings. Container support for this field is OPTIONAL. This field may be used interchangeably with the string 'activities'.

opensocial.Person.Field.ADDRESSES

Addresses associated with the person, specified as an Array of Address es. Container support for this field is OPTIONAL. This field may be used interchangeably with the string 'addresses'.

opensocial.Person.Field.AGE