本文整理汇总了PHP中ilObjRole::_getRolesByAuthMode方法的典型用法代码示例。如果您正苦于以下问题:PHP ilObjRole::_getRolesByAuthMode方法的具体用法?PHP ilObjRole::_getRolesByAuthMode怎么用?PHP ilObjRole::_getRolesByAuthMode使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ilObjRole
的用法示例。
在下文中一共展示了ilObjRole::_getRolesByAuthMode方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: read
/**
* Read settings
*
* @access private
*
*/
private function read()
{
$all_settings = $this->settings->getAll();
$sets = array("radius_active" => "setActive", "radius_port" => "setPort", "radius_shared_secret" => "setSecret", "radius_name" => "setName", "radius_creation" => "enableCreation", "radius_migration" => "enableAccountMigration", "radius_charset" => "setCharset");
foreach ($sets as $s => $m) {
if (isset($all_settings[$s])) {
$this->{$m}($all_settings[$s]);
}
}
reset($all_settings);
foreach ($all_settings as $k => $v) {
if (substr($k, 0, 13) == "radius_server") {
$this->servers[] = $v;
}
}
include_once './Services/AccessControl/classes/class.ilObjRole.php';
$roles = ilObjRole::_getRolesByAuthMode('radius');
$this->default_role = 0;
if (isset($roles[0]) && $roles[0]) {
$this->default_role = $roles[0];
}
}