Correct a parameter order swap in "diffusion.historyquery" for Mercurial
[phabricator.git] / src / applications / config / option / PhabricatorNotificationConfigOptions.php
blobe92017d2c51eddfb21f30ff7363ec75cdd27a957
1 <?php
3 final class PhabricatorNotificationConfigOptions
4 extends PhabricatorApplicationConfigOptions {
6 public function getName() {
7 return pht('Notifications');
10 public function getDescription() {
11 return pht('Configure real-time notifications.');
14 public function getIcon() {
15 return 'fa-bell';
18 public function getGroup() {
19 return 'core';
22 public function getOptions() {
23 $servers_type = 'cluster.notifications';
24 $servers_help = $this->deformat(pht(<<<EOTEXT
25 Provide a list of notification servers to enable real-time notifications.
27 For help setting up notification servers, see **[[ %s | %s ]]** in the
28 documentation.
29 EOTEXT
31 PhabricatorEnv::getDoclink(
32 'Notifications User Guide: Setup and Configuration'),
33 pht('Notifications User Guide: Setup and Configuration')));
35 $servers_example1 = array(
36 array(
37 'type' => 'client',
38 'host' => 'phabricator.mycompany.com',
39 'port' => 22280,
40 'protocol' => 'https',
42 array(
43 'type' => 'admin',
44 'host' => '127.0.0.1',
45 'port' => 22281,
46 'protocol' => 'http',
50 $servers_example1 = id(new PhutilJSON())->encodeAsList(
51 $servers_example1);
53 return array(
54 $this->newOption('notification.servers', $servers_type, array())
55 ->setHidden(true)
56 ->setSummary(pht('Configure real-time notifications.'))
57 ->setDescription($servers_help)
58 ->addExample(
59 $servers_example1,
60 pht('Simple Example')),