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


PHP OutputFormatter::__construct方法代码示例

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


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

示例1: __construct

 /**
  * @param boolean $decorated
  *
  * @param array $styles
  */
 public function __construct($decorated = false, array $styles = array())
 {
     parent::__construct($decorated, $styles);
     $this->setStyle('pending', new OutputFormatterStyle('yellow'));
     $this->setStyle('pending-bg', new OutputFormatterStyle('black', 'yellow', array('bold')));
     $this->setStyle('skipped', new OutputFormatterStyle('cyan'));
     $this->setStyle('skipped-bg', new OutputFormatterStyle('white', 'cyan', array('bold')));
     $this->setStyle('failed', new OutputFormatterStyle('red'));
     $this->setStyle('failed-bg', new OutputFormatterStyle('white', 'red', array('bold')));
     $this->setStyle('broken', new OutputFormatterStyle('magenta'));
     $this->setStyle('broken-bg', new OutputFormatterStyle('white', 'magenta', array('bold')));
     $this->setStyle('passed', new OutputFormatterStyle('green'));
     $this->setStyle('passed-bg', new OutputFormatterStyle('black', 'green', array('bold')));
     $this->setStyle('value', new OutputFormatterStyle('yellow'));
     $this->setStyle('lineno', new OutputFormatterStyle(null, 'black'));
     $this->setStyle('code', new OutputFormatterStyle('white'));
     $this->setStyle('hl', new OutputFormatterStyle('black', 'yellow', array('bold')));
     $this->setStyle('question', new OutputFormatterStyle('black', 'yellow', array('bold')));
     $this->setStyle('trace', new OutputFormatterStyle());
     $this->setStyle('trace-class', new OutputFormatterStyle('cyan'));
     $this->setStyle('trace-func', new OutputFormatterStyle('cyan'));
     $this->setStyle('trace-type', new OutputFormatterStyle());
     $this->setStyle('trace-args', new OutputFormatterStyle());
     $this->setStyle('diff-add', new OutputFormatterStyle('green'));
     $this->setStyle('diff-del', new OutputFormatterStyle('red'));
 }
开发者ID:duxor,项目名称:GUSLE,代码行数:31,代码来源:Formatter.php

示例2: __construct

 /**
  * Constructor
  *
  * @author Art <a.molcanovas@gmail.com>
  */
 public function __construct()
 {
     parent::__construct();
     self::initStyles();
     foreach (self::$styles as $code => $class) {
         $this->setStyle($code, $class);
     }
 }
开发者ID:aloframework,项目名称:handlers,代码行数:13,代码来源:OutputFormatter.php

示例3: __construct

 public function __construct($decorated = false, array $styles = array())
 {
     parent::__construct(true, $styles);
     $this->setStyle('logo', new OutputFormatterStyle('magenta'));
     $this->setStyle('error', new OutputFormatterStyle('white', 'red'));
     $this->setStyle('comment', new OutputFormatterStyle('magenta', null, array('underscore')));
     $this->setStyle('info', new OutputFormatterStyle('cyan'));
     $this->setStyle('question', new OutputFormatterStyle('black', 'cyan'));
 }
开发者ID:glynnforrest,项目名称:neptune,代码行数:9,代码来源:OutputFormatter.php

示例4: __construct

 /**
  * OutputFormatter constructor.
  *
  * @param bool  $decorated
  * @param array $styles
  */
 public function __construct($decorated = false, array $styles = array())
 {
     parent::__construct($decorated, $styles);
     $this->setStyle('passed', new OutputFormatterStyle('green', null, array()));
     $this->setStyle('passed-bg', new OutputFormatterStyle('black', 'green', array('bold')));
     $this->setStyle('broken', new OutputFormatterStyle('red', null, array()));
     $this->setStyle('broken-bg', new OutputFormatterStyle('white', 'red', array('bold')));
     $this->setStyle('blink', new OutputFormatterStyle(null, null, array('blink')));
 }
开发者ID:akeneo,项目名称:php-coupling-detector,代码行数:15,代码来源:OutputFormatter.php

示例5: __construct

 /**
  * Constructs a new OutputFormatter.
  *
  * @param bool                            $decorated
  * @param OutputFormatterStyleInterface[] $styles
  */
 public function __construct($decorated = false, array $styles = array())
 {
     parent::__construct($decorated, $styles);
     $this->setStyle('title', new OutputFormatterStyle());
     $this->setStyle(LogLevel::EMERGENCY, new OutputFormatterStyle('white', 'red'));
     $this->setStyle(LogLevel::CRITICAL, new OutputFormatterStyle('white', 'red'));
     $this->setStyle(LogLevel::ALERT, new OutputFormatterStyle('white', 'red'));
     $this->setStyle(LogLevel::ERROR, new OutputFormatterStyle('white', 'red'));
     $this->setStyle(LogLevel::WARNING, new OutputFormatterStyle('white', 'red'));
     $this->setStyle(LogLevel::NOTICE, new OutputFormatterStyle());
     $this->setStyle(LogLevel::INFO, new OutputFormatterStyle('black', 'yellow'));
     $this->setStyle(LogLevel::DEBUG, new OutputFormatterStyle());
     $this->setStyle('event-name', new OutputFormatterStyle('yellow'));
     $this->setStyle('event-task-name', new OutputFormatterStyle('yellow'));
     $this->setStyle('event-task-action-in_progress', new OutputFormatterStyle());
     $this->setStyle('event-task-action-failed', new OutputFormatterStyle('red'));
     $this->setStyle('event-task-action-completed', new OutputFormatterStyle('green'));
 }
开发者ID:deborahvandervegt,项目名称:accompli,代码行数:24,代码来源:OutputFormatter.php

示例6: __construct

 /**
  * {@inheritdoc}
  */
 public function __construct($decorated = null, array $styles = array())
 {
     parent::__construct($decorated, array_merge(array('undefined' => new OutputFormatterStyle('yellow'), 'pending' => new OutputFormatterStyle('yellow'), 'pending_param' => new OutputFormatterStyle('yellow', null, array('bold')), 'failed' => new OutputFormatterStyle('red'), 'failed_param' => new OutputFormatterStyle('red', null, array('bold')), 'passed' => new OutputFormatterStyle('green'), 'passed_param' => new OutputFormatterStyle('green', null, array('bold')), 'skipped' => new OutputFormatterStyle('cyan'), 'skipped_param' => new OutputFormatterStyle('cyan', null, array('bold')), 'comment' => new OutputFormatterStyle('black'), 'tag' => new OutputFormatterStyle('cyan')), $styles));
 }
开发者ID:kingsj,项目名称:core,代码行数:7,代码来源:OutputFormatter.php

示例7: __construct

 /**
  * @param array $styles Array of "name => FormatterStyle" instances
  */
 public function __construct(array $styles = array())
 {
     parent::__construct(true, $styles);
 }
开发者ID:bookin,项目名称:yii2-composer-web,代码行数:7,代码来源:BootstrapOutputFormatter.php

示例8: __construct

 public function __construct($decorated = false, array $styles = array())
 {
     parent::__construct($decorated, array_merge($styles, array('success' => new OutputFormatterStyle('black', 'green'), 'notice' => new OutputFormatterStyle('cyan'), 'noticebg' => new OutputFormatterStyle('black', 'cyan'), 'warning' => new OutputFormatterStyle('yellow'), 'error' => new OutputFormatterStyle('red'), 'fatal' => new OutputFormatterStyle('white', 'red'))));
 }
开发者ID:Elsensee,项目名称:phpbb-translation-validator,代码行数:4,代码来源:OutputFormatter.php

示例9: __construct

 public function __construct($decorated = null, array $styles = array())
 {
     parent::__construct(true, array('error' => new OutputFormatterStyle('white', 'red'), 'green' => new OutputFormatterStyle('green'), 'yellow' => new OutputFormatterStyle('yellow'), 'question' => new OutputFormatterStyle('black', 'cyan')));
 }
开发者ID:bonndan,项目名称:release-manager,代码行数:4,代码来源:Formatter.php

示例10: __construct

 public function __construct()
 {
     parent::__construct(NULL, $this->getStyles());
 }
开发者ID:nunodotferreira,项目名称:ApiGen,代码行数:4,代码来源:OutputFormatter.php

示例11: __construct

 /**
  * Initializes console output formatter.
  *
  * @param   Boolean $decorated  Whether this formatter should actually decorate strings
  * @param   array   $styles     Array of "name => FormatterStyle" instance
  *
  * @api
  */
 public function __construct($decorated = null, array $styles = array())
 {
     $styles = array_merge(array('error' => new OutputFormatterStyleHtml('white', 'red'), 'info' => new OutputFormatterStyleHtml('green'), 'comment' => new OutputFormatterStyleHtml('yellow'), 'question' => new OutputFormatterStyleHtml('black', 'cyan')), $styles);
     parent::__construct($decorated, $styles);
     $this->getStyleStack()->setEmptyStyle(new OutputFormatterStyleHtml());
 }
开发者ID:RapotOR,项目名称:ConsoleBundle,代码行数:14,代码来源:OutputFormatterHtml.php

示例12: __construct

 /**
  * {@inheritdoc}
  */
 public function __construct($decorated = false, array $styles = array())
 {
     $this->setStyle('label', new OutputFormatterStyle('yellow', 'black'));
     $this->setStyle('value', new OutputFormatterStyle('green', 'black'));
     parent::__construct($decorated, $styles);
 }
开发者ID:vanslambrouckd,项目名称:geotools,代码行数:9,代码来源:OutputFormatter.php

示例13: __construct

 /**
  * {@inheritdoc}
  */
 public function __construct($decorated = null, array $styles = array())
 {
     parent::__construct($decorated, array_merge(array('emergency' => new OutputFormatterStyle('red'), 'alert' => new OutputFormatterStyle('red'), 'critical' => new OutputFormatterStyle('red'), 'error' => new OutputFormatterStyle('red'), 'warning' => new OutputFormatterStyle('yellow'), 'notice' => new OutputFormatterStyle('cyan'), 'info' => new OutputFormatterStyle('cyan'), 'debug' => new OutputFormatterStyle('blue')), $styles));
 }
开发者ID:zroger,项目名称:feather,代码行数:7,代码来源:OutputFormatter.php


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