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


PHP LoggerOptionConverter::findAndSubst方法代码示例

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


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

示例1: setProperties

 public function setProperties($properties, $prefix)
 {
     $len = strlen($prefix);
     while (list($key, ) = each($properties)) {
         if (strpos($key, $prefix) === 0) {
             if (strpos($key, '.', $len + 1) > 0) {
                 continue;
             }
             $value = LoggerOptionConverter::findAndSubst($key, $properties);
             $key = substr($key, $len);
             if ($key == 'layout' and $this->obj instanceof LoggerAppender) {
                 continue;
             }
             $this->setProperty($key, $value);
         }
     }
     $this->activate();
 }
开发者ID:BGCX067,项目名称:ezboss-svn-to-git,代码行数:18,代码来源:LoggerReflectionUtils.php

示例2: parseAdditivityForLogger

 /**
  * Parse the additivity option for a non-root category.
  *
  * @param array $props array of properties
  * @param Logger $cat
  * @param string $loggerName
  */
 private function parseAdditivityForLogger($props, Logger $cat, $loggerName)
 {
     $value = LoggerOptionConverter::findAndSubst(self::ADDITIVITY_PREFIX . $loggerName, $props);
     // touch additivity only if necessary
     if (!empty($value)) {
         $additivity = LoggerOptionConverter::toBoolean($value, true);
         $cat->setAdditivity($additivity);
     }
 }
开发者ID:sacredwebsite,项目名称:scalr,代码行数:16,代码来源:LoggerConfiguratorIni.php

示例3: parseAdditivityForLogger

 /**
  * Parse the additivity option for a non-root category.
  *
  * @param array $props array of properties
  * @param Logger &$cat
  * @param string $loggerName
  */
 function parseAdditivityForLogger($props, &$cat, $loggerName)
 {
     $value = LoggerOptionConverter::findAndSubst(LOG4PHP_LOGGER_PROPERTY_CONFIGURATOR_ADDITIVITY_PREFIX . $loggerName, $props);
     LoggerLog::debug("LoggerPropertyConfigurator::parseAdditivityForLogger() " . "Handling " . LOG4PHP_LOGGER_PROPERTY_CONFIGURATOR_ADDITIVITY_PREFIX . $loggerName . "=[{$value}]");
     // touch additivity only if necessary
     if (!empty($value)) {
         $additivity = LoggerOptionConverter::toBoolean($value, true);
         LoggerLog::debug("LoggerPropertyConfigurator::parseAdditivityForLogger() " . "Setting additivity for [{$loggerName}] to [{$additivity}]");
         $cat->setAdditivity($additivity);
     }
 }
开发者ID:ruckfull,项目名称:taobaocrm,代码行数:18,代码来源:LoggerPropertyConfigurator.php

示例4: setProperties

 /**
  * Set the properites for the object that match the
  * <code>prefix</code> passed as parameter.
  *
  * @param array $properties An array containing keys and values.
  * @param string $prefix Only keys having the specified prefix will be set.
  */
 function setProperties($properties, $prefix)
 {
     LoggerLog::debug("LoggerOptionConverter::setProperties():prefix=[{$prefix}]");
     $len = strlen($prefix);
     while (list($key, ) = each($properties)) {
         if (strpos($key, $prefix) === 0) {
             if (strpos($key, '.', $len + 1) > 0) {
                 continue;
             }
             $value = LoggerOptionConverter::findAndSubst($key, $properties);
             $key = substr($key, $len);
             if ($key == 'layout' && is_a($this->obj, 'loggerappender')) {
                 continue;
             }
             $this->setProperty($key, $value);
         }
     }
     $this->activate();
 }
开发者ID:Bergdahls,项目名称:YetiForceCRM,代码行数:26,代码来源:LoggerPropertySetter.php


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