Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 4.0.x will end 8 May 2023 (12 months).
  • Bug fixes for security issues in 4.0.x will end 13 November 2023 (18 months).
  • PHP version: minimum PHP 7.3.0 Note: the minimum PHP version has increased since Moodle 3.10. PHP 7.4.x is also supported.

Contains the import_strategy_link class.

Copyright: 2020 Jake Dallimore <jrhdallimore@gmail.com>
License: http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
File Size: 71 lines (3 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

import_strategy_link:: (2 methods):
  get_handlers()
  import()


Class: import_strategy_link  - X-Ref

The import_strategy_link class.

The import_strategy_link objects contains the setup steps needed to prepare a resource for import as a URL into Moodle.

get_handlers(array $registrydata, remote_resource $resource)   X-Ref
Get an array of import_handler_info objects representing modules supporting import of the resource.

return: import_handler_info[] the array of import_handler_info objects.
param: array $registrydata the fully populated registry.
param: remote_resource $resource the remote resource.

import(remote_resource $resource, \stdClass $user, \stdClass $course, int $section)   X-Ref
Import the remote resource according to the rules of this strategy.

return: \stdClass the module data.
param: remote_resource $resource the resource to import.
param: \stdClass $user the user to import on behalf of.
param: \stdClass $course the course into which the remote_resource is being imported.
param: int $section the section into which the remote_resource is being imported.