Proyectos de Subversion Moodle

Rev

| Ultima modificación | Ver Log |

Rev Autor Línea Nro. Línea
1 efrain 1
<?php
2
// This file is part of Moodle - http://moodle.org/
3
//
4
// This program is free software: you can redistribute it and/or modify
5
// it under the terms of the GNU General Public License as published by
6
// the Free Software Foundation, either version 3 of the License, or
7
// (at your option) any later version.
8
//
9
// This program is distributed in the hope that it will be useful,
10
// but WITHOUT ANY WARRANTY; without even the implied warranty of
11
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12
// GNU General Public License for more details.
13
//
14
// You should have received a copy of the GNU General Public License
15
// along with Moodle.  If not, see <http://www.gnu.org/licenses/>.
16
 
17
/**
18
 * eduSharingAutoloader
19
 *
20
 * makes the namespace EduSharingApiClient autoloadable
21
 * It contains the classes from the external ES API library
22
 *
23
 * @package    mod_edusharing
24
 * @copyright  metaVentis GmbH — http://metaventis.com
25
 * @license    http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
26
 */
27
 
28
defined('MOODLE_INTERNAL') || die();
29
 
30
$mapping = [
31
    'EduSharingApiClient\AppAuthException'           => __DIR__ . '/apiClient/src/EduSharing/AppAuthException.php',
32
    'EduSharingApiClient\CurlHandler'                => __DIR__ . '/apiClient/src/EduSharing/CurlHandler.php',
33
    'EduSharingApiClient\CurlResult'                 => __DIR__ . '/apiClient/src/EduSharing/CurlResult.php',
34
    'EduSharingApiClient\DefaultCurlHandler'         => __DIR__ . '/apiClient/src/EduSharing/DefaultCurlHandler.php',
35
    'EduSharingApiClient\DisplayMode'                => __DIR__ . '/apiClient/src/EduSharing/DisplayMode.php',
36
    'EduSharingApiClient\EduSharingAuthHelper'       => __DIR__ . '/apiClient/src/EduSharing/EduSharingAuthHelper.php',
37
    'EduSharingApiClient\EduSharingHelper'           => __DIR__ . '/apiClient/src/EduSharing/EduSharingHelper.php',
38
    'EduSharingApiClient\EduSharingHelperAbstract'   => __DIR__ . '/apiClient/src/EduSharing/EduSharingHelperAbstract.php',
39
    'EduSharingApiClient\EduSharingHelperBase'       => __DIR__ . '/apiClient/src/EduSharing/EduSharingHelperBase.php',
40
    'EduSharingApiClient\EduSharingNodeHelper'       => __DIR__ . '/apiClient/src/EduSharing/EduSharingNodeHelper.php',
41
    'EduSharingApiClient\EduSharingNodeHelperConfig' => __DIR__ . '/apiClient/src/EduSharing/EduSharingNodeHelperConfig.php',
42
    'EduSharingApiClient\NodeDeletedException'       => __DIR__ . '/apiClient/src/EduSharing/NodeDeletedException.php',
43
    'EduSharingApiClient\UrlHandling'                => __DIR__ . '/apiClient/src/EduSharing/UrlHandling.php',
44
    'EduSharingApiClient\Usage'                      => __DIR__ . '/apiClient/src/EduSharing/Usage.php',
45
    'EduSharingApiClient\UsageDeletedException'      => __DIR__ . '/apiClient/src/EduSharing/UsageDeletedException.php',
46
    'EduSharingApiClient\MissingRightsException'     => __DIR__ . '/apiClient/src/EduSharing/MissingRightsException.php',
47
];
48
 
49
spl_autoload_register(function ($class) use ($mapping) {
50
    isset($mapping[$class]) && require_once($mapping[$class]);
51
});