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.

(no description)

File Size: 210 lines (9 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class


Class: file_node  - X-Ref

Class used to represent a file node in the googledocs repository.

__construct(\stdClass $gdfile)   X-Ref
Constructor.

param: \stdClass $gdfile The Google Drive file object

create_node_array()   X-Ref
Create a repository file array.

This method returns an array which structure is compatible to represent a file node in the repository.

return: array|null The node array or null if the node could not be created

generate_file_title(\stdClass $gdfile)   X-Ref
Generates and returns the title for the file node depending on the type of the Google drive file.

return: string The file title
param: \stdClass $gdfile The Google Drive file object

generate_file_export_format(\stdClass $gdfile)   X-Ref
Generates and returns the file export format depending on the type of the Google drive file.

return: string The file export format
param: \stdClass $gdfile The Google Drive file object

generate_file_link(\stdClass $gdfile)   X-Ref
Generates and returns the external link to the file.

return: string The link to the file
param: \stdClass $gdfile The Google Drive file object