C# 클래스 Octopus.Client.Model.Versioning.StrictSemanticVersion

파일 보기 프로젝트 열기: OctopusDeploy/Octo.exe 1 사용 예제들

공개 메소드들

메소드 설명
Parse ( string value ) : StrictSemanticVersion

Parses a SemVer string using strict SemVer rules.

StrictSemanticVersion ( StrictSemanticVersion version ) : System

Creates a SemanticVersion from an existing SemanticVersion

StrictSemanticVersion ( int major, int minor, int patch ) : System

Creates a SemanticVersion X.Y.Z

StrictSemanticVersion ( int major, int minor, int patch, IEnumerable releaseLabels, string metadata ) : System

Creates a NuGetVersion X.Y.Z-alpha.1.2#build01

StrictSemanticVersion ( int major, int minor, int patch, string releaseLabel ) : System

Creates a NuGetVersion X.Y.Z-alpha

StrictSemanticVersion ( int major, int minor, int patch, string releaseLabel, string metadata ) : System

Creates a NuGetVersion X.Y.Z-alpha#build01

TryParse ( string value, StrictSemanticVersion &version ) : bool

Parse a version string

보호된 메소드들

메소드 설명
StrictSemanticVersion ( System.Version version, IEnumerable releaseLabels, string metadata, bool preserveMissingComponents = false ) : System
StrictSemanticVersion ( System.Version version, string releaseLabel = null, string metadata = null ) : System
StrictSemanticVersion ( int major, int minor, int patch, int revision, IEnumerable releaseLabels, string metadata ) : System
StrictSemanticVersion ( int major, int minor, int patch, int revision, string releaseLabel, string metadata ) : System

비공개 메소드들

메소드 설명
IsLetterOrDigitOrDash ( char c ) : bool
IsValid ( string s, bool allowLeadingZeros ) : bool
IsValidPart ( char chars, bool allowLeadingZeros ) : bool
IsValidPart ( string s, bool allowLeadingZeros ) : bool
NormalizeVersionValue ( System.Version version ) : System.Version
ParseReleaseLabels ( string releaseLabels ) : IEnumerable
ParseSections ( string value ) : Tuple

Parse the version string into version/release/build The goal of this code is to take the most direct and optimized path to parsing and validating a semver. Regex would be much cleaner, but due to the number of versions created in NuGet Regex is too slow.

메소드 상세

Parse() 공개 정적인 메소드

Parses a SemVer string using strict SemVer rules.
public static Parse ( string value ) : StrictSemanticVersion
value string
리턴 StrictSemanticVersion

StrictSemanticVersion() 공개 메소드

Creates a SemanticVersion from an existing SemanticVersion
public StrictSemanticVersion ( StrictSemanticVersion version ) : System
version StrictSemanticVersion
리턴 System

StrictSemanticVersion() 보호된 메소드

protected StrictSemanticVersion ( System.Version version, IEnumerable releaseLabels, string metadata, bool preserveMissingComponents = false ) : System
version System.Version
releaseLabels IEnumerable
metadata string
preserveMissingComponents bool
리턴 System

StrictSemanticVersion() 보호된 메소드

protected StrictSemanticVersion ( System.Version version, string releaseLabel = null, string metadata = null ) : System
version System.Version
releaseLabel string
metadata string
리턴 System

StrictSemanticVersion() 공개 메소드

Creates a SemanticVersion X.Y.Z
public StrictSemanticVersion ( int major, int minor, int patch ) : System
major int X.y.z
minor int x.Y.z
patch int x.y.Z
리턴 System

StrictSemanticVersion() 공개 메소드

Creates a NuGetVersion X.Y.Z-alpha.1.2#build01
public StrictSemanticVersion ( int major, int minor, int patch, IEnumerable releaseLabels, string metadata ) : System
major int X.y.z
minor int x.Y.z
patch int x.y.Z
releaseLabels IEnumerable Release labels that have been split by the dot separator
metadata string Build metadata
리턴 System

StrictSemanticVersion() 보호된 메소드

protected StrictSemanticVersion ( int major, int minor, int patch, int revision, IEnumerable releaseLabels, string metadata ) : System
major int
minor int
patch int
revision int
releaseLabels IEnumerable
metadata string
리턴 System

StrictSemanticVersion() 보호된 메소드

protected StrictSemanticVersion ( int major, int minor, int patch, int revision, string releaseLabel, string metadata ) : System
major int
minor int
patch int
revision int
releaseLabel string
metadata string
리턴 System

StrictSemanticVersion() 공개 메소드

Creates a NuGetVersion X.Y.Z-alpha
public StrictSemanticVersion ( int major, int minor, int patch, string releaseLabel ) : System
major int X.y.z
minor int x.Y.z
patch int x.y.Z
releaseLabel string Prerelease label
리턴 System

StrictSemanticVersion() 공개 메소드

Creates a NuGetVersion X.Y.Z-alpha#build01
public StrictSemanticVersion ( int major, int minor, int patch, string releaseLabel, string metadata ) : System
major int X.y.z
minor int x.Y.z
patch int x.y.Z
releaseLabel string Prerelease label
metadata string Build metadata
리턴 System

TryParse() 공개 정적인 메소드

Parse a version string
public static TryParse ( string value, StrictSemanticVersion &version ) : bool
value string
version StrictSemanticVersion
리턴 bool