当前位置: 首页>>代码示例>>PHP>>正文


PHP registry::add_class方法代码示例

本文整理汇总了PHP中registry::add_class方法的典型用法代码示例。如果您正苦于以下问题:PHP registry::add_class方法的具体用法?PHP registry::add_class怎么用?PHP registry::add_class使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在registry的用法示例。


在下文中一共展示了registry::add_class方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: __construct

 /**
  * Constructor
  * Initialize all informations for installing/uninstalling plugin
  */
 public function __construct()
 {
     parent::__construct();
     $this->add_data(array('name' => 'Awards', 'code' => 'awards', 'path' => 'awards', 'contact' => 'support@assasinen.5cz.de', 'template_path' => 'plugins/awards/templates/', 'icon' => 'fa fa-list-alt', 'version' => $this->version, 'author' => $this->copyright, 'description' => $this->user->lang('awards_short_desc'), 'long_description' => $this->user->lang('awards_long_desc'), 'homepage' => 'https://eqdkp-plus.eu/', 'manuallink' => 'https://eqdkp-plus.eu/wiki/Plugin:_Awards', 'plus_version' => '2.0', 'build' => $this->build));
     $this->add_dependency(array('plus_version' => '2.0'));
     // -- Register our permissions ------------------------
     // permissions: 'a'=admins, 'u'=user
     // ('a'/'u', Permission-Name, Enable? 'Y'/'N', Language string, array of user-group-ids that should have this permission)
     // Groups: 1 = Guests, 2 = Super-Admin, 3 = Admin, 4 = Member
     $this->add_permission('u', 'view', 'Y', $this->user->lang('view'), array(2, 3, 4));
     $this->add_permission('a', 'add', 'N', $this->user->lang('add'), array(2, 3));
     $this->add_permission('a', 'manage', 'N', $this->user->lang('manage'), array(2, 3));
     // -- PDH Modules -------------------------------------
     $this->add_pdh_read_module('awards_achievements');
     $this->add_pdh_read_module('awards_assignments');
     $this->add_pdh_read_module('awards_library');
     $this->add_pdh_write_module('awards_achievements');
     $this->add_pdh_write_module('awards_assignments');
     // -- Classes -----------------------------------------
     registry::add_class('awards_plugin', 'plugins/awards/classes/', 'awards');
     // -- Routing -----------------------------------------
     $this->routing->addRoute('Awards', 'awards', 'plugins/awards/pageobjects');
     // -- Hooks -------------------------------------------
     $this->add_hook('portal', 'awards_portal_hook', 'portal');
     $this->add_hook('userprofile_customtabs', 'awards_userprofile_customtabs_hook', 'userprofile_customtabs');
     // -- Menu --------------------------------------------
     $this->add_menu('admin', $this->gen_admin_menu());
     $this->add_menu('main', $this->gen_main_menu());
     $this->add_menu('settings', $this->usersettings());
 }
开发者ID:ZerGabriel,项目名称:plugin-awards,代码行数:34,代码来源:awards_plugin_class.php

示例2: __construct

 public function __construct()
 {
     parent::__construct();
     $this->pdh->register_read_module($this->this_game, $this->path . 'pdh/read/' . $this->this_game);
     // Meine Klasse und mein benötigtes PDH Modul
     registry::add_class('wow_arsenal', $this->path . 'arsenal/', 'arsenal');
     $this->pdh->register_read_module('arsenal_character', $this->path . 'pdh/read/arsenal_character');
     $this->pdh->register_write_module('arsenal_character', $this->path . 'pdh/write/arsenal_character');
     $this->importers = array('char_import' => 'charimporter.php', 'char_update' => 'charimporter.php', 'guild_import' => 'guildimporter.php', 'guild_imp_rsn' => false, 'import_data_cache' => false);
 }
开发者ID:ZerGabriel,项目名称:wow_assasinen,代码行数:10,代码来源:wow_assasinen.class.php


注:本文中的registry::add_class方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。