Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
| Total | |
0.00% |
0 / 9 |
|
0.00% |
0 / 6 |
CRAP | |
0.00% |
0 / 1 |
| common_ext_NamespaceManager | |
0.00% |
0 / 9 |
|
0.00% |
0 / 6 |
42 | |
0.00% |
0 / 1 |
| __construct | |
0.00% |
0 / 1 |
|
0.00% |
0 / 1 |
2 | |||
| singleton | |
0.00% |
0 / 1 |
|
0.00% |
0 / 1 |
2 | |||
| getAllNamespaces | |
0.00% |
0 / 1 |
|
0.00% |
0 / 1 |
2 | |||
| getLocalNamespace | |
0.00% |
0 / 4 |
|
0.00% |
0 / 1 |
2 | |||
| getNamespace | |
0.00% |
0 / 1 |
|
0.00% |
0 / 1 |
2 | |||
| reset | |
0.00% |
0 / 1 |
|
0.00% |
0 / 1 |
2 | |||
| 1 | <?php |
| 2 | |
| 3 | /** |
| 4 | * This program is free software; you can redistribute it and/or |
| 5 | * modify it under the terms of the GNU General Public License |
| 6 | * as published by the Free Software Foundation; under version 2 |
| 7 | * of the License (non-upgradable). |
| 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 this program; if not, write to the Free Software |
| 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. |
| 17 | * |
| 18 | * Copyright (c) 2008-2010 (original work) Deutsche Institut für Internationale Pädagogische Forschung |
| 19 | * (under the project TAO-TRANSFER); |
| 20 | * 2009-2012 (update and modification) Public Research Centre Henri Tudor |
| 21 | * (under the project TAO-SUSTAIN & TAO-DEV); |
| 22 | * 2013 (update and modification) Open Assessment Technologies SA (under the project TAO-PRODUCT); |
| 23 | * |
| 24 | */ |
| 25 | |
| 26 | /** |
| 27 | * Enables you to manage the module namespaces |
| 28 | * |
| 29 | * @access public |
| 30 | * @author Jerome Bogaerts, <jerome.bogaerts@tudor.lu> |
| 31 | * @package generis |
| 32 | * |
| 33 | * @deprecated |
| 34 | */ |
| 35 | class common_ext_NamespaceManager |
| 36 | { |
| 37 | /** |
| 38 | * Private constructor to force the use of the singleton |
| 39 | * |
| 40 | * @access private |
| 41 | * @author Jerome Bogaerts, <jerome.bogaerts@tudor.lu> |
| 42 | * @return mixed |
| 43 | */ |
| 44 | private function __construct() |
| 45 | { |
| 46 | } |
| 47 | |
| 48 | /** |
| 49 | * Main entry point to retrieve the NamespaceManager instance |
| 50 | * |
| 51 | * @access public |
| 52 | * @author Jerome Bogaerts, <jerome.bogaerts@tudor.lu> |
| 53 | * @return common_ext_NamespaceManager |
| 54 | */ |
| 55 | public static function singleton() |
| 56 | { |
| 57 | return new self(); |
| 58 | } |
| 59 | |
| 60 | /** |
| 61 | * Get the list of all module's namespaces |
| 62 | * |
| 63 | * @access public |
| 64 | * @author Jerome Bogaerts, <jerome.bogaerts@tudor.lu> |
| 65 | * @return array |
| 66 | */ |
| 67 | public function getAllNamespaces() |
| 68 | { |
| 69 | return []; |
| 70 | } |
| 71 | |
| 72 | /** |
| 73 | * Conveniance method to retrieve the local Namespace |
| 74 | * |
| 75 | * @access public |
| 76 | * @author Jerome Bogaerts, <jerome.bogaerts@tudor.lu> |
| 77 | * @return common_ext_Namespace |
| 78 | */ |
| 79 | public function getLocalNamespace() |
| 80 | { |
| 81 | return new common_ext_Namespace( |
| 82 | core_kernel_persistence_smoothsql_SmoothModel::DEFAULT_WRITABLE_MODEL, |
| 83 | LOCAL_NAMESPACE . '#' |
| 84 | ); |
| 85 | } |
| 86 | |
| 87 | /** |
| 88 | * Get a namesapce identified by the modelId or modelUri |
| 89 | * |
| 90 | * @access public |
| 91 | * @author Jerome Bogaerts, <jerome.bogaerts@tudor.lu> |
| 92 | * @param $modelid |
| 93 | * @return common_ext_Namespace |
| 94 | */ |
| 95 | public function getNamespace($modelid) |
| 96 | { |
| 97 | return null; |
| 98 | } |
| 99 | |
| 100 | /** |
| 101 | * Reset the current NamespaceManager instance. |
| 102 | * |
| 103 | * @access public |
| 104 | * @author Jerome Bogaerts, <jerome.bogaerts@tudor.lu> |
| 105 | * @return void |
| 106 | */ |
| 107 | public function reset() |
| 108 | { |
| 109 | } |
| 110 | } |