get() 공개 메소드

If that is not present, we return null.
public get ( string $parameter, string $app = null ) : string
$parameter string The configuration value to retrieve.
$app string The application to get the value for.
리턴 string The requested parameter, or null if it is not set.
예제 #1
0
파일: Perms.php 프로젝트: horde/horde
 /**
  * Given a permission name, returns the title for that permission by
  * looking it up in the applications's permission api.
  *
  * @param string $name  The permissions's name.
  *
  * @return string  The title for the permission.
  */
 public function getTitle($name)
 {
     if ($name === Horde_Perms::ROOT) {
         return Horde_Core_Translation::t("All Permissions");
     }
     $levels = explode(':', $name);
     if (count($levels) == 1) {
         return $this->_registry->get('name', $name) . ' (' . $name . ')';
     }
     array_pop($levels);
     // This is the permission name
     /* First level is always app. */
     $app = $levels[0];
     $app_perms = $this->getApplicationPermissions($app);
     return isset($app_perms['title'][$name]) ? $app_perms['title'][$name] . ' (' . $this->_perms->getShortName($name) . ')' : $this->_perms->getShortName($name);
 }