if (empty($definition[$required_property])) { throw new BadPluginDefinitionException($plugin_id,
$required_property);
} } } /**
* {@inheritdoc}
*/
protected function findDefinitions() { $definitions = parent::
findDefinitions();
$this->
sortDefinitions($definitions);
return $definitions;
} /**
* Sorts a definitions array.
*
* This sorts the definitions array first by the weight column, and then by
* the plugin ID, ensuring a stable, deterministic, and testable ordering of
* plugins.
*
* @param array $definitions
* The definitions array to sort.
*/