@Component(role=RuntimeInformation.class) public class DefaultRuntimeInformation extends Object implements RuntimeInformation
Constructor and Description |
---|
DefaultRuntimeInformation() |
Modifier and Type | Method and Description |
---|---|
String |
getMavenVersion()
Retrieves the current Maven version, for example "3.0.2".
|
boolean |
isMavenVersion(String versionRange)
Checks whether the current Maven runtime matches the specified version range.
|
public String getMavenVersion()
RuntimeInformation
getMavenVersion
in interface RuntimeInformation
null
.public boolean isMavenVersion(String versionRange)
RuntimeInformation
isMavenVersion
in interface RuntimeInformation
versionRange
- The version range to match the current Maven runtime against, must not be null
.true
if the current Maven runtime matches the specified version range, false
otherwise.Copyright © 2001–2021 The Apache Software Foundation. All rights reserved.