public static function isUuid($value): bool
    {
        if (!static::isStringCastable($value)) {
            return false;
        }

        // http://tools.ietf.org/html/rfc4122
        //
        // UUID                   = time-low "-" time-mid "-"
        //                          time-high-and-version "-"
        //                          clock-seq-and-reserved
        //                          clock-seq-low "-" node
        // time-low               = 4hexOctet
        // time-mid               = 2hexOctet
        // time-high-and-version  = 2hexOctet
        // clock-seq-and-reserved = hexOctet
        // clock-seq-low          = hexOctet
        // node                   = 6hexOctet
        // hexOctet               = hexDigit hexDigit
        // hexDigit =
        //       "0" / "1" / "2" / "3" / "4" / "5" / "6" / "7" / "8" / "9" /
        //       "a" / "b" / "c" / "d" / "e" / "f" /
        //       "A" / "B" / "C" / "D" / "E" / "F"
        $pattern = sprintf(
            '/\A%s-%s-%s-%s%s-%s\z/i',
            '[a-f0-9]{8}',
            '[a-f0-9]{4}',
            '[a-f0-9]{4}',
            '[a-f0-9]{2}',
            '[a-f0-9]{2}',
            '[a-f0-9]{12}'
        );

        $value = str_replace(['urn:', 'uuid:', '{', '}'], '', (string) $value);

        return !!preg_match($pattern, $value);
    }