function Random::getGenerator
Same name in other branches
- 10 core/tests/Drupal/TestTools/Random.php \Drupal\TestTools\Random::getGenerator()
Gets the random generator for the utility methods.
Return value
\Drupal\Component\Utility\Random The random generator.
1 call to Random::getGenerator()
- RandomGeneratorTrait::getRandomGenerator in core/
tests/ Drupal/ Tests/ RandomGeneratorTrait.php - Gets the random generator for the utility methods.
File
-
core/
tests/ Drupal/ TestTools/ Random.php, line 25
Class
- Random
- Provides random generator utility static methods.
Namespace
Drupal\TestToolsCode
public static function getGenerator() : RandomUtility {
if (!isset(static::$randomGenerator)) {
static::$randomGenerator = new RandomUtility();
}
return static::$randomGenerator;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.