Opensocial.MediaItem (v0.9)
NeedsExamples
- 1 Methods
- 2 opensocial.MediaItem.Field
- 2.1 opensocial.MediaItem.Field.ALBUM_ID
- 2.2 opensocial.MediaItem.Field.CREATED
- 2.3 opensocial.MediaItem.Field.DESCRIPTION
- 2.4 opensocial.MediaItem.Field.DURATION
- 2.5 opensocial.MediaItem.Field.FILE_SIZE
- 2.6 opensocial.MediaItem.Field.ID
- 2.7 opensocial.MediaItem.Field.LANGUAGE
- 2.8 opensocial.MediaItem.Field.LAST_UPDATED
- 2.9 opensocial.MediaItem.Field.LOCATION
- 2.10 opensocial.MediaItem.Field.MIME_TYPE
- 2.11 opensocial.MediaItem.Field.NUM_COMMENTS
- 2.12 opensocial.MediaItem.Field.NUM_VIEWS
- 2.13 opensocial.MediaItem.Field.NUM_VOTES
- 2.14 opensocial.MediaItem.Field.RATING
- 2.15 opensocial.MediaItem.Field.START_TIME
- 2.16 opensocial.MediaItem.Field.TAGGED_PEOPLE
- 2.17 opensocial.MediaItem.Field.TAGS
- 2.18 opensocial.MediaItem.Field.THUMBNAIL_URL
- 2.19 opensocial.MediaItem.Field.TITLE
- 2.20 opensocial.MediaItem.Field.TYPE
- 2.21 opensocial.MediaItem.Field.URL
- 3 opensocial.MediaItem.Type
opensocial.MediaItem
Represents images, movies, and audio. Create a MediaItem object using the opensocial.newMediaItem() method.
Methods
opensocial.MediaItem.getField
;String getField(key, opt_params)
Parameters
NameTypeDescription |
Returns
TypeDescription |
Description
Gets the media item data that's associated with the specified key.
opensocial.MediaItem.setField
;setField(key, data)
Parameters
NameTypeDescription |
Description
Sets data for this media item associated with the given key.
opensocial.MediaItem.Field
All of the fields that media items have. See also: opensocial.MediaItem.getField()
opensocial.MediaItem.Field.ALBUM_ID
string, album to which the media item belongs This field may be used interchangeably with the string 'albumId'.
opensocial.MediaItem.Field.CREATED
string, creation time associated with the media item - assigned by container in UTC This field may be used interchangeably with the string 'created'.
opensocial.MediaItem.Field.DESCRIPTION
string, description of the media item This field may be used interchangeably with the string 'description'.
opensocial.MediaItem.Field.DURATION
integer, for audio/video clips - playtime length in seconds. set to -1/not defined if unknown This field may be used interchangeably with the string 'duration'.
opensocial.MediaItem.Field.FILE_SIZE
long, number of bytes (set to -1/undefined if unknown). This field may be used interchangeably with the string 'fileSize'.
opensocial.MediaItem.Field.ID
string, id Associated with the media item This field may be used interchangeably with the string 'id'.
opensocial.MediaItem.Field.LANGUAGE
string, language associated with the media item in ISO 639-3 format This field may be used interchangeably with the string 'language'.
opensocial.MediaItem.Field.LAST_UPDATED
string, update time associated with the media item - assigned by container in UTC This field may be used interchangeably with the string 'lastUpdated'.
opensocial.MediaItem.Field.LOCATION
opensocial.Address, location corresponding to the media item This field may be used interchangeably with the string 'location'.
opensocial.MediaItem.Field.MIME_TYPE
The MIME type of media, specified as a string. This field may be used interchangeably with the string 'mimeType'.
opensocial.MediaItem.Field.NUM_COMMENTS
integer, number of comments on the photo. This field may be used interchangeably with the string 'numComments'.
opensocial.MediaItem.Field.NUM_VIEWS
integer, number of views for the media item. This field may be used interchangeably with the string 'numViews'.
opensocial.MediaItem.Field.NUM_VOTES
integer, number of votes received for voting. This field may be used interchangeably with the string 'numVotes'.
opensocial.MediaItem.Field.RATING
integer, average rating of the media item on a scale of 0-10. This field may be used interchangeably with the string 'rating'.
opensocial.MediaItem.Field.START_TIME
string, for streaming/live content, time when the content is available. This field may be used interchangeably with the string 'startTime'.
opensocial.MediaItem.Field.TAGGED_PEOPLE
<static> Member of: opensocial.MediaItem.Field.TAGGED_PEOPLE array of strings, array of string (IDs) of people tagged in the media item This field may be used interchangeably with the string 'taggedPeople'.
opensocial.MediaItem.Field.TAGS
array of strings, tags associated with this media item. This field may be used interchangeably with the string 'tags'.
opensocial.MediaItem.Field.THUMBNAIL_URL
<static> Member of: opensocial.MediaItem.Field.THUMBNAIL_URL string, URL to a thumbnail image of the media item This field may be used interchangeably with the string 'thumbnailUrl'.
opensocial.MediaItem.Field.TITLE
string describing the media item This field may be used interchangeably with the string 'title'.
opensocial.MediaItem.Field.TYPE
The type of media, specified as a MediaItem.Type object. This field may be used interchangeably with the string 'type'.
opensocial.MediaItem.Field.URL
A string specifying the URL where the media can be found. This field may be used interchangeably with the string 'url'.
opensocial.MediaItem.Type
The possible types of media items. See also: opensocial.MediaItem.Field
opensocial.MediaItem.Type.AUDIO
This field may be used interchangeably with the string 'audio'.
opensocial.MediaItem.Type.IMAGE
This field may be used interchangeably with the string 'image'.
opensocial.MediaItem.Type.VIDEO
This field may be used interchangeably with the string 'video'.
{{ JsApiAlphaList_(v0.9) }}