"MDL-17391, document file_type_to_ext class"
authorDongsheng Cai <unoter@gmail.com>
Fri, 13 Nov 2009 08:51:49 +0000 (08:51 +0000)
committerDongsheng Cai <unoter@gmail.com>
Fri, 13 Nov 2009 08:51:49 +0000 (08:51 +0000)
lib/filelib.php

index 1330b6fb0ef1ed59a969ea33e7b5b5ff912200ed..c922dcc225f54989cf4d7cac7a335bc62c5974b8 100644 (file)
@@ -2752,17 +2752,20 @@ class curl_cache {
 }
 
 /**
- * @todo Document this class
+ * This class is used to parse lib/file/file_types.mm which help get file
+ * extensions by file types. 
+ * The file_types.mm file can be edited by freemind in graphic environment.
  *
  * @package moodlecore
  * @subpackage file
- * @copyright 1999 onwards Martin Dougiamas  {@link http://moodle.com}
+ * @copyright 2009 Dongsheng Cai <dongsheng@moodle.com>
  * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
  */
 class file_type_to_ext {
     /**
-     * @todo Document this function
-     * @global object
+     * Check file_types.mm file, setup variables
+     *
+     * @global object $CFG
      * @param string $file
      */
     public function __construct($file = '') {
@@ -2777,7 +2780,8 @@ class file_type_to_ext {
     }
 
     /**
-     * @todo Document this function
+     * A private function to browse xml nodes
+     *
      * @param array $parent
      * @param array $types
      */
@@ -2798,7 +2802,8 @@ class file_type_to_ext {
     }
 
     /**
-     * @todo Document this function
+     * A private function to select text nodes
+     *
      * @param array $parent
      */
     private function _select_nodes($parent){
@@ -2813,7 +2818,8 @@ class file_type_to_ext {
 
 
     /**
-     * @todo Document this function
+     * Get file extensions by file types names.
+     *
      * @param array $types
      * @return mixed
      */