Class SemVerStrategy
- java.lang.Object
-
- com.github.manikmagar.maven.versioner.core.version.AbstractVersionStrategy
-
- com.github.manikmagar.maven.versioner.core.version.SemVerStrategy
-
- All Implemented Interfaces:
VersionStrategy
- Direct Known Subclasses:
VersionPatternStrategy
public class SemVerStrategy extends AbstractVersionStrategy
Create Semantic version string
-
-
Constructor Summary
Constructors Constructor Description SemVerStrategy(int major, int minor, int patch, String branchName, String hashRef)SemVerStrategy(String branchName, String hashRef)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description VersiongetVersion()voidincrement(VersionComponentType type, String hashRef)Increments the version componentStringstrategyName()StringtoVersionString()-
Methods inherited from class com.github.manikmagar.maven.versioner.core.version.AbstractVersionStrategy
getBranchName, getHash, getHashShort, setHash, toString
-
-
-
-
Method Detail
-
strategyName
public String strategyName()
- Specified by:
strategyNamein interfaceVersionStrategy- Overrides:
strategyNamein classAbstractVersionStrategy
-
toVersionString
public String toVersionString()
-
getVersion
public Version getVersion()
-
increment
public void increment(VersionComponentType type, String hashRef)
Description copied from interface:VersionStrategyIncrements the version component- Parameters:
type-VersionComponentTypeto incrementhashRef-Stringhash representing the change log
-
-