Differences Between: [Versions 400 and 402] [Versions 400 and 403]
(no description)
File Size: | 138 lines (3 kb) |
Included or required: | 0 times |
Referenced: | 0 times |
Includes or requires: | 0 files |
ContentItem:: (6 methods):
__construct()
setUrl()
setMediaType()
setTitle()
setText()
toJson()
Class: ContentItem - X-Ref
Class to represent a content-item object__construct($type, $placementAdvice = null, $id = null) X-Ref |
Class constructor. param: string $type Class type of content-item param: ContentItemPlacement $placementAdvice Placement object for item (optional) param: string $id URL of content-item (optional) |
setUrl($url) X-Ref |
Set a URL value for the content-item. param: string $url URL value |
setMediaType($mediaType) X-Ref |
Set a media type value for the content-item. param: string $mediaType Media type value |
setTitle($title) X-Ref |
Set a title value for the content-item. param: string $title Title value |
setText($text) X-Ref |
Set a link text value for the content-item. param: string $text Link text value |
toJson($items) X-Ref |
Wrap the content items to form a complete application/vnd.ims.lti.v1.contentitems+json media type instance. return: string param: mixed $items An array of content items or a single item |