(no description)
File Size: | 294 lines (12 kb) |
Included or required: | 0 times |
Referenced: | 0 times |
Includes or requires: | 0 files |
resource_link_repository:: (12 methods):
resource_link_from_record()
resource_links_from_records()
record_from_resource_link()
save()
find()
find_by_deployment()
find_by_resource_and_user()
find_by_resource()
exists()
delete()
delete_by_deployment()
delete_by_resource()
Class: resource_link_repository - X-Ref
Class resource_link_repository.resource_link_from_record(\stdClass $record) X-Ref |
Convert a record into an object and return it. return: resource_link a resource_link object. param: \stdClass $record the record from the store. |
resource_links_from_records(array $records) X-Ref |
Get a list of resource_link objects from a list of records. return: array the array of resource_link instances. param: array $records the list of records to transform. |
record_from_resource_link(resource_link $resourcelink) X-Ref |
Get a stdClass object ready for persisting, based on the supplied resource_link object. return: \stdClass the record. param: resource_link $resourcelink the resource link instance. |
save(resource_link $resourcelink) X-Ref |
Save a resource link instance in the store. return: resource_link the saved object. param: resource_link $resourcelink the object to save. |
find(int $id) X-Ref |
Find and return a resource_link by id. return: resource_link|null the resource_link object, or null if the object cannot be found. param: int $id the id of the resource_link object. |
find_by_deployment(deployment $deployment, string $resourcelinkid) X-Ref |
Get a resource by id, within a given tool deployment. return: resource_link|null the resource link instance, or null if not found. param: deployment $deployment the deployment instance. param: string $resourcelinkid the resourcelinkid from the platform. |
find_by_resource_and_user(int $resourceid, int $userid) X-Ref |
Find resource_link objects based on the resource and a given launching user. return: array an array of resource_links param: int $resourceid the local id of the resource (enrol_lti_tools id) param: int $userid the local id of the enrol_lti\local\ltiadvantage\user object |
find_by_resource(int $resourceid) X-Ref |
Gets all mapped resource links for a given resource. return: array the array of resource_link instances. param: int $resourceid the local id of the shared resource. |
exists(int $id) X-Ref |
Check whether or not the given resource_link object exists. return: bool true if found, false otherwise. param: int $id the unique id the resource_link. |
delete(int $id) X-Ref |
Delete a resource_link based on id. param: int $id the id of the resource_link to remove. |
delete_by_deployment(int $deploymentid) X-Ref |
Delete all resource links for a given deployment, as well as any mappings between users and the respective links. param: int $deploymentid the id of the deployment instance. |
delete_by_resource(int $resourceid) X-Ref |
Delete all resource_link instances referring to the resource identified by $resourceid. param: int $resourceid the id of the published resource. |