Exceptions classes are nearly always value objects, and should in most cases by newable. Bug: T247862 Change-Id: I4faa8ec6ea8bc44086cfc8075b32d10eea61e9df
19 lines
422 B
PHP
19 lines
422 B
PHP
<?php
|
|
|
|
/**
|
|
* @newable
|
|
*/
|
|
class HTMLFormFieldRequiredOptionsException extends MWException {
|
|
|
|
/**
|
|
* @stable for calling
|
|
*
|
|
* @param HTMLFormField $field
|
|
* @param array $missing
|
|
*/
|
|
public function __construct( HTMLFormField $field, array $missing ) {
|
|
parent::__construct( sprintf( "Form type `%s` expected the following parameters to be set: %s",
|
|
get_class( $field ),
|
|
implode( ', ', $missing ) ) );
|
|
}
|
|
}
|