87 $requests = array_filter( $reqs,
function ( $req ) use (
$name ) {
90 return count( $requests ) === 1 ? reset( $requests ) :
null;
100 if ( !isset( $data[
'label'] ) ) {
101 $data[
'label'] =
new RawMessage(
'$1', $data[
'name'] );
102 } elseif ( is_string( $data[
'label'] ) ) {
103 $data[
'label'] =
new Message( $data[
'label'] );
104 } elseif ( is_array( $data[
'label'] ) ) {
107 if ( !isset( $data[
'help'] ) ) {
108 $data[
'help'] =
new RawMessage(
'$1', $data[
'name'] );
109 } elseif ( is_string( $data[
'help'] ) ) {
110 $data[
'help'] =
new Message( $data[
'help'] );
111 } elseif ( is_array( $data[
'help'] ) ) {
114 $ret =
new static( $data[
'name'], $data[
'label'], $data[
'help'] );
115 foreach ( $data as $k => $v ) {
The Message class deals with fetching and processing of interface message into a variety of formats.
static newFromKey( $key,... $params)
Factory function that is just wrapper for the real constructor.
Variant of the Message class.