@Experimental public interface VersionParser extends Service
Version
and VersionRange
.Modifier and Type | Method and Description |
---|---|
boolean |
isSnapshot(String version)
Checks whether a given artifact version is considered a
SNAPSHOT or not. |
Version |
parseVersion(String version)
Parses the specified version string, for example "1.0".
|
VersionRange |
parseVersionRange(String range)
Parses the specified version range specification, for example "[1.0,2.0)".
|
@Nonnull Version parseVersion(@Nonnull String version)
version
- The version string to parse, must not be null
.null
.VersionParserException
- If the string violates the syntax rules of this scheme.Session.parseVersion(String)
@Nonnull VersionRange parseVersionRange(@Nonnull String range)
range
- The range specification to parse, must not be null
.null
.VersionParserException
- If the range specification violates the syntax rules of this scheme.Copyright © 2001–2022 The Apache Software Foundation. All rights reserved.