Package org.basepom.mojo.dvc.strategy
Class AprVersionStrategy
java.lang.Object
org.basepom.mojo.dvc.strategy.AprVersionStrategy
- All Implemented Interfaces:
Strategy
- Direct Known Subclasses:
TwoDigitsBackwardCompatibleVersionStrategy
Implements Apache versioning strategy for two or three digits. It expects versions formatted as x.y, x.y.z. Versions can have an additional qualifier.
Version A (xa.ya.za) can replace Version B (xb.yb.zb) if xa == xb and xa >= xb. component z is always compatible.
If an additional qualifier exists, the qualifiers must match.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiongetName()
final boolean
isCompatible
(org.apache.maven.artifact.versioning.ComparableVersion expectedVersion, org.apache.maven.artifact.versioning.ComparableVersion resolvedVersion)
-
Constructor Details
-
AprVersionStrategy
public AprVersionStrategy()
-
-
Method Details
-
getName
-
isCompatible
public final boolean isCompatible(org.apache.maven.artifact.versioning.ComparableVersion expectedVersion, org.apache.maven.artifact.versioning.ComparableVersion resolvedVersion) - Specified by:
isCompatible
in interfaceStrategy
- Parameters:
expectedVersion
- The artifact version expected (artifact version b).resolvedVersion
- The proposed artifact version (artifact version a).- Returns:
- True if an artifact with Version b can be replaced by an artifact with Version a.
-