Class OldStyleVersionComparator

java.lang.Object
com.github.aistomin.maven.browser.OldStyleVersionComparator
All Implemented Interfaces:
VersionComparator

public final class OldStyleVersionComparator
extends Object
implements VersionComparator
The comparator that compares two versions in the old style manner that we had before version 2.0.
Since:
2.0
  • Constructor Details

    • OldStyleVersionComparator

      public OldStyleVersionComparator​(MvnArtifactVersion one, MvnArtifactVersion two)
      Ctor.
      Parameters:
      one - The first version.
      two - The second version.
  • Method Details

    • isFirstBiggerThanSecond

      public Boolean isFirstBiggerThanSecond()
      Description copied from interface: VersionComparator
      Check if the first version is bigger than the second one.
      Specified by:
      isFirstBiggerThanSecond in interface VersionComparator
      Returns:
      True - first version is bigger than the second. False - first version is smaller or equal than the second one.
    • isApplicable

      public Boolean isApplicable()
      Description copied from interface: VersionComparator
      Is this comparator applicable for the provided versions.
      Specified by:
      isApplicable in interface VersionComparator
      Returns:
      True - the comparator is applicable; False - the comparator is not applicable.