Class RepositoryUtils


  • public class RepositoryUtils
    extends Object
    Utility class offering methods that help dealing with PackageVersions and PackageInformations.
    Author:
    Matthias Herlitzius
    • Method Detail

      • getContextPath

        public static String getContextPath()
        Returns the JAXB context-path org.appng.core.xml.repository.
        Returns:
        the context-path
      • isNewer

        public static boolean isNewer​(PackageInfo packageA,
                                      PackageInfo packageB)
        Checks whether packageA is newer than packageB. Comparison is first done by the version and then by the timestamp of the PackageInfo.
        Parameters:
        packageA -
        packageB -
        Returns:
        true if packageA is newer than packageB, false otherwise
        See Also:
        getDate(PackageInfo)
      • isSnapshot

        public static boolean isSnapshot​(String name)
        Check whether the given name represent a snapshot version
        Parameters:
        name - the name
        Returns:
        true if the given name contains "-SNAPSHOT", false otherwise