function drupal_autoload_trait
drupal_autoload_trait($trait)
Confirms that a trait is available.
This function is rarely called directly. Instead, it is registered as an spl_autoload() handler, and PHP calls it for us when necessary.
Parameters
string $trait: The name of the trait to check or load.
Return value
bool TRUE if the trait is currently available, FALSE otherwise.
Related topics
File
- includes/bootstrap.inc, line 3399
- Functions that need to be loaded on every Drupal request.
Code
function drupal_autoload_trait($trait) { return _registry_check_code('trait', $trait); }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/includes!bootstrap.inc/function/drupal_autoload_trait/7.x