harmony 鸿蒙Common Events of the File Management Subsystem

  • 2023-10-30
  • 浏览 (387)

Common Events of the File Management Subsystem

This document lists the common system events provided by the file management subsystem to applications. Applications can use APIs to subscribe to common system events.

COMMON_EVENT_VOLUME_REMOVED9+

Indicates that an external storage device was removed. - Value: usual.event.data.VOLUME_REMOVED - Required subscriber permissions: ohos.permission.STORAGE_MANAGER

When an external storage device is removed, the event notification service is triggered to publish this event.

COMMON_EVENT_VOLUME_UNMOUNTED9+

Indicates that an external storage device was unmounted. - Value: usual.event.data.VOLUME_UNMOUNTED - Required subscriber permissions: ohos.permission.STORAGE_MANAGER

When an external storage device is successfully unmounted by calling unmount or by removing the device, the event notification service is triggered to publish this event.

COMMON_EVENT_VOLUME_MOUNTED9+

Indicates that an external storage device was mounted. - Value: usual.event.data.VOLUME_MOUNTED - Required subscriber permissions: ohos.permission.STORAGE_MANAGER

When an external storage device is mounted by calling mount or by inserting the device, the event notification service is triggered to publish this event.

COMMON_EVENT_VOLUME_BAD_REMOVAL9+

Indicates that an external storage device was removed without being unmounted. - Value: usual.event.data.VOLUME_BAD_REMOVAL - Required subscriber permissions: ohos.permission.STORAGE_MANAGER

When an external storage device is directly removed without being umounted, the event notification service is triggered to publish this event.

COMMON_EVENT_VOLUME_EJECT9+

Indicates that an external storage device is about to be ejected. - Value: usual.event.data.VOLUME_EJECT - Required subscriber permissions: ohos.permission.STORAGE_MANAGER

When the user calls unmount on a mounted external storage device or removes the device, the event notification service is triggered to publish this event.

你可能感兴趣的鸿蒙文章

harmony 鸿蒙Common Events

harmony 鸿蒙Common Events of the Ability Subsystem

harmony 鸿蒙Common Events of the Account Subsystem

harmony 鸿蒙Common Events of the Notification Service

harmony 鸿蒙Common Events of the Bundle Management Subsystem

harmony 鸿蒙Common Events of the Language Subsystem

harmony 鸿蒙Common Events of the SMS Application

harmony 鸿蒙Common Events of the Network Management Subsystem

harmony 鸿蒙Common Events of the NFC Subsystem

harmony 鸿蒙Common Events of the Power Management Subsystem

0  赞