25use Wikimedia\ObjectFactory;
144 if ( isset( $this->config[$key] ) ) {
145 $this->config[$key] = array_merge( $this->config[$key],
$value );
147 $this->config[$key] =
$value;
160 $this->singletons = [
179 if ( !isset( $this->singletons[
'loggers'][$channel] ) ) {
182 $spec = isset( $this->config[
'loggers'][$channel] ) ?
183 $this->config[
'loggers'][$channel] :
184 $this->config[
'loggers'][
'@default'];
187 $this->singletons[
'loggers'][$channel] = $monolog;
190 return $this->singletons[
'loggers'][$channel];
200 $obj =
new Logger( $channel );
202 if ( isset( $spec[
'calls'] ) ) {
203 foreach ( $spec[
'calls'] as $method => $margs ) {
204 call_user_func_array( [ $obj, $method ], $margs );
208 if ( isset( $spec[
'processors'] ) ) {
209 foreach ( $spec[
'processors'] as $processor ) {
210 $obj->pushProcessor( $this->
getProcessor( $processor ) );
214 if ( isset( $spec[
'handlers'] ) ) {
215 foreach ( $spec[
'handlers'] as
$handler ) {
216 $obj->pushHandler( $this->
getHandler( $handler ) );
228 if ( !isset( $this->singletons[
'processors'][$name] ) ) {
229 $spec = $this->config[
'processors'][
$name];
230 $processor = ObjectFactory::getObjectFromSpec( $spec );
231 $this->singletons[
'processors'][
$name] = $processor;
233 return $this->singletons[
'processors'][
$name];
242 if ( !isset( $this->singletons[
'handlers'][$name] ) ) {
243 $spec = $this->config[
'handlers'][
$name];
244 $handler = ObjectFactory::getObjectFromSpec( $spec );
245 if ( isset( $spec[
'formatter'] ) ) {
250 if ( isset( $spec[
'buffer'] ) && $spec[
'buffer'] ) {
255 return $this->singletons[
'handlers'][
$name];
264 if ( !isset( $this->singletons[
'formatters'][$name] ) ) {
265 $spec = $this->config[
'formatters'][
$name];
266 $formatter = ObjectFactory::getObjectFromSpec( $spec );
267 $this->singletons[
'formatters'][
$name] = $formatter;
269 return $this->singletons[
'formatters'][
$name];
Allows to change the fields on the form that will be generated $name
this hook is for auditing only or null if authentication failed before getting that far or null if we can t even determine that probably a stub it is not rendered in wiki pages or galleries in category pages allow injecting custom HTML after the section Any uses of the hook need to handle escaping see BaseTemplate::getToolbox and BaseTemplate::makeListItem for details on the format of individual items inside of this array or by returning and letting standard HTTP rendering take place modifiable or by returning false and taking over the output modifiable modifiable after all normalizations have been except for the $wgMaxImageArea check set to true or false to override the $wgMaxImageArea check result gives extension the possibility to transform it themselves $handler