Migrator
in package
Migrator Object
Represents a migration system available in Canvas LMS. This is a read-only object returned by the Content Migrations API when listing available migration systems.
Table of Contents
Properties
- $name : string|null
- Description of the package type expected Example: "Common Cartridge 1.0/1.1/1.2 Package"
- $requiredSettings : array<string|int, string>|null
- A list of fields this system requires
- $requiresFileUpload : bool|null
- Whether this endpoint requires a file upload
- $type : string|null
- The value to pass to the create endpoint Examples: common_cartridge_importer, course_copy_importer, zip_file_importer
Methods
- __construct() : mixed
- Constructor
- getName() : string|null
- getRequiredSettings() : array<string|int, string>|null
- getRequiresFileUpload() : bool|null
- getType() : string|null
- isCanvasCartridge() : bool
- Check if this is a Canvas Cartridge migrator
- isCommonCartridge() : bool
- Check if this is a Common Cartridge migrator
- isCourseCopy() : bool
- Check if this is a course copy migrator
- isFileBased() : bool
- Check if this is a file-based migrator
- isMoodle() : bool
- Check if this is a Moodle migrator
- isQti() : bool
- Check if this is a QTI migrator
- isZipFile() : bool
- Check if this is a ZIP file migrator
- requiresSetting() : bool
- Check if this migrator requires a specific setting
Properties
$name
Description of the package type expected Example: "Common Cartridge 1.0/1.1/1.2 Package"
public
string|null
$name
= null
$requiredSettings
A list of fields this system requires
public
array<string|int, string>|null
$requiredSettings
= null
$requiresFileUpload
Whether this endpoint requires a file upload
public
bool|null
$requiresFileUpload
= null
$type
The value to pass to the create endpoint Examples: common_cartridge_importer, course_copy_importer, zip_file_importer
public
string|null
$type
= null
Methods
__construct()
Constructor
public
__construct([array<string, mixed> $data = [] ]) : mixed
Parameters
- $data : array<string, mixed> = []
getName()
public
getName() : string|null
Return values
string|nullgetRequiredSettings()
public
getRequiredSettings() : array<string|int, string>|null
Return values
array<string|int, string>|nullgetRequiresFileUpload()
public
getRequiresFileUpload() : bool|null
Return values
bool|nullgetType()
public
getType() : string|null
Return values
string|nullisCanvasCartridge()
Check if this is a Canvas Cartridge migrator
public
isCanvasCartridge() : bool
Return values
boolisCommonCartridge()
Check if this is a Common Cartridge migrator
public
isCommonCartridge() : bool
Return values
boolisCourseCopy()
Check if this is a course copy migrator
public
isCourseCopy() : bool
Return values
boolisFileBased()
Check if this is a file-based migrator
public
isFileBased() : bool
Return values
boolisMoodle()
Check if this is a Moodle migrator
public
isMoodle() : bool
Return values
boolisQti()
Check if this is a QTI migrator
public
isQti() : bool
Return values
boolisZipFile()
Check if this is a ZIP file migrator
public
isZipFile() : bool
Return values
boolrequiresSetting()
Check if this migrator requires a specific setting
public
requiresSetting(string $setting) : bool
Parameters
- $setting : string
-
Setting name to check