Core/CafeLib.Core/Support/SemVer.cs
/// <summary>
/// Parses the specified string to a semantic version.
/// </summary>
/// <param name="version">The version string.</param>
/// <param name="semver">When the method returns, contains a SemVersion instance equivalent 
/// to the version string passed in, if the version string was valid, or <c>null</c> if the 
/// version string was not valid.</param>
/// <param name="strict">If set to <c>true</c> minor and patch version are required, else they default to 0.</param>
/// <returns><c>False</c> when a invalid version string is passed, otherwise <c>true</c>.</returns>
Parses the specified string to a semantic version.
Parses the specified string to a semantic version .
public static bool TryParse(string version, out SemVer semver, bool strict = false)
        {
            try
            {
                semver = Parse(version, strict);
                return true;
            }
            catch (Exception)
            {
                semver = default;
                return false;
            }
        }
public static bool TryParse ( string version , out SemVer semver , bool strict = false ) { try { semver = Parse ( version , strict ) ; return true ; } catch ( Exception ) { semver = default ; return false ; } }
Parses the specified string to a semantic version.
Parses the specified string to a semantic version .
None
version
string
The version string.
The version string .
SemVer
out
strict
bool
If set to true
If set to true
semver
When the method returns, contains a SemVersion instance equivalent
to the version string passed in, if the version string was valid, or null
When the method returns contains a SemVersion instance equivalent to the version string passed in if the version string was valid or null