2013-11-19 12:55:50 +00:00
|
|
|
<?php
|
2013-11-19 13:08:16 +00:00
|
|
|
|
2020-06-29 12:13:29 +00:00
|
|
|
/**
|
|
|
|
|
* @newable
|
2020-07-10 19:23:59 +00:00
|
|
|
* @stable to extend
|
2020-06-29 12:13:29 +00:00
|
|
|
*/
|
2023-06-09 21:50:08 +00:00
|
|
|
class HTMLFormFieldRequiredOptionsException extends InvalidArgumentException {
|
2020-06-29 12:13:29 +00:00
|
|
|
|
|
|
|
|
/**
|
2020-07-10 19:23:59 +00:00
|
|
|
* @stable to call
|
2020-06-29 12:13:29 +00:00
|
|
|
*
|
|
|
|
|
* @param HTMLFormField $field
|
|
|
|
|
* @param array $missing
|
|
|
|
|
*/
|
2013-11-19 12:55:50 +00:00
|
|
|
public function __construct( HTMLFormField $field, array $missing ) {
|
2013-11-19 13:08:16 +00:00
|
|
|
parent::__construct( sprintf( "Form type `%s` expected the following parameters to be set: %s",
|
|
|
|
|
get_class( $field ),
|
|
|
|
|
implode( ', ', $missing ) ) );
|
2013-11-19 12:55:50 +00:00
|
|
|
}
|
2013-11-19 13:08:16 +00:00
|
|
|
}
|