Merge pull request !9667 from 赵淦/master
This commit is contained in:
openharmony_ci 2024-03-23 02:42:10 +00:00 committed by Gitee
commit d30b67b54c
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
2 changed files with 117 additions and 0 deletions

View File

@ -1192,6 +1192,81 @@ declare namespace bundleManager {
INTENT_PROFILE = 1
}
/**
* This enumeration value is used to identify the distribution type of application.
*
* @enum { number }
* @syscap SystemCapability.BundleManager.BundleFramework.Core
* @systemapi
* @since 12
*/
export enum AppDistributionType {
/**
* Indicates the application is distributed by the App Gallery.
*
* @syscap SystemCapability.BundleManager.BundleFramework.Core
* @systemapi
* @since 12
*/
APP_GALLERY = 1,
/**
* Indicates the enterprise application, which can be installed in personal devices.
*
* @syscap SystemCapability.BundleManager.BundleFramework.Core
* @systemapi
* @since 12
*/
ENTERPRISE = 2,
/**
* Indicates the normal enterprise application.
* This kind of application can only be installed on enterprise devices through the enterprise MDM application and does not require device management privileges.
*
* @syscap SystemCapability.BundleManager.BundleFramework.Core
* @systemapi
* @since 12
*/
ENTERPRISE_NORMAL = 3,
/**
* Indicates the enterprise MDM application, which can only be installed on enterprise devices.
* This kind of application requires device management privileges, such as remote locking, which can install normal enterprise applications, etc.
*
* @syscap SystemCapability.BundleManager.BundleFramework.Core
* @systemapi
* @since 12
*/
ENTERPRISE_MDM = 4,
/**
* Indicates the system preinstalled application.
*
* @syscap SystemCapability.BundleManager.BundleFramework.Core
* @systemapi
* @since 12
*/
OS_INTEGRATION = 5,
/**
* Indicates the crowdtesting application.
*
* @syscap SystemCapability.BundleManager.BundleFramework.Core
* @systemapi
* @since 12
*/
CROWDTESTING = 6,
/**
* Indicates other types of application.
*
* @syscap SystemCapability.BundleManager.BundleFramework.Core
* @systemapi
* @since 12
*/
NONE = 7
}
/**
* Obtains own bundleInfo.
*
@ -2789,6 +2864,37 @@ declare namespace bundleManager {
*/
function canOpenLink(link: string): boolean;
/**
* Get a list of BundleInfo objects by developerId.
*
* @permission ohos.permission.GET_BUNDLE_INFO_PRIVILEGED
* @param { string } developerId - Indicates the developerId of the application.
* @returns { Array<BundleInfo> } Returns a list of BundleInfo objects.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 202 - Permission denied, non-system app called system api.
* @throws { BusinessError } 401 - The parameter check failed.
* @throws { BusinessError } 17700059 - The specified developerId is invalid.
* @syscap SystemCapability.BundleManager.BundleFramework.Core
* @systemapi
* @since 12
*/
function getAllBundleInfoByDeveloperId(developerId: string): Array<BundleInfo>;
/**
* Get a list of developedId by distribution type.
*
* @permission ohos.permission.GET_BUNDLE_INFO_PRIVILEGED
* @param { number } appDistributionType - Indicates the distribution type of the application, and if not passed in, it gets all the developerId.
* @returns { Array<String> } Returns a list of developerId.
* @throws { BusinessError } 201 - Permission denied.
* @throws { BusinessError } 202 - Permission denied, non-system app called system api.
* @throws { BusinessError } 401 - The parameter check failed.
* @syscap SystemCapability.BundleManager.BundleFramework.Core
* @systemapi
* @since 12
*/
function getDeveloperIds(appDistributionType?: number): Array<String>;
/**
* Obtains configuration information about an application.
*

View File

@ -139,6 +139,17 @@ export interface AppProvisionInfo {
* @since 11
*/
readonly appIdentifier: string;
/**
* Indicates the organization information of the profile file.
*
* @type { string }
* @readonly
* @syscap SystemCapability.BundleManager.BundleFramework.Core
* @systemapi
* @since 12
*/
readonly organization: string;
}
/**