本文整理汇总了PHP中Notifier::__construct方法的典型用法代码示例。如果您正苦于以下问题:PHP Notifier::__construct方法的具体用法?PHP Notifier::__construct怎么用?PHP Notifier::__construct使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Notifier
的用法示例。
在下文中一共展示了Notifier::__construct方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __construct
public function __construct($url, $token, $room, $prefix = null, $spamTimeout = 60, $icons = [])
{
parent::__construct($spamTimeout);
self::$url = $url;
self::$token = $token;
self::$room = $room;
self::$prefix = $prefix;
self::$icons = $icons + ['sad' => ':thumbsdown:', 'smile' => ':thumbsup::sparkles:', 'error' => ':thumbsdown::shit:'];
}
示例2: __construct
public function __construct($url, $settings = [], $prefix = null, $attachment = [], $spamTimeout = 60)
{
if (!class_exists('\\Maknz\\Slack\\Client')) {
$message = 'Class \\Maknz\\Slack\\Client does not exist. Are you sure you have installed it? i.e. composer require "maknz/slack"';
throw new \Exception($message);
}
parent::__construct($spamTimeout);
self::$url = $url;
self::$prefix = $prefix;
self::$settings = $settings + ['username' => 'Behat', 'channel' => '#general', 'link_names' => true, 'icon' => ':fire:'];
self::$attachment = $attachment + ['fallback' => 'Behat test failed', 'text' => '', 'pretext' => '', 'color' => 'danger', 'fields' => array()];
}
示例3: __construct
public function __construct()
{
parent::__construct();
$this->subCommands = array();
$this->initializeMacroCommand();
}
示例4: __construct
/**
* Constructor.
*
* Your subclass MUST define a constructor, be
* sure to call <b>parent::__construct();</b> to
* have PHP instanciate the whole parent/child chain.
*
* @return void
*/
public function __construct()
{
parent::__construct();
}
示例5: __construct
public function __construct($spamTimeout = 60, $icons = [])
{
parent::__construct($spamTimeout);
$behatchDir = __DIR__ . '/Resources';
self::$icons = $icons + ['sad' => "{$behatchDir}/images/gnome-sad.png", 'smile' => "{$behatchDir}/images/gnome-smile.png", 'error' => "{$behatchDir}/images/gnome-error.png"];
}