1 | <?php |
||
23 | class Domains extends BasePlugin |
||
24 | { |
||
25 | /** |
||
26 | * @inheritdoc |
||
27 | */ |
||
28 | public function init() |
||
42 | |||
43 | /** |
||
44 | * @return services\Field |
||
45 | */ |
||
46 | public function getField() |
||
50 | |||
51 | /** |
||
52 | * @return services\Domains |
||
53 | */ |
||
54 | public function getDomains() |
||
58 | |||
59 | /** |
||
60 | * @return services\DomainAssociations |
||
61 | */ |
||
62 | public function getDomainAssociations() |
||
66 | |||
67 | /** |
||
68 | * @return services\Relationship |
||
69 | */ |
||
70 | public function getRelationship() |
||
74 | |||
75 | /******************************************* |
||
76 | * LOGGING |
||
77 | *******************************************/ |
||
78 | |||
79 | /** |
||
80 | * Logs a trace message. |
||
81 | * Trace messages are logged mainly for development purpose to see |
||
82 | * the execution work flow of some code. |
||
83 | * @param string $message the message to be logged. |
||
84 | * @param string $category the category of the message. |
||
85 | */ |
||
86 | public static function trace($message, string $category = null) |
||
90 | |||
91 | /** |
||
92 | * Logs an error message. |
||
93 | * An error message is typically logged when an unrecoverable error occurs |
||
94 | * during the execution of an application. |
||
95 | * @param string $message the message to be logged. |
||
96 | * @param string $category the category of the message. |
||
97 | */ |
||
98 | public static function error($message, string $category = null) |
||
102 | |||
103 | /** |
||
104 | * Logs a warning message. |
||
105 | * A warning message is typically logged when an error occurs while the execution |
||
106 | * can still continue. |
||
107 | * @param string $message the message to be logged. |
||
108 | * @param string $category the category of the message. |
||
109 | */ |
||
110 | public static function warning($message, string $category = null) |
||
114 | |||
115 | /** |
||
116 | * Logs an informative message. |
||
117 | * An informative message is typically logged by an application to keep record of |
||
118 | * something important (e.g. an administrator logs in). |
||
119 | * @param string $message the message to be logged. |
||
120 | * @param string $category the category of the message. |
||
121 | */ |
||
122 | public static function info($message, string $category = null) |
||
126 | |||
127 | /** |
||
128 | * @param string|null $category |
||
129 | * @return string |
||
130 | */ |
||
131 | private static function normalizeCategory(string $category = null) |
||
141 | } |
||
142 |