Same filename and directory in other branches
- 8.9.x core/lib/Drupal/Component/Uuid/Uuid.php
- 9 core/lib/Drupal/Component/Uuid/Uuid.php
Namespace
Drupal\Component\Uuid
File
core/lib/Drupal/Component/Uuid/Uuid.php
View source
<?php
namespace Drupal\Component\Uuid;
class Uuid {
const VALID_PATTERN = '[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}';
public static function isValid($uuid) {
return (bool) preg_match('/^' . self::VALID_PATTERN . '$/', $uuid);
}
}
Classes
Name |
Description |
Uuid |
UUID Helper methods. |