Class QualifierRestriction

  • All Implemented Interfaces:
    Restriction

    public class QualifierRestriction
    extends Object
    Restricts version qualifier to match one of the provided regular expressions. Qualifier is the part of the version that follows last leading numerical segment of the version. E.g. qualifier in version "1.1.1.Beta.1" is "Beta.1". Delimiter character is stripped.
    • Constructor Detail

      • QualifierRestriction

        public QualifierRestriction​(String[] expressions)
    • Method Detail

      • applies

        public boolean applies​(String version,
                               String originalVersion)
        Description copied from interface: Restriction
        Applies the restriction.
        Parameters:
        version - candidate version string
        originalVersion - original version string
        Returns:
        true if given version passed the restriction test (version can be considered candidate for upgrading)