Files external functions.  
 More...
|  | 
| static | get_files ($contextid, $component, $filearea, $itemid, $filepath, $filename, $modified=null, $contextlevel=null, $instanceid=null) | 
|  | Return moodle files listing. 
 | 
|  | 
| static | get_files_parameters () | 
|  | Returns description of get_files parameters. 
 | 
|  | 
| static | get_files_returns () | 
|  | Returns description of get_files returns. 
 | 
|  | 
| static | upload ( $contextid, $component, $filearea, $itemid, $filepath, $filename, $filecontent, $contextlevel, $instanceid) | 
|  | Uploading a file to moodle. 
 | 
|  | 
| static | upload_parameters () | 
|  | Returns description of upload parameters. 
 | 
|  | 
| static | upload_returns () | 
|  | Returns description of upload returns. 
 | 
|  | 
Files external functions. 
- Copyright
- 2011 Jerome Mouneyrac 
- License
- http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later 
- Since
- Moodle 2.2 
◆ get_files()
  
  | 
        
          | static core_files_external::get_files | ( |  | $contextid, |  
          |  |  |  | $component, |  
          |  |  |  | $filearea, |  
          |  |  |  | $itemid, |  
          |  |  |  | $filepath, |  
          |  |  |  | $filename, |  
          |  |  |  | $modified = null, |  
          |  |  |  | $contextlevel = null, |  
          |  |  |  | $instanceid = null ) |  | static | 
 
Return moodle files listing. 
- Parameters
- 
  
    | int | $contextid | context id |  | int | $component | component |  | int | $filearea | file area |  | int | $itemid | item id |  | string | $filepath | file path |  | string | $filename | file name |  | int | $modified | timestamp to return files changed after this time. |  | string | $contextlevel | The context level for the file location. |  | int | $instanceid | The instance id for where the file is located. |  
 
- Return values
- 
  
  
- Since
- Moodle 2.9 Returns additional fields (timecreated, filesize, author, license) 
- 
Moodle 2.2 
 
 
◆ get_files_parameters()
  
  | 
        
          | static core_files_external::get_files_parameters | ( |  | ) |  |  | static | 
 
Returns description of get_files parameters. 
- Return values
- 
  
    | external_function_parameters |  |  
 
- Since
- Moodle 2.2 
 
 
◆ get_files_returns()
  
  | 
        
          | static core_files_external::get_files_returns | ( |  | ) |  |  | static | 
 
Returns description of get_files returns. 
- Return values
- 
  
    | external_single_structure |  |  
 
- Since
- Moodle 2.9 Returns additional fields for files (timecreated, filesize, author, license) 
- 
Moodle 2.2 
 
 
◆ upload()
  
  | 
        
          | static core_files_external::upload | ( |  | $contextid, |  
          |  |  |  | $component, |  
          |  |  |  | $filearea, |  
          |  |  |  | $itemid, |  
          |  |  |  | $filepath, |  
          |  |  |  | $filename, |  
          |  |  |  | $filecontent, |  
          |  |  |  | $contextlevel, |  
          |  |  |  | $instanceid ) |  | static | 
 
Uploading a file to moodle. 
- Parameters
- 
  
    | int | $contextid | context id |  | string | $component | component |  | string | $filearea | file area |  | int | $itemid | item id |  | string | $filepath | file path |  | string | $filename | file name |  | string | $filecontent | file content |  | string | $contextlevel | Context level (block, course, coursecat, system, user or module) |  | int | $instanceid | Instance id of the item associated with the context level |  
 
- Return values
- 
  
  
- Since
- Moodle 2.2 
 
 
◆ upload_parameters()
  
  | 
        
          | static core_files_external::upload_parameters | ( |  | ) |  |  | static | 
 
Returns description of upload parameters. 
- Return values
- 
  
    | external_function_parameters |  |  
 
- Since
- Moodle 2.2 
 
 
◆ upload_returns()
  
  | 
        
          | static core_files_external::upload_returns | ( |  | ) |  |  | static | 
 
Returns description of upload returns. 
- Return values
- 
  
    | external_single_structure |  |  
 
- Since
- Moodle 2.2 
 
 
The documentation for this class was generated from the following file: