Lines Matching refs:type

34      * Returns a list of available plugins of given type
36 * @param $type string, plugin_type name;
37 * the type of plugin to return,
44 * - plugin names when $type = ''
45 * - or plugin component names when a $type is given
49 public function getList($type = '', $all = false)
53 if (!$type) {
57 if (!isset($this->listByType[$type]['enabled'])) {
58 $this->listByType[$type]['enabled'] = $this->getListByType($type, true);
60 if ($all && !isset($this->listByType[$type]['disabled'])) {
61 $this->listByType[$type]['disabled'] = $this->getListByType($type, false);
65 ? array_merge($this->listByType[$type]['enabled'], $this->listByType[$type]['disabled'])
66 : $this->listByType[$type]['enabled'];
72 * @param $type string type of plugin to load
80 public function load($type, $name, $new = false, $disabled = false)
93 $class = $type . '_plugin_' . $name;
97 if (!empty($DOKU_PLUGINS[$type][$name])) {
98 if ($new || !$DOKU_PLUGINS[$type][$name]->isSingleton()) {
103 return $DOKU_PLUGINS[$type][$name];
131 $DOKU_PLUGINS[$type][$name] = new $class;
138 return $DOKU_PLUGINS[$type][$name];
314 foreach (array('default', 'protected') as $type) {
315 if (array_key_exists($type, $config_cascade['plugins'])) {
316 $this->pluginCascade[$type] = $this->checkRequire($config_cascade['plugins'][$type]);
336 * Returns a list of available plugin components of given type
338 * @param string $type plugin_type name; the type of plugin to return,
341 * @return array of plugin components of requested type
343 protected function getListByType($type, $enabled)
352 if (file_exists(DOKU_PLUGIN . "$plugin/$type.php")) {
357 $typedir = DOKU_PLUGIN . "$plugin/$type/";