Class Version

java.lang.Object
com.unboundid.ldap.sdk.Version

This class provides information about the current version of the UnboundID LDAP SDK for Java.

Note that if you reference the constant values directly in your source code, those constant values may be compiled into your source code directly rather than dynamically replacing them at runtime or when the class is loaded. This means that if you swap out the LDAP SDK library after the source code has been compiled, the already-compiled code may not accurately reflect the values from the version of the LDAP SDK that is actually being used. To avoid that, you may wish to use the provided methods to obtain the values rather than referencing the constants directly (e.g., use getProductName() instead of PRODUCT_NAME).
  • Field Details

    • PRODUCT_NAME

      public static final String PRODUCT_NAME
      The official full product name for the LDAP SDK. For this build, the value is "UnboundID LDAP SDK for Java".
      See Also:
    • SHORT_NAME

      public static final String SHORT_NAME
      The short product name for the LDAP SDK. This will not have any spaces. For this build, the value is "unboundid-ldapsdk".
      See Also:
    • MAJOR_VERSION

      public static final int MAJOR_VERSION
      The major version number for the LDAP SDK. For this build, the value is 7.
      See Also:
    • MINOR_VERSION

      public static final int MINOR_VERSION
      The minor version number for the LDAP SDK. For this build, the value is 0.
      See Also:
    • POINT_VERSION

      public static final int POINT_VERSION
      The point version number for the LDAP SDK. For this build, the value is 3.
      See Also:
    • VERSION_QUALIFIER

      public static final String VERSION_QUALIFIER
      The version qualifier string for the LDAP SDK. It will often be a zero-length string, but may be non-empty for special builds that should be tagged in some way (e.g., "-beta1" or "-rc2"). For this build, the value is "".
      See Also:
    • BUILD_TIMESTAMP

      public static final String BUILD_TIMESTAMP
      A timestamp that indicates when this build of the LDAP SDK was generated. For this build, the value is "20250725000000Z".
      See Also:
    • REPOSITORY_TYPE

      public static final String REPOSITORY_TYPE
      The type of repository from which the source code used to build the LDAP SDK was retrieved. It will be one of "subversion", "git", or "{unknown}". For this build, the value is "git".
      See Also:
    • REPOSITORY_URL

      public static final String REPOSITORY_URL
      The URL for the repository from which the source code used to build the LDAP SDK was retrieved. If repository information could not be determined at build time, then this will be a file URL that references the path to the source code on the system used to build the LDAP SDK library. For this build, the value is "https://github.com/pingidentity/ldapsdk.git".
      See Also:
    • REPOSITORY_PATH

      public static final String REPOSITORY_PATH
      The path to the LDAP SDK source code in the repository. If repository information could not be determined at build time, then this will be "/". For this build, the value is "{unknown}".
      See Also:
    • REVISION_ID

      public static final String REVISION_ID
      The string representation of the source revision from which this build of the LDAP SDK was generated. For a subversion repository, this will be the string representation of the revision number. For a git repository, this will be the hexadecimal representation of the digest for the most recent commit. If repository information could not be determined at build time, the value will be "{unknown}". For this build, the value is "6580b9a0e188fedfe4c67776aabf1f0b61c06a28".
      See Also:
    • REVISION_NUMBER

      @Deprecated public static final long REVISION_NUMBER
      Deprecated.
      Use the REVISION_ID property instead, since it can handle non-numeric revision identifiers.
      The revision number for the source revision from which this build of the LDAP SDK was generated. For a subversion repository, this will be the revision number. For a git repository (which uses a hexadecimal digest to indicate revisions), or if repository information could not be determined at build time, the value will be -1. For this build, the value is -1.
      See Also:
    • FULL_VERSION_STRING

      public static final String FULL_VERSION_STRING
      The full version string for the LDAP SDK. For this build, the value is "UnboundID LDAP SDK for Java 7.0.3".
      See Also:
    • SHORT_VERSION_STRING

      public static final String SHORT_VERSION_STRING
      The short version string for the LDAP SDK. This will not have any spaces. For this build, the value is "unboundid-ldapsdk-7.0.3".
      See Also:
    • NUMERIC_VERSION_STRING

      public static final String NUMERIC_VERSION_STRING
      The version number string for the LDAP SDK, which contains just the major, minor, and point version, and optional version qualifier. For this build, the version string is "7.0.3".
      See Also:
  • Method Details

    • main

      public static void main(String... args)
      Prints version information from this class to standard output.
      Parameters:
      args - The command-line arguments provided to this program.
    • getProductName

      public static String getProductName()
      Retrieves the official full product name for the LDAP SDK. For this build, the value is "UnboundID LDAP SDK for Java".
      Returns:
      The official full product name for the LDAP SDK.
    • getShortName

      public static String getShortName()
      Retrieves the short product name for the LDAP SDK. This will not have any spaces. For this build, the value is "unboundid-ldapsdk".
      Returns:
      The short product name for the LDAP SDK.
    • getMajorVersion

      public static int getMajorVersion()
      Retrieves the major version number for the LDAP SDK. For this build, the value is 7.
      Returns:
      The major version number for the LDAP SDK.
    • getMinorVersion

      public static int getMinorVersion()
      Retrieves the minor version number for the LDAP SDK. For this build, the value is 0.
      Returns:
      The minor version number for the LDAP SDK.
    • getPointVersion

      public static int getPointVersion()
      Retrieves the point version number for the LDAP SDK. For this build, the value is 3.
      Returns:
      The point version number for the LDAP SDK.
    • getVersionQualifier

      public static String getVersionQualifier()
      Retrieves the version qualifier string for the LDAP SDK. It will often be a zero-length string, but may be non-empty for special builds that should be tagged in some way (e.g., "-beta1" or "-rc2"). For this build, the value is "".
      Returns:
      The version qualifier string for the LDAP SDK.
    • getBuildTimestamp

      public static String getBuildTimestamp()
      Retrieves a timestamp that indicates when this build of the LDAP SDK was generated. For this build, the value is "20250725000000Z".
      Returns:
      A timestamp that indicates when this build of the LDAP SDK was generated.
    • getRepositoryType

      public static String getRepositoryType()
      Retrieves the type of repository from which the source code used to build the LDAP SDK was retrieved. It will be one of "subversion", "git", or "{unknown}". For this build, the value is "git".
      Returns:
      The type of repository from which the source code used to build the LDAP SDK was retrieved.
    • getRepositoryURL

      public static String getRepositoryURL()
      Retrieves the URL for the repository from which the source code used to build the LDAP SDK was retrieved. If repository information could not be determined at build time, then this will be a file URL that references the path to the source code on the system used to build the LDAP SDK library. For this build, the value is "https://github.com/pingidentity/ldapsdk.git".
      Returns:
      The URL for the repository from which the source code used to build the LDAP SDK was retrieved.
    • getRepositoryPath

      public static String getRepositoryPath()
      Retrieves the path to the LDAP SDK source code in the repository. If repository information could not be determined at build time, then this will be "/". For this build, the value is "{unknown}".
      Returns:
      The path to the LDAP SDK source code in the repository.
    • getRevisionID

      public static String getRevisionID()
      Retrieves the string representation of the source revision from which this build of the LDAP SDK was generated. For a subversion repository, this will be the string representation of the revision number. For a git repository, this will be the hexadecimal representation of the digest for the most recent commit. If repository information could not be determined at build time, the value will be "{unknown}". For this build, the value is "6580b9a0e188fedfe4c67776aabf1f0b61c06a28".
      Returns:
      The string representation of the source revision from which this build of the LDAP SDK was generated.
    • getFullVersionString

      public static String getFullVersionString()
      Retrieves the full version string for the LDAP SDK. For this build, the value is "UnboundID LDAP SDK for Java 7.0.3".
      Returns:
      The full version string for the LDAP SDK.
    • getShortVersionString

      public static String getShortVersionString()
      Retrieves the short version string for the LDAP SDK. This will not have any spaces. For this build, the value is "unboundid-ldapsdk-7.0.3".
      Returns:
      The short version string for the LDAP SDK.
    • getNumericVersionString

      Retrieves the version number string for the LDAP SDK, which contains just the major, minor, and point version, and optional version qualifier. For this build, the version string is "7.0.3".
      Returns:
      The version number string for the LDAP SDK.
    • getVersionLines

      public static List<String> getVersionLines()
      Retrieves a list of lines containing information about the LDAP SDK version.
      Returns:
      A list of lines containing information about the LDAP SDK version.