final class ReleaseNumber
Restricted visibility: declared "@visibility root". Code outside that scope must not name this declaration.

A dotted release number such as 8.0.36, and how it compares to others.

Properties§

public string $number

Methods§

public function __construct(public string $number)

Parameters

$numberstringRelease number such as `8.0.36`
public static function fromReported(string $reported): self|null

Reads the number a server reports, ignoring any suffix such as -log or a build note.

Parameters

$reportedstringVersion string of the server, such as `8.0.36-0ubuntu0.22.04.1`

Returns

self|null The number, or null when the string does not start with one
Test cases 1
Called from 1
Calls 2
public function id(): int

Numbers the release as MySQL numbers its own, as in MYSQL_VERSION_ID.

Returns

int Major times ten thousand plus minor times a hundred plus patch
Test cases 1
Called from 2
Calls 1
public function series(): string

Names the series of the release: every number but the last.

Returns

string `8.0` for `8.0.36`, `17` for `17.2`, and the number itself when it has one part
Test cases 1
Called from 1
Calls 4

Test cases 8§

Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.

Dedicated tests 3
Other tests reaching this symbol 5

Relations§

Instantiated in 3
Static calls 1
Method calls 3