Class SlingVersionResolver

java.lang.Object
org.apache.sling.testing.paxexam.SlingVersionResolver
All Implemented Interfaces:
org.ops4j.pax.exam.options.MavenUrlReference.VersionResolver

public class SlingVersionResolver extends Object implements org.ops4j.pax.exam.options.MavenUrlReference.VersionResolver
Sling's Version Resolver for Sling's Options.

NOTE: This file is generated from Sling's Karaf Features

  • Field Details

  • Constructor Details

    • SlingVersionResolver

      public SlingVersionResolver()
      Creates a new SlingVersionResolver.
  • Method Details

    • setVersion

      public String setVersion(String groupId, String artifactId, String version)
      Sets the version of the bundle.
      Parameters:
      groupId - the group ID
      artifactId - the artifact ID
      version - the version
      Returns:
      the previous version, or null
    • setVersionFromProject

      public String setVersionFromProject(String groupId, String artifactId)
      Sets the version of the bundle by using the declared version from Maven project.
      Parameters:
      groupId - the group ID
      artifactId - the artifact ID
      Returns:
      the previous version, or null
    • getVersion

      public String getVersion(String groupId, String artifactId)
      Gets the version of the bundle.
      Specified by:
      getVersion in interface org.ops4j.pax.exam.options.MavenUrlReference.VersionResolver
      Parameters:
      groupId - the group ID
      artifactId - the artifact ID
      Returns:
      the version, or null
    • getJavaVersion

      public static int getJavaVersion()
      Gets the Java major version from System property java.specification.version or 0 in case of error.
      Returns:
      the Java version