/**
 * Copyright (c) 2020-2021 Qualcomm Technologies, Inc.
 * All Rights Reserved.
 * Qualcomm Technologies Proprietary and Confidential.
 */

/** @file ICPZLicense.idl */

/** @cond */
interface ICPZLicense {
/** @endcond */

  /**
    @addtogroup ICPZLicense
    @{
  */

  /** @cond */
  const uint32 FEATURE_ID_CPZ = 1;
  const uint32 FEATURE_ID_WIDEVINE = 2;
  const uint32 FEATURE_ID_FSP = 3;
  const uint32 FEATURE_ID_PPID = 4;
  const uint32 FEATURE_ID_KM_BCC = 5;

  error ERROR_BUSY_TRY_AGAIN;              /**< Service busy, please try again. */
  error ERROR_FAILED_TO_CHECK_LICENSE;     /**< License check not successful.   */
  error ERROR_FAILED_TO_GET_LICENSE;       /**< License parsing failed.         */
  error ERROR_FAILED_TO_VERIFY_LICENSE;    /**< License verification failed.    */
  /** @endcond */

  /**
    Check if the given feature id is licensed or not.

    @param [in]  featureID  : featureID to be verified.

    @return
        on success - Object_OK - A valid license is present on the device.
        on error   -
          ERROR_BUSY_TRY_AGAIN : The service is busy, so caller has to call
                    again in a loop till either the api returns success or
                    any other error code.
          Any other error code : If license parsing fails or valid license is
                    not present on the device.
   */
  method check(in uint32 featureID);
  /** @} */ /* end_addtogroup ICPZLicense */
};
