Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 3.10.x will end 8 November 2021 (12 months).
  • Bug fixes for security issues in 3.10.x will end 9 May 2022 (18 months).
  • PHP version: minimum PHP 7.2.0 Note: minimum PHP version has increased since Moodle 3.8. PHP 7.3.x and 7.4.x are supported too.

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.

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

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

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.
return: \stdClass the module data.