diff --git a/api/@ohos.bundle.d.ts b/api/@ohos.bundle.d.ts index 0b2eff47d641a924da0e2dcaff70dcd78bb5046d..481d0c905f9fe9f66c7dcdfc6f1609c694a954cf 100644 --- a/api/@ohos.bundle.d.ts +++ b/api/@ohos.bundle.d.ts @@ -116,12 +116,25 @@ declare namespace bundle { * @syscap SystemCapability.BundleManager.BundleFramework * @import NA * @permission NA + * @deprecated since 9, use PermissionGrantStatus */ export enum GrantStatus { PERMISSION_DENIED = -1, PERMISSION_GRANTED = 0, } +/** + * @name PermissionGrantStatus + * @since 9 + * @syscap SystemCapability.BundleManager.BundleFramework + * @import NA + * @permission NA + */ + export enum PermissionGrantStatus { + PERMISSION_DENIED = -1, + PERMISSION_GRANTED = 0, +} + /** * @name AbilityType * @since 7 diff --git a/api/@ohos.bundle.innerBundleManager.d.ts b/api/@ohos.bundle.innerBundleManager.d.ts index aba733ae16560ca6561d05becfb9b85429ab205d..2a5e7eefe34e093d139f21cfc69c1014960132b5 100644 --- a/api/@ohos.bundle.innerBundleManager.d.ts +++ b/api/@ohos.bundle.innerBundleManager.d.ts @@ -52,6 +52,7 @@ declare namespace innerBundleManager { * @return Returns the result or error maeeage. * @permission ohos.permission.LISTEN_BUNDLE_CHANGE * @systemapi Hide this for inner system use + * @deprecated since 9, use on(type:"bundleStatusChange", bundleStatusCallback : BundleStatusCallback) */ function on(type:"BundleStatusChange", bundleStatusCallback : BundleStatusCallback, callback: AsyncCallback) : void; function on(type:"BundleStatusChange", bundleStatusCallback : BundleStatusCallback): Promise; @@ -65,10 +66,38 @@ declare namespace innerBundleManager { * @return Returns the result or error maeeage. * @permission ohos.permission.LISTEN_BUNDLE_CHANGE * @systemapi Hide this for inner system use + * @deprecated since 9, use off(type:"bundleStatusChange") */ function off(type:"BundleStatusChange", callback: AsyncCallback) : void; function off(type:"BundleStatusChange"): Promise; + /** + * Register Callback. + * + * @since 9 + * @syscap SystemCapability.BundleManager.BundleFramework + * @param type Indicates the command should be implement. + * @param LauncherStatusCallback Indicates the callback to be register. + * @return Returns the result or error maeeage. + * @permission ohos.permission.LISTEN_BUNDLE_CHANGE + * @systemapi Hide this for inner system use + */ + function on(type:"bundleStatusChange", bundleStatusCallback : BundleStatusCallback, callback: Callback) : void; + function on(type:"bundleStatusChange", bundleStatusCallback : BundleStatusCallback): Promise; + + /** + * UnRegister Callback. + * + * @since 9 + * @syscap SystemCapability.BundleManager.BundleFramework + * @param type Indicates the command should be implement. + * @return Returns the result or error maeeage. + * @permission ohos.permission.LISTEN_BUNDLE_CHANGE + * @systemapi Hide this for inner system use + */ + function off(type:"bundleStatusChange", callback: Callback) : void; + function off(type:"bundleStatusChange"): Promise; + /** * Obtains based on a given userId. * diff --git a/api/bundle/hapModuleInfo.d.ts b/api/bundle/hapModuleInfo.d.ts index 5ed5be922e699bba39e878bdec513cbdfba1df67..5ca6893fa6902d4085b95fcd3851862f9fcbed0c 100644 --- a/api/bundle/hapModuleInfo.d.ts +++ b/api/bundle/hapModuleInfo.d.ts @@ -142,4 +142,10 @@ export interface HapModuleInfo { * @syscap SystemCapability.BundleManager.BundleFramework */ readonly hashValue: string; + /** + * @default Indicates the module source dir of this module + * @since 9 + * @syscap SystemCapability.BundleManager.BundleFramework + */ + readonly moduleSourceDir: string; } \ No newline at end of file