ExtensionVersion
final class ExtensionVersion (View source)
| internal |
Provides an extension version value object.
Constants
| CORE_PREFIX |
The '8.x-' prefix is used on contrib extension version numbers. |
Properties
| protected string | $majorVersion | The major version. |
|
| protected string|null | $minorVersion | The minor version. |
|
| protected string|null | $versionExtra | The version extra string. |
Methods
Constructs an extension version object from a version string.
Constructs an ExtensionVersion version object from a support branch.
Gets the major version.
Gets the minor version.
Gets the version extra string at the end of the version number.
Details
static ExtensionVersion
createFromVersionString(string $version_string)
Constructs an extension version object from a version string.
static ExtensionVersion
createFromSupportBranch(string $branch)
Constructs an ExtensionVersion version object from a support branch.
This can be used to determine the major version of the branch. ::getVersionExtra() will always return NULL for branches.
string
getMajorVersion()
Gets the major version.
string|null
getMinorVersion()
Gets the minor version.
string|null
getVersionExtra()
Gets the version extra string at the end of the version number.