mirror of
https://gitee.com/openharmony/interface_sdk-js
synced 2024-10-06 21:53:50 +00:00
Merge branch 'master' into uiservice-errcode
Signed-off-by: zhubingwei <zhubingwei@huawei.com>
This commit is contained in:
commit
82cc3f18da
314
api/@internal/component/ets/action_sheet.d.ts
vendored
314
api/@internal/component/ets/action_sheet.d.ts
vendored
@ -119,7 +119,16 @@ interface SheetInfo {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
action: () => void;
|
||||
/**
|
||||
* Callback method after the operation.
|
||||
*
|
||||
* @type { VoidCallback }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
action: VoidCallback;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -155,6 +164,167 @@ declare interface DismissDialogAction {
|
||||
reason: DismissReason;
|
||||
}
|
||||
|
||||
/**
|
||||
* Base button params used for ActionSheet.
|
||||
*
|
||||
* @interface ActionSheetButtonOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
interface ActionSheetButtonOptions {
|
||||
/**
|
||||
* Enable switch of confirmation button
|
||||
* @type { ?boolean }
|
||||
* @default true
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Enable switch of confirmation button
|
||||
* @type { ?boolean }
|
||||
* @default true
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
enabled?: boolean;
|
||||
|
||||
/**
|
||||
* Default focus switch of confirmation button
|
||||
* @type { ?boolean }
|
||||
* @default false
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Default focus switch of confirmation button
|
||||
* @type { ?boolean }
|
||||
* @default false
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
defaultFocus?: boolean;
|
||||
|
||||
/**
|
||||
* Style of confirmation button.
|
||||
* @type { ?DialogButtonStyle }
|
||||
* @default DialogButtonStyle.DEFAULT
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Style of confirmation button.
|
||||
* @type { ?DialogButtonStyle }
|
||||
* @default DialogButtonStyle.DEFAULT
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
style?: DialogButtonStyle;
|
||||
|
||||
/**
|
||||
* Text content of the confirmation button.
|
||||
*
|
||||
* @type { string | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Text content of the confirmation button.
|
||||
*
|
||||
* @type { string | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Text content of the confirmation button.
|
||||
*
|
||||
* @type { string | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
value: string | Resource;
|
||||
|
||||
/**
|
||||
* Method executed by the callback.
|
||||
*
|
||||
* @type { function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Method executed by the callback.
|
||||
*
|
||||
* @type { function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Method executed by the callback.
|
||||
*
|
||||
* @type { function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Method executed by the callback.
|
||||
*
|
||||
* @type { VoidCallback }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
action: VoidCallback;
|
||||
}
|
||||
|
||||
/**
|
||||
* ActionSheet offset.
|
||||
*
|
||||
* @interface ActionSheetOffset
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
interface ActionSheetOffset {
|
||||
/**
|
||||
* Dx of the pop-up window relative to the alignment position.
|
||||
*
|
||||
* @type { number | string | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
dx: number | string | Resource;
|
||||
/**
|
||||
* Dy of the pop-up window relative to the alignment position.
|
||||
*
|
||||
* @type { number | string | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
dy: number | string | Resource;
|
||||
}
|
||||
|
||||
/**
|
||||
* The options of ActionSheet.
|
||||
*
|
||||
@ -274,116 +444,16 @@ interface ActionSheetOptions
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
confirm?: {
|
||||
/**
|
||||
* Enable switch of confirmation button
|
||||
* @type { ?boolean }
|
||||
* @default true
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Enable switch of confirmation button
|
||||
* @type { ?boolean }
|
||||
* @default true
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
enabled?: boolean;
|
||||
|
||||
/**
|
||||
* Default focus switch of confirmation button
|
||||
* @type { ?boolean }
|
||||
* @default false
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Default focus switch of confirmation button
|
||||
* @type { ?boolean }
|
||||
* @default false
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
defaultFocus?: boolean;
|
||||
|
||||
/**
|
||||
* Style of confirmation button.
|
||||
* @type { ?DialogButtonStyle }
|
||||
* @default DialogButtonStyle.DEFAULT
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Style of confirmation button.
|
||||
* @type { ?DialogButtonStyle }
|
||||
* @default DialogButtonStyle.DEFAULT
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
style?: DialogButtonStyle;
|
||||
|
||||
/**
|
||||
* Text content of the confirmation button.
|
||||
*
|
||||
* @type { string | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Text content of the confirmation button.
|
||||
*
|
||||
* @type { string | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Text content of the confirmation button.
|
||||
*
|
||||
* @type { string | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
value: string | Resource;
|
||||
|
||||
/**
|
||||
* Method executed by the callback.
|
||||
*
|
||||
* @type { function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Method executed by the callback.
|
||||
*
|
||||
* @type { function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Method executed by the callback.
|
||||
*
|
||||
* @type { function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
action: () => void;
|
||||
};
|
||||
/**
|
||||
* Invoke the commit function.
|
||||
*
|
||||
* @type { ?ActionSheetButtonOptions }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
confirm?: ActionSheetButtonOptions;
|
||||
|
||||
/**
|
||||
* Execute Cancel Function.
|
||||
@ -409,7 +479,16 @@ interface ActionSheetOptions
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
cancel?: () => void;
|
||||
/**
|
||||
* Execute Cancel Function.
|
||||
*
|
||||
* @type { ?VoidCallback }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
cancel?: VoidCallback;
|
||||
|
||||
/**
|
||||
* The Array of sheets
|
||||
@ -513,7 +592,16 @@ interface ActionSheetOptions
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
offset?: { dx: number | string | Resource; dy: number | string | Resource };
|
||||
/**
|
||||
* Offset of the pop-up window relative to the alignment position.
|
||||
*
|
||||
* @type { ?ActionSheetOffset }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
offset?: ActionSheetOffset;
|
||||
|
||||
/**
|
||||
* Mask Region of dialog. The size cannot exceed the main window.
|
||||
|
585
api/@internal/component/ets/alert_dialog.d.ts
vendored
585
api/@internal/component/ets/alert_dialog.d.ts
vendored
@ -345,23 +345,15 @@ declare enum DialogButtonDirection {
|
||||
}
|
||||
|
||||
/**
|
||||
* Base button param used for AlertDialogParamWithOptions.
|
||||
* Base button param.
|
||||
*
|
||||
* @interface AlertDialogButtonOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Base button param used for AlertDialogParamWithOptions.
|
||||
*
|
||||
* @interface AlertDialogButtonOptions
|
||||
* @interface AlertDialogButtonBaseOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
* @since 13
|
||||
*/
|
||||
declare interface AlertDialogButtonOptions {
|
||||
declare interface AlertDialogButtonBaseOptions {
|
||||
/**
|
||||
* Enable switch of button.
|
||||
*
|
||||
@ -499,7 +491,45 @@ declare interface AlertDialogButtonOptions {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
action: () => void;
|
||||
/**
|
||||
* Method executed by the callback.
|
||||
*
|
||||
* @type { VoidCallback }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
action: VoidCallback;
|
||||
}
|
||||
|
||||
/**
|
||||
* Base button param used for AlertDialogParamWithOptions.
|
||||
*
|
||||
* @interface AlertDialogButtonOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Base button param used for AlertDialogParamWithOptions.
|
||||
*
|
||||
* @interface AlertDialogButtonOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Button param used for AlertDialogParamWithOptions.
|
||||
*
|
||||
* @interface AlertDialogButtonOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare interface AlertDialogButtonOptions extends AlertDialogButtonBaseOptions {
|
||||
/**
|
||||
* Define whether the button responds to Enter/Space key by default.
|
||||
*
|
||||
@ -509,7 +539,7 @@ declare interface AlertDialogButtonOptions {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
primary?: boolean;
|
||||
primary?: boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -678,7 +708,16 @@ declare interface AlertDialogParam {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
cancel?: () => void;
|
||||
/**
|
||||
* Execute Cancel Function.
|
||||
*
|
||||
* @type { ?VoidCallback }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
cancel?: VoidCallback;
|
||||
|
||||
/**
|
||||
* Alignment in the vertical direction.
|
||||
@ -1043,168 +1082,16 @@ declare interface AlertDialogParamWithConfirm extends AlertDialogParam {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
confirm?: {
|
||||
/**
|
||||
* Enable switch of confirmation button
|
||||
* @type { ?boolean }
|
||||
* @default true
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Enable switch of confirmation button
|
||||
* @type { ?boolean }
|
||||
* @default true
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
enabled?: boolean;
|
||||
|
||||
/**
|
||||
* Default focus switch of confirmation button
|
||||
* @type { ?boolean }
|
||||
* @default false
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Default focus switch of confirmation button
|
||||
* @type { ?boolean }
|
||||
* @default false
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
defaultFocus?: boolean;
|
||||
|
||||
/**
|
||||
* Style of confirmation button.
|
||||
* @type { ?DialogButtonStyle }
|
||||
* @default DialogButtonStyle.DEFAULT
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Style of confirmation button.
|
||||
* @type { ?DialogButtonStyle }
|
||||
* @default DialogButtonStyle.DEFAULT
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
style?: DialogButtonStyle;
|
||||
|
||||
/**
|
||||
* Text content of the confirmation button.
|
||||
*
|
||||
* @type { ResourceStr }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Text content of the confirmation button.
|
||||
*
|
||||
* @type { ResourceStr }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Text content of the confirmation button.
|
||||
*
|
||||
* @type { ResourceStr }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
value: ResourceStr;
|
||||
|
||||
/**
|
||||
* Text color of the confirmation button.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Text color of the confirmation button.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Text color of the confirmation button.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
fontColor?: ResourceColor;
|
||||
|
||||
/**
|
||||
* Background color of the confirmation button.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Background color of the confirmation button.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Background color of the confirmation button.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
backgroundColor?: ResourceColor;
|
||||
|
||||
/**
|
||||
* Method executed by the callback.
|
||||
*
|
||||
* @type { function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Method executed by the callback.
|
||||
*
|
||||
* @type { function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Method executed by the callback.
|
||||
*
|
||||
* @type { function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
action: () => void;
|
||||
};
|
||||
/**
|
||||
* Invoke the commit function.
|
||||
*
|
||||
* @type { ?AlertDialogButtonBaseOptions }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
confirm?: AlertDialogButtonBaseOptions;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -1289,168 +1176,16 @@ declare interface AlertDialogParamWithButtons extends AlertDialogParam {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
primaryButton: {
|
||||
/**
|
||||
* Enable switch of primaryButton
|
||||
* @type { ?boolean }
|
||||
* @default true
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Enable switch of primaryButton
|
||||
* @type { ?boolean }
|
||||
* @default true
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
enabled?: boolean;
|
||||
|
||||
/**
|
||||
* Default focus switch of primaryButton button
|
||||
* @type { ?boolean }
|
||||
* @default false
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Default focus switch of primaryButton button
|
||||
* @type { ?boolean }
|
||||
* @default false
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
defaultFocus?: boolean;
|
||||
|
||||
/**
|
||||
* Style of primaryButton button.
|
||||
* @type { ?DialogButtonStyle }
|
||||
* @default DialogButtonStyle.DEFAULT
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Style of primaryButton button.
|
||||
* @type { ?DialogButtonStyle }
|
||||
* @default DialogButtonStyle.DEFAULT
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
style?: DialogButtonStyle;
|
||||
|
||||
/**
|
||||
* Text content of the confirmation button.
|
||||
*
|
||||
* @type { ResourceStr }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Text content of the confirmation button.
|
||||
*
|
||||
* @type { ResourceStr }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Text content of the confirmation button.
|
||||
*
|
||||
* @type { ResourceStr }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
value: ResourceStr;
|
||||
|
||||
/**
|
||||
* Text color of the confirmation button.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Text color of the confirmation button.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Text color of the confirmation button.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
fontColor?: ResourceColor;
|
||||
|
||||
/**
|
||||
* Background color of the confirmation button.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Background color of the confirmation button.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Background color of the confirmation button.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
backgroundColor?: ResourceColor;
|
||||
|
||||
/**
|
||||
* Method executed by the callback.
|
||||
*
|
||||
* @type { function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Method executed by the callback.
|
||||
*
|
||||
* @type { function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Method executed by the callback.
|
||||
*
|
||||
* @type { function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
action: () => void;
|
||||
};
|
||||
/**
|
||||
* First button.
|
||||
*
|
||||
* @type { AlertDialogButtonBaseOptions }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
primaryButton: AlertDialogButtonBaseOptions;
|
||||
|
||||
/**
|
||||
* Second button.
|
||||
@ -1476,168 +1211,16 @@ declare interface AlertDialogParamWithButtons extends AlertDialogParam {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
secondaryButton: {
|
||||
/**
|
||||
* Enable switch of secondaryButton
|
||||
* @type { ?boolean }
|
||||
* @default true
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Enable switch of secondaryButton
|
||||
* @type { ?boolean }
|
||||
* @default true
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
enabled?: boolean;
|
||||
|
||||
/**
|
||||
* Default focus switch of secondaryButton button
|
||||
* @type { ?boolean }
|
||||
* @default false
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Default focus switch of secondaryButton button
|
||||
* @type { ?boolean }
|
||||
* @default false
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
defaultFocus?: boolean;
|
||||
|
||||
/**
|
||||
* Style of secondaryButton button.
|
||||
* @type { ?DialogButtonStyle }
|
||||
* @default DialogButtonStyle.DEFAULT
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Style of secondaryButton button.
|
||||
* @type { ?DialogButtonStyle }
|
||||
* @default DialogButtonStyle.DEFAULT
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
style?: DialogButtonStyle;
|
||||
|
||||
/**
|
||||
* Text content of the confirmation button.
|
||||
*
|
||||
* @type { ResourceStr }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Text content of the confirmation button.
|
||||
*
|
||||
* @type { ResourceStr }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Text content of the confirmation button.
|
||||
*
|
||||
* @type { ResourceStr }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
value: ResourceStr;
|
||||
|
||||
/**
|
||||
* Text color of the confirmation button.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Text color of the confirmation button.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Text color of the confirmation button.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
fontColor?: ResourceColor;
|
||||
|
||||
/**
|
||||
* Background color of the confirmation button.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Background color of the confirmation button.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Background color of the confirmation button.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
backgroundColor?: ResourceColor;
|
||||
|
||||
/**
|
||||
* Method executed by the callback.
|
||||
*
|
||||
* @type { function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Method executed by the callback.
|
||||
*
|
||||
* @type { function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Method executed by the callback.
|
||||
*
|
||||
* @type { function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
action: () => void;
|
||||
};
|
||||
/**
|
||||
* Second button.
|
||||
*
|
||||
* @type { AlertDialogButtonBaseOptions }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
secondaryButton: AlertDialogButtonBaseOptions;
|
||||
}
|
||||
|
||||
/**
|
||||
|
148
api/@internal/component/ets/alphabet_indexer.d.ts
vendored
148
api/@internal/component/ets/alphabet_indexer.d.ts
vendored
@ -110,6 +110,68 @@ declare enum IndexerAlign {
|
||||
END,
|
||||
}
|
||||
|
||||
/**
|
||||
* AlphabetIndexer constructor options.
|
||||
*
|
||||
* @interface AlphabetIndexerOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
interface AlphabetIndexerOptions {
|
||||
/**
|
||||
* Alphabetical index string array.
|
||||
*
|
||||
* @type { Array<string> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Alphabetical index string array.
|
||||
*
|
||||
* @type { Array<string> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Alphabetical index string array.
|
||||
*
|
||||
* @type { Array<string> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
arrayValue: Array<string>;
|
||||
/**
|
||||
* ID of the selected item.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* ID of the selected item.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* ID of the selected item.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
selected: number;
|
||||
}
|
||||
|
||||
/**
|
||||
* Alphabet index bar.
|
||||
*
|
||||
@ -165,9 +227,57 @@ interface AlphabetIndexerInterface {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
(value: { arrayValue: Array<string>; selected: number }): AlphabetIndexerAttribute;
|
||||
/**
|
||||
* Construct the alphabet indexer component.
|
||||
* Called when the alphabet indexer component is used.
|
||||
*
|
||||
* @param { AlphabetIndexerOptions } options - alphabet indexer options
|
||||
* @returns { AlphabetIndexerAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
(options: AlphabetIndexerOptions): AlphabetIndexerAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines an AlphabetIndexer callback when onSelect.
|
||||
*
|
||||
* @typedef { function } OnAlphabetIndexerSelectCallback
|
||||
* @param { number } index - selected index
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare type OnAlphabetIndexerSelectCallback = (index: number) => void;
|
||||
|
||||
/**
|
||||
* Defines an AlphabetIndexer callback when onPopupSelect.
|
||||
*
|
||||
* @typedef { function } OnAlphabetIndexerPopupSelectCallback
|
||||
* @param { number } index - selected index
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare type OnAlphabetIndexerPopupSelectCallback = (index: number) => void;
|
||||
|
||||
/**
|
||||
* Defines an AlphabetIndexer callback when onRequestPopupData.
|
||||
*
|
||||
* @typedef { function } OnAlphabetIndexerRequestPopupDataCallback
|
||||
* @param { number } index - selected index
|
||||
* @returns { Array<string> } string array corresponding to the index
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare type OnAlphabetIndexerRequestPopupDataCallback = (index: number) => Array<string>;
|
||||
|
||||
/**
|
||||
* Defines the alphabet index bar attribute functions.
|
||||
*
|
||||
@ -650,7 +760,17 @@ declare class AlphabetIndexerAttribute extends CommonMethod<AlphabetIndexerAttri
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onSelect(callback: (index: number) => void): AlphabetIndexerAttribute;
|
||||
/**
|
||||
* Index bar selection callback.
|
||||
*
|
||||
* @param { OnAlphabetIndexerSelectCallback } callback
|
||||
* @returns { AlphabetIndexerAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onSelect(callback: OnAlphabetIndexerSelectCallback): AlphabetIndexerAttribute;
|
||||
|
||||
/**
|
||||
* Index bar selection callback and return the strings which display on pop-up.
|
||||
@ -679,7 +799,17 @@ declare class AlphabetIndexerAttribute extends CommonMethod<AlphabetIndexerAttri
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onRequestPopupData(callback: (index: number) => Array<string>): AlphabetIndexerAttribute;
|
||||
/**
|
||||
* Index bar selection callback and return the strings which display on pop-up.
|
||||
*
|
||||
* @param { OnAlphabetIndexerRequestPopupDataCallback } callback
|
||||
* @returns { AlphabetIndexerAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onRequestPopupData(callback: OnAlphabetIndexerRequestPopupDataCallback): AlphabetIndexerAttribute;
|
||||
|
||||
/**
|
||||
* Pop-up selection callback.
|
||||
@ -708,7 +838,17 @@ declare class AlphabetIndexerAttribute extends CommonMethod<AlphabetIndexerAttri
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onPopupSelect(callback: (index: number) => void): AlphabetIndexerAttribute;
|
||||
/**
|
||||
* Pop-up selection callback.
|
||||
*
|
||||
* @param { OnAlphabetIndexerPopupSelectCallback } callback
|
||||
* @returns { AlphabetIndexerAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onPopupSelect(callback: OnAlphabetIndexerPopupSelectCallback): AlphabetIndexerAttribute;
|
||||
|
||||
/**
|
||||
* Sets the selected index.
|
||||
|
85
api/@internal/component/ets/calendar_picker.d.ts
vendored
85
api/@internal/component/ets/calendar_picker.d.ts
vendored
@ -238,7 +238,16 @@ declare class CalendarPickerAttribute extends CommonMethod<CalendarPickerAttribu
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onChange(callback: (value: Date) => void): CalendarPickerAttribute;
|
||||
/**
|
||||
* Callback for selected date changed.
|
||||
* @param { Callback<Date> } callback - callback for selected date changed.
|
||||
* @returns { CalendarPickerAttribute } the attribute of the CalendarPicker.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onChange(callback: Callback<Date>): CalendarPickerAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -272,7 +281,15 @@ declare interface CalendarDialogOptions extends CalendarOptions {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onAccept?: (value: Date) => void;
|
||||
/**
|
||||
* Called when the OK button in the dialog is clicked.
|
||||
* @type { ?Callback<Date> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onAccept?: Callback<Date>;
|
||||
|
||||
/**
|
||||
* Called when the Cancel button in the dialog is clicked.
|
||||
@ -289,7 +306,15 @@ declare interface CalendarDialogOptions extends CalendarOptions {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onCancel?: () => void;
|
||||
/**
|
||||
* Called when the Cancel button in the dialog is clicked.
|
||||
* @type { ?VoidCallback }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onCancel?: VoidCallback;
|
||||
|
||||
/**
|
||||
* This event is triggered when a date is selected in dialog.
|
||||
@ -306,7 +331,15 @@ declare interface CalendarDialogOptions extends CalendarOptions {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onChange?: (value: Date) => void;
|
||||
/**
|
||||
* This event is triggered when a date is selected in dialog.
|
||||
* @type { ?Callback<Date> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onChange?: Callback<Date>;
|
||||
|
||||
/**
|
||||
* Defines the calendarPickerDialog's background color
|
||||
@ -381,7 +414,16 @@ declare interface CalendarDialogOptions extends CalendarOptions {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
onDidAppear?: () => void;
|
||||
/**
|
||||
* Callback function when the dialog appears.
|
||||
*
|
||||
* @type { ?VoidCallback }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onDidAppear?: VoidCallback;
|
||||
|
||||
/**
|
||||
* Callback function when the dialog disappears.
|
||||
@ -392,7 +434,16 @@ declare interface CalendarDialogOptions extends CalendarOptions {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
onDidDisappear?: () => void;
|
||||
/**
|
||||
* Callback function when the dialog disappears.
|
||||
*
|
||||
* @type { ?VoidCallback }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onDidDisappear?: VoidCallback;
|
||||
|
||||
/**
|
||||
* Callback function before the dialog openAnimation starts.
|
||||
@ -403,7 +454,16 @@ declare interface CalendarDialogOptions extends CalendarOptions {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
onWillAppear?: () => void;
|
||||
/**
|
||||
* Callback function before the dialog openAnimation starts.
|
||||
*
|
||||
* @type { ?VoidCallback }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onWillAppear?: VoidCallback;
|
||||
|
||||
/**
|
||||
* Callback function before the dialog closeAnimation starts.
|
||||
@ -414,7 +474,16 @@ declare interface CalendarDialogOptions extends CalendarOptions {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
onWillDisappear?: () => void;
|
||||
/**
|
||||
* Callback function before the dialog closeAnimation starts.
|
||||
*
|
||||
* @type { ?VoidCallback }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onWillDisappear?: VoidCallback;
|
||||
|
||||
/**
|
||||
* Defines the dialog's shadow.
|
||||
|
94
api/@internal/component/ets/canvas.d.ts
vendored
94
api/@internal/component/ets/canvas.d.ts
vendored
@ -421,6 +421,17 @@ declare type CanvasTextBaseline = "alphabetic" | "bottom" | "hanging" | "ideogra
|
||||
*/
|
||||
declare type ImageSmoothingQuality = "high" | "low" | "medium";
|
||||
|
||||
/**
|
||||
* Import the frame node type object for Canvas.
|
||||
*
|
||||
* @typedef { import('../api/arkui/FrameNode').FrameNode } FrameNode
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare type FrameNode = import('../api/arkui/FrameNode').FrameNode;
|
||||
|
||||
/**
|
||||
* Opaque objects that describe gradients, created by createLinearGradient() or createRadialGradient()
|
||||
*
|
||||
@ -1025,7 +1036,7 @@ declare class Path2D extends CanvasPath {
|
||||
* Adds a path according to the specified path variable.
|
||||
*
|
||||
* @param { Path2D } path - Indicates the path object to be added.
|
||||
* @param { Matrix2D } transform - Transformation matrix of the new trail
|
||||
* @param { Matrix2D } transform - Transformation matrix of the new trail. The default value is null.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
@ -1033,7 +1044,7 @@ declare class Path2D extends CanvasPath {
|
||||
* Adds a path according to the specified path variable.
|
||||
*
|
||||
* @param { Path2D } path - Indicates the path object to be added.
|
||||
* @param { Matrix2D } transform - Transformation matrix of the new trail
|
||||
* @param { Matrix2D } transform - Transformation matrix of the new trail. The default value is null.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
@ -1042,7 +1053,7 @@ declare class Path2D extends CanvasPath {
|
||||
* Adds a path according to the specified path variable.
|
||||
*
|
||||
* @param { Path2D } path - Indicates the path object to be added.
|
||||
* @param { Matrix2D } transform - Transformation matrix of the new trail
|
||||
* @param { Matrix2D } transform - Transformation matrix of the new trail. The default value is null.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
@ -1052,7 +1063,7 @@ declare class Path2D extends CanvasPath {
|
||||
* Adds a path according to the specified path variable.
|
||||
*
|
||||
* @param { Path2D } path - Indicates the path object to be added.
|
||||
* @param { Matrix2D } transform - Transformation matrix of the new trail
|
||||
* @param { Matrix2D } transform - Transformation matrix of the new trail. The default value is null.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
@ -5248,6 +5259,17 @@ declare class CanvasRenderingContext2D extends CanvasRenderer {
|
||||
*/
|
||||
readonly width: number;
|
||||
|
||||
/**
|
||||
* Frame node of the canvas. The default value is null.
|
||||
*
|
||||
* @type { FrameNode }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
readonly canvas: FrameNode;
|
||||
|
||||
/**
|
||||
* Generate a character string in the data url format.
|
||||
*
|
||||
@ -5365,6 +5387,70 @@ declare class CanvasRenderingContext2D extends CanvasRenderer {
|
||||
* @since 12
|
||||
*/
|
||||
constructor(settings?: RenderingContextSettings, unit?: LengthMetricsUnit);
|
||||
|
||||
/**
|
||||
* Register the listener that watches if the canvasrenderingcontext2d attached to the Canvas frameNode.
|
||||
*
|
||||
* @param { 'onAttach' } type Indicates the type of event.
|
||||
* @param { Callback<void> } callback Indicates the listener.
|
||||
* @throws { BusinessError } 401 - Input parameter error. Possible causes:
|
||||
* 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types;
|
||||
* 3. Parameter verification failed.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
on(type: 'onAttach', callback: Callback<void>): void;
|
||||
|
||||
/**
|
||||
* Unregister the listener that watches if the canvasrenderingcontext2d attached to the Canvas frameNode.
|
||||
*
|
||||
* @param { 'onAttach' } type Indicates the type of event.
|
||||
* @param { Callback<void> } callback Indicates the listener.
|
||||
* @throws { BusinessError } 401 - Input parameter error. Possible causes:
|
||||
* 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types;
|
||||
* 3. Parameter verification failed.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
off(type: 'onAttach', callback?: Callback<void>): void;
|
||||
|
||||
/**
|
||||
* Register the listener that watches if the canvasrenderingcontext2d detached from the Canvas frameNode.
|
||||
*
|
||||
* @param { 'onDetach' } type Indicates the type of event.
|
||||
* @param { Callback<void> } callback Indicates the listener.
|
||||
* @throws { BusinessError } 401 - Input parameter error. Possible causes:
|
||||
* 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types;
|
||||
* 3. Parameter verification failed.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
on(type: 'onDetach', callback: Callback<void>): void;
|
||||
|
||||
/**
|
||||
* Unregister the listener that watches if the canvasrenderingcontext2d detached from the Canvas frameNode.
|
||||
*
|
||||
* @param { 'onDetach' } type Indicates the type of event.
|
||||
* @param { Callback<void> } callback Indicates the listener.
|
||||
* @throws { BusinessError } 401 - Input parameter error. Possible causes:
|
||||
* 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types;
|
||||
* 3. Parameter verification failed.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
off(type: 'onDetach', callback?: Callback<void>): void;
|
||||
}
|
||||
|
||||
/**
|
||||
|
26
api/@internal/component/ets/checkbox.d.ts
vendored
26
api/@internal/component/ets/checkbox.d.ts
vendored
@ -261,6 +261,19 @@ interface CheckboxInterface {
|
||||
(options?: CheckboxOptions): CheckboxAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines a Checkbox callback when onChange.
|
||||
*
|
||||
* @typedef { function } OnCheckboxChangeCallback
|
||||
* @param { boolean } value - selected status
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare type OnCheckboxChangeCallback = (value: boolean) => void;
|
||||
|
||||
/**
|
||||
* Defines the attribute functions of Checkbox.
|
||||
*
|
||||
@ -479,7 +492,18 @@ declare class CheckboxAttribute extends CommonMethod<CheckboxAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onChange(callback: (value: boolean) => void): CheckboxAttribute;
|
||||
/**
|
||||
* Called when the selection status changes.
|
||||
*
|
||||
* @param { OnCheckboxChangeCallback } callback
|
||||
* @returns { CheckboxAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onChange(callback: OnCheckboxChangeCallback): CheckboxAttribute;
|
||||
|
||||
/**
|
||||
* Set the content modifier of checkbox.
|
||||
|
26
api/@internal/component/ets/checkboxgroup.d.ts
vendored
26
api/@internal/component/ets/checkboxgroup.d.ts
vendored
@ -403,6 +403,19 @@ interface CheckboxGroupInterface {
|
||||
(options?: CheckboxGroupOptions): CheckboxGroupAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines a CheckboxGroup callback when onChange.
|
||||
*
|
||||
* @typedef { function } OnCheckboxGroupChangeCallback
|
||||
* @param { CheckboxGroupResult } value - checkbox group result
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare type OnCheckboxGroupChangeCallback = (value: CheckboxGroupResult) => void;
|
||||
|
||||
/**
|
||||
* Defines the attribute functions of CheckboxGroup.
|
||||
*
|
||||
@ -598,7 +611,18 @@ declare class CheckboxGroupAttribute extends CommonMethod<CheckboxGroupAttribute
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onChange(callback: (event: CheckboxGroupResult) => void): CheckboxGroupAttribute;
|
||||
/**
|
||||
* Called when the selection status changes.
|
||||
*
|
||||
* @param { OnCheckboxGroupChangeCallback } callback
|
||||
* @returns { CheckboxGroupAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onChange(callback: OnCheckboxGroupChangeCallback): CheckboxGroupAttribute;
|
||||
|
||||
/**
|
||||
* Setting the shape of checkbox group.
|
||||
|
61
api/@internal/component/ets/column.d.ts
vendored
61
api/@internal/component/ets/column.d.ts
vendored
@ -18,6 +18,54 @@
|
||||
* @kit ArkUI
|
||||
*/
|
||||
|
||||
/**
|
||||
* Column constructor options.
|
||||
*
|
||||
* @interface ColumnOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
interface ColumnOptions {
|
||||
/**
|
||||
* Vertical layout element spacing
|
||||
*
|
||||
* @type { ?(string | number) }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Vertical layout element spacing.
|
||||
*
|
||||
* @type { ?(string | number) }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Vertical layout element spacing.
|
||||
*
|
||||
* @type { ?(string | number) }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Vertical layout element spacing.
|
||||
*
|
||||
* @type { ?(string | number) }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
space?: string | number;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines the Column Component.
|
||||
*
|
||||
@ -99,7 +147,18 @@ interface ColumnInterface {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
(value?: { space?: string | number }): ColumnAttribute;
|
||||
/**
|
||||
* Set the options.
|
||||
*
|
||||
* @param { ColumnOptions } [options] - column options
|
||||
* @returns { ColumnAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
(options?: ColumnOptions): ColumnAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
|
457
api/@internal/component/ets/common.d.ts
vendored
457
api/@internal/component/ets/common.d.ts
vendored
@ -1676,7 +1676,7 @@ declare interface Rectangle {
|
||||
/**
|
||||
* Interface for ExpectedFrameRateRange.
|
||||
*
|
||||
* @typedef ExpectedFrameRateRange
|
||||
* @interface ExpectedFrameRateRange
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
@ -2200,14 +2200,14 @@ declare interface AnimateParam {
|
||||
playMode?: PlayMode;
|
||||
|
||||
/**
|
||||
* Callback invoked when the animation playback is complete.
|
||||
* Callback invoked when the animation playback is complete or the ability is about to enter the background.
|
||||
*
|
||||
* @type { ?function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Callback invoked when the animation playback is complete.
|
||||
* Callback invoked when the animation playback is complete or the ability is about to enter the background.
|
||||
*
|
||||
* @type { ?function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
@ -2215,7 +2215,7 @@ declare interface AnimateParam {
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Callback invoked when the animation playback is complete.
|
||||
* Callback invoked when the animation playback is complete or the ability is about to enter the background.
|
||||
*
|
||||
* @type { ?function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
@ -2224,7 +2224,7 @@ declare interface AnimateParam {
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Callback invoked when the animation playback is complete.
|
||||
* Callback invoked when the animation playback is complete or the ability is about to enter the background.
|
||||
*
|
||||
* @type { ?function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
@ -2305,7 +2305,7 @@ interface ICurve {
|
||||
/**
|
||||
* Get curve value by fraction.
|
||||
*
|
||||
* @param { number } fraction -Indicates the current normalized time parameter. Value range: [0, 1].
|
||||
* @param { number } fraction - Indicates the current normalized time parameter. Value range: [0, 1].
|
||||
* Note: If the value is less than 0, it will be processed as 0. If the value is greater than 1, 1 is used.
|
||||
* @returns { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
@ -2315,7 +2315,7 @@ interface ICurve {
|
||||
/**
|
||||
* Get curve value by fraction.
|
||||
*
|
||||
* @param { number } fraction -Indicates the current normalized time parameter. Value range: [0, 1].
|
||||
* @param { number } fraction - Indicates the current normalized time parameter. Value range: [0, 1].
|
||||
* Note: If the value is less than 0, it will be processed as 0. If the value is greater than 1, 1 is used.
|
||||
* @returns { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
@ -2326,7 +2326,7 @@ interface ICurve {
|
||||
/**
|
||||
* Get curve value by fraction.
|
||||
*
|
||||
* @param { number } fraction -Indicates the current normalized time parameter. Value range: [0, 1].
|
||||
* @param { number } fraction - Indicates the current normalized time parameter. Value range: [0, 1].
|
||||
* Note: If the value is less than 0, it will be processed as 0. If the value is greater than 1, 1 is used.
|
||||
* @returns { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
@ -4818,6 +4818,15 @@ declare enum PreDragStatus {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* DragItemInfo object description
|
||||
*
|
||||
* @interface DragItemInfo
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare interface DragItemInfo {
|
||||
/**
|
||||
* Uses the pixelMap object for drawing.
|
||||
@ -4834,6 +4843,15 @@ declare interface DragItemInfo {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Uses the pixelMap object for drawing.
|
||||
*
|
||||
* @type { ?PixelMap }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
pixelMap?: PixelMap;
|
||||
|
||||
/**
|
||||
@ -4851,6 +4869,15 @@ declare interface DragItemInfo {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Uses the custom builder for drawing, if pixelMap is set, this value is ignored.
|
||||
*
|
||||
* @type { ?CustomBuilder }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
builder?: CustomBuilder;
|
||||
|
||||
/**
|
||||
@ -4868,6 +4895,15 @@ declare interface DragItemInfo {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Sets the extra info for drag event.
|
||||
*
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
extraInfo?: string;
|
||||
}
|
||||
|
||||
@ -6009,7 +6045,7 @@ declare enum BlurStyle {
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
declare enum BlurStyleActivePolicy {
|
||||
/**
|
||||
@ -6018,7 +6054,7 @@ declare enum BlurStyleActivePolicy {
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
FOLLOWS_WINDOW_ACTIVE_STATE = 0,
|
||||
|
||||
@ -6028,7 +6064,7 @@ declare enum BlurStyleActivePolicy {
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
ALWAYS_ACTIVE = 1,
|
||||
|
||||
@ -6038,7 +6074,7 @@ declare enum BlurStyleActivePolicy {
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
ALWAYS_INACTIVE = 2,
|
||||
}
|
||||
@ -6050,7 +6086,7 @@ declare enum BlurStyleActivePolicy {
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
declare enum BlurType {
|
||||
/**
|
||||
@ -6059,7 +6095,7 @@ declare enum BlurType {
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
WITHIN_WINDOW = 0,
|
||||
/**
|
||||
@ -6068,7 +6104,7 @@ declare enum BlurType {
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
BEHIND_WINDOW = 1
|
||||
}
|
||||
@ -6292,7 +6328,7 @@ declare interface BackgroundBlurStyleOptions extends BlurStyleOptions {
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
policy?: BlurStyleActivePolicy;
|
||||
|
||||
@ -6304,7 +6340,7 @@ declare interface BackgroundBlurStyleOptions extends BlurStyleOptions {
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
inactiveColor?: ResourceColor;
|
||||
|
||||
@ -6316,7 +6352,7 @@ declare interface BackgroundBlurStyleOptions extends BlurStyleOptions {
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
type?: BlurType;
|
||||
}
|
||||
@ -6621,7 +6657,7 @@ declare interface BackgroundEffectOptions {
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
policy?: BlurStyleActivePolicy;
|
||||
|
||||
@ -6633,7 +6669,7 @@ declare interface BackgroundEffectOptions {
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
inactiveColor?: ResourceColor;
|
||||
|
||||
@ -6645,7 +6681,7 @@ declare interface BackgroundEffectOptions {
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
type?: BlurType;
|
||||
}
|
||||
@ -9373,6 +9409,15 @@ declare type UniformDataType = import('../api/@ohos.data.uniformTypeDescriptor')
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Enum for Drag Result.
|
||||
*
|
||||
* @enum { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare enum DragResult {
|
||||
/**
|
||||
* If the drag is successful, return DragResult.DRAG_SUCCESSFUL.
|
||||
@ -9387,6 +9432,14 @@ declare enum DragResult {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* If the drag is successful, return DragResult.DRAG_SUCCESSFUL.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
DRAG_SUCCESSFUL = 0,
|
||||
/**
|
||||
* If drag fail, return DragResult.DRAG_FAILED.
|
||||
@ -9401,6 +9454,14 @@ declare enum DragResult {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* If drag fail, return DragResult.DRAG_FAILED.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
DRAG_FAILED = 1,
|
||||
/**
|
||||
* If drag action cancel, return DragResult.DRAG_CANCELED.
|
||||
@ -10094,6 +10155,15 @@ declare enum BlendApplyType {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* DragEvent object description
|
||||
*
|
||||
* @interface DragEvent
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare interface DragEvent {
|
||||
/**
|
||||
* X coordinate of the touch point relative to the left edge of the device screen.
|
||||
@ -10110,6 +10180,15 @@ declare interface DragEvent {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* X coordinate of the touch point relative to the left edge of the device screen.
|
||||
*
|
||||
* @returns { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
getDisplayX(): number;
|
||||
|
||||
/**
|
||||
@ -10127,6 +10206,15 @@ declare interface DragEvent {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Y coordinate of the touch point relative to the upper edge of the device screen.
|
||||
*
|
||||
* @returns { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
getDisplayY(): number;
|
||||
|
||||
/**
|
||||
@ -10144,6 +10232,15 @@ declare interface DragEvent {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* X coordinate of the touch point relative to the left edge of the current window.
|
||||
*
|
||||
* @returns { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
getWindowX(): number;
|
||||
|
||||
/**
|
||||
@ -10161,6 +10258,15 @@ declare interface DragEvent {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Y coordinate of the touch point relative to the left edge of the current window.
|
||||
*
|
||||
* @returns { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
getWindowY(): number;
|
||||
|
||||
/**
|
||||
@ -10295,6 +10401,15 @@ declare interface DragEvent {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Set dragEvent result to DragEvent.
|
||||
*
|
||||
* @param { DragResult } dragResult - the return of dragEvent.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
setResult(dragResult: DragResult): void;
|
||||
|
||||
/**
|
||||
@ -10312,6 +10427,15 @@ declare interface DragEvent {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Get dragEvent result from DragEvent.
|
||||
*
|
||||
* @returns { DragResult } - dragResult Data.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
getResult(): DragResult;
|
||||
|
||||
/**
|
||||
@ -10329,6 +10453,15 @@ declare interface DragEvent {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Get the rectangle of drag window.
|
||||
*
|
||||
* @returns { Rectangle } - getPreview rectangle.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
getPreviewRect(): Rectangle;
|
||||
|
||||
/**
|
||||
@ -10396,9 +10529,19 @@ declare interface DragEvent {
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Incorrect parameter types. 2. Parameter verification failed.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Query the ModifierKey press state, support 'ctrl'|'alt'|'shift'|'fn'
|
||||
*
|
||||
* @param { Array<string> } keys - indicate the keys of the ModifierKey.
|
||||
* @returns { boolean }
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Incorrect parameter types. 2. Parameter verification failed.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
getModifierKeyState?(keys: Array<string>): boolean;
|
||||
}
|
||||
|
||||
@ -10682,9 +10825,19 @@ declare interface KeyEvent {
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Incorrect parameter types. 2. Parameter verification failed.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Get the modifier keys press state, support 'ctrl'|'alt'|'shift'|'fn'
|
||||
*
|
||||
* @param { Array<string> } keys - indicate the modifier keys.
|
||||
* @returns { boolean }
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Incorrect parameter types. 2. Parameter verification failed.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
getModifierKeyState?(keys: Array<string>): boolean;
|
||||
|
||||
/**
|
||||
@ -11080,6 +11233,59 @@ declare enum ScrollSizeMode {
|
||||
CONTINUOUS = 1,
|
||||
}
|
||||
|
||||
/**
|
||||
* Define the mode of sheet how to avoid keyboard.
|
||||
*
|
||||
* @enum { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
declare enum SheetKeyboardAvoidMode {
|
||||
/**
|
||||
* Sheet will not aovid keyboard.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
NONE = 0,
|
||||
|
||||
/**
|
||||
* Firstly sheet will avoid keyboard by changing its height.
|
||||
* And then sheet will avoid by resizing after reaching its maximum height.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
TRANSLATE_AND_RESIZE = 1,
|
||||
|
||||
/**
|
||||
* Sheet will only avoid keyboard by resizing the content.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
RESIZE_ONLY = 2,
|
||||
|
||||
/**
|
||||
* Firstly sheet will avoid keyboard by changing its height.
|
||||
* And then sheet will avoid keyboard by scrolling after reaching its maximum height.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
TRANSLATE_AND_SCROLL = 3,
|
||||
}
|
||||
|
||||
/**
|
||||
* Component sheet dismiss
|
||||
*
|
||||
@ -11559,6 +11765,18 @@ declare interface SheetOptions extends BindOptions {
|
||||
* @since 12
|
||||
*/
|
||||
uiContext?: UIContext;
|
||||
|
||||
/**
|
||||
* Determine the mode of sheet how to avoid keyboard.
|
||||
*
|
||||
* @type { ?SheetKeyboardAvoidMode }
|
||||
* @default SheetKeyboardAvoidMode.TRANSLATE_AND_SCROLL
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
keyboardAvoidMode?: SheetKeyboardAvoidMode;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -13457,6 +13675,17 @@ declare interface ContextMenuOptions {
|
||||
*/
|
||||
aboutToDisappear?: () => void;
|
||||
|
||||
/**
|
||||
* The margin of menu's layoutRegion.
|
||||
*
|
||||
* @type { ?Margin }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
layoutRegionMargin?: Margin;
|
||||
|
||||
/**
|
||||
* The preview animator options.
|
||||
*
|
||||
@ -16691,6 +16920,20 @@ declare class CommonMethod<T> {
|
||||
* @since 12
|
||||
*/
|
||||
focusScopeId(id: string, isGroup?: boolean): T;
|
||||
/**
|
||||
* Set container as a focus group with a specific identifier.
|
||||
*
|
||||
* @param { string } id - focus scope identifier.
|
||||
* @param { boolean } [isGroup] - whether this scope is a focus group, the default value is false.
|
||||
* @param { boolean } [arrowStepOut] - whether the arrow keys can move focus from inside the focus group to outside,
|
||||
* only effective when isGroup is true, the default value is true.
|
||||
* @returns { T }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
focusScopeId(id: string, isGroup?: boolean, arrowStepOut?: boolean): T;
|
||||
|
||||
/**
|
||||
* Set the focus priority of component in a specific focus scope.
|
||||
@ -18582,6 +18825,17 @@ declare class CommonMethod<T> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* After a listener is bound, the component can be dragged. After the drag occurs, a callback is triggered.
|
||||
* (To be triggered, press and hold for 170 milliseconds (ms))
|
||||
*
|
||||
* @param { function } event
|
||||
* @returns { T }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onDragStart(event: (event: DragEvent, extraParams?: string) => CustomBuilder | DragItemInfo): T;
|
||||
|
||||
/**
|
||||
@ -18601,6 +18855,16 @@ declare class CommonMethod<T> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* After binding, a callback is triggered when the component is dragged to the range of the component.
|
||||
*
|
||||
* @param { function } event
|
||||
* @returns { T }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onDragEnter(event: (event: DragEvent, extraParams?: string) => void): T;
|
||||
|
||||
/**
|
||||
@ -18620,6 +18884,16 @@ declare class CommonMethod<T> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* After binding, a callback is triggered when the drag moves within the range of a placeable component.
|
||||
*
|
||||
* @param { function } event
|
||||
* @returns { T }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onDragMove(event: (event: DragEvent, extraParams?: string) => void): T;
|
||||
|
||||
/**
|
||||
@ -18639,6 +18913,16 @@ declare class CommonMethod<T> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* After binding, a callback is triggered when the component is dragged out of the component range.
|
||||
*
|
||||
* @param { function } event
|
||||
* @returns { T }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onDragLeave(event: (event: DragEvent, extraParams?: string) => void): T;
|
||||
|
||||
/**
|
||||
@ -18660,6 +18944,17 @@ declare class CommonMethod<T> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* The component bound to this event can be used as the drag release target.
|
||||
* This callback is triggered when the drag behavior is stopped within the scope of the component.
|
||||
*
|
||||
* @param { function } event
|
||||
* @returns { T }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onDrop(event: (event: DragEvent, extraParams?: string) => void): T;
|
||||
|
||||
/**
|
||||
@ -18679,6 +18974,16 @@ declare class CommonMethod<T> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* This function is called when the drag event is end.
|
||||
*
|
||||
* @param { function } event - indicates the function to be called.
|
||||
* @returns { T } property value of type T.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onDragEnd(event: (event: DragEvent, extraParams?: string) => void): T;
|
||||
|
||||
/**
|
||||
@ -19190,7 +19495,21 @@ declare class CommonMethod<T> {
|
||||
blendMode(value: BlendMode, type?: BlendApplyType): T;
|
||||
|
||||
/**
|
||||
* Whether to crop the sub components of the current component.
|
||||
* Add a blendMode effect to the current component.Cannot be used together with the blendMode interface.
|
||||
*
|
||||
* @param { BlendMode | Blender } effect - When the effect type is BlendMode type, define Different hybrid modes.
|
||||
* When the effect type is Blender type, Define the corresponding blending effect.
|
||||
* @param { BlendApplyType } [type] - Different blend apply type
|
||||
* @returns { T }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @systemapi
|
||||
* @form
|
||||
* @since 13
|
||||
*/
|
||||
advancedBlendMode(effect: BlendMode | Blender, type?: BlendApplyType): T;
|
||||
|
||||
/**
|
||||
* Whether to crop the sub components beyond the current component range.
|
||||
*
|
||||
* @param { boolean } value
|
||||
* @returns { T }
|
||||
@ -19771,7 +20090,18 @@ declare class CommonMethod<T> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onVisibleAreaChange(ratios: Array<number>, event: (isVisible: boolean, currentRatio: number) => void): T;
|
||||
/**
|
||||
* Trigger a visible area change event.
|
||||
*
|
||||
* @param { Array<number> } ratios
|
||||
* @param { VisibleAreaChangeCallback } event
|
||||
* @returns { T }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onVisibleAreaChange(ratios: Array<number>, event: VisibleAreaChangeCallback): T;
|
||||
|
||||
/**
|
||||
* Set the spherical effect of the component.
|
||||
@ -20026,6 +20356,32 @@ declare class CommonMethod<T> {
|
||||
*/
|
||||
accessibilityVirtualNode(builder: CustomBuilder): T;
|
||||
|
||||
/**
|
||||
* Sets accessibilityChecked
|
||||
*
|
||||
* @param { boolean } isCheck - set accessibility checked status
|
||||
* @returns { T }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
accessibilityChecked(isCheck: boolean): T;
|
||||
|
||||
/**
|
||||
* Sets accessibilitySelected
|
||||
*
|
||||
* @param { boolean } isSelect - set accessibility selected status
|
||||
* @returns { T }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
accessibilitySelected(isSelect: boolean): T;
|
||||
|
||||
/**
|
||||
* Sets obscured
|
||||
*
|
||||
@ -21896,17 +22252,6 @@ declare interface MeasureResult extends SizeResult {
|
||||
*/
|
||||
declare type NavDestinationInfo = import('../api/@ohos.arkui.observer').default.NavDestinationInfo;
|
||||
|
||||
/**
|
||||
* The router page information.
|
||||
*
|
||||
* @typedef {import('../api/@ohos.arkui.observer').default.RouterPageInfo} RouterPageInfo
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
declare type RouterPageInfo = import('../api/@ohos.arkui.observer').default.RouterPageInfo;
|
||||
|
||||
/**
|
||||
* The navigation information.
|
||||
*
|
||||
@ -21918,6 +22263,17 @@ declare type NavDestinationInfo = import('../api/@ohos.arkui.observer').default.
|
||||
*/
|
||||
declare type NavigationInfo = import('../api/@ohos.arkui.observer').default.NavigationInfo;
|
||||
|
||||
/**
|
||||
* The router page information.
|
||||
*
|
||||
* @typedef {import('../api/@ohos.arkui.observer').default.RouterPageInfo} RouterPageInfo
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
declare type RouterPageInfo = import('../api/@ohos.arkui.observer').default.RouterPageInfo;
|
||||
|
||||
/**
|
||||
* UIContext
|
||||
*
|
||||
@ -21970,6 +22326,17 @@ declare type VisualEffect = import('../api/@ohos.graphics.uiEffect').default.Vis
|
||||
*/
|
||||
declare type Filter = import('../api/@ohos.graphics.uiEffect').default.Filter;
|
||||
|
||||
/**
|
||||
* Blender
|
||||
*
|
||||
* @typedef { import('../api/@ohos.graphics.uiEffect').default.Blender } Blender
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @systemapi
|
||||
* @form
|
||||
* @since 13
|
||||
*/
|
||||
declare type Blender = import('../api/@ohos.graphics.uiEffect').default.Blender;
|
||||
|
||||
/**
|
||||
* ComponentContent.
|
||||
*
|
||||
@ -23472,7 +23839,7 @@ declare interface KeyframeAnimateParam {
|
||||
iterations?: number;
|
||||
|
||||
/**
|
||||
* Callback invoked when the whole keyframe animation is complete.
|
||||
* Callback invoked when the whole keyframe animation is complete or the ability is about to enter the background.
|
||||
*
|
||||
* @type { ?function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
@ -23480,7 +23847,7 @@ declare interface KeyframeAnimateParam {
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Callback invoked when the whole keyframe animation is complete.
|
||||
* Callback invoked when the whole keyframe animation is complete or the ability is about to enter the background.
|
||||
*
|
||||
* @type { ?function }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
@ -23667,7 +24034,19 @@ declare interface VisibleAreaEventOptions {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
declare type VisibleAreaChangeCallback = (isVisible: boolean, currentRatio: number) => void;
|
||||
/**
|
||||
* Defines the callback type used in VisibleAreaChange events.
|
||||
*
|
||||
* @typedef { function } VisibleAreaChangeCallback
|
||||
* @param { boolean } isExpanding - Indicates the ratio of the visible area to its own area compared to the last change.
|
||||
* It is true as the ratio increases and false as the ratio decreases.
|
||||
* @param { number } currentRatio - The value of currentRatio indicates the visibility ratio of the current component.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare type VisibleAreaChangeCallback = (isExpanding: boolean, currentRatio: number) => void;
|
||||
|
||||
/**
|
||||
* Defines a UICommonEvent which is used to set different common event to target component.
|
||||
|
26
api/@internal/component/ets/counter.d.ts
vendored
26
api/@internal/component/ets/counter.d.ts
vendored
@ -163,7 +163,18 @@ declare class CounterAttribute extends CommonMethod<CounterAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onInc(event: () => void): CounterAttribute;
|
||||
/**
|
||||
* Listen to the event that the value increases.
|
||||
*
|
||||
* @param { VoidCallback } event
|
||||
* @returns { CounterAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onInc(event: VoidCallback): CounterAttribute;
|
||||
|
||||
/**
|
||||
* Listens to the number decrease event.
|
||||
@ -203,7 +214,18 @@ declare class CounterAttribute extends CommonMethod<CounterAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onDec(event: () => void): CounterAttribute;
|
||||
/**
|
||||
* Listens to the number decrease event.
|
||||
*
|
||||
* @param { VoidCallback } event
|
||||
* @returns { CounterAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onDec(event: VoidCallback): CounterAttribute;
|
||||
|
||||
/**
|
||||
* Indicates whether the decrease button of counter component is available or not.
|
||||
|
2
api/@internal/component/ets/data_panel.d.ts
vendored
2
api/@internal/component/ets/data_panel.d.ts
vendored
@ -132,7 +132,7 @@ declare enum DataPanelType {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
declare type ColorStop = {
|
||||
declare interface ColorStop {
|
||||
/**
|
||||
* Color property.
|
||||
* @type { ResourceColor } color - the color value.
|
||||
|
144
api/@internal/component/ets/date_picker.d.ts
vendored
144
api/@internal/component/ets/date_picker.d.ts
vendored
@ -429,7 +429,61 @@ declare class DatePickerAttribute extends CommonMethod<DatePickerAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onDateChange(callback: (value: Date) => void): DatePickerAttribute;
|
||||
/**
|
||||
* This event is triggered when a DatePicker date or time is selected.
|
||||
*
|
||||
* @param { Callback<Date> } callback
|
||||
* @returns { DatePickerAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onDateChange(callback: Callback<Date>): DatePickerAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
* Provide an interface for the lunar switch style of DatePickerDialog
|
||||
*
|
||||
* @interface LunarSwitchStyle
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
declare interface LunarSwitchStyle {
|
||||
/**
|
||||
* Define the selected color of lunar switch.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
selectedColor?: ResourceColor;
|
||||
|
||||
/**
|
||||
* Define the unselected color of lunar switch.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
unselectedColor?: ResourceColor;
|
||||
|
||||
/**
|
||||
* Define the stroke color of lunar switch.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
strokeColor?: ResourceColor;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -502,6 +556,17 @@ declare interface DatePickerDialogOptions extends DatePickerOptions {
|
||||
*/
|
||||
lunarSwitch?: boolean;
|
||||
|
||||
/**
|
||||
* Describes the lunar switch color.
|
||||
*
|
||||
* @type { ?LunarSwitchStyle }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
lunarSwitchStyle?: LunarSwitchStyle;
|
||||
|
||||
/**
|
||||
* Indicates whether to show the time selector.
|
||||
*
|
||||
@ -711,7 +776,16 @@ declare interface DatePickerDialogOptions extends DatePickerOptions {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onCancel?: () => void;
|
||||
/**
|
||||
* Called when the Cancel button in the dialog is clicked.
|
||||
*
|
||||
* @type { ?VoidCallback }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onCancel?: VoidCallback;
|
||||
|
||||
/**
|
||||
* This event is triggered when a DatePicker date or time is selected in dialog.
|
||||
@ -741,7 +815,16 @@ declare interface DatePickerDialogOptions extends DatePickerOptions {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onDateAccept?: (value: Date) => void;
|
||||
/**
|
||||
* Called when the OK button in the dialog is clicked.
|
||||
*
|
||||
* @type { ?Callback<Date> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onDateAccept?: Callback<Date>;
|
||||
|
||||
/**
|
||||
* This event is triggered when a DatePicker date or time is selected in dialog.
|
||||
@ -760,7 +843,16 @@ declare interface DatePickerDialogOptions extends DatePickerOptions {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onDateChange?: (value: Date) => void;
|
||||
/**
|
||||
* This event is triggered when a DatePicker date or time is selected in dialog.
|
||||
*
|
||||
* @type { ?Callback<Date> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onDateChange?: Callback<Date>;
|
||||
|
||||
/**
|
||||
* Defines the datePickerDialog's background color
|
||||
@ -813,7 +905,16 @@ declare interface DatePickerDialogOptions extends DatePickerOptions {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
onDidAppear?: () => void;
|
||||
/**
|
||||
* Callback function when the dialog appears.
|
||||
*
|
||||
* @type { ?VoidCallback }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onDidAppear?: VoidCallback;
|
||||
|
||||
/**
|
||||
* Callback function when the dialog disappears.
|
||||
@ -824,7 +925,16 @@ declare interface DatePickerDialogOptions extends DatePickerOptions {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
onDidDisappear?: () => void;
|
||||
/**
|
||||
* Callback function when the dialog disappears.
|
||||
*
|
||||
* @type { ?VoidCallback }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onDidDisappear?: VoidCallback;
|
||||
|
||||
/**
|
||||
* Callback function before the dialog openAnimation starts.
|
||||
@ -835,7 +945,16 @@ declare interface DatePickerDialogOptions extends DatePickerOptions {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
onWillAppear?: () => void;
|
||||
/**
|
||||
* Callback function before the dialog openAnimation starts.
|
||||
*
|
||||
* @type { ?VoidCallback }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onWillAppear?: VoidCallback;
|
||||
|
||||
/**
|
||||
* Callback function before the dialog closeAnimation starts.
|
||||
@ -846,7 +965,16 @@ declare interface DatePickerDialogOptions extends DatePickerOptions {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
onWillDisappear?: () => void;
|
||||
/**
|
||||
* Callback function before the dialog closeAnimation starts.
|
||||
*
|
||||
* @type { ?VoidCallback }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onWillDisappear?: VoidCallback;
|
||||
|
||||
/**
|
||||
* Defines the dialog's shadow.
|
||||
|
92
api/@internal/component/ets/enums.d.ts
vendored
92
api/@internal/component/ets/enums.d.ts
vendored
@ -9728,3 +9728,95 @@ declare enum AccessibilityHoverType {
|
||||
*/
|
||||
HOVER_CANCEL = 3,
|
||||
}
|
||||
|
||||
/**
|
||||
* Type of window width breakpoint.
|
||||
*
|
||||
* @enum {number}
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare enum WidthBreakpoint {
|
||||
/**
|
||||
* Window width < 320vp type.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
WIDTH_XS = 0,
|
||||
|
||||
/**
|
||||
* Window width >= 320vp and < 600vp type.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
WIDTH_SM = 1,
|
||||
|
||||
/**
|
||||
* Window width >= 600vp and < 840vp type.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
WIDTH_MD = 2,
|
||||
|
||||
/**
|
||||
* Window width >= 840vp and < 1440vp type.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
WIDTH_LG = 3,
|
||||
|
||||
/**
|
||||
* Window width >= 1440vp type.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
WIDTH_XL = 4,
|
||||
}
|
||||
|
||||
/**
|
||||
* Type of window height breakpoint.
|
||||
*
|
||||
* @enum {number}
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare enum HeightBreakpoint {
|
||||
/**
|
||||
* Window aspectRatio < 0.8 type.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
HEIGHT_SM = 0,
|
||||
|
||||
/**
|
||||
* Window aspectRatio >= 0.8 and < 1.2 type.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
HEIGHT_MD = 1,
|
||||
|
||||
/**
|
||||
* Window aspectRatio >= 1.2 type.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
HEIGHT_LG = 2,
|
||||
}
|
177
api/@internal/component/ets/folder_stack.d.ts
vendored
177
api/@internal/component/ets/folder_stack.d.ts
vendored
@ -28,6 +28,36 @@
|
||||
*/
|
||||
declare type WindowStatusType = import('../api/@ohos.window').default.WindowStatusType;
|
||||
|
||||
/**
|
||||
* FolderStack constructor options.
|
||||
*
|
||||
* @interface FolderStackOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
interface FolderStackOptions {
|
||||
/**
|
||||
* Define the IDs of the sub component that will be moved to the upper half screen when hovering.
|
||||
*
|
||||
* @type { ?Array<string> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Define the IDs of the sub component that will be moved to the upper half screen when hovering.
|
||||
*
|
||||
* @type { ?Array<string> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
upperItems?: Array<string>;
|
||||
}
|
||||
|
||||
/**
|
||||
* Provides ports for stacking containers.
|
||||
*
|
||||
@ -66,9 +96,72 @@ interface FolderStackInterface {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
(value?: { upperItems?: Array<string> }): FolderStackAttribute;
|
||||
/**
|
||||
* Defines the constructor of folderStack.
|
||||
*
|
||||
* @param { FolderStackOptions } [options] - id of children need to be show in upperItem
|
||||
* @returns { FolderStackAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
(options?: FolderStackOptions): FolderStackAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
* Information when onFolderStateChange.
|
||||
*
|
||||
* @interface OnFoldStatusChangeInfo
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
interface OnFoldStatusChangeInfo {
|
||||
/**
|
||||
* Folder state.
|
||||
*
|
||||
* @type { FoldStatus }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Folder state.
|
||||
*
|
||||
* @type { FoldStatus }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
foldStatus: FoldStatus
|
||||
}
|
||||
|
||||
/**
|
||||
* Callback when onStateChangeCallback.
|
||||
*
|
||||
* @typedef { function } OnFoldStatusChangeCallback
|
||||
* @param { OnFoldStatusChangeInfo } event - the folding information of the current device
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare type OnFoldStatusChangeCallback = (event: OnFoldStatusChangeInfo) => void;
|
||||
|
||||
/**
|
||||
* Callback when onHoverStatusChange.
|
||||
*
|
||||
* @typedef { function } OnHoverStatusChangeCallback
|
||||
* @param { HoverEventParam } param - hover event param
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare type OnHoverStatusChangeCallback = (param: HoverEventParam) => void;
|
||||
|
||||
/**
|
||||
/**
|
||||
* @extends CommonMethod<FolderStackAttribute>
|
||||
@ -106,47 +199,38 @@ declare class FolderStackAttribute extends CommonMethod<FolderStackAttribute> {
|
||||
alignContent(value: Alignment): FolderStackAttribute;
|
||||
|
||||
/**
|
||||
* Callback folderState when the folderState changes
|
||||
*
|
||||
* @param { function } callback - executed when folderStatus changed
|
||||
* @returns { FolderStackAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Callback folderState when the folderState changes
|
||||
*
|
||||
* @param { function } callback - executed when folderStatus changed
|
||||
* @returns { FolderStackAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
onFolderStateChange(callback: (event: {
|
||||
/**
|
||||
* folder state.
|
||||
*
|
||||
* @type { FoldStatus }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* folder state.
|
||||
*
|
||||
* @type { FoldStatus }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
foldStatus: FoldStatus
|
||||
}) => void): FolderStackAttribute;
|
||||
|
||||
|
||||
* Callback folderState when the folderState changes
|
||||
*
|
||||
* @param { function } callback - executed when folderStatus changed
|
||||
* @returns { FolderStackAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Callback folderState when the folderState changes
|
||||
*
|
||||
* @param { function } callback - executed when folderStatus changed
|
||||
* @returns { FolderStackAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Callback folderState when the folderState changes
|
||||
*
|
||||
* @param { OnFoldStatusChangeCallback } callback - executed when folderStatus changed
|
||||
* @returns { FolderStackAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onFolderStateChange(callback: OnFoldStatusChangeCallback): FolderStackAttribute;
|
||||
|
||||
|
||||
/**
|
||||
* Callback hoverStatus|folderStatus|rotation|windowMode when the hoverStatus changes
|
||||
*
|
||||
* @param { function } handler - executed when hoverStatus changed
|
||||
@ -155,7 +239,16 @@ declare class FolderStackAttribute extends CommonMethod<FolderStackAttribute> {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
onHoverStatusChange(handler: (param: HoverEventParam) => void): FolderStackAttribute;
|
||||
/**
|
||||
* Callback hoverStatus|folderStatus|rotation|windowMode when the hoverStatus changes
|
||||
*
|
||||
* @param { OnHoverStatusChangeCallback } handler - executed when hoverStatus changed
|
||||
* @returns { FolderStackAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onHoverStatusChange(handler: OnHoverStatusChangeCallback): FolderStackAttribute;
|
||||
|
||||
/**
|
||||
* Enable the animation of folderStack.
|
||||
|
133
api/@internal/component/ets/gauge.d.ts
vendored
133
api/@internal/component/ets/gauge.d.ts
vendored
@ -18,6 +18,126 @@
|
||||
* @kit ArkUI
|
||||
*/
|
||||
|
||||
/**
|
||||
* Defines Gauge constructor options.
|
||||
*
|
||||
* @interface GaugeOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
interface GaugeOptions {
|
||||
/**
|
||||
* Set current data value.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Set current data value.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Set current data value.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Set current data value.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
value: number;
|
||||
|
||||
/**
|
||||
* Set current segment minimum value.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Set current segment minimum value.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Set current segment minimum value.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Set current segment minimum value.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
min?: number;
|
||||
|
||||
/**
|
||||
* Set current segment maximum value.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Set current segment maximum value.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Set current segment maximum value.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Set current segment maximum value.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
max?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines the Gauge component.
|
||||
*
|
||||
@ -99,7 +219,18 @@ interface GaugeInterface {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
(options: { value: number; min?: number; max?: number }): GaugeAttribute;
|
||||
/**
|
||||
* Called when the gauge component is used.
|
||||
*
|
||||
* @param { GaugeOptions } options - Gauge options.
|
||||
* @returns { GaugeAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
(options: GaugeOptions): GaugeAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
|
99
api/@internal/component/ets/image.d.ts
vendored
99
api/@internal/component/ets/image.d.ts
vendored
@ -465,6 +465,91 @@ interface ImageInterface {
|
||||
(src: PixelMap | ResourceStr | DrawableDescriptor, imageAIOptions: ImageAIOptions): ImageAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines source size of image.
|
||||
*
|
||||
* @interface ImageSourceSize
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
|
||||
interface ImageSourceSize {
|
||||
/**
|
||||
* Set width.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Set width.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Set width.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Set width.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
width: number;
|
||||
|
||||
/**
|
||||
* Set height.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Set height.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Set height.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Set height.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
height: number;
|
||||
}
|
||||
|
||||
/**
|
||||
* @extends CommonMethod<ImageAttribute>
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
@ -916,7 +1001,19 @@ declare class ImageAttribute extends CommonMethod<ImageAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
sourceSize(value: { width: number; height: number }): ImageAttribute;
|
||||
/**
|
||||
* Specifies the picture decoding size.
|
||||
* The original picture is decoded into a picture of a specified size. The unit of the number type is px.
|
||||
*
|
||||
* @param { ImageSourceSize } value - Image source size.
|
||||
* @returns { ImageAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
sourceSize(value: ImageSourceSize): ImageAttribute;
|
||||
|
||||
/**
|
||||
* Sets the synchronous or asynchronous mode for image loading.
|
||||
|
302
api/@internal/component/ets/list.d.ts
vendored
302
api/@internal/component/ets/list.d.ts
vendored
@ -836,6 +836,124 @@ declare class ListScroller extends Scroller {
|
||||
getVisibleListContentInfo(x: number, y: number): VisibleListContentInfo;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines List constructor options.
|
||||
*
|
||||
* @interface ListOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
interface ListOptions {
|
||||
/**
|
||||
* Set initialIndex.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Set initialIndex.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Set initialIndex.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Set initialIndex.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
initialIndex?: number;
|
||||
/**
|
||||
* Set space.
|
||||
*
|
||||
* @type { ?(number | string) }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Set space.
|
||||
*
|
||||
* @type { ?(number | string) }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Set space.
|
||||
*
|
||||
* @type { ?(number | string) }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Set space.
|
||||
*
|
||||
* @type { ?(number | string) }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
space?: number | string;
|
||||
/**
|
||||
* Set scroller.
|
||||
*
|
||||
* @type { ?Scroller }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Set scroller.
|
||||
*
|
||||
* @type { ?Scroller }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Set scroller.
|
||||
*
|
||||
* @type { ?Scroller }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Set scroller.
|
||||
*
|
||||
* @type { ?Scroller }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
scroller?: Scroller;
|
||||
}
|
||||
|
||||
/**
|
||||
* The list interface is extended.
|
||||
*
|
||||
@ -909,7 +1027,171 @@ interface ListInterface {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
(value?: { initialIndex?: number; space?: number | string; scroller?: Scroller }): ListAttribute;
|
||||
/**
|
||||
* Called when interface data is called.
|
||||
*
|
||||
* @param { ListOptions } [options] - list options
|
||||
* @returns { ListAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
(options?: ListOptions): ListAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines List divider opotions.
|
||||
*
|
||||
* @interface ListDividerOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare interface ListDividerOptions {
|
||||
/**
|
||||
* Set strokeWidth.
|
||||
*
|
||||
* @type { Length }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Set strokeWidth.
|
||||
*
|
||||
* @type { Length }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Set strokeWidth.
|
||||
*
|
||||
* @type { Length }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Set strokeWidth.
|
||||
*
|
||||
* @type { Length }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
strokeWidth: Length;
|
||||
/**
|
||||
* Set color.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Set color.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Set color.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Set color.
|
||||
*
|
||||
* @type { ?ResourceColor }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
color?: ResourceColor;
|
||||
/**
|
||||
* Set startMargin.
|
||||
*
|
||||
* @type { ?Length }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Set startMargin.
|
||||
*
|
||||
* @type { ?Length }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Set startMargin.
|
||||
*
|
||||
* @type { ?Length }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Set startMargin.
|
||||
*
|
||||
* @type { ?Length }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
startMargin?: Length;
|
||||
/**
|
||||
* Set endMargin.
|
||||
*
|
||||
* @type { ?Length }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Set endMargin.
|
||||
*
|
||||
* @type { ?Length }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Set endMargin.
|
||||
*
|
||||
* @type { ?Length }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Set endMargin.
|
||||
*
|
||||
* @type { ?Length }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
endMargin?: Length;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -1202,13 +1484,19 @@ declare class ListAttribute extends ScrollableCommonMethod<ListAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Called when the ListItem split line style is set.
|
||||
*
|
||||
* @param { ListDividerOptions | null } value
|
||||
* @returns { ListAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
divider(
|
||||
value: {
|
||||
strokeWidth: Length;
|
||||
color?: ResourceColor;
|
||||
startMargin?: Length;
|
||||
endMargin?: Length;
|
||||
} | null,
|
||||
value: ListDividerOptions | null,
|
||||
): ListAttribute;
|
||||
|
||||
/**
|
||||
|
17
api/@internal/component/ets/list_item_group.d.ts
vendored
17
api/@internal/component/ets/list_item_group.d.ts
vendored
@ -334,13 +334,18 @@ declare class ListItemGroupAttribute extends CommonMethod<ListItemGroupAttribute
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Called when the ListItemGroup split line style is set.
|
||||
*
|
||||
* @param { ListDividerOptions | null } value
|
||||
* @returns { ListItemGroupAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
divider(
|
||||
value: {
|
||||
strokeWidth: Length;
|
||||
color?: ResourceColor;
|
||||
startMargin?: Length;
|
||||
endMargin?: Length;
|
||||
} | null,
|
||||
value: ListDividerOptions | null,
|
||||
): ListItemGroupAttribute;
|
||||
|
||||
/**
|
||||
|
205
api/@internal/component/ets/marquee.d.ts
vendored
205
api/@internal/component/ets/marquee.d.ts
vendored
@ -18,6 +18,198 @@
|
||||
* @kit ArkUI
|
||||
*/
|
||||
|
||||
/**
|
||||
* Defines Marquee constructor options.
|
||||
*
|
||||
* @interface MarqueeOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
interface MarqueeOptions {
|
||||
/**
|
||||
* Control whether the running lamp enters the playing state.
|
||||
*
|
||||
* @type { boolean }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Control whether the running lamp enters the playing state.
|
||||
*
|
||||
* @type { boolean }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Control whether the running lamp enters the playing state.
|
||||
*
|
||||
* @type { boolean }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Control whether the running lamp enters the playing state.
|
||||
*
|
||||
* @type { boolean }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
start: boolean;
|
||||
|
||||
/**
|
||||
* Scroll animation text scroll step, when step is larger than the text width of Marquee, take the default value.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Scroll animation text scroll step, when step is larger than the text width of Marquee, take the default value.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Scroll animation text scroll step, when step is larger than the text width of Marquee, take the default value.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Scroll animation text scroll step, when step is larger than the text width of Marquee, take the default value.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
step?: number;
|
||||
|
||||
/**
|
||||
* Set the number of times the scroll is repeated, infinite loop if it is less than or equal to zero.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Set the number of times the scroll is repeated, infinite loop if it is less than or equal to zero.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Set the number of times the scroll is repeated, infinite loop if it is less than or equal to zero.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Set the number of times the scroll is repeated, infinite loop if it is less than or equal to zero.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
loop?: number;
|
||||
|
||||
/**
|
||||
* Set text to scroll from the beginning or backward.
|
||||
*
|
||||
* @type { ?boolean }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Set text to scroll from the beginning or backward.
|
||||
*
|
||||
* @type { ?boolean }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Set text to scroll from the beginning or backward.
|
||||
*
|
||||
* @type { ?boolean }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Set text to scroll from the beginning or backward.
|
||||
*
|
||||
* @type { ?boolean }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
fromStart?: boolean;
|
||||
|
||||
/**
|
||||
* Text that needs scrolling.
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Text that needs scrolling.
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Text that needs scrolling.
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Text that needs scrolling.
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
src: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* Provides the interface for the marquee attributes.
|
||||
*
|
||||
@ -91,7 +283,18 @@ interface MarqueeInterface {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
(value: { start: boolean; step?: number; loop?: number; fromStart?: boolean; src: string }): MarqueeAttribute;
|
||||
/**
|
||||
* Create marquee.
|
||||
*
|
||||
* @param { MarqueeOptions } options - Marquee options.
|
||||
* @returns { MarqueeAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
(options: MarqueeOptions): MarqueeAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
|
146
api/@internal/component/ets/nav_destination.d.ts
vendored
146
api/@internal/component/ets/nav_destination.d.ts
vendored
@ -67,7 +67,16 @@ declare interface NavDestinationCommonTitle {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
main: string;
|
||||
/**
|
||||
* Sets the main title.
|
||||
*
|
||||
* @type { string | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
main: string | Resource;
|
||||
|
||||
/**
|
||||
* Sets the sub title.
|
||||
@ -93,7 +102,16 @@ declare interface NavDestinationCommonTitle {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
sub: string;
|
||||
/**
|
||||
* Sets the sub title.
|
||||
*
|
||||
* @type { string | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
sub: string | Resource;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -174,6 +192,54 @@ declare interface NavDestinationCustomTitle {
|
||||
height: TitleHeight | Length;
|
||||
}
|
||||
|
||||
/**
|
||||
* Types of system Transition.
|
||||
*
|
||||
* @enum { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
declare enum NavigationSystemTransitionType {
|
||||
/**
|
||||
* Default system transition.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
DEFAULT = 0,
|
||||
/**
|
||||
* None system transition.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
NONE = 1,
|
||||
/**
|
||||
* Configure only titlebar transition.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
TITLE = 2,
|
||||
/**
|
||||
* Configure only content transition.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
CONTENT = 3,
|
||||
}
|
||||
|
||||
/**
|
||||
* NavDestination mode.
|
||||
*
|
||||
@ -442,7 +508,19 @@ declare class NavDestinationAttribute extends CommonMethod<NavDestinationAttribu
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
title(value: string | CustomBuilder | NavDestinationCommonTitle | NavDestinationCustomTitle, options?: NavigationTitleOptions): NavDestinationAttribute;
|
||||
/**
|
||||
* NavDestination title bar
|
||||
*
|
||||
* @param { string | CustomBuilder | NavDestinationCommonTitle | NavDestinationCustomTitle | Resource } value
|
||||
* @param { NavigationTitleOptions } [options] - Indicates the options of titlebar.
|
||||
* @returns { NavDestinationAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
title(value: string | CustomBuilder | NavDestinationCommonTitle | NavDestinationCustomTitle | Resource,
|
||||
options?: NavigationTitleOptions): NavDestinationAttribute;
|
||||
|
||||
/**
|
||||
* Hide navigation title bar
|
||||
@ -473,6 +551,19 @@ declare class NavDestinationAttribute extends CommonMethod<NavDestinationAttribu
|
||||
*/
|
||||
hideTitleBar(value: boolean): NavDestinationAttribute;
|
||||
|
||||
/**
|
||||
* Hide navigation title bar
|
||||
*
|
||||
* @param { boolean } hide
|
||||
* @param { boolean } animated
|
||||
* @returns { NavDestinationAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
hideTitleBar(hide: boolean, animated: boolean): NavDestinationAttribute;
|
||||
|
||||
/**
|
||||
* Invoked when the navDestination page is displayed.
|
||||
*
|
||||
@ -590,6 +681,32 @@ declare class NavDestinationAttribute extends CommonMethod<NavDestinationAttribu
|
||||
*/
|
||||
menus(value: Array<NavigationMenuItem> | CustomBuilder): NavDestinationAttribute;
|
||||
|
||||
/**
|
||||
* Configure toolbar with default style parameter or custom parameter.
|
||||
*
|
||||
* @param { Array<ToolbarItem> | CustomBuilder } toolbarParam - Toolbar configuration parameters.
|
||||
* @param { NavigationToolbarOptions } [options] - Indicates the options of toolbar.
|
||||
* @returns { NavDestinationAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
toolbarConfiguration(toolbarParam: Array<ToolbarItem> | CustomBuilder, options?: NavigationToolbarOptions): NavDestinationAttribute;
|
||||
|
||||
/**
|
||||
* Hide tool bar
|
||||
*
|
||||
* @param { boolean } hide
|
||||
* @param { boolean } [animated]
|
||||
* @returns { NavDestinationAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
hideToolBar(hide: boolean, animated?: boolean): NavDestinationAttribute;
|
||||
|
||||
/**
|
||||
* Invoked before sub-components of NavDestination are created.
|
||||
*
|
||||
@ -674,6 +791,29 @@ declare class NavDestinationAttribute extends CommonMethod<NavDestinationAttribu
|
||||
* @since 12
|
||||
*/
|
||||
systemBarStyle(style: Optional<SystemBarStyle>): NavDestinationAttribute;
|
||||
|
||||
/**
|
||||
* Set the NavDestination can be restored after the application is terminated.
|
||||
* To enable this attribute, recoverable and id of Navigation must be set.
|
||||
*
|
||||
* @param { boolean } recoverable - set navdestination can be recovered.
|
||||
* @returns { NavDestinationAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 13
|
||||
*/
|
||||
recoverable(recoverable: Optional<boolean>): NavDestinationAttribute;
|
||||
|
||||
/**
|
||||
* Configuration of system transition
|
||||
*
|
||||
* @param { NavigationSystemTransitionType } type - Types of system Transition
|
||||
* @returns { NavDestinationAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
systemTransition(type: NavigationSystemTransitionType): NavDestinationAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
|
93
api/@internal/component/ets/navigation.d.ts
vendored
93
api/@internal/component/ets/navigation.d.ts
vendored
@ -77,7 +77,16 @@ declare interface NavigationCommonTitle {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
main: string;
|
||||
/**
|
||||
* Sets the main title.
|
||||
*
|
||||
* @type { string | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
main: string | Resource;
|
||||
|
||||
/**
|
||||
* Sets the sub title.
|
||||
@ -103,7 +112,16 @@ declare interface NavigationCommonTitle {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
sub: string;
|
||||
/**
|
||||
* Sets the sub title.
|
||||
*
|
||||
* @type { string | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
sub: string | Resource;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -499,7 +517,16 @@ declare interface NavigationMenuItem {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
value: string;
|
||||
/**
|
||||
* The value of navigation menu item.
|
||||
*
|
||||
* @type { string | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
value: string | Resource;
|
||||
|
||||
/**
|
||||
* The icon of navigation menu item.
|
||||
@ -525,7 +552,16 @@ declare interface NavigationMenuItem {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
icon?: string;
|
||||
/**
|
||||
* The value of navigation menu item.
|
||||
*
|
||||
* @type { ?(string | Resource) }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
icon?: string | Resource;
|
||||
|
||||
/**
|
||||
* The symbol of navigation menu item.
|
||||
@ -2038,6 +2074,18 @@ declare interface NavigationTitleOptions {
|
||||
* @since 13
|
||||
*/
|
||||
subTitleModifier?: TextModifier;
|
||||
|
||||
/**
|
||||
* Defines whether to respond to the hover mode.
|
||||
*
|
||||
* @type { ?boolean }
|
||||
* @default false
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
enableHoverMode?: boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -2406,6 +2454,19 @@ declare class NavigationAttribute extends CommonMethod<NavigationAttribute> {
|
||||
*/
|
||||
hideTitleBar(value: boolean): NavigationAttribute;
|
||||
|
||||
/**
|
||||
* Hide navigation title bar
|
||||
*
|
||||
* @param { boolean } hide
|
||||
* @param { boolean } animated
|
||||
* @returns { NavigationAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
hideTitleBar(hide: boolean, animated: boolean): NavigationAttribute;
|
||||
|
||||
/**
|
||||
* Hide navigation back button
|
||||
*
|
||||
@ -2558,6 +2619,19 @@ declare class NavigationAttribute extends CommonMethod<NavigationAttribute> {
|
||||
*/
|
||||
hideToolBar(value: boolean): NavigationAttribute;
|
||||
|
||||
/**
|
||||
* Hide tool bar
|
||||
*
|
||||
* @param { boolean } hide
|
||||
* @param { boolean } animated
|
||||
* @returns { NavigationAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
hideToolBar(hide: boolean, animated: boolean): NavigationAttribute;
|
||||
|
||||
/**
|
||||
* Trigger callback when title mode change finished at free mode.
|
||||
*
|
||||
@ -2693,6 +2767,17 @@ declare class NavigationAttribute extends CommonMethod<NavigationAttribute> {
|
||||
* @since 12
|
||||
*/
|
||||
systemBarStyle(style: Optional<SystemBarStyle>): NavigationAttribute;
|
||||
|
||||
/**
|
||||
* Set the Navigation can be restored after the application is terminated.
|
||||
* To enable this attribute, a navigation id must be set.
|
||||
*
|
||||
* @param { boolean } recoverable - navigation can be recovered.
|
||||
* @returns { NavigationAttribute } Returns the instance of the NavigationAttribute.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 13
|
||||
*/
|
||||
recoverable(recoverable: Optional<boolean>): NavigationAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
|
670
api/@internal/component/ets/particle.d.ts
vendored
670
api/@internal/component/ets/particle.d.ts
vendored
@ -18,6 +18,110 @@
|
||||
* @kit ArkUI
|
||||
*/
|
||||
|
||||
/**
|
||||
* Defines a pair of given type for particle.
|
||||
*
|
||||
* @typedef { [T1, T2] } ParticleTuple
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
declare type ParticleTuple<T1, T2> = [T1, T2];
|
||||
|
||||
/**
|
||||
* Defines velocity options.
|
||||
*
|
||||
* @typedef VelocityOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
declare interface VelocityOptions {
|
||||
/**
|
||||
* Particle speed.
|
||||
* @type { ParticleTuple<number, number> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Particle speed.
|
||||
* @type { ParticleTuple<number, number> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
speed: ParticleTuple<number, number>;
|
||||
|
||||
/**
|
||||
* Angle of particle's direction.
|
||||
* @type { ParticleTuple<number, number> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Angle of particle's direction.
|
||||
* @type { ParticleTuple<number, number> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
angle: ParticleTuple<number, number>;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines acceleration options.
|
||||
*
|
||||
* @typedef AccelerationOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
declare interface AccelerationOptions<
|
||||
ACC_SPEED_UPDATER extends ParticleUpdater,
|
||||
ACC_ANGLE_UPDATER extends ParticleUpdater
|
||||
> {
|
||||
/**
|
||||
* Speed property options.
|
||||
* @type { ?ParticlePropertyOptions<number, ACC_SPEED_UPDATER> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Speed property options.
|
||||
* @type { ?ParticlePropertyOptions<number, ACC_SPEED_UPDATER> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
speed?: ParticlePropertyOptions<number, ACC_SPEED_UPDATER>;
|
||||
|
||||
/**
|
||||
* Angle property options.
|
||||
* @type { ?ParticlePropertyOptions<number, ACC_ANGLE_UPDATER> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Angle property options.
|
||||
* @type { ?ParticlePropertyOptions<number, ACC_ANGLE_UPDATER> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
angle?: ParticlePropertyOptions<number, ACC_ANGLE_UPDATER>;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines the ParticleOptions Interface.
|
||||
* @interface ParticleOptions
|
||||
@ -133,10 +237,16 @@ interface ParticleOptions<
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
velocity?: {
|
||||
speed: [number, number];
|
||||
angle: [number, number];
|
||||
};
|
||||
/**
|
||||
* Particle velocity.
|
||||
* @type { ?VelocityOptions }
|
||||
* @default {speed:[0,0];angle:[0,0]}
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
velocity?: VelocityOptions;
|
||||
|
||||
/**
|
||||
* Particle acceleration.
|
||||
@ -155,10 +265,16 @@ interface ParticleOptions<
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
acceleration?: {
|
||||
speed?: ParticlePropertyOptions<number, ACC_SPEED_UPDATER>;
|
||||
angle?: ParticlePropertyOptions<number, ACC_ANGLE_UPDATER>;
|
||||
};
|
||||
/**
|
||||
* Particle acceleration.
|
||||
* @type { ?AccelerationOptions<ACC_SPEED_UPDATER, ACC_ANGLE_UPDATER> }
|
||||
* @default {speed:{range:[0,0]};angle:{range:[0,0]}}
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
acceleration?: AccelerationOptions<ACC_SPEED_UPDATER, ACC_ANGLE_UPDATER>;
|
||||
|
||||
/**
|
||||
* Particle spin.
|
||||
@ -262,7 +378,15 @@ interface ImageParticleParameters {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
size: [Dimension, Dimension];
|
||||
/**
|
||||
* Particle image size.
|
||||
* @type { ParticleTuple<Dimension, Dimension> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
size: ParticleTuple<Dimension, Dimension>;
|
||||
|
||||
/**
|
||||
* Image fit.
|
||||
@ -391,6 +515,98 @@ interface EmitterProperty {
|
||||
size?: SizeT<number>;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines parameters of particles used by emitters.
|
||||
*
|
||||
* @typedef EmitterParticleOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
interface EmitterParticleOptions<PARTICLE extends ParticleType> {
|
||||
/**
|
||||
* Particle type.
|
||||
* @type { PARTICLE }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Particle type.
|
||||
* @type { PARTICLE }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
type: PARTICLE;
|
||||
/**
|
||||
* Particle config.
|
||||
* @type { ParticleConfigs[PARTICLE] }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Particle config.
|
||||
* @type { ParticleConfigs[PARTICLE] }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
config: ParticleConfigs[PARTICLE];
|
||||
|
||||
/**
|
||||
* Particle count.
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Particle count.
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
count: number;
|
||||
|
||||
/**
|
||||
* Particle lifetime.
|
||||
* @type { ?number }
|
||||
* @default 1000
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Particle lifetime.
|
||||
* @type { ?number }
|
||||
* @default 1000
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
lifetime?: number;
|
||||
|
||||
/**
|
||||
* Particle lifetimeRange,value range [0, ∞).
|
||||
* when lifetimeRange>lifetime,minimum lifetime is 0.
|
||||
* @type { ?number }
|
||||
* @default 0
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
lifetimeRange?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines the emitter Options.
|
||||
* @interface EmitterOptions
|
||||
@ -422,88 +638,15 @@ interface EmitterOptions<PARTICLE extends ParticleType> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
particle: {
|
||||
/**
|
||||
* Particle type.
|
||||
* @type { PARTICLE }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Particle type.
|
||||
* @type { PARTICLE }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
type: PARTICLE;
|
||||
/**
|
||||
* Particle config.
|
||||
* @type { ParticleConfigs[PARTICLE] }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Particle config.
|
||||
* @type { ParticleConfigs[PARTICLE] }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
config: ParticleConfigs[PARTICLE];
|
||||
|
||||
/**
|
||||
* Particle count.
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Particle count.
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
count: number;
|
||||
|
||||
/**
|
||||
* Particle lifetime.
|
||||
* @type { ?number }
|
||||
* @default 1000
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Particle lifetime.
|
||||
* @type { ?number }
|
||||
* @default 1000
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
lifetime?: number;
|
||||
|
||||
/**
|
||||
* Particle lifetimeRange,value range [0, ∞).
|
||||
* when lifetimeRange>lifetime,minimum lifetime is 0.
|
||||
* @type { ?number }
|
||||
* @default 0
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
lifetimeRange?: number;
|
||||
};
|
||||
/**
|
||||
* Set particle config.
|
||||
* @type { EmitterParticleOptions<PARTICLE> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
particle: EmitterParticleOptions<PARTICLE>;
|
||||
|
||||
/**
|
||||
* Emitting rate, that is, the number of particles produced per second.
|
||||
@ -564,7 +707,18 @@ interface EmitterOptions<PARTICLE extends ParticleType> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
position?: [Dimension, Dimension];
|
||||
/**
|
||||
* Position of emitter.
|
||||
* The first element means X-axis location.
|
||||
* The second element means the Y-axis location.
|
||||
* @type { ?ParticleTuple<Dimension, Dimension> }
|
||||
* @default [0,0]
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
position?: ParticleTuple<Dimension, Dimension>;
|
||||
|
||||
/**
|
||||
* Size of emitter.
|
||||
@ -587,7 +741,18 @@ interface EmitterOptions<PARTICLE extends ParticleType> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
size?: [Dimension, Dimension];
|
||||
/**
|
||||
* Size of emitter.
|
||||
* The first element means emitter width.
|
||||
* The second element means emitter height.
|
||||
* @type { ?ParticleTuple<Dimension, Dimension> }
|
||||
* @default ['100%','100%']
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
size?: ParticleTuple<Dimension, Dimension>;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -640,7 +805,15 @@ interface ParticlePropertyUpdaterConfigs<T> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
[ParticleUpdater.RANDOM]: [T, T];
|
||||
/**
|
||||
* Random effect of particle updater.
|
||||
* @type { ParticleTuple<T, T> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
[ParticleUpdater.RANDOM]: ParticleTuple<T, T>;
|
||||
|
||||
/**
|
||||
* Curve effect of particle updater.
|
||||
@ -660,6 +833,175 @@ interface ParticlePropertyUpdaterConfigs<T> {
|
||||
[ParticleUpdater.CURVE]: Array<ParticlePropertyAnimation<T>>;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines the particle updater options.
|
||||
*
|
||||
* @typedef ParticleUpdaterOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
interface ParticleUpdaterOptions<TYPE, UPDATER extends ParticleUpdater> {
|
||||
/**
|
||||
* Particle updater type.
|
||||
* @type { UPDATER }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Particle updater type.
|
||||
* @type { UPDATER }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
type: UPDATER;
|
||||
|
||||
/**
|
||||
* Particle updater configuration.
|
||||
* @type { ParticlePropertyUpdaterConfigs<TYPE>[UPDATER] }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Particle updater configuration.
|
||||
* @type { ParticlePropertyUpdaterConfigs<TYPE>[UPDATER] }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
config: ParticlePropertyUpdaterConfigs<TYPE>[UPDATER];
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines the particle color options.
|
||||
*
|
||||
* @typedef ParticleColorOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
interface ParticleColorOptions {
|
||||
/**
|
||||
* Red component of particle color.
|
||||
* @type { ParticleTuple<number, number> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Red component of particle color.
|
||||
* @type { ParticleTuple<number, number> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
r: ParticleTuple<number, number>;
|
||||
|
||||
/**
|
||||
* Green component of particle color.
|
||||
* @type { ParticleTuple<number, number> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Green component of particle color.
|
||||
* @type { ParticleTuple<number, number> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
g: ParticleTuple<number, number>;
|
||||
|
||||
/**
|
||||
* Blue component of particle color.
|
||||
* @type { ParticleTuple<number, number> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Blue component of particle color.
|
||||
* @type { ParticleTuple<number, number> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
b: ParticleTuple<number, number>;
|
||||
|
||||
/**
|
||||
* Opacity component of particle color.
|
||||
* @type { ParticleTuple<number, number> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Opacity component of particle color.
|
||||
* @type { ParticleTuple<number, number> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
a: ParticleTuple<number, number>;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines the particle color updater options.
|
||||
*
|
||||
* @typedef ParticleColorUpdaterOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
interface ParticleColorUpdaterOptions<UPDATER extends ParticleUpdater> {
|
||||
/**
|
||||
* Color updater.
|
||||
* @type { UPDATER }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Color updater.
|
||||
* @type { UPDATER }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
type: UPDATER;
|
||||
|
||||
/**
|
||||
* Color updater configuration.
|
||||
* @type { ParticleColorPropertyUpdaterConfigs[UPDATER] }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Color updater configuration.
|
||||
* @type { ParticleColorPropertyUpdaterConfigs[UPDATER] }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
config: ParticleColorPropertyUpdaterConfigs[UPDATER];
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines the particle property Options.
|
||||
* @interface ParticlePropertyOptions
|
||||
@ -691,7 +1033,15 @@ interface ParticlePropertyOptions<TYPE, UPDATER extends ParticleUpdater> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
range: [TYPE, TYPE];
|
||||
/**
|
||||
* Initial range, within which the initial value are randomly generated.
|
||||
* @type { ParticleTuple<TYPE, TYPE> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
range: ParticleTuple<TYPE, TYPE>;
|
||||
|
||||
/**
|
||||
* Particle property updater.
|
||||
@ -710,10 +1060,16 @@ interface ParticlePropertyOptions<TYPE, UPDATER extends ParticleUpdater> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
updater?: {
|
||||
type: UPDATER;
|
||||
config: ParticlePropertyUpdaterConfigs<TYPE>[UPDATER];
|
||||
};
|
||||
/**
|
||||
* Particle property updater.
|
||||
* @type { ?ParticleUpdaterOptions<TYPE, UPDATER> }
|
||||
* @default {type:UPDATER.NONE;config:ParticlePropertyUpdaterConfigs<UPDATER.NONE>[UPDATER.NONE]}
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
updater?: ParticleUpdaterOptions<TYPE, UPDATER>;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -766,12 +1122,15 @@ interface ParticleColorPropertyUpdaterConfigs {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
[ParticleUpdater.RANDOM]: {
|
||||
r: [number, number];
|
||||
g: [number, number];
|
||||
b: [number, number];
|
||||
a: [number, number];
|
||||
};
|
||||
/**
|
||||
* Random effect of particle color property updater.
|
||||
* @type { ParticleColorOptions }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
[ParticleUpdater.RANDOM]: ParticleColorOptions;
|
||||
|
||||
/**
|
||||
* Curve effect of particle color property updater.
|
||||
@ -824,7 +1183,15 @@ interface ParticleColorPropertyOptions<UPDATER extends ParticleUpdater> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
range: [ResourceColor, ResourceColor];
|
||||
/**
|
||||
* Initial color range, within which the initial color is randomly generated.
|
||||
* @type { ParticleTuple<ResourceColor, ResourceColor> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
range: ParticleTuple<ResourceColor, ResourceColor>;
|
||||
|
||||
/**
|
||||
* Distribution type of particle color.
|
||||
@ -854,10 +1221,16 @@ interface ParticleColorPropertyOptions<UPDATER extends ParticleUpdater> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
updater?: {
|
||||
type: UPDATER;
|
||||
config: ParticleColorPropertyUpdaterConfigs[UPDATER];
|
||||
};
|
||||
/**
|
||||
* Particle color property updater.
|
||||
* @type { ?ParticleColorUpdaterOptions<UPDATER> }
|
||||
* @default {type:UPDATER.NONE;config:ParticleColorPropertyUpdaterConfigs[UPDATER.NONE]}
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
updater?: ParticleColorUpdaterOptions<UPDATER>;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -964,6 +1337,52 @@ interface ParticlePropertyAnimation<T> {
|
||||
curve?: Curve | ICurve;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines the particle array.
|
||||
*
|
||||
* @typedef Particles
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
interface Particles<
|
||||
PARTICLE extends ParticleType,
|
||||
COLOR_UPDATER extends ParticleUpdater,
|
||||
OPACITY_UPDATER extends ParticleUpdater,
|
||||
SCALE_UPDATER extends ParticleUpdater,
|
||||
ACC_SPEED_UPDATER extends ParticleUpdater,
|
||||
ACC_ANGLE_UPDATER extends ParticleUpdater,
|
||||
SPIN_UPDATER extends ParticleUpdater
|
||||
> {
|
||||
/**
|
||||
* Array of particles.
|
||||
* @type { Array<ParticleOptions<PARTICLE, COLOR_UPDATER, OPACITY_UPDATER, SCALE_UPDATER, ACC_SPEED_UPDATER, ACC_ANGLE_UPDATER, SPIN_UPDATER>> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Array of particles.
|
||||
* @type { Array<ParticleOptions<PARTICLE, COLOR_UPDATER, OPACITY_UPDATER, SCALE_UPDATER, ACC_SPEED_UPDATER, ACC_ANGLE_UPDATER, SPIN_UPDATER>> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
particles: Array<
|
||||
ParticleOptions<
|
||||
PARTICLE,
|
||||
COLOR_UPDATER,
|
||||
OPACITY_UPDATER,
|
||||
SCALE_UPDATER,
|
||||
ACC_SPEED_UPDATER,
|
||||
ACC_ANGLE_UPDATER,
|
||||
SPIN_UPDATER
|
||||
>
|
||||
>;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines the particle Interface.
|
||||
* @interface ParticleInterface
|
||||
@ -999,6 +1418,15 @@ interface ParticleInterface {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* create a particle array.
|
||||
* @param { Particles<PARTICLE, COLOR_UPDATER, OPACITY_UPDATER, SCALE_UPDATER, ACC_SPEED_UPDATER, ACC_ANGLE_UPDATER, SPIN_UPDATER> } particles - Array of particles.
|
||||
* @returns { ParticleAttribute } Returns the particle attribute.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
<
|
||||
PARTICLE extends ParticleType,
|
||||
COLOR_UPDATER extends ParticleUpdater,
|
||||
@ -1007,19 +1435,15 @@ interface ParticleInterface {
|
||||
ACC_SPEED_UPDATER extends ParticleUpdater,
|
||||
ACC_ANGLE_UPDATER extends ParticleUpdater,
|
||||
SPIN_UPDATER extends ParticleUpdater
|
||||
>(value: {
|
||||
particles: Array<
|
||||
ParticleOptions<
|
||||
PARTICLE,
|
||||
COLOR_UPDATER,
|
||||
OPACITY_UPDATER,
|
||||
SCALE_UPDATER,
|
||||
ACC_SPEED_UPDATER,
|
||||
ACC_ANGLE_UPDATER,
|
||||
SPIN_UPDATER
|
||||
>
|
||||
>;
|
||||
}): ParticleAttribute;
|
||||
>(particles: Particles<
|
||||
PARTICLE,
|
||||
COLOR_UPDATER,
|
||||
OPACITY_UPDATER,
|
||||
SCALE_UPDATER,
|
||||
ACC_SPEED_UPDATER,
|
||||
ACC_ANGLE_UPDATER,
|
||||
SPIN_UPDATER
|
||||
>): ParticleAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
|
230
api/@internal/component/ets/rating.d.ts
vendored
230
api/@internal/component/ets/rating.d.ts
vendored
@ -18,6 +18,210 @@
|
||||
* @kit ArkUI
|
||||
*/
|
||||
|
||||
/**
|
||||
* Define options used to construct a rating.
|
||||
*
|
||||
* @interface RatingOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare interface RatingOptions {
|
||||
/**
|
||||
* Rating option.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Rating option.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Rating option.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Rating option.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
rating: number;
|
||||
|
||||
/**
|
||||
* Indicator option.
|
||||
*
|
||||
* @type { ?boolean }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Indicator option.
|
||||
*
|
||||
* @type { ?boolean }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Indicator option.
|
||||
*
|
||||
* @type { ?boolean }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Indicator option.
|
||||
*
|
||||
* @type { ?boolean }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
indicator?: boolean
|
||||
}
|
||||
|
||||
/**
|
||||
* Define star style options.
|
||||
*
|
||||
* @interface StarStyleOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare interface StarStyleOptions {
|
||||
/**
|
||||
* Background URI option.
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Background URI option.
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Background URI option.
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Background URI option.
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
backgroundUri: string;
|
||||
|
||||
/**
|
||||
* Foreground URI option.
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Foreground URI option.
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Foreground URI option.
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Foreground URI option.
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
foregroundUri: string;
|
||||
|
||||
/**
|
||||
* Secondary URI option.
|
||||
*
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Secondary URI option.
|
||||
*
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Secondary URI option.
|
||||
*
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Secondary URI option.
|
||||
*
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
secondaryUri?: string
|
||||
}
|
||||
|
||||
/**
|
||||
* Provides the interface for scoring bars.
|
||||
*
|
||||
@ -91,7 +295,18 @@ interface RatingInterface {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
(options?: { rating: number; indicator?: boolean }): RatingAttribute;
|
||||
/**
|
||||
* Called when a score bar is created.
|
||||
*
|
||||
* @param { RatingOptions } [options] - rating options
|
||||
* @returns { RatingAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
(options?: RatingOptions): RatingAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -313,7 +528,18 @@ declare class RatingAttribute extends CommonMethod<RatingAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
starStyle(value: { backgroundUri: string; foregroundUri: string; secondaryUri?: string }): RatingAttribute;
|
||||
/**
|
||||
* Called when a picture is set.
|
||||
*
|
||||
* @param { StarStyleOptions } options - star style options
|
||||
* @returns { RatingAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
starStyle(options: StarStyleOptions): RatingAttribute;
|
||||
|
||||
/**
|
||||
* Called when the star rating of the operation scoring bar changes.
|
||||
|
25
api/@internal/component/ets/rich_editor.d.ts
vendored
25
api/@internal/component/ets/rich_editor.d.ts
vendored
@ -2721,6 +2721,17 @@ declare interface SelectionMenuOptions {
|
||||
* @since 12
|
||||
*/
|
||||
onDisappear?: Callback<void>;
|
||||
|
||||
/**
|
||||
* Menu type, default value is MenuType.SELECTION_MENU.
|
||||
*
|
||||
* @type { ?MenuType }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
menuType?: MenuType;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -3734,7 +3745,7 @@ declare class RichEditorAttribute extends CommonMethod<RichEditorAttribute> {
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
* @since 12
|
||||
*/
|
||||
enableKeyboardOnFocus(isEnabled: boolean): RichEditorAttribute;
|
||||
|
||||
@ -3749,6 +3760,18 @@ declare class RichEditorAttribute extends CommonMethod<RichEditorAttribute> {
|
||||
* @since 13
|
||||
*/
|
||||
enableHapticFeedback(isEnabled: boolean): RichEditorAttribute;
|
||||
|
||||
/**
|
||||
* Define bar state of the RichEditor.
|
||||
*
|
||||
* @param { BarState } state - bar state.
|
||||
* @returns { RichEditorAttribute } returns the instance of the RichEditorAttribute.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
barState(state: BarState): RichEditorAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
|
61
api/@internal/component/ets/row.d.ts
vendored
61
api/@internal/component/ets/row.d.ts
vendored
@ -18,6 +18,54 @@
|
||||
* @kit ArkUI
|
||||
*/
|
||||
|
||||
/**
|
||||
* Define options used to construct a row.
|
||||
*
|
||||
* @interface RowOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare interface RowOptions {
|
||||
/**
|
||||
* Row spacing.
|
||||
*
|
||||
* @type { ?(string | number) }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Row spacing.
|
||||
*
|
||||
* @type { ?(string | number) }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Row spacing.
|
||||
*
|
||||
* @type { ?(string | number) }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Row spacing.
|
||||
*
|
||||
* @type { ?(string | number) }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
space?: string | number;
|
||||
}
|
||||
|
||||
/**
|
||||
* The components are laid out horizontally
|
||||
*
|
||||
@ -91,7 +139,18 @@ interface RowInterface {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
(value?: { space?: string | number }): RowAttribute;
|
||||
/**
|
||||
* Called when the layout is set in the horizontal direction.
|
||||
*
|
||||
* @param { ?RowOptions } options - row options
|
||||
* @returns { RowAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
(options?: RowOptions): RowAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
|
274
api/@internal/component/ets/scroll.d.ts
vendored
274
api/@internal/component/ets/scroll.d.ts
vendored
@ -433,76 +433,16 @@ declare class Scroller {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
scrollTo(value: {
|
||||
/**
|
||||
* The X-axis offset.
|
||||
*
|
||||
* @type { number | string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* The X-axis offset.
|
||||
*
|
||||
* @type { number | string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
xOffset: number | string;
|
||||
|
||||
/**
|
||||
* The Y-axis offset.
|
||||
*
|
||||
* @type { number | string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* The Y-axis offset.
|
||||
*
|
||||
* @type { number | string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
yOffset: number | string;
|
||||
|
||||
/**
|
||||
* Descriptive animation.
|
||||
*
|
||||
* @type { ?({ duration?: number; curve?: Curve | ICurve } | boolean) } The object type provides custom animation parameters
|
||||
* and the boolean type enables default spring animation.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Descriptive animation.
|
||||
*
|
||||
* @type { ?({ duration?: number; curve?: Curve | ICurve } | boolean) } The object type provides custom animation parameters
|
||||
* and the boolean type enables default spring animation.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Descriptive animation.
|
||||
*
|
||||
* @type { ?( ScrollAnimationOptions | boolean) } The ScrollAnimationOptions type provides custom animation parameters
|
||||
* and the boolean type enables default spring animation.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
animation?: ScrollAnimationOptions | boolean;
|
||||
});
|
||||
/**
|
||||
* Called when the setting slides to the specified position.
|
||||
*
|
||||
* @param { ScrollOptions } options - scroll options
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
scrollTo(options: ScrollOptions);
|
||||
|
||||
/**
|
||||
* Called when scrolling to the edge of the container.
|
||||
@ -580,16 +520,7 @@ declare class Scroller {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Called when page turning mode is set.
|
||||
*
|
||||
* @param { ScrollPageOptions } value
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
scrollPage(value: ScrollPageOptions);
|
||||
scrollPage(value: { next: boolean });
|
||||
|
||||
/**
|
||||
* Called when page turning mode is set.
|
||||
@ -768,35 +699,83 @@ declare class Scroller {
|
||||
}
|
||||
|
||||
/**
|
||||
* Define scroll page options
|
||||
* @interface ScrollPageOptions
|
||||
* Define scroll options.
|
||||
*
|
||||
* @interface ScrollOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
declare interface ScrollPageOptions {
|
||||
declare interface ScrollOptions {
|
||||
/**
|
||||
* Control whether to scroll to the next page or the previous page.
|
||||
* The X-axis offset.
|
||||
*
|
||||
* @type { boolean }
|
||||
* @type { number | string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* The X-axis offset.
|
||||
*
|
||||
* @type { number | string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
* @since 11
|
||||
*/
|
||||
next: boolean;
|
||||
xOffset: number | string;
|
||||
|
||||
/**
|
||||
* Set whether the scrollPage have animate.
|
||||
* The Y-axis offset.
|
||||
*
|
||||
* @type { ?boolean }
|
||||
* @default false
|
||||
* @type { number | string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* The Y-axis offset.
|
||||
*
|
||||
* @type { number | string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
yOffset: number | string;
|
||||
|
||||
/**
|
||||
* Descriptive animation.
|
||||
*
|
||||
* @type { ?({ duration?: number; curve?: Curve | ICurve } | boolean) } The object type provides custom animation parameters
|
||||
* and the boolean type enables default spring animation.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Descriptive animation.
|
||||
*
|
||||
* @type { ?({ duration?: number; curve?: Curve | ICurve } | boolean) } The object type provides custom animation parameters
|
||||
* and the boolean type enables default spring animation.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Descriptive animation.
|
||||
*
|
||||
* @type { ?( ScrollAnimationOptions | boolean) } The ScrollAnimationOptions type provides custom animation parameters
|
||||
* and the boolean type enables default spring animation.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
animation?: boolean;
|
||||
animation?: ScrollAnimationOptions | boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -949,6 +928,69 @@ interface ScrollInterface {
|
||||
(scroller?: Scroller): ScrollAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines a Scroll onScrollEdge callback.
|
||||
*
|
||||
* @typedef { function } OnScrollEdgeCallback
|
||||
* @param { Edge } side - the edge position scrolled to
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare type OnScrollEdgeCallback = (side: Edge) => void;
|
||||
|
||||
/**
|
||||
* The data returned by the event handler when onScrollFrameBegin.
|
||||
*
|
||||
* @interface OnScrollFrameBeginHandlerResult
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
interface OnScrollFrameBeginHandlerResult {
|
||||
/**
|
||||
* Actual sliding amount, unit vp.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Actual sliding amount, unit vp.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Actual sliding amount, unit vp.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
offsetRemain: number;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines a Scroll onScrollFrameBegin callback.
|
||||
*
|
||||
* @typedef { function } OnScrollFrameBeginCallback
|
||||
* @param { number } offset - The upcoming sliding amount, unit vp
|
||||
* @param { ScrollState } state - current sliding status
|
||||
* @returns { OnScrollFrameBeginHandlerResult } data - the scroll data return by handler
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare type OnScrollFrameBeginCallback = (offset: number, state: ScrollState) => OnScrollFrameBeginHandlerResult;
|
||||
|
||||
/**
|
||||
* Defines the scroll attribute functions.
|
||||
*
|
||||
@ -1087,7 +1129,17 @@ declare class ScrollAttribute extends ScrollableCommonMethod<ScrollAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onScrollEdge(event: (side: Edge) => void): ScrollAttribute;
|
||||
/**
|
||||
* Called when scrolling to the edge of the container.
|
||||
*
|
||||
* @param { OnScrollEdgeCallback } event
|
||||
* @returns { ScrollAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onScrollEdge(event: OnScrollEdgeCallback): ScrollAttribute;
|
||||
|
||||
/**
|
||||
* Called when scrolling start.
|
||||
@ -1116,7 +1168,17 @@ declare class ScrollAttribute extends ScrollableCommonMethod<ScrollAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onScrollStart(event: () => void): ScrollAttribute;
|
||||
/**
|
||||
* Called when scrolling start.
|
||||
*
|
||||
* @param { VoidCallback } event
|
||||
* @returns { ScrollAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onScrollStart(event: VoidCallback): ScrollAttribute;
|
||||
|
||||
/**
|
||||
* Called when scrolling has stopped.
|
||||
@ -1157,7 +1219,17 @@ declare class ScrollAttribute extends ScrollableCommonMethod<ScrollAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onScrollStop(event: () => void): ScrollAttribute;
|
||||
/**
|
||||
* Called when scrolling has stopped.
|
||||
*
|
||||
* @param { VoidCallback } event
|
||||
* @returns { ScrollAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onScrollStop(event: VoidCallback): ScrollAttribute;
|
||||
|
||||
/**
|
||||
* Called when the status of the scroll bar is set.
|
||||
@ -1303,7 +1375,17 @@ declare class ScrollAttribute extends ScrollableCommonMethod<ScrollAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onScrollFrameBegin(event: (offset: number, state: ScrollState) => { offsetRemain: number }): ScrollAttribute;
|
||||
/**
|
||||
* Called when scrolling begin each frame.
|
||||
*
|
||||
* @param { OnScrollFrameBeginCallback } event
|
||||
* @returns { ScrollAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onScrollFrameBegin(event: OnScrollFrameBeginCallback): ScrollAttribute;
|
||||
|
||||
/**
|
||||
* Called to setting the nested scroll options.
|
||||
|
257
api/@internal/component/ets/search.d.ts
vendored
257
api/@internal/component/ets/search.d.ts
vendored
@ -300,6 +300,92 @@ declare enum SearchType {
|
||||
URL = 13,
|
||||
}
|
||||
|
||||
/**
|
||||
* Options used to construct the search.
|
||||
*
|
||||
* @typedef SearchOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
declare interface SearchOptions {
|
||||
/**
|
||||
* Text input in the search text box.
|
||||
*
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Text input in the search text box.
|
||||
*
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
value?: string;
|
||||
|
||||
/**
|
||||
* Text displayed when there is no input.
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Text displayed when there is no input.
|
||||
*
|
||||
* @type { ?ResourceStr }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Text displayed when there is no input.
|
||||
*
|
||||
* @type { ?ResourceStr }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
placeholder?: ResourceStr;
|
||||
|
||||
/**
|
||||
* Path to the search icon.
|
||||
*
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Path to the search icon.
|
||||
*
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
icon?: string;
|
||||
|
||||
/**
|
||||
* Controller of the <Search> component.
|
||||
*
|
||||
* @type { ?SearchController }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Controller of the <Search> component.
|
||||
*
|
||||
* @type { ?SearchController }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
controller?: SearchController;
|
||||
}
|
||||
|
||||
/**
|
||||
* The construct function of search
|
||||
*
|
||||
@ -352,82 +438,17 @@ interface SearchInterface {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
(options?: {
|
||||
/**
|
||||
* Text input in the search text box
|
||||
*
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Text input in the search text box
|
||||
*
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
value?: string;
|
||||
|
||||
/**
|
||||
* Text displayed when there is no input
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Text displayed when there is no input
|
||||
*
|
||||
* @type { ?ResourceStr }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Text displayed when there is no input
|
||||
*
|
||||
* @type { ?ResourceStr }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
placeholder?: ResourceStr;
|
||||
|
||||
/**
|
||||
* Path to the search icon
|
||||
*
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Path to the search icon
|
||||
*
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
icon?: string;
|
||||
|
||||
/**
|
||||
* Controller of the <Search> component
|
||||
*
|
||||
* @type { ?SearchController }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Controller of the <Search> component
|
||||
*
|
||||
* @type { ?SearchController }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
controller?: SearchController
|
||||
}): SearchAttribute;
|
||||
/**
|
||||
* The options of SearchInterface.
|
||||
*
|
||||
* @param { SearchOptions } [options] - Search options.
|
||||
* @returns { SearchAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
(options?: SearchOptions): SearchAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -965,7 +986,17 @@ declare class SearchAttribute extends CommonMethod<SearchAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onSubmit(callback: (value: string) => void): SearchAttribute;
|
||||
/**
|
||||
* Call the function when clicked the search button.
|
||||
*
|
||||
* @param { Callback<string> } callback
|
||||
* @returns { SearchAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onSubmit(callback: Callback<string>): SearchAttribute;
|
||||
|
||||
/**
|
||||
* Call the function when editing the input text
|
||||
@ -1025,7 +1056,17 @@ declare class SearchAttribute extends CommonMethod<SearchAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onTextSelectionChange(callback: (selectionStart: number, selectionEnd: number) => void): SearchAttribute;
|
||||
/**
|
||||
* Called when the text selection changes.
|
||||
*
|
||||
* @param { OnTextSelectionChangeCallback } callback - Callback of the listened event.
|
||||
* @returns { SearchAttribute } Returns the instance of the SearchAttribute.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onTextSelectionChange(callback: OnTextSelectionChangeCallback): SearchAttribute;
|
||||
|
||||
/**
|
||||
* Called when the content scrolls.
|
||||
@ -1046,7 +1087,17 @@ declare class SearchAttribute extends CommonMethod<SearchAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onContentScroll(callback: (totalOffsetX: number, totalOffsetY: number) => void): SearchAttribute;
|
||||
/**
|
||||
* Called when the content scrolls.
|
||||
*
|
||||
* @param { OnContentScrollCallback } callback - Callback of the listened event.
|
||||
* @returns { SearchAttribute } Returns the instance of the SearchAttribute.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onContentScroll(callback: OnContentScrollCallback): SearchAttribute;
|
||||
|
||||
/**
|
||||
* Called when using the Clipboard menu
|
||||
@ -1075,7 +1126,17 @@ declare class SearchAttribute extends CommonMethod<SearchAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onCopy(callback: (value: string) => void): SearchAttribute;
|
||||
/**
|
||||
* Called when using the Clipboard menu.
|
||||
*
|
||||
* @param { Callback<string> } callback
|
||||
* @returns { SearchAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onCopy(callback: Callback<string>): SearchAttribute;
|
||||
|
||||
/**
|
||||
* Called when using the Clipboard menu
|
||||
@ -1104,7 +1165,17 @@ declare class SearchAttribute extends CommonMethod<SearchAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onCut(callback: (value: string) => void): SearchAttribute;
|
||||
/**
|
||||
* Called when using the Clipboard menu.
|
||||
*
|
||||
* @param { Callback<string> } callback
|
||||
* @returns { SearchAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onCut(callback: Callback<string>): SearchAttribute;
|
||||
|
||||
/**
|
||||
* Called when using the Clipboard menu
|
||||
@ -1136,7 +1207,17 @@ declare class SearchAttribute extends CommonMethod<SearchAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onPaste(callback: (value: string, event: PasteEvent) => void): SearchAttribute;
|
||||
/**
|
||||
* Called when using the Clipboard menu.
|
||||
*
|
||||
* @param { OnPasteCallback } callback - Executed when a paste operation is performed.
|
||||
* @returns { SearchAttribute } Returns the instance of the SearchAttribute.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onPaste(callback: OnPasteCallback): SearchAttribute;
|
||||
|
||||
/**
|
||||
* Called when the copy option is set.
|
||||
@ -1458,6 +1539,18 @@ declare class SearchAttribute extends CommonMethod<SearchAttribute> {
|
||||
* @since 12
|
||||
*/
|
||||
enablePreviewText(enable: boolean): SearchAttribute;
|
||||
|
||||
/**
|
||||
* Enable or disable haptic feedback.
|
||||
*
|
||||
* @param { boolean } isEnabled - Default value is true, set false to disable haptic feedback.
|
||||
* @returns { SearchAttribute } returns the instance of the SearchAttribute.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
enableHapticFeedback(isEnabled: boolean): SearchAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
|
104
api/@internal/component/ets/sidebar.d.ts
vendored
104
api/@internal/component/ets/sidebar.d.ts
vendored
@ -177,6 +177,95 @@ declare enum SideBarPosition {
|
||||
End,
|
||||
}
|
||||
|
||||
/**
|
||||
* ButtonStyle icons.
|
||||
*
|
||||
* @typedef ButtonStyleIcon
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
declare interface ButtonIconOptions {
|
||||
/**
|
||||
* Defines whether an icon is shown.
|
||||
*
|
||||
* @type { string | PixelMap | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Defines whether an icon is shown.
|
||||
*
|
||||
* @type { string | PixelMap | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Defines whether an icon is shown.
|
||||
*
|
||||
* @type { string | PixelMap | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
shown: string | PixelMap | Resource;
|
||||
|
||||
/**
|
||||
* Defines whether an icon is hidden.
|
||||
*
|
||||
* @type { string | PixelMap | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Defines whether an icon is hidden.
|
||||
*
|
||||
* @type { string | PixelMap | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Defines whether an icon is hidden.
|
||||
*
|
||||
* @type { string | PixelMap | Resource }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
hidden: string | PixelMap | Resource;
|
||||
|
||||
/**
|
||||
* Defines whether an icon is switching.
|
||||
*
|
||||
* @type { ?(string | PixelMap | Resource) }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Defines whether an icon is switching.
|
||||
*
|
||||
* @type { ?(string | PixelMap | Resource) }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Defines whether an icon is switching.
|
||||
*
|
||||
* @type { ?(string | PixelMap | Resource) }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
switching?: string | PixelMap | Resource;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the control button style
|
||||
*
|
||||
@ -342,11 +431,16 @@ declare interface ButtonStyle {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
icons?: {
|
||||
shown: string | PixelMap | Resource;
|
||||
hidden: string | PixelMap | Resource;
|
||||
switching?: string | PixelMap | Resource;
|
||||
};
|
||||
/**
|
||||
* Set the button icon when sidebar status has changed
|
||||
*
|
||||
* @type { ?ButtonIconOptions }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
icons?: ButtonIconOptions;
|
||||
}
|
||||
|
||||
/**
|
||||
|
61
api/@internal/component/ets/stack.d.ts
vendored
61
api/@internal/component/ets/stack.d.ts
vendored
@ -18,6 +18,54 @@
|
||||
* @kit ArkUI
|
||||
*/
|
||||
|
||||
/**
|
||||
* Options used to construct the stack.
|
||||
*
|
||||
* @interface StackOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare interface StackOptions {
|
||||
/**
|
||||
* Set the alignment of sub components within the container.
|
||||
*
|
||||
* @type { ?Alignment }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Set the alignment of sub components within the container.
|
||||
*
|
||||
* @type { ?Alignment }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Set the alignment of sub components within the container.
|
||||
*
|
||||
* @type { ?Alignment }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Set the alignment of sub components within the container.
|
||||
*
|
||||
* @type { ?Alignment }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
alignContent?: Alignment;
|
||||
}
|
||||
|
||||
/**
|
||||
* Provides ports for stacking containers.
|
||||
*
|
||||
@ -91,7 +139,18 @@ interface StackInterface {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
(value?: { alignContent?: Alignment }): StackAttribute;
|
||||
/**
|
||||
* Set the options.
|
||||
*
|
||||
* @param { ?StackOptions } options - stack options
|
||||
* @returns { StackAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
(options?: StackOptions): StackAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
|
10
api/@internal/component/ets/styled_string.d.ts
vendored
10
api/@internal/component/ets/styled_string.d.ts
vendored
@ -1632,6 +1632,16 @@ declare abstract class CustomSpan {
|
||||
* @since 12
|
||||
*/
|
||||
abstract onDraw(context: DrawContext, drawInfo: CustomSpanDrawInfo): void;
|
||||
|
||||
/**
|
||||
* Invalidate all components that use the object, which will cause a re-render of all components.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
invalidate(): void;
|
||||
}
|
||||
|
||||
/**
|
||||
|
73
api/@internal/component/ets/text.d.ts
vendored
73
api/@internal/component/ets/text.d.ts
vendored
@ -18,6 +18,54 @@
|
||||
* @kit ArkUI
|
||||
*/
|
||||
|
||||
/**
|
||||
* Text overflow options.
|
||||
*
|
||||
* @interface TextOverflowOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare interface TextOverflowOptions {
|
||||
/**
|
||||
* Text overflow option.
|
||||
*
|
||||
* @type { TextOverflow }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 7
|
||||
*/
|
||||
/**
|
||||
* Text overflow option.
|
||||
*
|
||||
* @type { TextOverflow }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Text overflow option.
|
||||
*
|
||||
* @type { TextOverflow }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Text overflow option.
|
||||
*
|
||||
* @type { TextOverflow }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
overflow: TextOverflow;
|
||||
}
|
||||
|
||||
/**
|
||||
* Provides an interface for writing texts.
|
||||
*
|
||||
@ -562,7 +610,18 @@ declare class TextAttribute extends CommonMethod<TextAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
textOverflow(value: { overflow: TextOverflow }): TextAttribute;
|
||||
/**
|
||||
* Called when the overflow mode of the font is set.
|
||||
*
|
||||
* @param { TextOverflowOptions } options - Text overflow options.
|
||||
* @returns { TextAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
textOverflow(options: TextOverflowOptions): TextAttribute;
|
||||
|
||||
/**
|
||||
* Called when the font list of text is set.
|
||||
@ -1152,6 +1211,18 @@ declare class TextAttribute extends CommonMethod<TextAttribute> {
|
||||
* @since 12
|
||||
*/
|
||||
halfLeading(halfLeading: boolean): TextAttribute;
|
||||
|
||||
/**
|
||||
* Enable or disable haptic feedback.
|
||||
*
|
||||
* @param { boolean } isEnabled - Default value is true, set false to disable haptic feedback.
|
||||
* @returns { TextAttribute } returns the instance of the TextAttribute.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
enableHapticFeedback(isEnabled: boolean): TextAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
|
12
api/@internal/component/ets/text_area.d.ts
vendored
12
api/@internal/component/ets/text_area.d.ts
vendored
@ -1648,6 +1648,18 @@ declare class TextAreaAttribute extends CommonMethod<TextAreaAttribute> {
|
||||
* @since 12
|
||||
*/
|
||||
enablePreviewText(enable: boolean): TextAreaAttribute;
|
||||
|
||||
/**
|
||||
* Enable or disable haptic feedback.
|
||||
*
|
||||
* @param { boolean } isEnabled - Default value is true, set false to disable haptic feedback.
|
||||
* @returns { TextAreaAttribute } returns the instance of the TextAreaAttribute.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
enableHapticFeedback(isEnabled: boolean): TextAreaAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
|
82
api/@internal/component/ets/text_clock.d.ts
vendored
82
api/@internal/component/ets/text_clock.d.ts
vendored
@ -159,6 +159,72 @@ declare interface TextClockConfiguration extends CommonConfiguration<TextClockCo
|
||||
timeValue: number;
|
||||
}
|
||||
|
||||
/**
|
||||
* Options to construct TextClock component.
|
||||
*
|
||||
* @interface TextClockOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
declare interface TextClockOptions {
|
||||
/**
|
||||
* Time zone offset.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Time zone offset.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Time zone offset.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
timeZoneOffset?: number;
|
||||
|
||||
/**
|
||||
* TextClock controller.
|
||||
*
|
||||
* @type { ?TextClockController }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* TextClock controller.
|
||||
*
|
||||
* @type { ?TextClockController }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* TextClock controller.
|
||||
*
|
||||
* @type { ?TextClockController }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
controller?: TextClockController
|
||||
}
|
||||
|
||||
/**
|
||||
* TextClock component, which provides the text clock capability.
|
||||
*
|
||||
@ -222,7 +288,21 @@ interface TextClockInterface {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
(options?: { timeZoneOffset?: number; controller?: TextClockController }): TextClockAttribute;
|
||||
/**
|
||||
* Construct the text clock component.
|
||||
* Specifies the current time zone.
|
||||
* The valid value is an integer ranging from - 14 to 12,
|
||||
* Where a negative value indicates the eastern time zone, for example, -8.
|
||||
*
|
||||
* @param { TextClockOptions } [options] - TextClock options.
|
||||
* @returns { TextClockAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
(options?: TextClockOptions): TextClockAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
|
31
api/@internal/component/ets/text_common.d.ts
vendored
31
api/@internal/component/ets/text_common.d.ts
vendored
@ -274,6 +274,37 @@ declare enum TextDeleteDirection {
|
||||
FORWARD = 1,
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines menu type.
|
||||
*
|
||||
* @enum { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare enum MenuType {
|
||||
/**
|
||||
* Selection menu.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
SELECTION_MENU = 0,
|
||||
|
||||
/**
|
||||
* Preview menu, only for image.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
PREVIEW_MENU = 1,
|
||||
}
|
||||
|
||||
/**
|
||||
* Provides an interface for deleting value from text.
|
||||
*
|
||||
|
174
api/@internal/component/ets/text_input.d.ts
vendored
174
api/@internal/component/ets/text_input.d.ts
vendored
@ -1101,6 +1101,59 @@ interface PasswordIcon {
|
||||
offIconSrc?: string | Resource;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines a TextInput callback when onSubmit.
|
||||
*
|
||||
* @typedef { function } OnSubmitCallback
|
||||
* @param { EnterKeyType } enterKey - Input method Enter key type.
|
||||
* @param { SubmitEvent } event - The event submitted.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
declare type OnSubmitCallback = (enterKey: EnterKeyType, event: SubmitEvent) => void;
|
||||
|
||||
/**
|
||||
* Defines a TextInput callback when onTextSelectionChange.
|
||||
*
|
||||
* @typedef { function } OnTextSelectionChangeCallback
|
||||
* @param { number } selectionStart - The starting position of the selected text, the starting position of the text is 0.
|
||||
* @param { number } selectionEnd - The end location of the selected text.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
declare type OnTextSelectionChangeCallback = (selectionStart: number, selectionEnd: number) => void;
|
||||
|
||||
/**
|
||||
* Defines a TextInput callback when onContentScroll.
|
||||
*
|
||||
* @typedef { function } OnContentScrollCallback
|
||||
* @param { number } totalOffsetX - The text is offset in px on the horizontal axis of the content area.
|
||||
* @param { number } totalOffsetY - The text is offset in px on the vertical axis of the content area.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
declare type OnContentScrollCallback = (totalOffsetX: number, totalOffsetY: number) => void;
|
||||
|
||||
|
||||
/**
|
||||
* Defines a TextInput callback when onPaste.
|
||||
*
|
||||
* @typedef { function } OnPasteCallback
|
||||
* @param { string } content - The text content of the paste.
|
||||
* @param { PasteEvent } event - User-defined paste event.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
declare type OnPasteCallback = (content: string, event: PasteEvent) => void;
|
||||
|
||||
/**
|
||||
* Defines the TextInput attribute functions.
|
||||
*
|
||||
@ -1345,7 +1398,17 @@ declare class TextInputAttribute extends CommonMethod<TextInputAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onEditChange(callback: (isEditing: boolean) => void): TextInputAttribute;
|
||||
/**
|
||||
* Called when judging whether the text editing change finished.
|
||||
*
|
||||
* @param { Callback<boolean> } callback
|
||||
* @returns { TextInputAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onEditChange(callback: Callback<boolean>): TextInputAttribute;
|
||||
|
||||
/**
|
||||
* Called when submitted.
|
||||
@ -1374,7 +1437,17 @@ declare class TextInputAttribute extends CommonMethod<TextInputAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onSubmit(callback: (enterKey: EnterKeyType, event: SubmitEvent) => void): TextInputAttribute;
|
||||
/**
|
||||
* Called when submitted.
|
||||
*
|
||||
* @param { OnSubmitCallback } callback - Callback of the listened event.
|
||||
* @returns { TextInputAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onSubmit(callback: OnSubmitCallback): TextInputAttribute;
|
||||
|
||||
/**
|
||||
* Called when the input of the input box changes.
|
||||
@ -1434,7 +1507,17 @@ declare class TextInputAttribute extends CommonMethod<TextInputAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onTextSelectionChange(callback: (selectionStart: number, selectionEnd: number) => void): TextInputAttribute;
|
||||
/**
|
||||
* Called when the text selection changes.
|
||||
*
|
||||
* @param { OnTextSelectionChangeCallback } callback - Callback of the listened event.
|
||||
* @returns { TextInputAttribute } Returns the instance of the TextInputAttribute.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onTextSelectionChange(callback: OnTextSelectionChangeCallback): TextInputAttribute;
|
||||
|
||||
/**
|
||||
* Called when the content scrolls.
|
||||
@ -1455,7 +1538,17 @@ declare class TextInputAttribute extends CommonMethod<TextInputAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onContentScroll(callback: (totalOffsetX: number, totalOffsetY: number) => void): TextInputAttribute;
|
||||
/**
|
||||
* Called when the content scrolls.
|
||||
*
|
||||
* @param { OnContentScrollCallback } callback - Callback of the listened event.
|
||||
* @returns { TextInputAttribute } Returns the instance of the TextInputAttribute.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onContentScroll(callback: OnContentScrollCallback): TextInputAttribute;
|
||||
|
||||
/**
|
||||
* Called when the input of maximum text length is set.
|
||||
@ -1661,7 +1754,18 @@ declare class TextInputAttribute extends CommonMethod<TextInputAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
inputFilter(value: ResourceStr, error?: (value: string) => void): TextInputAttribute;
|
||||
/**
|
||||
* Called when the inputFilter of text is set.
|
||||
*
|
||||
* @param { ResourceStr } value
|
||||
* @param { Callback<string> } [error]
|
||||
* @returns { TextInputAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
inputFilter(value: ResourceStr, error?: Callback<string>): TextInputAttribute;
|
||||
|
||||
/**
|
||||
* Called when using the Clipboard menu
|
||||
@ -1690,7 +1794,17 @@ declare class TextInputAttribute extends CommonMethod<TextInputAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onCopy(callback: (value: string) => void): TextInputAttribute;
|
||||
/**
|
||||
* Called when using the Clipboard menu.
|
||||
*
|
||||
* @param { Callback<string> } callback
|
||||
* @returns { TextInputAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onCopy(callback: Callback<string>): TextInputAttribute;
|
||||
|
||||
/**
|
||||
* Called when using the Clipboard menu
|
||||
@ -1719,7 +1833,17 @@ declare class TextInputAttribute extends CommonMethod<TextInputAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onCut(callback: (value: string) => void): TextInputAttribute;
|
||||
/**
|
||||
* Called when using the Clipboard menu.
|
||||
*
|
||||
* @param { Callback<string> } callback
|
||||
* @returns { TextInputAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onCut(callback: Callback<string>): TextInputAttribute;
|
||||
|
||||
/**
|
||||
* Called when using the Clipboard menu
|
||||
@ -1751,7 +1875,17 @@ declare class TextInputAttribute extends CommonMethod<TextInputAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onPaste(callback: (value: string, event: PasteEvent) => void): TextInputAttribute;
|
||||
/**
|
||||
* Called when using the Clipboard menu.
|
||||
*
|
||||
* @param { OnPasteCallback } callback - Executed when a paste operation is performed.
|
||||
* @returns { TextInputAttribute } Returns the instance of the TextInputAttribute.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onPaste(callback: OnPasteCallback): TextInputAttribute;
|
||||
|
||||
/**
|
||||
* Called when the copy option is set.
|
||||
@ -2203,7 +2337,17 @@ declare class TextInputAttribute extends CommonMethod<TextInputAttribute> {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
cancelButton(value: { style?: CancelButtonStyle, icon?: IconOptions }): TextInputAttribute;
|
||||
/**
|
||||
* Set the cancel button style.
|
||||
*
|
||||
* @param { CancelButtonOptions } options - Indicates the style of the cancel button.
|
||||
* @returns { TextInputAttribute } Returns the instance of the TextInputAttribute.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
cancelButton(options: CancelButtonOptions): TextInputAttribute;
|
||||
|
||||
/**
|
||||
* Sets selection when on focus.
|
||||
@ -2447,6 +2591,18 @@ declare class TextInputAttribute extends CommonMethod<TextInputAttribute> {
|
||||
* @since 12
|
||||
*/
|
||||
enablePreviewText(enable: boolean): TextInputAttribute;
|
||||
|
||||
/**
|
||||
* Enable or disable haptic feedback.
|
||||
*
|
||||
* @param { boolean } isEnabled - Default value is true, set false to disable haptic feedback.
|
||||
* @returns { TextInputAttribute } returns the instance of the TextInputAttribute.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
enableHapticFeedback(isEnabled: boolean): TextInputAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
|
97
api/@internal/component/ets/toggle.d.ts
vendored
97
api/@internal/component/ets/toggle.d.ts
vendored
@ -250,6 +250,90 @@ declare interface ToggleConfiguration extends CommonConfiguration<ToggleConfigur
|
||||
triggerChange: Callback<boolean>;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines the toggle options.
|
||||
*
|
||||
* @interface ToggleOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare interface ToggleOptions {
|
||||
/**
|
||||
* Type of the toggle.
|
||||
*
|
||||
* @type { ToggleType }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Type of the toggle.
|
||||
*
|
||||
* @type { ToggleType }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Type of the toggle.
|
||||
*
|
||||
* @type { ToggleType }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Type of the toggle.
|
||||
*
|
||||
* @type { ToggleType }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
type: ToggleType;
|
||||
|
||||
/**
|
||||
* Whether the toggle is on.
|
||||
*
|
||||
* @type { ?boolean }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @since 8
|
||||
*/
|
||||
/**
|
||||
* Whether the toggle is on.
|
||||
*
|
||||
* @type { ?boolean }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @form
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Whether the toggle is on.
|
||||
*
|
||||
* @type { ?boolean }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Whether the toggle is on.
|
||||
*
|
||||
* @type { ?boolean }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
isOn?: boolean
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines the toggle interface.
|
||||
*
|
||||
@ -323,7 +407,18 @@ interface ToggleInterface {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
(options: { type: ToggleType; isOn?: boolean }): ToggleAttribute;
|
||||
/**
|
||||
* Set parameters to obtain the toggle.
|
||||
*
|
||||
* @param { ToggleOptions } options - toggle options
|
||||
* @returns { ToggleAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
(options: ToggleOptions): ToggleAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -78,6 +78,18 @@ declare interface UIExtensionOptions {
|
||||
*/
|
||||
placeholder?: ComponentContent;
|
||||
|
||||
/**
|
||||
* Set Areachange placeholder.
|
||||
* If the Areachange placeholder ComponentContent is set, the placeholder node is displayed until
|
||||
* the UIExtensionComponent size change is complete.
|
||||
*
|
||||
* @type { ?Record<string, ComponentContent> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
areaChangePlaceholder?: Record<string, ComponentContent>;
|
||||
|
||||
/**
|
||||
* Set UIExtensionComponent Content Dpi Follow Strategy.
|
||||
*
|
||||
|
268
api/@internal/component/ets/video.d.ts
vendored
268
api/@internal/component/ets/video.d.ts
vendored
@ -277,6 +277,93 @@ declare enum PlaybackSpeed {
|
||||
Speed_Forward_2_00_X,
|
||||
}
|
||||
|
||||
/**
|
||||
* Fullscreen information of the video.
|
||||
*
|
||||
* @typedef FullscreenInfo
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
interface FullscreenInfo {
|
||||
/**
|
||||
* The flag whether play in full screen.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* The flag whether play in full screen.
|
||||
*
|
||||
* @type { boolean }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
fullscreen: boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* Prepared information of the video.
|
||||
*
|
||||
* @typedef PreparedInfo
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
interface PreparedInfo {
|
||||
/**
|
||||
* The duration of the current video, in seconds.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* The duration of the current video, in seconds.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
duration: number;
|
||||
}
|
||||
|
||||
/**
|
||||
* Playback information of the video.
|
||||
*
|
||||
* @typedef PlaybackInfo
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
interface PlaybackInfo {
|
||||
/**
|
||||
* The current video playback progress, expressed in seconds.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* The current video playback progress, expressed in seconds.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
time: number;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines the video options.
|
||||
*
|
||||
@ -906,7 +993,17 @@ declare class VideoAttribute extends CommonMethod<VideoAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onStart(event: () => void): VideoAttribute;
|
||||
/**
|
||||
* Called when the video is played.
|
||||
*
|
||||
* @param { VoidCallback } event
|
||||
* @returns { VideoAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onStart(event: VoidCallback): VideoAttribute;
|
||||
|
||||
/**
|
||||
* Called when the video is paused.
|
||||
@ -935,7 +1032,17 @@ declare class VideoAttribute extends CommonMethod<VideoAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onPause(event: () => void): VideoAttribute;
|
||||
/**
|
||||
* Called when the video is paused.
|
||||
*
|
||||
* @param { VoidCallback } event
|
||||
* @returns { VideoAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onPause(event: VoidCallback): VideoAttribute;
|
||||
|
||||
/**
|
||||
* Called when the video playback ends.
|
||||
@ -964,7 +1071,17 @@ declare class VideoAttribute extends CommonMethod<VideoAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onFinish(event: () => void): VideoAttribute;
|
||||
/**
|
||||
* Called when the video playback ends.
|
||||
*
|
||||
* @param { VoidCallback } event
|
||||
* @returns { VideoAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onFinish(event: VoidCallback): VideoAttribute;
|
||||
|
||||
/**
|
||||
* Called when the video enters and exits the full screen.
|
||||
@ -993,24 +1110,17 @@ declare class VideoAttribute extends CommonMethod<VideoAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onFullscreenChange(callback: (event: {
|
||||
/**
|
||||
* Play the flag in full screen.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Play the flag in full screen.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
fullscreen: boolean
|
||||
}) => void): VideoAttribute;
|
||||
/**
|
||||
* Called when the video enters and exits the full screen.
|
||||
*
|
||||
* @param { Callback<FullscreenInfo> } callback
|
||||
* @returns { VideoAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onFullscreenChange(callback: Callback<FullscreenInfo>): VideoAttribute;
|
||||
|
||||
/**
|
||||
* Called when the video preparation is complete.
|
||||
@ -1039,24 +1149,17 @@ declare class VideoAttribute extends CommonMethod<VideoAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onPrepared(callback: (event: {
|
||||
/**
|
||||
* Playback duration.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Playback duration.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
duration: number
|
||||
}) => void): VideoAttribute;
|
||||
/**
|
||||
* Called when the video preparation is complete.
|
||||
*
|
||||
* @param { Callback<PreparedInfo> } callback
|
||||
* @returns { VideoAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onPrepared(callback: Callback<PreparedInfo>): VideoAttribute;
|
||||
|
||||
/**
|
||||
* Called when the time information is reported when the progress bar process is operated.
|
||||
@ -1085,24 +1188,17 @@ declare class VideoAttribute extends CommonMethod<VideoAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onSeeking(callback: (event: {
|
||||
/**
|
||||
* Play time.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Play time.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
time: number
|
||||
}) => void): VideoAttribute;
|
||||
/**
|
||||
* Called when the time information is reported when the progress bar process is operated.
|
||||
*
|
||||
* @param { Callback<PlaybackInfo> } callback
|
||||
* @returns { VideoAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onSeeking(callback: Callback<PlaybackInfo>): VideoAttribute;
|
||||
|
||||
/**
|
||||
* Called when the playback time information is reported after the operation progress bar is completed.
|
||||
@ -1131,24 +1227,17 @@ declare class VideoAttribute extends CommonMethod<VideoAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onSeeked(callback: (event: {
|
||||
/**
|
||||
* Play time.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Play time.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
time: number
|
||||
}) => void): VideoAttribute;
|
||||
/**
|
||||
* Called when the playback time information is reported after the operation progress bar is completed.
|
||||
*
|
||||
* @param { Callback<PlaybackInfo> } callback
|
||||
* @returns { VideoAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onSeeked(callback: Callback<PlaybackInfo>): VideoAttribute;
|
||||
|
||||
/**
|
||||
* Called when the playback progress changes.
|
||||
@ -1177,24 +1266,17 @@ declare class VideoAttribute extends CommonMethod<VideoAttribute> {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
onUpdate(callback: (event: {
|
||||
/**
|
||||
* Play time.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Play time.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
time: number
|
||||
}) => void): VideoAttribute;
|
||||
/**
|
||||
* Called when the playback progress changes.
|
||||
*
|
||||
* @param { Callback<PlaybackInfo> } callback
|
||||
* @returns { VideoAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
onUpdate(callback: Callback<PlaybackInfo>): VideoAttribute;
|
||||
|
||||
/**
|
||||
* Called when playback fails.
|
||||
|
34
api/@internal/component/ets/web.d.ts
vendored
34
api/@internal/component/ets/web.d.ts
vendored
@ -3421,6 +3421,19 @@ declare class WebResourceResponse {
|
||||
*/
|
||||
getResponseData(): string;
|
||||
|
||||
/**
|
||||
* Gets the response data.
|
||||
*
|
||||
* @returns { string | number | ArrayBuffer | Resource | undefined } Return the response data.
|
||||
* string type indicate string in HTML format.
|
||||
* number type indicate file handle.
|
||||
* Resource type indicate $rawfile resource.
|
||||
* ArrayBuffer type indicate binary data.
|
||||
* @syscap SystemCapability.Web.Webview.Core
|
||||
* @since 13
|
||||
*/
|
||||
getResponseDataEx(): string | number | ArrayBuffer | Resource | undefined;
|
||||
|
||||
/**
|
||||
* Gets the response encoding.
|
||||
*
|
||||
@ -3689,6 +3702,15 @@ declare class WebResourceResponse {
|
||||
* @since 12
|
||||
*/
|
||||
setResponseIsReady(IsReady: boolean): void;
|
||||
|
||||
/**
|
||||
* Gets whether the response is ready.
|
||||
*
|
||||
* @returns { boolean } True indicates the response data is ready and false is not ready.
|
||||
* @syscap SystemCapability.Web.Webview.Core
|
||||
* @since 13
|
||||
*/
|
||||
getResponseIsReady(): boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -7862,7 +7884,7 @@ declare class WebAttribute extends CommonMethod<WebAttribute> {
|
||||
* @returns { WebAttribute }
|
||||
* @syscap SystemCapability.Web.Webview.Core
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
* @since 14
|
||||
*/
|
||||
forceDisplayScrollBar(enabled: boolean): WebAttribute;
|
||||
|
||||
@ -8526,6 +8548,16 @@ declare class WebAttribute extends CommonMethod<WebAttribute> {
|
||||
* @since 12
|
||||
*/
|
||||
editMenuOptions(editMenu: EditMenuOptions): WebAttribute;
|
||||
|
||||
/**
|
||||
* Enable or disable haptic feedback.
|
||||
*
|
||||
* @param { boolean } enabled - Default value is true, set false to disable haptic feedback.
|
||||
* @returns { WebAttribute }
|
||||
* @syscap SystemCapability.Web.Webview.Core
|
||||
* @since 13
|
||||
*/
|
||||
enableHapticFeedback(enabled: boolean): WebAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
|
11
api/@internal/component/ets/xcomponent.d.ts
vendored
11
api/@internal/component/ets/xcomponent.d.ts
vendored
@ -431,6 +431,17 @@ declare class XComponentAttribute extends CommonMethod<XComponentAttribute> {
|
||||
* @since 12
|
||||
*/
|
||||
enableAnalyzer(enable: boolean): XComponentAttribute;
|
||||
|
||||
/**
|
||||
* Enable privacy protection for XComponent.
|
||||
*
|
||||
* @param { boolean } isSecure
|
||||
* @returns { XComponentAttribute }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
enableSecure(isSecure: boolean): XComponentAttribute;
|
||||
}
|
||||
|
||||
/**
|
||||
|
2
api/@ohos.PiPWindow.d.ts
vendored
2
api/@ohos.PiPWindow.d.ts
vendored
@ -20,7 +20,7 @@
|
||||
|
||||
import type BaseContext from './application/BaseContext';
|
||||
import type { Callback } from './@ohos.base';
|
||||
import { NodeController } from '@kit.ArkUI';
|
||||
import { NodeController } from './arkui/NodeController';
|
||||
import { typeNode } from './arkui/FrameNode';
|
||||
|
||||
/**
|
||||
|
@ -40,7 +40,7 @@ export default class InsightIntentContext {
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000001 - The specified ability does not exist.
|
||||
* @throws { BusinessError } 16000004 - Can not start invisible component.
|
||||
* @throws { BusinessError } 16000004 - Failed to start the invisible ability.
|
||||
* @throws { BusinessError } 16000005 - The specified process does not have the permission.
|
||||
* @throws { BusinessError } 16000006 - Cross-user operations are not allowed.
|
||||
* @throws { BusinessError } 16000008 - The crowdtesting application expires.
|
||||
@ -51,7 +51,7 @@ export default class InsightIntentContext {
|
||||
* @throws { BusinessError } 16000050 - Internal error.
|
||||
* @throws { BusinessError } 16000053 - The ability is not on the top of the UI.
|
||||
* @throws { BusinessError } 16000055 - Installation-free timed out.
|
||||
* @throws { BusinessError } 16000061 - Can not start component belongs to other bundle.
|
||||
* @throws { BusinessError } 16000061 - Operation not supported.
|
||||
* @throws { BusinessError } 16200001 - The caller has been released.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @StageModelOnly
|
||||
@ -70,7 +70,7 @@ export default class InsightIntentContext {
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000001 - The specified ability does not exist.
|
||||
* @throws { BusinessError } 16000004 - Can not start invisible component.
|
||||
* @throws { BusinessError } 16000004 - Failed to start the invisible ability.
|
||||
* @throws { BusinessError } 16000005 - The specified process does not have the permission.
|
||||
* @throws { BusinessError } 16000006 - Cross-user operations are not allowed.
|
||||
* @throws { BusinessError } 16000008 - The crowdtesting application expires.
|
||||
@ -81,7 +81,7 @@ export default class InsightIntentContext {
|
||||
* @throws { BusinessError } 16000050 - Internal error.
|
||||
* @throws { BusinessError } 16000053 - The ability is not on the top of the UI.
|
||||
* @throws { BusinessError } 16000055 - Installation-free timed out.
|
||||
* @throws { BusinessError } 16000061 - Can not start component belongs to other bundle.
|
||||
* @throws { BusinessError } 16000061 - Operation not supported.
|
||||
* @throws { BusinessError } 16200001 - The caller has been released.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @StageModelOnly
|
||||
|
10
api/@ohos.app.ability.UIAbility.d.ts
vendored
10
api/@ohos.app.ability.UIAbility.d.ts
vendored
@ -104,7 +104,7 @@ export interface Caller {
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16200001 - Caller released. The caller has been released.
|
||||
* @throws { BusinessError } 16200002 - Callee invalid. The callee does not exist.
|
||||
* @throws { BusinessError } 16200002 - The callee does not exist.
|
||||
* @throws { BusinessError } 16000050 - Internal error.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
|
||||
* @StageModelOnly
|
||||
@ -121,7 +121,7 @@ export interface Caller {
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16200001 - Caller released. The caller has been released.
|
||||
* @throws { BusinessError } 16200002 - Callee invalid. The callee does not exist.
|
||||
* @throws { BusinessError } 16200002 - The callee does not exist.
|
||||
* @throws { BusinessError } 16000050 - Internal error.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
|
||||
* @StageModelOnly
|
||||
@ -133,7 +133,7 @@ export interface Caller {
|
||||
* Register the generic component server Stub (stub) disconnect listening notification.
|
||||
*
|
||||
* @throws { BusinessError } 16200001 - Caller released. The caller has been released.
|
||||
* @throws { BusinessError } 16200002 - Callee invalid. The callee does not exist.
|
||||
* @throws { BusinessError } 16200002 - The callee does not exist.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
|
||||
* @StageModelOnly
|
||||
* @since 9
|
||||
@ -222,7 +222,7 @@ export interface Callee {
|
||||
* @param { CalleeCallback } callback - Register a callback function that listens for notification events.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 16200004 - Method registered. The method has registered.
|
||||
* @throws { BusinessError } 16200004 - The method has been registered.
|
||||
* @throws { BusinessError } 16000050 - Internal error.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
|
||||
* @StageModelOnly
|
||||
@ -236,7 +236,7 @@ export interface Callee {
|
||||
* @param { string } method - A string registered to listen for notification events.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 16200005 - Method not registered. The method has not registered.
|
||||
* @throws { BusinessError } 16200005 - The method has not been registered.
|
||||
* @throws { BusinessError } 16000050 - Internal error.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
|
||||
* @StageModelOnly
|
||||
|
@ -122,7 +122,7 @@ export default class UIExtensionContentSession {
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000001 - The specified ability does not exist.
|
||||
* @throws { BusinessError } 16000002 - Incorrect ability type.
|
||||
* @throws { BusinessError } 16000004 - Can not start invisible component.
|
||||
* @throws { BusinessError } 16000004 - Failed to start the invisible ability.
|
||||
* @throws { BusinessError } 16000005 - The specified process does not have the permission.
|
||||
* @throws { BusinessError } 16000006 - Cross-user operations are not allowed.
|
||||
* @throws { BusinessError } 16000008 - The crowdtesting application expires.
|
||||
@ -158,7 +158,7 @@ export default class UIExtensionContentSession {
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000001 - The specified ability does not exist.
|
||||
* @throws { BusinessError } 16000004 - Can not start invisible component.
|
||||
* @throws { BusinessError } 16000004 - Failed to start the invisible ability.
|
||||
* @throws { BusinessError } 16000005 - The specified process does not have the permission.
|
||||
* @throws { BusinessError } 16000006 - Cross-user operations are not allowed.
|
||||
* @throws { BusinessError } 16000008 - The crowdtesting application expires.
|
||||
@ -194,7 +194,7 @@ export default class UIExtensionContentSession {
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000001 - The specified ability does not exist.
|
||||
* @throws { BusinessError } 16000002 - Incorrect ability type.
|
||||
* @throws { BusinessError } 16000004 - Can not start invisible component.
|
||||
* @throws { BusinessError } 16000004 - Failed to start the invisible ability.
|
||||
* @throws { BusinessError } 16000005 - The specified process does not have the permission.
|
||||
* @throws { BusinessError } 16000006 - Cross-user operations are not allowed.
|
||||
* @throws { BusinessError } 16000008 - The crowdtesting application expires.
|
||||
@ -230,7 +230,7 @@ export default class UIExtensionContentSession {
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000001 - The specified ability does not exist.
|
||||
* @throws { BusinessError } 16000002 - Incorrect ability type.
|
||||
* @throws { BusinessError } 16000004 - Can not start invisible component.
|
||||
* @throws { BusinessError } 16000004 - Failed to start the invisible ability.
|
||||
* @throws { BusinessError } 16000005 - The specified process does not have the permission.
|
||||
* @throws { BusinessError } 16000006 - Cross-user operations are not allowed.
|
||||
* @throws { BusinessError } 16000008 - The crowdtesting application expires.
|
||||
@ -266,7 +266,7 @@ export default class UIExtensionContentSession {
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000001 - The specified ability does not exist.
|
||||
* @throws { BusinessError } 16000004 - Can not start invisible component.
|
||||
* @throws { BusinessError } 16000004 - Failed to start the invisible ability.
|
||||
* @throws { BusinessError } 16000005 - The specified process does not have the permission.
|
||||
* @throws { BusinessError } 16000006 - Cross-user operations are not allowed.
|
||||
* @throws { BusinessError } 16000008 - The crowdtesting application expires.
|
||||
@ -302,7 +302,7 @@ export default class UIExtensionContentSession {
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000001 - The specified ability does not exist.
|
||||
* @throws { BusinessError } 16000002 - Incorrect ability type.
|
||||
* @throws { BusinessError } 16000004 - Can not start invisible component.
|
||||
* @throws { BusinessError } 16000004 - Failed to start the invisible ability.
|
||||
* @throws { BusinessError } 16000005 - The specified process does not have the permission.
|
||||
* @throws { BusinessError } 16000006 - Cross-user operations are not allowed.
|
||||
* @throws { BusinessError } 16000008 - The crowdtesting application expires.
|
||||
@ -338,7 +338,7 @@ export default class UIExtensionContentSession {
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000001 - The specified ability does not exist.
|
||||
* @throws { BusinessError } 16000002 - Incorrect ability type.
|
||||
* @throws { BusinessError } 16000004 - Can not start invisible component.
|
||||
* @throws { BusinessError } 16000004 - Failed to start the invisible ability.
|
||||
* @throws { BusinessError } 16000005 - The specified process does not have the permission.
|
||||
* @throws { BusinessError } 16000006 - Cross-user operations are not allowed.
|
||||
* @throws { BusinessError } 16000008 - The crowdtesting application expires.
|
||||
@ -374,7 +374,7 @@ export default class UIExtensionContentSession {
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000001 - The specified ability does not exist.
|
||||
* @throws { BusinessError } 16000004 - Can not start invisible component.
|
||||
* @throws { BusinessError } 16000004 - Failed to start the invisible ability.
|
||||
* @throws { BusinessError } 16000005 - The specified process does not have the permission.
|
||||
* @throws { BusinessError } 16000006 - Cross-user operations are not allowed.
|
||||
* @throws { BusinessError } 16000008 - The crowdtesting application expires.
|
||||
@ -410,7 +410,7 @@ export default class UIExtensionContentSession {
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000001 - The specified ability does not exist.
|
||||
* @throws { BusinessError } 16000002 - Incorrect ability type.
|
||||
* @throws { BusinessError } 16000004 - Can not start invisible component.
|
||||
* @throws { BusinessError } 16000004 - Failed to start the invisible ability.
|
||||
* @throws { BusinessError } 16000005 - The specified process does not have the permission.
|
||||
* @throws { BusinessError } 16000006 - Cross-user operations are not allowed.
|
||||
* @throws { BusinessError } 16000008 - The crowdtesting application expires.
|
||||
@ -548,6 +548,7 @@ export default class UIExtensionContentSession {
|
||||
*/
|
||||
/**
|
||||
* Starts the UIAbility or UIExtensionAbility by type.
|
||||
* If the caller application is in the background, it is not allowed to call this interface.
|
||||
*
|
||||
* @param { string } type - The type of target ability.
|
||||
* @param { Record<string, Object> } wantParam - Indicates the want parameter.
|
||||
@ -586,6 +587,7 @@ export default class UIExtensionContentSession {
|
||||
*/
|
||||
/**
|
||||
* Starts the UIAbility or UIExtensionAbility by type.
|
||||
* If the caller application is in the background, it is not allowed to call this interface.
|
||||
*
|
||||
* @param { string } type - The type of target ability.
|
||||
* @param { Record<string, Object> } wantParam - Indicates the want parameter.
|
||||
|
@ -21,6 +21,7 @@
|
||||
import { AbilityDelegator as _AbilityDelegator } from './application/AbilityDelegator';
|
||||
import { AbilityDelegatorArgs as _AbilityDelegatorArgs } from './application/abilityDelegatorArgs';
|
||||
import { AbilityMonitor as _AbilityMonitor } from './application/AbilityMonitor';
|
||||
import { AbilityStageMonitor as _AbilityStageMonitor } from './application/AbilityStageMonitor';
|
||||
import { ShellCmdResult as _ShellCmdResult } from './application/shellCmdResult';
|
||||
|
||||
/**
|
||||
@ -334,6 +335,18 @@ declare namespace abilityDelegatorRegistry {
|
||||
* @since 11
|
||||
*/
|
||||
export type ShellCmdResult = _ShellCmdResult;
|
||||
|
||||
/**
|
||||
* Provide methods for matching monitored AbilityStage objects that meet specified conditions.
|
||||
* The most recently matched AbilityStage objects will be saved in the AbilityStageMonitor object.
|
||||
*
|
||||
* @typedef { _AbilityStageMonitor }
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
export type AbilityStageMonitor = _AbilityStageMonitor;
|
||||
}
|
||||
|
||||
export default abilityDelegatorRegistry;
|
||||
|
2
api/@ohos.app.ability.appManager.d.ts
vendored
2
api/@ohos.app.ability.appManager.d.ts
vendored
@ -979,7 +979,7 @@ declare namespace appManager {
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 16000072 - App clone or multi-instance is not supported.
|
||||
* @throws { BusinessError } 18500001 - The bundle does not exist.
|
||||
* @throws { BusinessError } 18500001 - The bundle does not exist or no patch has been applied.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @systemapi
|
||||
* @stagemodelonly
|
||||
|
2
api/@ohos.app.ability.autoFillManager.d.ts
vendored
2
api/@ohos.app.ability.autoFillManager.d.ts
vendored
@ -295,7 +295,7 @@ declare namespace autoFillManager {
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.AbilityCore
|
||||
* @systemapi
|
||||
* @stagemodelonly
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
export type CustomData = _CustomData.default;
|
||||
|
||||
|
@ -80,7 +80,7 @@ declare namespace autoStartupManager {
|
||||
* @throws { BusinessError } 202 - Permission denied, non-system app called system api.
|
||||
* @throws { BusinessError } 401 - The parameter check failed. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* <br>2. Incorrect parameters types.
|
||||
* @throws { BusinessError } 16000004 - Can not start invisible component.
|
||||
* @throws { BusinessError } 16000004 - Failed to start the invisible ability.
|
||||
* @throws { BusinessError } 16000013 - The application is controlled by EDM.
|
||||
* @throws { BusinessError } 16000050 - Internal error.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
@ -101,7 +101,7 @@ declare namespace autoStartupManager {
|
||||
* @throws { BusinessError } 202 - Permission denied, non-system app called system api.
|
||||
* @throws { BusinessError } 401 - The parameter check failed. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* <br>2. Incorrect parameters types.
|
||||
* @throws { BusinessError } 16000004 - Can not start invisible component.
|
||||
* @throws { BusinessError } 16000004 - Failed to start the invisible ability.
|
||||
* @throws { BusinessError } 16000013 - The application is controlled by EDM.
|
||||
* @throws { BusinessError } 16000050 - Internal error.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
@ -122,7 +122,7 @@ declare namespace autoStartupManager {
|
||||
* @throws { BusinessError } 202 - Permission denied, non-system app called system api.
|
||||
* @throws { BusinessError } 401 - The parameter check failed. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* <br>2. Incorrect parameters types.
|
||||
* @throws { BusinessError } 16000004 - Can not start invisible component.
|
||||
* @throws { BusinessError } 16000004 - Failed to start the invisible ability.
|
||||
* @throws { BusinessError } 16000013 - The application is controlled by EDM.
|
||||
* @throws { BusinessError } 16000050 - Internal error.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
@ -143,7 +143,7 @@ declare namespace autoStartupManager {
|
||||
* @throws { BusinessError } 202 - Permission denied, non-system app called system api.
|
||||
* @throws { BusinessError } 401 - The parameter check failed. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* <br>2. Incorrect parameters types.
|
||||
* @throws { BusinessError } 16000004 - Can not start invisible component.
|
||||
* @throws { BusinessError } 16000004 - Failed to start the invisible ability.
|
||||
* @throws { BusinessError } 16000013 - The application is controlled by EDM.
|
||||
* @throws { BusinessError } 16000050 - Internal error.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
|
25
api/@ohos.app.ability.childProcessManager.d.ts
vendored
25
api/@ohos.app.ability.childProcessManager.d.ts
vendored
@ -71,7 +71,7 @@ declare namespace childProcessManager {
|
||||
* 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types; 3.Parameter verification failed.
|
||||
* @throws { BusinessError } 16000050 - Internal error.
|
||||
* @throws { BusinessError } 16000061 - Operation not supported.
|
||||
* @throws { BusinessError } 16000062 - The number of child process exceeds upper bound.
|
||||
* @throws { BusinessError } 16000062 - The number of child processes exceeds the upper limit.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @stagemodelonly
|
||||
* @since 11
|
||||
@ -88,7 +88,7 @@ declare namespace childProcessManager {
|
||||
* 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types; 3.Parameter verification failed.
|
||||
* @throws { BusinessError } 16000050 - Internal error.
|
||||
* @throws { BusinessError } 16000061 - Operation not supported.
|
||||
* @throws { BusinessError } 16000062 - The number of child process exceeds upper bound.
|
||||
* @throws { BusinessError } 16000062 - The number of child processes exceeds the upper limit.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @stagemodelonly
|
||||
* @since 11
|
||||
@ -111,23 +111,38 @@ declare namespace childProcessManager {
|
||||
* @stagemodelonly
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Start child process with the given args and options.
|
||||
*
|
||||
* @param { string } srcEntry - Indicates child process source file entrance to be started.
|
||||
* @param { ChildProcessArgs } args - Indicates args to pass to child process.
|
||||
* @param { ChildProcessOptions } [options] - Indicates options for starting child process.
|
||||
* @returns { Promise<number> } Returns the started child process pid.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:
|
||||
* 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types; 3.Parameter verification failed.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 16000050 - Internal error.
|
||||
* @throws { BusinessError } 16000061 - Operation not supported. The API cannot be called in a child process.
|
||||
* @throws { BusinessError } 16000062 - The number of child processes exceeds the upper limit.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @stagemodelonly
|
||||
* @since 13
|
||||
*/
|
||||
function startArkChildProcess(srcEntry: string, args: ChildProcessArgs, options?: ChildProcessOptions): Promise<number>;
|
||||
|
||||
/**
|
||||
* Start native child process with the given args and options.
|
||||
*
|
||||
* @permission ohos.permission.START_NATIVE_CHILD_PROCESS
|
||||
* @param { string } entryPoint - Indicates entry point of child process, consisting of library and entry function, such as "libEntry.so:Main".
|
||||
* @param { ChildProcessArgs } args - Indicates args to pass to child process.
|
||||
* @param { ChildProcessOptions } [options] - Indicates options for starting child process.
|
||||
* @returns { Promise<number> } Returns the started child process pid.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:
|
||||
* 1.Mandatory parameters are left unspecified; 2.Incorrect parameter types; 3.Parameter verification failed.
|
||||
* @throws { BusinessError } 801 - Capability not supported. Failed to call the API due to limited device capabilities.
|
||||
* @throws { BusinessError } 16000050 - Internal error.
|
||||
* @throws { BusinessError } 16000061 - Operation not supported. The API cannot be called in a child process.
|
||||
* @throws { BusinessError } 16000062 - The number of native child process exceeds upper bound.
|
||||
* @throws { BusinessError } 16000062 - The number of child processes exceeds the upper limit.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @stagemodelonly
|
||||
* @since 13
|
||||
|
6
api/@ohos.app.ability.errorManager.d.ts
vendored
6
api/@ohos.app.ability.errorManager.d.ts
vendored
@ -58,7 +58,7 @@ declare namespace errorManager {
|
||||
* @returns { number } Returns the number code of the observer.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 16000003 - Id does not exist.
|
||||
* @throws { BusinessError } 16000003 - The specified ID does not exist.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
@ -85,7 +85,7 @@ declare namespace errorManager {
|
||||
* @param { AsyncCallback<void> } callback - The callback of off.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 16000003 - Id does not exist.
|
||||
* @throws { BusinessError } 16000003 - The specified ID does not exist.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
@ -112,7 +112,7 @@ declare namespace errorManager {
|
||||
* @returns { Promise<void> } The promise returned by the function.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 16000003 - Id does not exist.
|
||||
* @throws { BusinessError } 16000003 - The specified ID does not exist.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
|
@ -133,7 +133,7 @@ declare namespace insightIntentDriver {
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000001 - The specified ability does not exist.
|
||||
* @throws { BusinessError } 16000002 - Incorrect ability type.
|
||||
* @throws { BusinessError } 16000004 - Can not start invisible component.
|
||||
* @throws { BusinessError } 16000004 - Failed to start the invisible ability.
|
||||
* @throws { BusinessError } 16000005 - The specified process does not have the permission.
|
||||
* @throws { BusinessError } 16000006 - Cross-user operations are not allowed.
|
||||
* @throws { BusinessError } 16000008 - The crowdtesting application expires.
|
||||
@ -166,7 +166,7 @@ declare namespace insightIntentDriver {
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000001 - The specified ability does not exist.
|
||||
* @throws { BusinessError } 16000002 - Incorrect ability type.
|
||||
* @throws { BusinessError } 16000004 - Can not start invisible component.
|
||||
* @throws { BusinessError } 16000004 - Failed to start the invisible ability.
|
||||
* @throws { BusinessError } 16000005 - The specified process does not have the permission.
|
||||
* @throws { BusinessError } 16000006 - Cross-user operations are not allowed.
|
||||
* @throws { BusinessError } 16000008 - The crowdtesting application expires.
|
||||
|
4
api/@ohos.app.ability.missionManager.d.ts
vendored
4
api/@ohos.app.ability.missionManager.d.ts
vendored
@ -61,7 +61,7 @@ declare namespace missionManager {
|
||||
* @throws { BusinessError } 202 - Not system application.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 16300002 - Input error. The specified mission listener does not exist.
|
||||
* @throws { BusinessError } 16300002 - The specified mission listener does not exist.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Mission
|
||||
* @systemapi
|
||||
* @since 9
|
||||
@ -79,7 +79,7 @@ declare namespace missionManager {
|
||||
* @throws { BusinessError } 202 - Not system application.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 16300002 - Input error. The specified mission listener does not exist.
|
||||
* @throws { BusinessError } 16300002 - The specified mission listener does not exist.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Mission
|
||||
* @systemapi
|
||||
* @since 9
|
||||
|
12
api/@ohos.app.ability.quickFixManager.d.ts
vendored
12
api/@ohos.app.ability.quickFixManager.d.ts
vendored
@ -196,8 +196,8 @@ declare namespace quickFixManager {
|
||||
* @throws { BusinessError } 202 - The application is not system-app, can not use system-api.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 18500001 - The bundle is not exist or no patch has applied.
|
||||
* @throws { BusinessError } 18500009 - The application has a apply quick fix task that is being processed.
|
||||
* @throws { BusinessError } 18500001 - The bundle does not exist or no patch has been applied.
|
||||
* @throws { BusinessError } 18500009 - The application has an ongoing quick fix task.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.QuickFix
|
||||
* @systemapi
|
||||
* @since 10
|
||||
@ -214,8 +214,8 @@ declare namespace quickFixManager {
|
||||
* @throws { BusinessError } 202 - The application is not system-app, can not use system-api.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 18500001 - The bundle is not exist or no patch has applied.
|
||||
* @throws { BusinessError } 18500009 - The application has a apply quick fix task that is being processed.
|
||||
* @throws { BusinessError } 18500001 - The bundle does not exist or no patch has been applied.
|
||||
* @throws { BusinessError } 18500009 - The application has an ongoing quick fix task.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.QuickFix
|
||||
* @systemapi
|
||||
* @since 10
|
||||
@ -232,7 +232,7 @@ declare namespace quickFixManager {
|
||||
* @throws { BusinessError } 202 - Not system application.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 18500001 - The specified bundleName is invalid.
|
||||
* @throws { BusinessError } 18500001 - The bundle does not exist or no patch has been applied.
|
||||
* @throws { BusinessError } 18500008 - Internal error.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.QuickFix
|
||||
* @systemapi
|
||||
@ -250,7 +250,7 @@ declare namespace quickFixManager {
|
||||
* @throws { BusinessError } 202 - Not system application.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 18500001 - The specified bundleName is invalid.
|
||||
* @throws { BusinessError } 18500001 - The bundle does not exist or no patch has been applied.
|
||||
* @throws { BusinessError } 18500008 - Internal error.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.QuickFix
|
||||
* @systemapi
|
||||
|
24
api/@ohos.app.ability.wantAgent.d.ts
vendored
24
api/@ohos.app.ability.wantAgent.d.ts
vendored
@ -60,7 +60,7 @@ declare namespace wantAgent {
|
||||
* @param { AsyncCallback<string> } callback - The callback is used to return the bundle name.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000007 - Service busy, there are concurrent tasks, waiting for retry.
|
||||
* @throws { BusinessError } 16000007 - Service busy. There are concurrent tasks. Try again later.
|
||||
* @throws { BusinessError } 16000151 - Invalid wantagent object.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @atomicservice
|
||||
@ -87,7 +87,7 @@ declare namespace wantAgent {
|
||||
* @returns { Promise<string> } Returns the bundle name.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000007 - Service busy, there are concurrent tasks, waiting for retry.
|
||||
* @throws { BusinessError } 16000007 - Service busy. There are concurrent tasks. Try again later.
|
||||
* @throws { BusinessError } 16000151 - Invalid wantagent object.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @atomicservice
|
||||
@ -114,7 +114,7 @@ declare namespace wantAgent {
|
||||
* @param { AsyncCallback<number> } callback - The callback is used to return the UID.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000007 - Service busy, there are concurrent tasks, waiting for retry.
|
||||
* @throws { BusinessError } 16000007 - Service busy. There are concurrent tasks. Try again later.
|
||||
* @throws { BusinessError } 16000151 - Invalid wantagent object.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @atomicservice
|
||||
@ -141,7 +141,7 @@ declare namespace wantAgent {
|
||||
* @returns { Promise<number> } Returns the UID.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000007 - Service busy, there are concurrent tasks, waiting for retry.
|
||||
* @throws { BusinessError } 16000007 - Service busy. There are concurrent tasks. Try again later.
|
||||
* @throws { BusinessError } 16000151 - Invalid wantagent object.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @atomicservice
|
||||
@ -156,7 +156,7 @@ declare namespace wantAgent {
|
||||
* @param { AsyncCallback<Want> } callback - The callback is used to return the Want.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000007 - Service busy, there are concurrent tasks, waiting for retry.
|
||||
* @throws { BusinessError } 16000007 - Service busy. There are concurrent tasks. Try again later.
|
||||
* @throws { BusinessError } 16000015 - Service timeout.
|
||||
* @throws { BusinessError } 16000151 - Invalid wantagent object.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
@ -172,7 +172,7 @@ declare namespace wantAgent {
|
||||
* @returns { Promise<Want> } Returns the Want.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000007 - Service busy, there are concurrent tasks, waiting for retry.
|
||||
* @throws { BusinessError } 16000007 - Service busy. There are concurrent tasks. Try again later.
|
||||
* @throws { BusinessError } 16000015 - Service timeout.
|
||||
* @throws { BusinessError } 16000151 - Invalid wantagent object.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
@ -200,7 +200,7 @@ declare namespace wantAgent {
|
||||
* @param { AsyncCallback<void> } callback - The callback of cancel.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000007 - Service busy, there are concurrent tasks, waiting for retry.
|
||||
* @throws { BusinessError } 16000007 - Service busy. There are concurrent tasks. Try again later.
|
||||
* @throws { BusinessError } 16000151 - Invalid wantagent object.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @atomicservice
|
||||
@ -227,7 +227,7 @@ declare namespace wantAgent {
|
||||
* @returns { Promise<void> } The promise returned by the function.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000007 - Service busy, there are concurrent tasks, waiting for retry.
|
||||
* @throws { BusinessError } 16000007 - Service busy. There are concurrent tasks. Try again later.
|
||||
* @throws { BusinessError } 16000151 - Invalid wantagent object.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @atomicservice
|
||||
@ -329,7 +329,7 @@ declare namespace wantAgent {
|
||||
* @param { AsyncCallback<WantAgent> } callback - The callback is used to return the created WantAgent.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000007 - Service busy, there are concurrent tasks, waiting for retry.
|
||||
* @throws { BusinessError } 16000007 - Service busy. There are concurrent tasks. Try again later.
|
||||
* @throws { BusinessError } 16000151 - Invalid wantagent object.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @atomicservice
|
||||
@ -356,7 +356,7 @@ declare namespace wantAgent {
|
||||
* @returns { Promise<WantAgent> } Returns the created WantAgent.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000007 - Service busy, there are concurrent tasks, waiting for retry.
|
||||
* @throws { BusinessError } 16000007 - Service busy. There are concurrent tasks. Try again later.
|
||||
* @throws { BusinessError } 16000151 - Invalid wantagent object.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @atomicservice
|
||||
@ -384,7 +384,7 @@ declare namespace wantAgent {
|
||||
* @param { AsyncCallback<number> } callback - The callback is used to return the OperationType of the WantAgent.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000007 - Service busy, there are concurrent tasks, waiting for retry.
|
||||
* @throws { BusinessError } 16000007 - Service busy. There are concurrent tasks. Try again later.
|
||||
* @throws { BusinessError } 16000015 - Service timeout.
|
||||
* @throws { BusinessError } 16000151 - Invalid wantagent object.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
@ -413,7 +413,7 @@ declare namespace wantAgent {
|
||||
* @returns { Promise<number> } Returns the OperationType of the WantAgent.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 16000007 - Service busy, there are concurrent tasks, waiting for retry.
|
||||
* @throws { BusinessError } 16000007 - Service busy. There are concurrent tasks. Try again later.
|
||||
* @throws { BusinessError } 16000015 - Service timeout.
|
||||
* @throws { BusinessError } 16000151 - Invalid wantagent object.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
|
16
api/@ohos.app.ability.wantConstant.d.ts
vendored
16
api/@ohos.app.ability.wantConstant.d.ts
vendored
@ -300,6 +300,22 @@ declare namespace wantConstant {
|
||||
* @since 12
|
||||
*/
|
||||
SUB_PACKAGE_NAME = 'ohos.param.atomicservice.subpackageName',
|
||||
|
||||
/**
|
||||
* Indicates the param of app instance key.
|
||||
*
|
||||
* @syscap SystemCapability.Ability.AbilityBase
|
||||
* @since 14
|
||||
*/
|
||||
APP_INSTANCE_KEY = 'ohos.extra.param.key.appInstance',
|
||||
|
||||
/**
|
||||
* Indicates the param of creating a new instance.
|
||||
*
|
||||
* @syscap SystemCapability.Ability.AbilityBase
|
||||
* @since 14
|
||||
*/
|
||||
CREATE_APP_INSTANCE_KEY = 'ohos.extra.param.key.createAppInstance',
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -47,7 +47,7 @@ declare namespace uriPermissionManager {
|
||||
* @throws { BusinessError } 16000050 - Internal error.
|
||||
* @throws { BusinessError } 16000058 - Invalid URI flag.
|
||||
* @throws { BusinessError } 16000059 - Invalid URI type.
|
||||
* @throws { BusinessError } 16000060 - Sandbox application can not grant URI permission.
|
||||
* @throws { BusinessError } 16000060 - A sandbox application cannot grant URI permission.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @systemapi hide this for inner system use.
|
||||
* @since 10
|
||||
@ -77,7 +77,7 @@ declare namespace uriPermissionManager {
|
||||
* @throws { BusinessError } 16000050 - Internal error.
|
||||
* @throws { BusinessError } 16000058 - Invalid URI flag.
|
||||
* @throws { BusinessError } 16000059 - Invalid URI type.
|
||||
* @throws { BusinessError } 16000060 - Sandbox application can not grant URI permission.
|
||||
* @throws { BusinessError } 16000060 - A sandbox application cannot grant URI permission.
|
||||
* @syscap SystemCapability.Ability.AbilityRuntime.Core
|
||||
* @systemapi hide this for inner system use.
|
||||
* @since 10
|
||||
|
70
api/@ohos.arkui.UIContext.d.ts
vendored
70
api/@ohos.arkui.UIContext.d.ts
vendored
@ -2048,6 +2048,26 @@ export class SwiperDynamicSyncScene extends DynamicSyncScene {
|
||||
readonly type: SwiperDynamicSyncSceneType;
|
||||
}
|
||||
|
||||
/**
|
||||
* Represents a dynamic synchronization scene of Marquee.
|
||||
*
|
||||
* @extends DynamicSyncScene
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
export class MarqueeDynamicSyncScene extends DynamicSyncScene {
|
||||
/**
|
||||
* Type of the MarqueeDynamicSyncSceneType.
|
||||
* @type { MarqueeDynamicSyncSceneType }
|
||||
* @readonly
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
readonly type: MarqueeDynamicSyncSceneType;
|
||||
}
|
||||
|
||||
/**
|
||||
* class DragController
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
@ -2242,6 +2262,17 @@ export class FocusController {
|
||||
* @since 12
|
||||
*/
|
||||
requestFocus(key: string): void;
|
||||
|
||||
/**
|
||||
* Activate focus style.
|
||||
* @param { boolean } isActive - activate/deactivate the focus style.
|
||||
* @param { boolean } [autoInactive] - deactivate the focus style when touch event or mouse event triggers, the default value is true.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
activate(isActive: boolean, autoInactive?: boolean): void;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -3111,6 +3142,26 @@ export class UIContext {
|
||||
*/
|
||||
getWindowName(): string | undefined;
|
||||
|
||||
/**
|
||||
* Get the width breakpoint of current window.
|
||||
*
|
||||
* @returns { WidthBreakpoint } The width breakpoint of current window.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
getWindowWidthBreakpoint(): WidthBreakpoint;
|
||||
|
||||
/**
|
||||
* Get the height breakpoint of current window.
|
||||
*
|
||||
* @returns { HeightBreakpoint } The height breakpoint of current window.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
getWindowHeightBreakpoint(): HeightBreakpoint;
|
||||
|
||||
/**
|
||||
* Open the BindSheet.
|
||||
*
|
||||
@ -3297,3 +3348,22 @@ export const enum SwiperDynamicSyncSceneType {
|
||||
*/
|
||||
ANIMATION = 1
|
||||
}
|
||||
|
||||
/**
|
||||
* Enum of scene type for Marquee
|
||||
*
|
||||
* @enum { number } MarqueeDynamicSyncSceneType
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
export const enum MarqueeDynamicSyncSceneType {
|
||||
/**
|
||||
* Scene type is ANIMATION.
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ANIMATION = 1
|
||||
}
|
||||
|
@ -837,3 +837,61 @@ export declare struct CustomContentDialog {
|
||||
*/
|
||||
themeColorMode?: ThemeColorMode;
|
||||
}
|
||||
|
||||
/**
|
||||
* Declare struct PopoverDialog
|
||||
*
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
@Component
|
||||
export declare struct PopoverDialog {
|
||||
/**
|
||||
* Sets the PopoverDialog Visible Status.
|
||||
*
|
||||
* @type { boolean }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
@Link
|
||||
visible: boolean;
|
||||
/**
|
||||
* Sets the PopoverDialog options.
|
||||
*
|
||||
* @type { PopoverOptions }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
@Require @Prop
|
||||
popover: PopoverOptions;
|
||||
/**
|
||||
* Sets the targetBuilder content.
|
||||
*
|
||||
* @type { Callback<void> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
@Require @BuilderParam
|
||||
targetBuilder: Callback<void>;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines PopoverDialog Options
|
||||
*
|
||||
* @typedef PopoverOptions
|
||||
* @extends CustomPopupOptions
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
export declare interface PopoverOptions extends CustomPopupOptions {
|
||||
}
|
||||
|
@ -59,6 +59,30 @@ interface SegmentButtonTextItem {
|
||||
* @since 12
|
||||
*/
|
||||
text: ResourceStr;
|
||||
|
||||
/**
|
||||
* The accessibilityLevel of buttonItem.
|
||||
*
|
||||
* @type { ?string }
|
||||
* @default "auto"
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
accessibilityLevel?: string;
|
||||
|
||||
/**
|
||||
* The accessibilityDescription of buttonItem.
|
||||
*
|
||||
* @type { ?ResourceStr }
|
||||
* @default ""
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
accessibilityDescription?: ResourceStr;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -98,6 +122,18 @@ interface SegmentButtonIconItem {
|
||||
*/
|
||||
icon: ResourceStr;
|
||||
|
||||
/**
|
||||
* The accessibilityText of icon.
|
||||
*
|
||||
* @type { ?ResourceStr }
|
||||
* @default ""
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
iconAccessibilityText?: ResourceStr;
|
||||
|
||||
/**
|
||||
* The icon of icon only item in the selected state.
|
||||
*
|
||||
@ -116,6 +152,42 @@ interface SegmentButtonIconItem {
|
||||
* @since 12
|
||||
*/
|
||||
selectedIcon: ResourceStr;
|
||||
|
||||
/**
|
||||
* The accessibilityText of selectedIcon.
|
||||
*
|
||||
* @type { ?ResourceStr }
|
||||
* @default ""
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
selectedIconAccessibilityText?: ResourceStr;
|
||||
|
||||
/**
|
||||
* The accessibilityLevel of buttonItem.
|
||||
*
|
||||
* @type { ?string }
|
||||
* @default "auto"
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
accessibilityLevel?: string;
|
||||
|
||||
/**
|
||||
* The accessibilityDescription of buttonItem.
|
||||
*
|
||||
* @type { ?ResourceStr }
|
||||
* @default ""
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
accessibilityDescription?: ResourceStr;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -155,6 +227,18 @@ interface SegmentButtonIconTextItem {
|
||||
*/
|
||||
icon: ResourceStr;
|
||||
|
||||
/**
|
||||
* The accessibilityText of icon.
|
||||
*
|
||||
* @type { ?ResourceStr }
|
||||
* @default ""
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
iconAccessibilityText?: ResourceStr;
|
||||
|
||||
/**
|
||||
* The icon of icon and text item in the selected state.
|
||||
*
|
||||
@ -174,6 +258,18 @@ interface SegmentButtonIconTextItem {
|
||||
*/
|
||||
selectedIcon: ResourceStr;
|
||||
|
||||
/**
|
||||
* The accessibilityText of selectedIcon.
|
||||
*
|
||||
* @type { ?ResourceStr }
|
||||
* @default ""
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
selectedIconAccessibilityText?: ResourceStr;
|
||||
|
||||
/**
|
||||
* The text of icon and text item.
|
||||
*
|
||||
@ -192,6 +288,30 @@ interface SegmentButtonIconTextItem {
|
||||
* @since 12
|
||||
*/
|
||||
text: ResourceStr;
|
||||
|
||||
/**
|
||||
* The accessibilityLevel of buttonItem.
|
||||
*
|
||||
* @type { ?string }
|
||||
* @default "auto"
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
accessibilityLevel?: string;
|
||||
|
||||
/**
|
||||
* The accessibilityDescription of buttonItem.
|
||||
*
|
||||
* @type { ?ResourceStr }
|
||||
* @default ""
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
accessibilityDescription?: ResourceStr;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -780,6 +900,18 @@ interface SegmentButtonItemOptionsConstructorOptions {
|
||||
*/
|
||||
icon?: ResourceStr;
|
||||
|
||||
/**
|
||||
* The accessibilityText of icon.
|
||||
*
|
||||
* @type { ?ResourceStr }
|
||||
* @default ""
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
iconAccessibilityText?: ResourceStr;
|
||||
|
||||
/**
|
||||
* The icon of icon and text item in the selected state.
|
||||
*
|
||||
@ -799,6 +931,18 @@ interface SegmentButtonItemOptionsConstructorOptions {
|
||||
*/
|
||||
selectedIcon?: ResourceStr;
|
||||
|
||||
/**
|
||||
* The accessibilityText of selectedIcon.
|
||||
*
|
||||
* @type { ?ResourceStr }
|
||||
* @default ""
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
selectedIconAccessibilityText?: ResourceStr;
|
||||
|
||||
/**
|
||||
* The text of icon and text item.
|
||||
*
|
||||
@ -817,6 +961,30 @@ interface SegmentButtonItemOptionsConstructorOptions {
|
||||
* @since 12
|
||||
*/
|
||||
text?: ResourceStr;
|
||||
|
||||
/**
|
||||
* The accessibilityLevel of buttonItem.
|
||||
*
|
||||
* @type { ?string }
|
||||
* @default "auto"
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
accessibilityLevel?: string;
|
||||
|
||||
/**
|
||||
* The accessibilityDescription of buttonItem.
|
||||
*
|
||||
* @type { ?ResourceStr }
|
||||
* @default ""
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
accessibilityDescription?: ResourceStr;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -855,6 +1023,18 @@ declare class SegmentButtonItemOptions {
|
||||
*/
|
||||
icon?: ResourceStr;
|
||||
|
||||
/**
|
||||
* The accessibilityText of icon.
|
||||
*
|
||||
* @type { ?ResourceStr }
|
||||
* @default ""
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
iconAccessibilityText?: ResourceStr;
|
||||
|
||||
/**
|
||||
* The icon of selected item.
|
||||
*
|
||||
@ -874,6 +1054,18 @@ declare class SegmentButtonItemOptions {
|
||||
*/
|
||||
selectedIcon?: ResourceStr;
|
||||
|
||||
/**
|
||||
* The accessibilityText of selectedIcon.
|
||||
*
|
||||
* @type { ?ResourceStr }
|
||||
* @default ""
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
selectedIconAccessibilityText?: ResourceStr;
|
||||
|
||||
/**
|
||||
* The text of item.
|
||||
*
|
||||
@ -893,6 +1085,30 @@ declare class SegmentButtonItemOptions {
|
||||
*/
|
||||
text?: ResourceStr;
|
||||
|
||||
/**
|
||||
* The accessibilityLevel of buttonItem.
|
||||
*
|
||||
* @type { ?string }
|
||||
* @default "auto"
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
accessibilityLevel?: string;
|
||||
|
||||
/**
|
||||
* The accessibilityDescription of buttonItem.
|
||||
*
|
||||
* @type { ?ResourceStr }
|
||||
* @default ""
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
accessibilityDescription?: ResourceStr;
|
||||
|
||||
/**
|
||||
* The constructor used to create a SegmentButtonOptionsArray object.
|
||||
*
|
||||
@ -1535,6 +1751,17 @@ declare struct SegmentButton {
|
||||
*/
|
||||
@Link
|
||||
selectedIndexes: number[];
|
||||
|
||||
/**
|
||||
* The click event callback will be triggered when a option button of SegmentButton is clicked.
|
||||
*
|
||||
* @type { ?Callback<number> }
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onItemClicked?: Callback<number>;
|
||||
}
|
||||
|
||||
export {
|
||||
|
1
api/@ohos.arkui.modifier.d.ts
vendored
1
api/@ohos.arkui.modifier.d.ts
vendored
@ -120,6 +120,7 @@ export { DividerModifier } from './arkui/DividerModifier';
|
||||
/**
|
||||
* Export FormComponentModifier, which is used to expose applyNormalAttribute function.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @systemapi
|
||||
* @crossplatform
|
||||
* @since 12
|
||||
*/
|
||||
|
7
api/@ohos.arkui.uiExtension.d.ts
vendored
7
api/@ohos.arkui.uiExtension.d.ts
vendored
@ -117,13 +117,20 @@ declare namespace uiExtension {
|
||||
|
||||
/**
|
||||
* Hide the non-secure windows.
|
||||
* When called by modal UIExtension and shouldHide == false, the "ohos.permission.ALLOW_SHOW_NON_SECURE_WINDOWS" permission is required.
|
||||
*
|
||||
* @permission ohos.permission.ALLOW_SHOW_NON_SECURE_WINDOWS
|
||||
* @param { boolean } shouldHide - Hide the non-secure windows if true, otherwise means the opposite.
|
||||
* @returns { Promise<void> } - The promise returned by the function.
|
||||
* @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:
|
||||
* <br> 1. Mandatory parameters are left unspecified.
|
||||
* <br> 2. Incorrect parameters types.
|
||||
* <br> 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 1300002 - Abnormal state. Possible causes:
|
||||
* <br> 1. Permission denied. Interface caller does not have permission "ohos.permission.ALLOW_SHOW_NON_SECURE_WINDOWS".
|
||||
* <br> 2. The UIExtension window proxy is abnormal.
|
||||
* @throws { BusinessError } 1300003 - This window manager service works abnormally.
|
||||
* @syscap SystemCapability.ArkUI.ArkUI.Full
|
||||
* @systemapi
|
||||
* @since 12
|
||||
|
@ -111,7 +111,7 @@ export declare class NavPushPathHelper {
|
||||
*
|
||||
* @param { string } moduleName - Module name
|
||||
* @param { string } name - Indicates the name of the route page to be pushed.
|
||||
* @param { unknown } param - Indicates the detailed parameter of the route page to be pushed.
|
||||
* @param { Object } param - Indicates the detailed parameter of the route page to be pushed.
|
||||
* @param { boolean } [animated] - Indicates whether the transition is animated.
|
||||
* @returns { Promise<void> } The promise returned by the function.
|
||||
* @throws { BusinessError } 300001 - hsp silent install fail.
|
||||
@ -119,7 +119,7 @@ export declare class NavPushPathHelper {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
pushPathByName(moduleName: string, name: string, param: unknown, animated?: boolean): Promise<void>;
|
||||
pushPathByName(moduleName: string, name: string, param: Object, animated?: boolean): Promise<void>;
|
||||
|
||||
/**
|
||||
* Pushes the specified route page into the stack.
|
||||
|
45
api/@ohos.bluetooth.a2dp.d.ts
vendored
45
api/@ohos.bluetooth.a2dp.d.ts
vendored
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2023 Huawei Device Co., Ltd.
|
||||
* Copyright (C) 2023-2024 Huawei Device Co., Ltd.
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
@ -28,6 +28,14 @@ import type baseProfile from './@ohos.bluetooth.baseProfile';
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Provides methods to accessing bluetooth audio related capabilities.
|
||||
*
|
||||
* @namespace a2dp
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
declare namespace a2dp {
|
||||
/**
|
||||
* Base interface of profile.
|
||||
@ -48,6 +56,17 @@ declare namespace a2dp {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* create the instance of a2dp profile.
|
||||
*
|
||||
* @returns { A2dpSourceProfile } Returns the instance of profile.
|
||||
* @throws { BusinessError } 401 - Invalid parameter.Possible causes: 1. Mandatory parameters are left unspecified.
|
||||
* <br>2. Incorrect parameter types. 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
function createA2dpSrcProfile(): A2dpSourceProfile;
|
||||
|
||||
/**
|
||||
@ -57,6 +76,14 @@ declare namespace a2dp {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Manager a2dp source profile.
|
||||
*
|
||||
* @typedef A2dpSourceProfile
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
interface A2dpSourceProfile extends BaseProfile {
|
||||
/**
|
||||
* Initiate an A2DP connection to a remote device.
|
||||
@ -481,7 +508,21 @@ declare namespace a2dp {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 11
|
||||
*/
|
||||
CODEC_TYPE_L2HC = 2
|
||||
CODEC_TYPE_L2HC = 2,
|
||||
/**
|
||||
* L2HCST.
|
||||
*
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 13
|
||||
*/
|
||||
CODEC_TYPE_L2HCST = 3,
|
||||
/**
|
||||
* LDAC.
|
||||
*
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 13
|
||||
*/
|
||||
CODEC_TYPE_LDAC = 4
|
||||
}
|
||||
|
||||
/**
|
||||
|
124
api/@ohos.bluetooth.access.d.ts
vendored
124
api/@ohos.bluetooth.access.d.ts
vendored
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2023 Huawei Device Co., Ltd.
|
||||
* Copyright (C) 2023-2024 Huawei Device Co., Ltd.
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
@ -35,6 +35,15 @@ import type { AsyncCallback, Callback } from './@ohos.base';
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Provides methods for enabling/disabling bluetooth or monitoring bluetooth state.
|
||||
*
|
||||
* @namespace access
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare namespace access {
|
||||
/**
|
||||
* Enables Bluetooth on a device.
|
||||
@ -59,6 +68,19 @@ declare namespace access {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Enables Bluetooth on a device.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
function enableBluetooth(): void;
|
||||
|
||||
/**
|
||||
@ -84,6 +106,19 @@ declare namespace access {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Disables Bluetooth on a device.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
function disableBluetooth(): void;
|
||||
|
||||
/**
|
||||
@ -127,6 +162,20 @@ declare namespace access {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Obtains the Bluetooth status of a device.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @returns { BluetoothState } Returns the Bluetooth status.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
function getState(): BluetoothState;
|
||||
|
||||
/**
|
||||
@ -208,6 +257,22 @@ declare namespace access {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Subscribe the event reported when the Bluetooth state changes.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @param { 'stateChange' } type - Type of the Bluetooth state changes event to listen for.
|
||||
* @param { Callback<BluetoothState> } callback - Callback used to listen for the Bluetooth state event.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 401 - Invalid parameter. Possible causes: 1. Mandatory parameters are left unspecified.
|
||||
* <br>2. Incorrect parameter types. 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
function on(type: 'stateChange', callback: Callback<BluetoothState>): void;
|
||||
|
||||
/**
|
||||
@ -239,6 +304,22 @@ declare namespace access {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Unsubscribe the event reported when the Bluetooth state changes.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @param { 'stateChange' } type - Type of the Bluetooth state changes event to listen for.
|
||||
* @param { Callback<BluetoothState> } callback - Callback used to listen for the Bluetooth state event.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 401 - Invalid parameter. Possible causes: 1. Mandatory parameters are left unspecified.
|
||||
* <br>2. Incorrect parameter types. 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
function off(type: 'stateChange', callback?: Callback<BluetoothState>): void;
|
||||
|
||||
/**
|
||||
@ -256,6 +337,15 @@ declare namespace access {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* The enum of bluetooth state.
|
||||
*
|
||||
* @enum { number }
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
export enum BluetoothState {
|
||||
/**
|
||||
* Indicates the local Bluetooth is off
|
||||
@ -270,6 +360,14 @@ declare namespace access {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Indicates the local Bluetooth is off
|
||||
*
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
STATE_OFF = 0,
|
||||
/**
|
||||
* Indicates the local Bluetooth is turning on
|
||||
@ -284,6 +382,14 @@ declare namespace access {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Indicates the local Bluetooth is turning on
|
||||
*
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
STATE_TURNING_ON = 1,
|
||||
/**
|
||||
* Indicates the local Bluetooth is on, and ready for use
|
||||
@ -298,6 +404,14 @@ declare namespace access {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Indicates the local Bluetooth is on, and ready for use
|
||||
*
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
STATE_ON = 2,
|
||||
/**
|
||||
* Indicates the local Bluetooth is turning off
|
||||
@ -312,6 +426,14 @@ declare namespace access {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Indicates the local Bluetooth is turning off
|
||||
*
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
STATE_TURNING_OFF = 3,
|
||||
/**
|
||||
* Indicates the local Bluetooth is turning LE mode on
|
||||
|
134
api/@ohos.bluetooth.baseProfile.d.ts
vendored
134
api/@ohos.bluetooth.baseProfile.d.ts
vendored
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2023 Huawei Device Co., Ltd.
|
||||
* Copyright (c) 2023-2024 Huawei Device Co., Ltd.
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
@ -28,6 +28,14 @@ import type constant from './@ohos.bluetooth.constant';
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Provides basic profile methods.
|
||||
*
|
||||
* @namespace baseProfile
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
declare namespace baseProfile {
|
||||
/**
|
||||
* Indicate the profile connection state.
|
||||
@ -36,6 +44,14 @@ declare namespace baseProfile {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Indicate the profile connection state.
|
||||
*
|
||||
* @typedef { constant.ProfileConnectionState } ProfileConnectionState
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
type ProfileConnectionState = constant.ProfileConnectionState;
|
||||
|
||||
/**
|
||||
@ -80,6 +96,14 @@ declare namespace baseProfile {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Enum for cause of disconnect.
|
||||
*
|
||||
* @enum { number }
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
enum DisconnectCause {
|
||||
/**
|
||||
* User disconnect device.
|
||||
@ -87,6 +111,13 @@ declare namespace baseProfile {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* User disconnect device.
|
||||
*
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
USER_DISCONNECT = 0,
|
||||
/**
|
||||
* The connection needs to be initiated from the keyboard side.
|
||||
@ -132,6 +163,14 @@ declare namespace baseProfile {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Profile state change parameters.
|
||||
*
|
||||
* @typedef StateChangeParam
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
export interface StateChangeParam {
|
||||
/**
|
||||
* The address of device
|
||||
@ -140,6 +179,14 @@ declare namespace baseProfile {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* The address of device
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
deviceId: string;
|
||||
|
||||
/**
|
||||
@ -149,6 +196,14 @@ declare namespace baseProfile {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Profile state value
|
||||
*
|
||||
* @type { ProfileConnectionState }
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
state: ProfileConnectionState;
|
||||
|
||||
/**
|
||||
@ -158,6 +213,14 @@ declare namespace baseProfile {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Cause of disconnect
|
||||
*
|
||||
* @type { DisconnectCause }
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
cause: DisconnectCause;
|
||||
}
|
||||
|
||||
@ -168,6 +231,14 @@ declare namespace baseProfile {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Base interface of profile.
|
||||
*
|
||||
* @typedef BaseProfile
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
export interface BaseProfile {
|
||||
/**
|
||||
* Set connection strategy of this profile.
|
||||
@ -269,6 +340,21 @@ declare namespace baseProfile {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Obtains the connected devices list of profile.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @returns { Array<string> } Returns the address of connected devices list.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900003 - Bluetooth disabled.
|
||||
* @throws { BusinessError } 2900004 - Profile not supported.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
getConnectedDevices(): Array<string>;
|
||||
|
||||
/**
|
||||
@ -288,6 +374,24 @@ declare namespace baseProfile {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Obtains the profile connection state.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @param { string } deviceId - Indicates device ID. For example, "11:22:33:AA:BB:FF".
|
||||
* @returns { ProfileConnectionState } Returns the connection state.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 401 - Invalid parameter. Possible causes: 1. Mandatory parameters are left unspecified.
|
||||
* <br>2. Incorrect parameter types. 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900003 - Bluetooth disabled.
|
||||
* @throws { BusinessError } 2900004 - Profile not supported.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
getConnectionState(deviceId: string): ProfileConnectionState;
|
||||
|
||||
/**
|
||||
@ -303,6 +407,20 @@ declare namespace baseProfile {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Subscribe the event reported when the profile connection state changes .
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @param { 'connectionStateChange' } type - Type of the profile connection state changes event to listen for.
|
||||
* @param { Callback<StateChangeParam> } callback - Callback used to listen for event.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 401 - Invalid parameter. Possible causes: 1. Mandatory parameters are left unspecified.
|
||||
* <br>2. Incorrect parameter types. 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
on(type: 'connectionStateChange', callback: Callback<StateChangeParam>): void;
|
||||
|
||||
/**
|
||||
@ -318,6 +436,20 @@ declare namespace baseProfile {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Unsubscribe the event reported when the profile connection state changes .
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @param { 'connectionStateChange' } type - Type of the profile connection state changes event to listen for.
|
||||
* @param { Callback<StateChangeParam> } callback - Callback used to listen for event.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 401 - Invalid parameter. Possible causes: 1. Mandatory parameters are left unspecified.
|
||||
* <br>2. Incorrect parameter types. 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
off(type: 'connectionStateChange', callback?: Callback<StateChangeParam>): void;
|
||||
}
|
||||
}
|
||||
|
1876
api/@ohos.bluetooth.ble.d.ts
vendored
1876
api/@ohos.bluetooth.ble.d.ts
vendored
File diff suppressed because it is too large
Load Diff
477
api/@ohos.bluetooth.connection.d.ts
vendored
477
api/@ohos.bluetooth.connection.d.ts
vendored
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2023 Huawei Device Co., Ltd.
|
||||
* Copyright (C) 2023-2024 Huawei Device Co., Ltd.
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
@ -36,6 +36,15 @@ import type constant from './@ohos.bluetooth.constant';
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Provides methods to operate or manage Bluetooth.
|
||||
*
|
||||
* @namespace connection
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare namespace connection {
|
||||
/**
|
||||
* Indicate the profile connection state.
|
||||
@ -44,6 +53,14 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Indicate the profile connection state.
|
||||
*
|
||||
* @typedef { constant.ProfileConnectionState } ProfileConnectionState
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
type ProfileConnectionState = constant.ProfileConnectionState;
|
||||
|
||||
/**
|
||||
@ -53,6 +70,14 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Indicate the profile id.
|
||||
*
|
||||
* @typedef { constant.ProfileId } ProfileId
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
type ProfileId = constant.ProfileId;
|
||||
|
||||
/**
|
||||
@ -70,6 +95,14 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Indicate the profile uuid.
|
||||
*
|
||||
* @typedef { constant.ProfileUuids } ProfileUuids
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
type ProfileUuids = constant.ProfileUuids;
|
||||
|
||||
/**
|
||||
@ -79,6 +112,14 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Indicate the major class of a bluetooth device.
|
||||
*
|
||||
* @typedef { constant.MajorClass } MajorClass
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
type MajorClass = constant.MajorClass;
|
||||
|
||||
/**
|
||||
@ -88,6 +129,14 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Indicate the major minor class of a bluetooth device.
|
||||
*
|
||||
* @typedef { constant.MajorMinorClass } MajorMinorClass
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
type MajorMinorClass = constant.MajorMinorClass;
|
||||
|
||||
/**
|
||||
@ -109,6 +158,26 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Get the profile connection state of the current device.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @param { ProfileId } [profileId] - Indicate the profile id. This is an optional parameter.
|
||||
* With profileId, returns the current connection state of this profile, {@link ProfileConnectionState}.
|
||||
* Without profileId, if any profile is connected, {@link ProfileConnectionState#STATE_CONNECTED} is returned.
|
||||
* Otherwise, {@link ProfileConnectionState#STATE_DISCONNECTED} is returned.
|
||||
* @returns { ProfileConnectionState } Returns the connection state.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 401 - Invalid parameter. Possible causes: 1. Incorrect parameter types.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900003 - Bluetooth disabled.
|
||||
* @throws { BusinessError } 2900004 - Profile not supported.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
function getProfileConnectionState(profileId?: ProfileId): ProfileConnectionState;
|
||||
|
||||
/**
|
||||
@ -144,6 +213,24 @@ declare namespace connection {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Starts pairing with a remote Bluetooth device.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @param { string } deviceId - Indicates device ID. For example, "11:22:33:AA:BB:FF".
|
||||
* @param { AsyncCallback<void> } callback - the callback of pairDevice.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 401 - Invalid parameter. Possible causes: 1. Mandatory parameters are left unspecified.
|
||||
* <br>2. Incorrect parameter types. 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900003 - Bluetooth disabled.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
function pairDevice(deviceId: string, callback: AsyncCallback<void>): void;
|
||||
|
||||
/**
|
||||
@ -179,6 +266,24 @@ declare namespace connection {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Starts pairing with a remote Bluetooth device.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @param { string } deviceId - Indicates device ID. For example, "11:22:33:AA:BB:FF".
|
||||
* @returns { Promise<void> } Returns the promise object.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 401 - Invalid parameter. Possible causes: 1. Mandatory parameters are left unspecified.
|
||||
* <br>2. Incorrect parameter types. 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900003 - Bluetooth disabled.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
function pairDevice(deviceId: string): Promise<void>;
|
||||
|
||||
/**
|
||||
@ -340,6 +445,24 @@ declare namespace connection {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Obtains the name of a peer Bluetooth device.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @param { string } deviceId - Indicates device ID. For example, "11:22:33:AA:BB:FF".
|
||||
* @returns { string } Returns the device name in character string format.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 401 - Invalid parameter. Possible causes: 1. Mandatory parameters are left unspecified.
|
||||
* <br>2. Incorrect parameter types. 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900003 - Bluetooth disabled.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
function getRemoteDeviceName(deviceId: string): string;
|
||||
|
||||
/**
|
||||
@ -358,6 +481,23 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Obtains the class of a peer Bluetooth device.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @param { string } deviceId - Indicates device ID. For example, "11:22:33:AA:BB:FF".
|
||||
* @returns { DeviceClass } The class of the remote device.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 401 - Invalid parameter. Possible causes: 1. Mandatory parameters are left unspecified.
|
||||
* <br>2. Incorrect parameter types. 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900003 - Bluetooth disabled.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
function getRemoteDeviceClass(deviceId: string): DeviceClass;
|
||||
|
||||
/**
|
||||
@ -372,6 +512,19 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Obtains the Bluetooth local name of a device.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @returns { string } Returns the name the device.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
function getLocalName(): string;
|
||||
|
||||
/**
|
||||
@ -401,6 +554,21 @@ declare namespace connection {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Obtains the list of Bluetooth devices that have been paired with the current device.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @returns { Array<string> } Returns a list of paired Bluetooth devices's address.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900003 - Bluetooth disabled.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
function getPairedDevices(): Array<string>;
|
||||
|
||||
/**
|
||||
@ -436,6 +604,24 @@ declare namespace connection {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Obtains the pair state of a specified device.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @param { string } deviceId - Indicates device ID. For example, "11:22:33:AA:BB:FF".
|
||||
* @returns { BondState } Returns the pair state.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 401 - Invalid parameter. Possible causes: 1. Mandatory parameters are left unspecified.
|
||||
* <br>2. Incorrect parameter types. 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900003 - Bluetooth disabled.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
function getPairState(deviceId: string): BondState;
|
||||
|
||||
/**
|
||||
@ -544,6 +730,20 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Obtains the Bluetooth scanning mode of a device.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @returns { ScanMode } Returns the Bluetooth scanning mode.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900003 - Bluetooth disabled.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
function getBluetoothScanMode(): ScanMode;
|
||||
|
||||
/**
|
||||
@ -571,6 +771,20 @@ declare namespace connection {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Starts scanning Bluetooth devices.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900003 - Bluetooth disabled.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
function startBluetoothDiscovery(): void;
|
||||
|
||||
/**
|
||||
@ -598,6 +812,20 @@ declare namespace connection {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Stops Bluetooth device scanning.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900003 - Bluetooth disabled.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
function stopBluetoothDiscovery(): void;
|
||||
|
||||
/**
|
||||
@ -613,6 +841,20 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Check if bluetooth is discovering.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @returns { boolean } Returns {@code true} if the local device is discovering; returns {@code false} otherwise.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900003 - Bluetooth disabled.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
function isBluetoothDiscovering(): boolean;
|
||||
|
||||
/**
|
||||
@ -686,6 +928,22 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Obtains the profile UUIDs supported by the remote device.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @param { string } deviceId - Indicates device ID. For example, "11:22:33:AA:BB:FF".
|
||||
* @param { AsyncCallback<Array<ProfileUuids>> } callback - the callback of getRemoteProfileUuids.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 401 - Invalid parameter.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900003 - Bluetooth disabled.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
function getRemoteProfileUuids(deviceId: string, callback: AsyncCallback<Array<ProfileUuids>>): void;
|
||||
|
||||
/**
|
||||
@ -721,6 +979,22 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Obtains the profile UUIDs supported by the remote device.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @param { string } deviceId - Indicates device ID. For example, "11:22:33:AA:BB:FF".
|
||||
* @returns { Promise<Array<ProfileUuids>> } Returns the promise object.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 401 - Invalid parameter.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900001 - Service stopped.
|
||||
* @throws { BusinessError } 2900003 - Bluetooth disabled.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
function getRemoteProfileUuids(deviceId: string): Promise<Array<ProfileUuids>>;
|
||||
|
||||
/**
|
||||
@ -921,6 +1195,22 @@ declare namespace connection {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Subscribe the event reported when a remote Bluetooth device is discovered.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @param { 'bluetoothDeviceFind' } type - Type of the discovering event to listen for.
|
||||
* @param { Callback<Array<string>> } callback - Callback used to listen for the discovering event.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 401 - Invalid parameter. Possible causes: 1. Mandatory parameters are left unspecified.
|
||||
* <br>2. Incorrect parameter types. 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
function on(type: 'bluetoothDeviceFind', callback: Callback<Array<string>>): void;
|
||||
|
||||
/**
|
||||
@ -948,6 +1238,20 @@ declare namespace connection {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Unsubscribe the event reported when a remote Bluetooth device is discovered.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @param { 'bluetoothDeviceFind' } type - Type of the discovering event to listen for.
|
||||
* @param { Callback<Array<string>> } callback - Callback used to listen for the discovering event.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
function off(type: 'bluetoothDeviceFind', callback?: Callback<Array<string>>): void;
|
||||
|
||||
/**
|
||||
@ -996,6 +1300,21 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Subscribe the event reported when a remote Bluetooth device is bonded.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @param { 'bondStateChange' } type - Type of the bond state event to listen for.
|
||||
* @param { Callback<BondStateParam> } callback - Callback used to listen for the bond state event.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 401 - Invalid parameter. Possible causes: 1. Mandatory parameters are left unspecified.
|
||||
* <br>2. Incorrect parameter types. 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
function on(type: 'bondStateChange', callback: Callback<BondStateParam>): void;
|
||||
|
||||
/**
|
||||
@ -1012,6 +1331,21 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Unsubscribe the event reported when a remote Bluetooth device is bonded.
|
||||
*
|
||||
* @permission ohos.permission.ACCESS_BLUETOOTH
|
||||
* @param { 'bondStateChange' } type - Type of the bond state event to listen for.
|
||||
* @param { Callback<BondStateParam> } callback - Callback used to listen for the bond state event.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 401 - Invalid parameter. Possible causes: 1. Mandatory parameters are left unspecified.
|
||||
* <br>2. Incorrect parameter types. 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 801 - Capability not supported.
|
||||
* @throws { BusinessError } 2900099 - Operation failed.
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
function off(type: 'bondStateChange', callback?: Callback<BondStateParam>): void;
|
||||
|
||||
/**
|
||||
@ -1079,6 +1413,14 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Describes the class of a bluetooth device.
|
||||
*
|
||||
* @typedef BondStateParam
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
interface BondStateParam {
|
||||
/**
|
||||
* Address of a Bluetooth device.
|
||||
@ -1087,6 +1429,14 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Address of a Bluetooth device.
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
deviceId: string;
|
||||
/**
|
||||
* Profile connection state of the device.
|
||||
@ -1095,6 +1445,14 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Profile connection state of the device.
|
||||
*
|
||||
* @type { BondState }
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
state: BondState;
|
||||
/**
|
||||
* Cause of unbond.
|
||||
@ -1103,6 +1461,14 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Cause of unbond.
|
||||
*
|
||||
* @type { UnbondCause }
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
cause: UnbondCause;
|
||||
}
|
||||
|
||||
@ -1148,6 +1514,14 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Describes the class of a bluetooth device.
|
||||
*
|
||||
* @typedef DeviceClass
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
interface DeviceClass {
|
||||
/**
|
||||
* Major classes of Bluetooth devices.
|
||||
@ -1156,6 +1530,14 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Major classes of Bluetooth devices.
|
||||
*
|
||||
* @type { MajorClass }
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
majorClass: MajorClass;
|
||||
/**
|
||||
* Major and minor classes of Bluetooth devices.
|
||||
@ -1164,6 +1546,14 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Major and minor classes of Bluetooth devices.
|
||||
*
|
||||
* @type { MajorMinorClass }
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
majorMinorClass: MajorMinorClass;
|
||||
/**
|
||||
* Class of the device.
|
||||
@ -1172,6 +1562,14 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Class of the device.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
classOfDevice: number;
|
||||
}
|
||||
|
||||
@ -1206,6 +1604,14 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* The enum of BR scan mode.
|
||||
*
|
||||
* @enum { number }
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
enum ScanMode {
|
||||
/**
|
||||
* Indicates the scan mode is none
|
||||
@ -1213,6 +1619,13 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Indicates the scan mode is none
|
||||
*
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
SCAN_MODE_NONE = 0,
|
||||
/**
|
||||
* Indicates the scan mode is connectable
|
||||
@ -1220,6 +1633,13 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Indicates the scan mode is connectable
|
||||
*
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
SCAN_MODE_CONNECTABLE = 1,
|
||||
/**
|
||||
* Indicates the scan mode is general discoverable
|
||||
@ -1241,6 +1661,13 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 10
|
||||
*/
|
||||
/**
|
||||
* Indicates the scan mode is connectable and general discoverable
|
||||
*
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
SCAN_MODE_CONNECTABLE_GENERAL_DISCOVERABLE = 4,
|
||||
/**
|
||||
* Indicates the scan mode is connectable and limited discoverable
|
||||
@ -1266,6 +1693,15 @@ declare namespace connection {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* The enum of bond state.
|
||||
*
|
||||
* @enum { number }
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
enum BondState {
|
||||
/**
|
||||
* Indicate the bond state is invalid
|
||||
@ -1280,6 +1716,14 @@ declare namespace connection {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Indicate the bond state is invalid
|
||||
*
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
BOND_STATE_INVALID = 0,
|
||||
/**
|
||||
* Indicate the bond state is bonding
|
||||
@ -1294,6 +1738,14 @@ declare namespace connection {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Indicate the bond state is bonding
|
||||
*
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
BOND_STATE_BONDING = 1,
|
||||
/**
|
||||
* Indicate the bond state is bonded
|
||||
@ -1308,6 +1760,14 @@ declare namespace connection {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Indicate the bond state is bonded
|
||||
*
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
BOND_STATE_BONDED = 2
|
||||
}
|
||||
|
||||
@ -1628,6 +2088,14 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Enum for cause of unbond.
|
||||
*
|
||||
* @enum { number }
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
enum UnbondCause {
|
||||
/**
|
||||
* User proactively removed device.
|
||||
@ -1635,6 +2103,13 @@ declare namespace connection {
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* User proactively removed device.
|
||||
*
|
||||
* @syscap SystemCapability.Communication.Bluetooth.Core
|
||||
* @crossplatform
|
||||
* @since 13
|
||||
*/
|
||||
USER_REMOVED = 0,
|
||||
/**
|
||||
* Remote device shut down.
|
||||
|
547
api/@ohos.bluetooth.constant.d.ts
vendored
547
api/@ohos.bluetooth.constant.d.ts
vendored
File diff suppressed because it is too large
Load Diff
8
api/@ohos.bundle.appDomainVerify.d.ts
vendored
8
api/@ohos.bundle.appDomainVerify.d.ts
vendored
@ -13,9 +13,9 @@
|
||||
* @syscap SystemCapability.BundleManager.AppDomainVerify
|
||||
* @systemapi
|
||||
* @stagemodelonly
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
declare namespace appDomainVerify {
|
||||
declare namespace appDomainVerify {
|
||||
|
||||
|
||||
/**
|
||||
@ -30,7 +30,7 @@
|
||||
* @syscap SystemCapability.BundleManager.AppDomainVerify
|
||||
* @systemapi
|
||||
* @stagemodelonly
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
function queryAssociatedDomains(bundleName: string): string[];
|
||||
|
||||
@ -46,7 +46,7 @@
|
||||
* @syscap SystemCapability.BundleManager.AppDomainVerify
|
||||
* @systemapi
|
||||
* @stagemodelonly
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
function queryAssociatedBundleNames(domain: string): string[];
|
||||
}
|
||||
|
57
api/@ohos.bundle.bundleManager.d.ts
vendored
57
api/@ohos.bundle.bundleManager.d.ts
vendored
@ -2431,6 +2431,19 @@ declare namespace bundleManager {
|
||||
*/
|
||||
function getLaunchWantForBundleSync(bundleName: string, userId?: number): Want;
|
||||
|
||||
/**
|
||||
* Obtains the Want for starting the main ability of own application.
|
||||
* The main ability of an application is the ability that has the
|
||||
* #ACTION_HOME and #ENTITY_HOME Want filters set in the application's <b>config.json</b> or <b>module.json</b> file.
|
||||
*
|
||||
* @returns { Want } the Want for starting the application's main ability.
|
||||
* @throws { BusinessError } 17700072 - The launch want is not found.
|
||||
* @syscap SystemCapability.BundleManager.BundleFramework.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
function getLaunchWant(): Want;
|
||||
|
||||
/**
|
||||
* Obtains the profile designated by metadata name, abilityName and moduleName from the current application.
|
||||
*
|
||||
@ -3122,6 +3135,21 @@ declare namespace bundleManager {
|
||||
* @syscap SystemCapability.BundleManager.BundleFramework.Core
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Verifies the validity of .abc files. Only .abc files passed the verification can run on the restricted VM.
|
||||
*
|
||||
* @permission ohos.permission.RUN_DYN_CODE
|
||||
* @param { Array<string> } abcPaths - The abc path.
|
||||
* @param { boolean } deleteOriginalFiles - Used to decide whether to delete the original files.
|
||||
* @param { AsyncCallback<void> } callback - Indicates the callback of verifyAbc result.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 202 - Permission denied, non-system app called system api.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 17700201 - Failed to verify the abc file.
|
||||
* @syscap SystemCapability.BundleManager.BundleFramework.Core
|
||||
* @systemapi
|
||||
* @since 12
|
||||
*/
|
||||
function verifyAbc(abcPaths: Array<string>, deleteOriginalFiles: boolean, callback: AsyncCallback<void>): void;
|
||||
|
||||
/**
|
||||
@ -3137,6 +3165,21 @@ declare namespace bundleManager {
|
||||
* @syscap SystemCapability.BundleManager.BundleFramework.Core
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Verifies the validity of .abc files. Only .abc files passed the verification can run on the restricted VM.
|
||||
*
|
||||
* @permission ohos.permission.RUN_DYN_CODE
|
||||
* @param { Array<string> } abcPaths - The abc path.
|
||||
* @param { boolean } deleteOriginalFiles - Used to decide whether to delete the original files.
|
||||
* @returns { Promise<void> } Returns verifyAbc result.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 202 - Permission denied, non-system app called system api.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 17700201 - Failed to verify the abc file.
|
||||
* @syscap SystemCapability.BundleManager.BundleFramework.Core
|
||||
* @systemapi
|
||||
* @since 12
|
||||
*/
|
||||
function verifyAbc(abcPaths: Array<string>, deleteOriginalFiles: boolean): Promise<void>;
|
||||
|
||||
/**
|
||||
@ -3195,6 +3238,20 @@ declare namespace bundleManager {
|
||||
* @syscap SystemCapability.BundleManager.BundleFramework.Core
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Delete the verified .abc file.
|
||||
*
|
||||
* @permission ohos.permission.RUN_DYN_CODE
|
||||
* @param { string } abcPath - The abc path.
|
||||
* @returns { Promise<void> } Returns deleteAbc result.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 202 - Permission denied, non-system app called system api.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 17700202 - Failed to delete the abc file.
|
||||
* @syscap SystemCapability.BundleManager.BundleFramework.Core
|
||||
* @systemapi
|
||||
* @since 12
|
||||
*/
|
||||
function deleteAbc(abcPath: string): Promise<void>;
|
||||
|
||||
/**
|
||||
|
198
api/@ohos.bundle.installer.d.ts
vendored
198
api/@ohos.bundle.installer.d.ts
vendored
@ -227,6 +227,49 @@ declare namespace installer {
|
||||
* @systemapi
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Install HAPs for an application.
|
||||
* To install a non-enterprise application, you must have the permission ohos.permission.INSTALL_BUNDLE.
|
||||
* To install an enterprise application, you must have the permission ohos.permission.INSTALL_ENTERPRISE_BUNDLE.
|
||||
* To install an enterprise administrator application, you must have the permission ohos.permission.INSTALL_ENTERPRISE_MDM_BUNDLE.
|
||||
* To install an enterprise normal application, you must have the permission ohos.permission.INSTALL_ENTERPRISE_NORMAL_BUNDLE.
|
||||
* To install an internal beta application, you must have the permission ohos.permission.INSTALL_INTERNALTESTING_BUNDLE.
|
||||
*
|
||||
* @permission ohos.permission.INSTALL_BUNDLE or ohos.permission.INSTALL_ENTERPRISE_BUNDLE or ohos.permission.INSTALL_ENTERPRISE_MDM_BUNDLE or ohos.permission.INSTALL_ENTERPRISE_NORMAL_BUNDLE
|
||||
* @param { Array<string> } hapFilePaths - Indicates the path where the HAP of the application is stored.
|
||||
* @param { InstallParam } installParam - Indicates other parameters required for the installation.
|
||||
* @param { AsyncCallback<void> } callback - The callback of installing HAPs result.
|
||||
* @throws { BusinessError } 201 - Calling interface without permission 'ohos.permission.INSTALL_BUNDLE' or 'ohos.permission.INSTALL_ENTERPRISE_BUNDLE' or
|
||||
* 'ohos.permission.INSTALL_ENTERPRISE_MDM_BUNDLE' or 'ohos.permission.INSTALL_ENTERPRISE_NORMAL_BUNDLE'.
|
||||
* @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter hapFiles is needed for code signature; 4. The size of specifiedDistributionType is greater than 128; 5. The size of additionalInfo is greater than 3000.
|
||||
* @throws { BusinessError } 17700004 - The specified user ID is not found.
|
||||
* @throws { BusinessError } 17700010 - Failed to install the HAP because the HAP fails to be parsed.
|
||||
* @throws { BusinessError } 17700011 - Failed to install the HAP because the HAP signature fails to be verified.
|
||||
* @throws { BusinessError } 17700012 - Failed to install the HAP because the HAP path is invalid or the HAP is too large.
|
||||
* @throws { BusinessError } 17700015 - Failed to install the HAPs because they have different configuration information.
|
||||
* @throws { BusinessError } 17700016 - Failed to install the HAP because of insufficient system disk space.
|
||||
* @throws { BusinessError } 17700017 - Failed to install the HAP since the version of the HAP to install is too early.
|
||||
* @throws { BusinessError } 17700018 - Failed to install because the dependent module does not exist.
|
||||
* @throws { BusinessError } 17700031 - Failed to install the HAP because the overlay check of the HAP is failed.
|
||||
* @throws { BusinessError } 17700036 - Failed to install the HSP because lacks appropriate permissions.
|
||||
* @throws { BusinessError } 17700039 - Failed to install because disallow install a shared bundle by hapFilePaths.
|
||||
* @throws { BusinessError } 17700041 - Failed to install because enterprise device management disallow install.
|
||||
* @throws { BusinessError } 17700042 - Failed to install the HAP because of incorrect URI in the data proxy.
|
||||
* @throws { BusinessError } 17700043 - Failed to install the HAP because of low APL in the non-system data proxy
|
||||
* (required APL: system_basic or system_core).
|
||||
* @throws { BusinessError } 17700044 - Failed to install the HAP because the isolationMode configured is not supported.
|
||||
* @throws { BusinessError } 17700047 - Failed to install the HAP because the VersionCode to be updated is not greater than the current VersionCode.
|
||||
* @throws { BusinessError } 17700048 - Failed to install the HAP because the code signature verification is failed.
|
||||
* @throws { BusinessError } 17700050 - Failed to install the HAP because enterprise normal/MDM bundle cannot be installed on non-enterprise device.
|
||||
* @throws { BusinessError } 17700052 - Failed to install the HAP because debug bundle cannot be installed under non-developer mode.
|
||||
* @throws { BusinessError } 17700054 - Failed to install the HAP because the HAP requests wrong permissions.
|
||||
* @throws { BusinessError } 17700058 - Failed to install the HAP because the device has been controlled.
|
||||
* @throws { BusinessError } 17700066 - Failed to install the HAP because installing the native package failed.
|
||||
* @syscap SystemCapability.BundleManager.BundleFramework.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
install(hapFilePaths: Array<string>, installParam: InstallParam, callback: AsyncCallback<void>): void;
|
||||
|
||||
/**
|
||||
@ -372,6 +415,47 @@ declare namespace installer {
|
||||
* @systemapi
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Install HAPs for an application.
|
||||
* To install a non-enterprise application, you must have the permission ohos.permission.INSTALL_BUNDLE.
|
||||
* To install an enterprise application, you must have the permission ohos.permission.INSTALL_ENTERPRISE_BUNDLE.
|
||||
* To install an enterprise administrator application, you must have the permission ohos.permission.INSTALL_ENTERPRISE_MDM_BUNDLE.
|
||||
* To install an enterprise normal application, you must have the permission ohos.permission.INSTALL_ENTERPRISE_NORMAL_BUNDLE.
|
||||
* To install an internal beta application, you must have the permission ohos.permission.INSTALL_INTERNALTESTING_BUNDLE.
|
||||
*
|
||||
* @permission ohos.permission.INSTALL_BUNDLE or ohos.permission.INSTALL_ENTERPRISE_BUNDLE or ohos.permission.INSTALL_ENTERPRISE_MDM_BUNDLE or ohos.permission.INSTALL_ENTERPRISE_NORMAL_BUNDLE
|
||||
* @param { Array<string> } hapFilePaths - Indicates the path where the HAP of the application is stored.
|
||||
* @param { AsyncCallback<void> } callback - The callback of installing HAPs result.
|
||||
* @throws { BusinessError } 201 - Calling interface without permission 'ohos.permission.INSTALL_BUNDLE' or 'ohos.permission.INSTALL_ENTERPRISE_BUNDLE' or
|
||||
* 'ohos.permission.INSTALL_ENTERPRISE_MDM_BUNDLE' or 'ohos.permission.INSTALL_ENTERPRISE_NORMAL_BUNDLE'.
|
||||
* @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 17700010 - Failed to install the HAP because the HAP fails to be parsed.
|
||||
* @throws { BusinessError } 17700011 - Failed to install the HAP because the HAP signature fails to be verified.
|
||||
* @throws { BusinessError } 17700012 - Failed to install the HAP because the HAP path is invalid or the HAP is too large.
|
||||
* @throws { BusinessError } 17700015 - Failed to install the HAPs because they have different configuration information.
|
||||
* @throws { BusinessError } 17700016 - Failed to install the HAP because of insufficient system disk space.
|
||||
* @throws { BusinessError } 17700017 - Failed to install the HAP since the version of the HAP to install is too early.
|
||||
* @throws { BusinessError } 17700018 - Failed to install because the dependent module does not exist.
|
||||
* @throws { BusinessError } 17700031 - Failed to install the HAP because the overlay check of the HAP is failed.
|
||||
* @throws { BusinessError } 17700036 - Failed to install the HSP because lacks appropriate permissions.
|
||||
* @throws { BusinessError } 17700039 - Failed to install because disallow install a shared bundle by hapFilePaths.
|
||||
* @throws { BusinessError } 17700041 - Failed to install because enterprise device management disallow install.
|
||||
* @throws { BusinessError } 17700042 - Failed to install the HAP because of incorrect URI in the data proxy.
|
||||
* @throws { BusinessError } 17700043 - Failed to install the HAP because of low APL in the non-system data proxy
|
||||
* (required APL: system_basic or system_core).
|
||||
* @throws { BusinessError } 17700044 - Failed to install the HAP because the isolationMode configured is not supported.
|
||||
* @throws { BusinessError } 17700047 - Failed to install the HAP because the VersionCode to be updated is not greater than the current VersionCode.
|
||||
* @throws { BusinessError } 17700048 - Failed to install the HAP because the code signature verification is failed.
|
||||
* @throws { BusinessError } 17700050 - Failed to install the HAP because enterprise normal/MDM bundle cannot be installed on non-enterprise device.
|
||||
* @throws { BusinessError } 17700052 - Failed to install the HAP because debug bundle cannot be installed under non-developer mode.
|
||||
* @throws { BusinessError } 17700054 - Failed to install the HAP because the HAP requests wrong permissions.
|
||||
* @throws { BusinessError } 17700058 - Failed to install the HAP because the device has been controlled.
|
||||
* @throws { BusinessError } 17700066 - Failed to install the HAP because installing the native package failed.
|
||||
* @syscap SystemCapability.BundleManager.BundleFramework.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
install(hapFilePaths: Array<string>, callback: AsyncCallback<void>): void;
|
||||
|
||||
/**
|
||||
@ -529,6 +613,49 @@ declare namespace installer {
|
||||
* @systemapi
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Install haps for an application.
|
||||
* To install a non-enterprise application, you must have the permission ohos.permission.INSTALL_BUNDLE.
|
||||
* To install an enterprise application, you must have the permission ohos.permission.INSTALL_ENTERPRISE_BUNDLE.
|
||||
* To install an enterprise administrator application, you must have the permission ohos.permission.INSTALL_ENTERPRISE_MDM_BUNDLE.
|
||||
* To install an enterprise normal application, you must have the permission ohos.permission.INSTALL_ENTERPRISE_NORMAL_BUNDLE.
|
||||
* To install an internal beta application, you must have the permission ohos.permission.INSTALL_INTERNALTESTING_BUNDLE.
|
||||
*
|
||||
* @permission ohos.permission.INSTALL_BUNDLE or ohos.permission.INSTALL_ENTERPRISE_BUNDLE or ohos.permission.INSTALL_ENTERPRISE_MDM_BUNDLE or ohos.permission.INSTALL_ENTERPRISE_NORMAL_BUNDLE
|
||||
* @param { Array<string> } hapFilePaths - Indicates the path where the HAP of the application is stored.
|
||||
* @param { InstallParam } [installParam] - Indicates other parameters required for the installation.
|
||||
* @returns { Promise<void> }
|
||||
* @throws { BusinessError } 201 - Calling interface without permission 'ohos.permission.INSTALL_BUNDLE' or 'ohos.permission.INSTALL_ENTERPRISE_BUNDLE' or
|
||||
* 'ohos.permission.INSTALL_ENTERPRISE_MDM_BUNDLE' or 'ohos.permission.INSTALL_ENTERPRISE_NORMAL_BUNDLE'.
|
||||
* @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types; 3. Parameter hapFiles is needed for code signature; 4. The size of specifiedDistributionType is greater than 128; 5. The size of additionalInfo is greater than 3000.
|
||||
* @throws { BusinessError } 17700004 - The specified user ID is not found.
|
||||
* @throws { BusinessError } 17700010 - Failed to install the HAP because the HAP fails to be parsed.
|
||||
* @throws { BusinessError } 17700011 - Failed to install the HAP because the HAP signature fails to be verified.
|
||||
* @throws { BusinessError } 17700012 - Failed to install the HAP because the HAP path is invalid or the HAP is too large.
|
||||
* @throws { BusinessError } 17700015 - Failed to install the HAPs because they have different configuration information.
|
||||
* @throws { BusinessError } 17700016 - Failed to install the HAP because of insufficient system disk space.
|
||||
* @throws { BusinessError } 17700017 - Failed to install the HAP since the version of the HAP to install is too early.
|
||||
* @throws { BusinessError } 17700018 - Failed to install because the dependent module does not exist.
|
||||
* @throws { BusinessError } 17700031 - Failed to install the HAP because the overlay check of the HAP is failed.
|
||||
* @throws { BusinessError } 17700036 - Failed to install the HSP because lacks appropriate permissions.
|
||||
* @throws { BusinessError } 17700039 - Failed to install because disallow install a shared bundle by hapFilePaths.
|
||||
* @throws { BusinessError } 17700041 - Failed to install because enterprise device management disallow install.
|
||||
* @throws { BusinessError } 17700042 - Failed to install the HAP because of incorrect URI in the data proxy.
|
||||
* @throws { BusinessError } 17700043 - Failed to install the HAP because of low APL in the non-system data proxy
|
||||
* (required APL: system_basic or system_core).
|
||||
* @throws { BusinessError } 17700044 - Failed to install the HAP because the isolationMode configured is not supported.
|
||||
* @throws { BusinessError } 17700047 - Failed to install the HAP because the VersionCode to be updated is not greater than the current VersionCode.
|
||||
* @throws { BusinessError } 17700048 - Failed to install the HAP because the code signature verification is failed.
|
||||
* @throws { BusinessError } 17700050 - Failed to install the HAP because enterprise normal/MDM bundle cannot be installed on non-enterprise device.
|
||||
* @throws { BusinessError } 17700052 - Failed to install the HAP because debug bundle cannot be installed under non-developer mode.
|
||||
* @throws { BusinessError } 17700054 - Failed to install the HAP because the HAP requests wrong permissions.
|
||||
* @throws { BusinessError } 17700058 - Failed to install the HAP because the device has been controlled.
|
||||
* @throws { BusinessError } 17700066 - Failed to install the HAP because installing the native package failed.
|
||||
* @syscap SystemCapability.BundleManager.BundleFramework.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
install(hapFilePaths: Array<string>, installParam?: InstallParam): Promise<void>;
|
||||
|
||||
/**
|
||||
@ -727,6 +854,24 @@ declare namespace installer {
|
||||
* @systemapi
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Recover an application.
|
||||
*
|
||||
* @permission ohos.permission.INSTALL_BUNDLE or ohos.permission.RECOVER_BUNDLE
|
||||
* @param { string } bundleName - Indicates the bundle name of the application to be recovered.
|
||||
* @param { InstallParam } installParam - Indicates other parameters required for the recover.
|
||||
* @param { AsyncCallback<void> } callback - The callback of recovering application result.
|
||||
* @throws { BusinessError } 201 - Calling interface without permission 'ohos.permission.INSTALL_BUNDLE' or 'ohos.permission.RECOVER_BUNDLE'.
|
||||
* @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 17700001 - The specified bundle name is not found.
|
||||
* @throws { BusinessError } 17700004 - The specified user ID is not found.
|
||||
* @throws { BusinessError } 17700058 - Failed to install the HAP because this application is prohibited
|
||||
* <br>from being installed on this device or by specified users.
|
||||
* @syscap SystemCapability.BundleManager.BundleFramework.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
recover(bundleName: string, installParam: InstallParam, callback: AsyncCallback<void>): void;
|
||||
|
||||
/**
|
||||
@ -743,6 +888,22 @@ declare namespace installer {
|
||||
* @systemapi
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Recover an application.
|
||||
*
|
||||
* @permission ohos.permission.INSTALL_BUNDLE or ohos.permission.RECOVER_BUNDLE
|
||||
* @param { string } bundleName - Indicates the bundle name of the application to be recovered.
|
||||
* @param { AsyncCallback<void> } callback - The callback of recovering application result.
|
||||
* @throws { BusinessError } 201 - Calling interface without permission 'ohos.permission.INSTALL_BUNDLE' or 'ohos.permission.RECOVER_BUNDLE'.
|
||||
* @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 17700001 - The specified bundle name is not found.
|
||||
* @throws { BusinessError } 17700058 - Failed to install the HAP because this application is prohibited
|
||||
* <br>from being installed on this device or by specified users.
|
||||
* @syscap SystemCapability.BundleManager.BundleFramework.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
recover(bundleName: string, callback: AsyncCallback<void>): void;
|
||||
|
||||
/**
|
||||
@ -761,6 +922,24 @@ declare namespace installer {
|
||||
* @systemapi
|
||||
* @since 9
|
||||
*/
|
||||
/**
|
||||
* Recover an application.
|
||||
*
|
||||
* @permission ohos.permission.INSTALL_BUNDLE or ohos.permission.RECOVER_BUNDLE
|
||||
* @param { string } bundleName - Indicates the bundle name of the application to be recovered.
|
||||
* @param { InstallParam } installParam - Indicates other parameters required for the recover.
|
||||
* @returns { Promise<void> }
|
||||
* @throws { BusinessError } 201 - Calling interface without permission 'ohos.permission.INSTALL_BUNDLE' or 'ohos.permission.RECOVER_BUNDLE'.
|
||||
* @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 17700001 - The specified bundle name is not found.
|
||||
* @throws { BusinessError } 17700004 - The specified user ID is not found.
|
||||
* @throws { BusinessError } 17700058 - Failed to install the HAP because this application is prohibited
|
||||
* <br>from being installed on this device or by specified users.
|
||||
* @syscap SystemCapability.BundleManager.BundleFramework.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
recover(bundleName: string, installParam?: InstallParam): Promise<void>;
|
||||
|
||||
/**
|
||||
@ -1119,6 +1298,25 @@ declare namespace installer {
|
||||
* @systemapi
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Install application by bundle name with specified user.
|
||||
*
|
||||
* @permission ohos.permission.INSTALL_BUNDLE
|
||||
* @param { string } bundleName - Indicates the bundle name of application.
|
||||
* @param { number } [userId] - userId Indicates the user ID.
|
||||
* @returns { Promise<void> }
|
||||
* @throws { BusinessError } 201 - Calling interface without permission 'ohos.permission.INSTALL_BUNDLE'.
|
||||
* @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 17700001 - The specified bundleName cannot be found or the bundle is not installed by the specified user.
|
||||
* @throws { BusinessError } 17700004 - The userId is invalid.
|
||||
* @throws { BusinessError } 17700071 - It is not allowed to install the enterprise bundle.
|
||||
* @throws { BusinessError } 17700058 - Failed to install the HAP because this application is prohibited
|
||||
* <br>from being installed on this device or by specified users.
|
||||
* @syscap SystemCapability.BundleManager.BundleFramework.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
installPreexistingApp(bundleName: string, userId?: number): Promise<void>;
|
||||
}
|
||||
|
||||
|
330
api/@ohos.data.unifiedDataChannel.d.ts
vendored
330
api/@ohos.data.unifiedDataChannel.d.ts
vendored
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2023 Huawei Device Co., Ltd.
|
||||
* Copyright (c) 2023-2024 Huawei Device Co., Ltd.
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
@ -37,6 +37,15 @@ import Want from "./@ohos.app.ability.Want";
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Provide methods for sharing data between different applications across unified data channels.
|
||||
*
|
||||
* @namespace unifiedDataChannel
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare namespace unifiedDataChannel {
|
||||
/**
|
||||
* Types of scope that UnifiedData can be used.
|
||||
@ -81,6 +90,14 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Indicates type of value.
|
||||
* @typedef {number | string | boolean | image.PixelMap | Want | ArrayBuffer | object | null | undefined}
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
type ValueType = number | string | boolean | image.PixelMap | Want | ArrayBuffer | object | null | undefined;
|
||||
|
||||
/**
|
||||
@ -150,6 +167,14 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Describe the unified data.
|
||||
*
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
class UnifiedData {
|
||||
/**
|
||||
* Create unified data with a record
|
||||
@ -170,6 +195,17 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Create unified data with a record
|
||||
*
|
||||
* @param { UnifiedRecord } record - Record will add into unified data.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:1.Mandatory parameters are left unspecified;
|
||||
* <br>2.Incorrect Parameters types.
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
constructor(record: UnifiedRecord);
|
||||
/**
|
||||
* Create a empty unified data.
|
||||
@ -178,6 +214,14 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Create a empty unified data.
|
||||
*
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
constructor();
|
||||
/**
|
||||
* Add a record into unified data
|
||||
@ -198,6 +242,17 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Add a record into unified data
|
||||
*
|
||||
* @param { UnifiedRecord } record - Record will add into unified data.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:1.Mandatory parameters are left unspecified;
|
||||
* <br>2.Incorrect Parameters types.
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
addRecord(record: UnifiedRecord): void;
|
||||
/**
|
||||
* Get all records of unified data
|
||||
@ -214,6 +269,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Get all records of unified data
|
||||
*
|
||||
* @returns { Array<UnifiedRecord> } Return the records of unified data
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
getRecords(): Array<UnifiedRecord>;
|
||||
|
||||
/**
|
||||
@ -226,6 +290,17 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Checks whether there is a specified type of data in DataProperties.
|
||||
* @param { string } type - indicates to query data type.
|
||||
* @returns { boolean } if having mimeType in UnifiedData returns true, else returns false.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:1.Mandatory parameters are left unspecified;
|
||||
* <br>2.Incorrect Parameters types.
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
hasType(type: string): boolean;
|
||||
|
||||
/**
|
||||
@ -235,6 +310,14 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* UTD types of all content in the UnifiedData.
|
||||
* @returns { Array<string> } type of array
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
getTypes(): Array<string>;
|
||||
|
||||
/**
|
||||
@ -306,6 +389,14 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Describe the unified record
|
||||
*
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
class UnifiedRecord {
|
||||
/**
|
||||
* Get type of unified record
|
||||
@ -322,6 +413,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Get type of unified record
|
||||
*
|
||||
* @returns { string } Return the type of unified data
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
getType(): string;
|
||||
|
||||
/**
|
||||
@ -331,6 +431,14 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Create unified record.
|
||||
*
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
constructor();
|
||||
|
||||
/**
|
||||
@ -345,6 +453,19 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Create unified record by type and value.
|
||||
*
|
||||
* @param { string } type - indicates to data type of unified record. It can not be empty. When type of value is object, parameter type must be pixel-map or want UTD type.
|
||||
* @param { ValueType } value - indicates to value of unified record.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:1.Mandatory parameters are left unspecified;
|
||||
* <br>2.Incorrect Parameters types;
|
||||
* <br>3.Parameter verification failed.
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
constructor(type: string, value: ValueType);
|
||||
|
||||
/**
|
||||
@ -355,6 +476,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Get the value of unified record.
|
||||
*
|
||||
* @returns { ValueType } Return the value of unified record.
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
getValue(): ValueType;
|
||||
}
|
||||
|
||||
@ -373,6 +503,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Describe the unified text data
|
||||
*
|
||||
* @extends UnifiedRecord
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
class Text extends UnifiedRecord {
|
||||
/**
|
||||
* Indicates the details of unified text
|
||||
@ -388,6 +527,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Indicates the details of unified text
|
||||
*
|
||||
* @type { ?Record<string, string> }
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
details?: Record<string, string>;
|
||||
}
|
||||
|
||||
@ -406,6 +554,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Describe the unified plain text data
|
||||
*
|
||||
* @extends Text
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
class PlainText extends Text {
|
||||
/**
|
||||
* Indicates the content of text
|
||||
@ -421,6 +578,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Indicates the content of text
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
textContent: string;
|
||||
/**
|
||||
* Indicates the abstract of text
|
||||
@ -436,6 +602,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Indicates the abstract of text
|
||||
*
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
abstract?: string;
|
||||
}
|
||||
|
||||
@ -454,6 +629,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Describe the unified link data
|
||||
*
|
||||
* @extends Text
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
class Hyperlink extends Text {
|
||||
/**
|
||||
* Indicates the url of a link
|
||||
@ -469,6 +653,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Indicates the url of a link
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
url: string;
|
||||
/**
|
||||
* Indicates the description of a link
|
||||
@ -484,6 +677,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Indicates the description of a link
|
||||
*
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
description?: string;
|
||||
}
|
||||
|
||||
@ -502,6 +704,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Describe the unified html data
|
||||
*
|
||||
* @extends Text
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
class HTML extends Text {
|
||||
/**
|
||||
* Indicates the content of html, with html tags
|
||||
@ -517,6 +728,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Indicates the content of html, with html tags
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
htmlContent: string;
|
||||
/**
|
||||
* Indicates the plain content of html
|
||||
@ -532,6 +752,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Indicates the plain content of html
|
||||
*
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
plainContent?: string;
|
||||
}
|
||||
|
||||
@ -550,6 +779,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Describe the unified file data
|
||||
*
|
||||
* @extends UnifiedRecord
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
class File extends UnifiedRecord {
|
||||
/**
|
||||
* Indicates the details of unified File
|
||||
@ -565,6 +803,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Indicates the details of unified File
|
||||
*
|
||||
* @type { ?Record<string, string> }
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
details?: Record<string, string>;
|
||||
/**
|
||||
* Indicates the uri of file
|
||||
@ -580,6 +827,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Indicates the uri of file
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
uri: string;
|
||||
}
|
||||
|
||||
@ -598,6 +854,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Describe the unified image data
|
||||
*
|
||||
* @extends File
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
class Image extends File {
|
||||
/**
|
||||
* Indicates the uri of image
|
||||
@ -613,6 +878,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Indicates the uri of image
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
imageUri: string;
|
||||
}
|
||||
|
||||
@ -631,6 +905,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Describe the unified video data
|
||||
*
|
||||
* @extends File
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
class Video extends File {
|
||||
/**
|
||||
* Indicates the uri of video
|
||||
@ -646,6 +929,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Indicates the uri of video
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
videoUri: string;
|
||||
}
|
||||
|
||||
@ -664,6 +956,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Describe the unified audio data
|
||||
*
|
||||
* @extends File
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
class Audio extends File {
|
||||
/**
|
||||
* Indicates the uri of audio
|
||||
@ -679,6 +980,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Indicates the uri of audio
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
audioUri: string;
|
||||
}
|
||||
|
||||
@ -697,6 +1007,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Describe the unified folder data
|
||||
*
|
||||
* @extends File
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
class Folder extends File {
|
||||
/**
|
||||
* Indicates the uri of folder
|
||||
@ -712,6 +1031,15 @@ declare namespace unifiedDataChannel {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Indicates the uri of folder
|
||||
*
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
folderUri: string;
|
||||
}
|
||||
|
||||
|
104
api/@ohos.data.uniformTypeDescriptor.d.ts
vendored
104
api/@ohos.data.uniformTypeDescriptor.d.ts
vendored
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2023 Huawei Device Co., Ltd.
|
||||
* Copyright (c) 2023-2024 Huawei Device Co., Ltd.
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
@ -33,6 +33,15 @@
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Provides methods for uniform data type definition and query.
|
||||
*
|
||||
* @namespace uniformTypeDescriptor
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
declare namespace uniformTypeDescriptor {
|
||||
/**
|
||||
* Uniform data type IDs.
|
||||
@ -49,6 +58,15 @@ declare namespace uniformTypeDescriptor {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Uniform data type IDs.
|
||||
*
|
||||
* @enum { string }
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
enum UniformDataType {
|
||||
/**
|
||||
* Base data type for physical hierarchy, which identifies the physical representation of the data type.
|
||||
@ -87,6 +105,14 @@ declare namespace uniformTypeDescriptor {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Text data type.
|
||||
*
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
TEXT = 'general.text',
|
||||
|
||||
/**
|
||||
@ -102,6 +128,14 @@ declare namespace uniformTypeDescriptor {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Plain text data type.
|
||||
*
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
PLAIN_TEXT = 'general.plain-text',
|
||||
|
||||
/**
|
||||
@ -117,6 +151,14 @@ declare namespace uniformTypeDescriptor {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* HTML data type.
|
||||
*
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
HTML = 'general.html',
|
||||
|
||||
/**
|
||||
@ -132,6 +174,14 @@ declare namespace uniformTypeDescriptor {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Hyperlink data type.
|
||||
*
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
HYPERLINK = 'general.hyperlink',
|
||||
|
||||
/**
|
||||
@ -419,6 +469,14 @@ declare namespace uniformTypeDescriptor {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Image data type.
|
||||
*
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
IMAGE = 'general.image',
|
||||
|
||||
/**
|
||||
@ -658,6 +716,14 @@ declare namespace uniformTypeDescriptor {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Video data type.
|
||||
*
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
VIDEO = 'general.video',
|
||||
|
||||
/**
|
||||
@ -793,6 +859,14 @@ declare namespace uniformTypeDescriptor {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Audio data type.
|
||||
*
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
AUDIO = 'general.audio',
|
||||
|
||||
/**
|
||||
@ -968,6 +1042,14 @@ declare namespace uniformTypeDescriptor {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* File data type.
|
||||
*
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
FILE = 'general.file',
|
||||
|
||||
/**
|
||||
@ -991,6 +1073,14 @@ declare namespace uniformTypeDescriptor {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* Folder data type.
|
||||
*
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
FOLDER = 'general.folder',
|
||||
|
||||
/**
|
||||
@ -1452,6 +1542,14 @@ declare namespace uniformTypeDescriptor {
|
||||
* @atomicservice
|
||||
* @since 11
|
||||
*/
|
||||
/**
|
||||
* OpenHarmony system defined pixel map data type(the data is provided and bound to OpenHarmony system).
|
||||
*
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
OPENHARMONY_PIXEL_MAP = 'openharmony.pixel-map',
|
||||
|
||||
/**
|
||||
@ -1714,7 +1812,7 @@ declare namespace uniformTypeDescriptor {
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:1.Mandatory parameters are left unspecified;
|
||||
* <br>2.Incorrect Parameters types.
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
function getUniformDataTypesByFilenameExtension(filenameExtension: string, belongsTo?: string): Array<string>;
|
||||
|
||||
@ -1728,7 +1826,7 @@ declare namespace uniformTypeDescriptor {
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:1.Mandatory parameters are left unspecified;
|
||||
* <br>2.Incorrect Parameters types.
|
||||
* @syscap SystemCapability.DistributedDataManager.UDMF.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
function getUniformDataTypesByMIMEType(mimeType: string, belongsTo?: string): Array<string>;
|
||||
}
|
||||
|
10
api/@ohos.deviceInfo.d.ts
vendored
10
api/@ohos.deviceInfo.d.ts
vendored
@ -617,6 +617,16 @@ declare namespace deviceInfo {
|
||||
*/
|
||||
const distributionOSApiVersion: number;
|
||||
|
||||
/**
|
||||
* Obtains the Distribution OS api name.
|
||||
* <p>Independent Software Vendor (ISV) may distribute OHOS with their own OS api name.
|
||||
* distributionOSApiName will return the ISV OS api name
|
||||
*
|
||||
* @syscap SystemCapability.Startup.SystemInfo
|
||||
* @since 13
|
||||
*/
|
||||
const distributionOSApiName: string;
|
||||
|
||||
/**
|
||||
* Obtains the Distribution OS release type.
|
||||
* <p>Independent Software Vendor (ISV) may distribute OHOS with their own OS release type.
|
||||
|
8
api/@ohos.distributedDeviceManager.d.ts
vendored
8
api/@ohos.distributedDeviceManager.d.ts
vendored
@ -38,7 +38,9 @@ declare namespace distributedDeviceManager {
|
||||
*/
|
||||
interface DeviceBasicInfo {
|
||||
/**
|
||||
* Device unique identifier, The actual value is the udid-hash confused with the appid based on sha256.
|
||||
* Device identifier. The actual value is udid-hash confused with appid and salt value based on sha256.
|
||||
* This id remains unchanged after application installation. If the application is uninstalled and reinstalled,
|
||||
* the obtained ID will change.
|
||||
* @type { string }
|
||||
* @syscap SystemCapability.DistributedHardware.DeviceManager
|
||||
* @since 10
|
||||
@ -224,7 +226,9 @@ declare namespace distributedDeviceManager {
|
||||
* Get the device id of the local device.
|
||||
*
|
||||
* @permission ohos.permission.DISTRIBUTED_DATASYNC
|
||||
* @returns { string } - Returns local device id.
|
||||
* @returns { string } - Device identifier. The actual value is udid-hash confused with appid and salt value based on sha256.
|
||||
* This id remains unchanged after application installation. If the application is uninstalled and reinstalled,
|
||||
* the obtained ID will change.
|
||||
* @throws { BusinessError } 201 - Permission verification failed. The application does not have the permission required to call the API.
|
||||
* @throws { BusinessError } 11600101 - Failed to execute the function.
|
||||
* @syscap SystemCapability.DistributedHardware.DeviceManager
|
||||
|
250
api/@ohos.effectKit.d.ts
vendored
250
api/@ohos.effectKit.d.ts
vendored
@ -31,7 +31,13 @@ import image from './@ohos.multimedia.image';
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
|
||||
/**
|
||||
* @namespace effectKit
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
|
||||
declare namespace effectKit {
|
||||
|
||||
@ -49,6 +55,15 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* The Filter of FilterChain.
|
||||
* @typedef Filter
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
interface Filter {
|
||||
|
||||
/**
|
||||
@ -67,6 +82,16 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* A blur effect is added to the image.
|
||||
* @param { number } radius - The degree of blur, the value is measured in pixels.
|
||||
* @returns { Filter } Filters for the current effect have been added.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
blur(radius: number): Filter;
|
||||
|
||||
/**
|
||||
@ -85,6 +110,16 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* A Brightness effect is added to the image.
|
||||
* @param { number } bright - The degree of light and darkness,the value range is 0 to 1.
|
||||
* @returns { Filter } Filters for the current effect have been added.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
brightness(bright: number): Filter;
|
||||
|
||||
/**
|
||||
@ -101,6 +136,15 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* A Grayscale effect is added to the image.
|
||||
* @returns { Filter } Filters for the current effect have been added.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
grayscale(): Filter;
|
||||
|
||||
/**
|
||||
@ -109,6 +153,13 @@ declare namespace effectKit {
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* A invert effect is added to the image.
|
||||
* @returns { Filter } Filters for the current effect have been added.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @since 14
|
||||
*/
|
||||
invert(): Filter;
|
||||
|
||||
/**
|
||||
@ -120,6 +171,16 @@ declare namespace effectKit {
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* A custom effect is added to the image.
|
||||
*
|
||||
* @param { Array<number> } colorMatrix - A matrix of 5x4 size for create effect filter.
|
||||
* @returns { Filter } Filters for the current effect have been added.
|
||||
* @throws { BusinessError } 401 - Input parameter error.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @since 14
|
||||
*/
|
||||
setColorMatrix(colorMatrix: Array<number>): Filter;
|
||||
|
||||
/**
|
||||
@ -146,6 +207,15 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Gets the PixelMap where all filter effects have been added to the image.
|
||||
* @returns { Promise<image.PixelMap> } - returns the PixelMap generated.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
getEffectPixelMap(): Promise<image.PixelMap>;
|
||||
}
|
||||
|
||||
@ -163,6 +233,15 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* The color picker of an image.
|
||||
* @typedef ColorPicker
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
interface ColorPicker {
|
||||
|
||||
/**
|
||||
@ -179,6 +258,15 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* get main color of an image
|
||||
* @returns { Promise<Color> } returns the MainColor generated.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
getMainColor(): Promise<Color>;
|
||||
|
||||
/**
|
||||
@ -195,6 +283,15 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* get main color of an image
|
||||
* @returns { Color } Main color picked in the image.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
getMainColorSync(): Color;
|
||||
|
||||
/**
|
||||
@ -211,6 +308,15 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Get largest proportion color of an image
|
||||
* @returns { Color } Largest proportion color picked in the image.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
getLargestProportionColor(): Color;
|
||||
|
||||
/**
|
||||
@ -223,6 +329,17 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Get top proportion color of an image
|
||||
* @param { number } colorCount - The number of colors to require, the value is 1 to 10.
|
||||
* @returns { Array<Color | null> } An array of feature colors sorted by proportion, with a size equal to
|
||||
* the minimum of colorCount and the actual number of extracted feature colors.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
getTopProportionColors(colorCount: number): Array<Color | null>;
|
||||
|
||||
/**
|
||||
@ -239,6 +356,15 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Get highest saturation color of an image
|
||||
* @returns { Color } Highest saturation color picked in the image.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
getHighestSaturationColor(): Color;
|
||||
|
||||
/**
|
||||
@ -255,6 +381,15 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Get average color of an image
|
||||
* @returns { Color } Average color calculated in the image.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
getAverageColor(): Color;
|
||||
|
||||
/**
|
||||
@ -273,6 +408,16 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Determine whether the color is black or white or gray
|
||||
* @param { number } color - The 32 bit ARGB color to discriminate.
|
||||
* @returns { boolean } Result of judging black, white and gray.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
isBlackOrWhiteOrGrayColor(color: number): boolean;
|
||||
}
|
||||
|
||||
@ -290,6 +435,15 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* The color param.
|
||||
* @typedef Color
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
interface Color {
|
||||
|
||||
/**
|
||||
@ -306,6 +460,15 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Red
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
red: number;
|
||||
|
||||
/**
|
||||
@ -322,6 +485,15 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Green
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
green: number;
|
||||
|
||||
/**
|
||||
@ -338,6 +510,15 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Blue
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
blue: number;
|
||||
|
||||
/**
|
||||
@ -354,6 +535,15 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Alpha
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
alpha: number;
|
||||
}
|
||||
|
||||
@ -373,6 +563,16 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Create a FilterChain to add multiple effects to an image.
|
||||
* @param { image.PixelMap } source - the source pixelmap.
|
||||
* @returns { Filter } Returns the head node of FilterChain.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
function createEffect(source: image.PixelMap): Filter;
|
||||
|
||||
/**
|
||||
@ -393,6 +593,17 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Create a color picker to get color of an image.
|
||||
* @param { image.PixelMap } source - the source pixelmap.
|
||||
* @returns { Promise<ColorPicker> } - returns the ColorPicker generated.
|
||||
* @throws { BusinessError } 401 - Input parameter error.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
function createColorPicker(source: image.PixelMap): Promise<ColorPicker>;
|
||||
|
||||
/**
|
||||
@ -417,6 +628,19 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Create a color picker to get color of an image.
|
||||
* @param { image.PixelMap } source - the source pixelmap.
|
||||
* @param { Array<number> } region - contains 4 elements, represents the region's left, top, right, bottom coordinates,
|
||||
* default is [0, 0, 1, 1], represents the region of color picker is the whole pixelMap.
|
||||
* @returns { Promise<ColorPicker> } - returns the ColorPicker generated.
|
||||
* @throws { BusinessError } 401 - Input parameter error.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
function createColorPicker(source: image.PixelMap, region: Array<number>): Promise<ColorPicker>;
|
||||
|
||||
/**
|
||||
@ -437,6 +661,17 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Create a color picker to get color of an image.
|
||||
* @param { image.PixelMap } source - the source pixelmap.
|
||||
* @param { AsyncCallback<ColorPicker> } callback - the callback of createColorPicker.
|
||||
* @throws { BusinessError } 401 - Input parameter error.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
function createColorPicker(source: image.PixelMap, callback: AsyncCallback<ColorPicker>): void;
|
||||
|
||||
/**
|
||||
@ -461,6 +696,19 @@ declare namespace effectKit {
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
*/
|
||||
/**
|
||||
* Create a color picker to get color of an image.
|
||||
* @param { image.PixelMap } source - the source pixelmap.
|
||||
* @param { Array<number> } region - contains 4 elements, represents the region's left, top, right, bottom coordinates,
|
||||
* default is [0, 0, 1, 1], represents the region of color picker is the whole pixelMap.
|
||||
* @param { AsyncCallback<ColorPicker> } callback - the callback of createColorPicker.
|
||||
* @throws { BusinessError } 401 - Input parameter error.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @crossplatform
|
||||
* @form
|
||||
* @atomicservice
|
||||
* @since 14
|
||||
*/
|
||||
function createColorPicker(source: image.PixelMap, region: Array<number>, callback: AsyncCallback<ColorPicker>): void;
|
||||
}
|
||||
|
||||
|
61
api/@ohos.enterprise.restrictions.d.ts
vendored
61
api/@ohos.enterprise.restrictions.d.ts
vendored
@ -336,7 +336,7 @@ declare namespace restrictions {
|
||||
* 2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @syscap SystemCapability.Customization.EnterpriseDeviceManager
|
||||
* @stagemodelonly
|
||||
* @since 13
|
||||
* @since 14
|
||||
*/
|
||||
function setDisallowedPolicyForAccount(admin: Want, feature: string, disallow: boolean, accountId: number): void;
|
||||
|
||||
@ -355,9 +355,66 @@ declare namespace restrictions {
|
||||
* 2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @syscap SystemCapability.Customization.EnterpriseDeviceManager
|
||||
* @stagemodelonly
|
||||
* @since 13
|
||||
* @since 14
|
||||
*/
|
||||
function getDisallowedPolicyForAccount(admin: Want, feature: string, accountId: number): boolean;
|
||||
|
||||
/**
|
||||
* Adds applications or bundles or other contents to the list to restrict them from using a specific feature.
|
||||
*
|
||||
* @permission ohos.permission.ENTERPRISE_MANAGE_RESTRICTIONS
|
||||
* @param { Want } admin - admin indicates the administrator ability information.
|
||||
* @param { string } feature - feature indicates the specific feature to be disallowed.
|
||||
* @param { Array<string> } list - list of restricted applications or bundles or other contents.
|
||||
* @param { number } accountId - indicates the account ID.
|
||||
* @throws { BusinessError } 9200001 - The application is not an administrator application of the device.
|
||||
* @throws { BusinessError } 9200002 - The administrator application does not have permission to manage the device.
|
||||
* @throws { BusinessError } 201 - Permission verification failed. The application does not have the permission required to call the API.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @syscap SystemCapability.Customization.EnterpriseDeviceManager
|
||||
* @stagemodelonly
|
||||
* @since 14
|
||||
*/
|
||||
function addDisallowedListForAccount(admin: Want, feature: string, list: Array<string>, accountId: number): void;
|
||||
|
||||
/**
|
||||
* Removes applications or bundles or other contents from the list to unblock them from using a specific feature.
|
||||
*
|
||||
* @permission ohos.permission.ENTERPRISE_MANAGE_RESTRICTIONS
|
||||
* @param { Want } admin - admin indicates the administrator ability information.
|
||||
* @param { string } feature - feature indicates the specific feature to be disallowed.
|
||||
* @param { Array<string> } list - list of unblock applications or bundles or other contents.
|
||||
* @param { number } accountId - indicates the account ID.
|
||||
* @throws { BusinessError } 9200001 - The application is not an administrator application of the device.
|
||||
* @throws { BusinessError } 9200002 - The administrator application does not have permission to manage the device.
|
||||
* @throws { BusinessError } 201 - Permission verification failed. The application does not have the permission required to call the API.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @syscap SystemCapability.Customization.EnterpriseDeviceManager
|
||||
* @stagemodelonly
|
||||
* @since 14
|
||||
*/
|
||||
function removeDisallowedListForAccount(admin: Want, feature: string, list: Array<string>, accountId: number): void;
|
||||
|
||||
/**
|
||||
* Gets the list of applications or bundles or other contents that are restrict from using a specific feature.
|
||||
*
|
||||
* @permission ohos.permission.ENTERPRISE_MANAGE_RESTRICTIONS
|
||||
* @param { Want } admin - admin indicates the administrator ability information.
|
||||
* @param { string } feature - feature indicates the specific feature to be disallowed.
|
||||
* @param { number } accountId - indicates the account ID.
|
||||
* @returns { Array<string> } list - list of applications or bundles or other contents.
|
||||
* @throws { BusinessError } 9200001 - The application is not an administrator application of the device.
|
||||
* @throws { BusinessError } 9200002 - The administrator application does not have permission to manage the device.
|
||||
* @throws { BusinessError } 201 - Permission verification failed. The application does not have the permission required to call the API.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @syscap SystemCapability.Customization.EnterpriseDeviceManager
|
||||
* @stagemodelonly
|
||||
* @since 14
|
||||
*/
|
||||
function getDisallowedListForAccount(admin: Want, feature: string, accountId: number): Array<string>;
|
||||
}
|
||||
|
||||
export default restrictions;
|
||||
|
38
api/@ohos.enterprise.securityManager.d.ts
vendored
38
api/@ohos.enterprise.securityManager.d.ts
vendored
@ -19,6 +19,7 @@
|
||||
*/
|
||||
|
||||
import type Want from './@ohos.app.ability.Want';
|
||||
import type image from './@ohos.multimedia.image';
|
||||
|
||||
/**
|
||||
* This module provides the capability to manage the security of the enterprise devices.
|
||||
@ -270,6 +271,43 @@ declare namespace securityManager {
|
||||
*/
|
||||
function getAppClipboardPolicy(admin: Want, tokenId?: number): string;
|
||||
|
||||
/**
|
||||
* Sets the watermark image displayed during the application running.
|
||||
*
|
||||
* @permission ohos.permission.ENTERPRISE_MANAGE_SECURITY
|
||||
* @param { Want } admin - admin indicates the administrator ability information.
|
||||
* @param { string } bundleName - the bundle name of the application to be set watermark.
|
||||
* @param { string | image.PixelMap } source - watermark's pixelMap or its url.
|
||||
* @param { number } accountId - indicates the accountID.
|
||||
* @throws { BusinessError } 9200001 - The application is not an administrator application of the device.
|
||||
* @throws { BusinessError } 9200002 - The administrator application does not have permission to manage the device.
|
||||
* @throws { BusinessError } 201 - Permission verification failed. The application does not have the permission required to call the API.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @syscap SystemCapability.Customization.EnterpriseDeviceManager
|
||||
* @stagemodelonly
|
||||
* @since 14
|
||||
*/
|
||||
function setWatermarkImage(admin: Want, bundleName: string, source: string | image.PixelMap, accountId: number): void;
|
||||
|
||||
/**
|
||||
* Cancels the watermark image displayed during the application running.
|
||||
*
|
||||
* @permission ohos.permission.ENTERPRISE_MANAGE_SECURITY
|
||||
* @param { Want } admin - admin indicates the administrator ability information.
|
||||
* @param { string } bundleName - the bundle name of the application to be set watermark.
|
||||
* @param { number } accountId - indicates the accountID.
|
||||
* @throws { BusinessError } 9200001 - The application is not an administrator application of the device.
|
||||
* @throws { BusinessError } 9200002 - The administrator application does not have permission to manage the device.
|
||||
* @throws { BusinessError } 201 - Permission verification failed. The application does not have the permission required to call the API.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* 2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @syscap SystemCapability.Customization.EnterpriseDeviceManager
|
||||
* @stagemodelonly
|
||||
* @since 14
|
||||
*/
|
||||
function cancelWatermarkImage(admin: Want, bundleName: string, accountId: number): void;
|
||||
|
||||
/**
|
||||
* Password policy.
|
||||
*
|
||||
|
22
api/@ohos.enterprise.usbManager.d.ts
vendored
22
api/@ohos.enterprise.usbManager.d.ts
vendored
@ -102,7 +102,7 @@ declare namespace usbManager {
|
||||
* @enum { number }
|
||||
* @syscap SystemCapability.Customization.EnterpriseDeviceManager
|
||||
* @stagemodelonly
|
||||
* @since 13
|
||||
* @since 14
|
||||
*/
|
||||
enum Descriptor {
|
||||
/**
|
||||
@ -110,7 +110,7 @@ declare namespace usbManager {
|
||||
*
|
||||
* @syscap SystemCapability.Customization.EnterpriseDeviceManager
|
||||
* @stagemodelonly
|
||||
* @since 13
|
||||
* @since 14
|
||||
*/
|
||||
INTERFACE = 0,
|
||||
|
||||
@ -119,7 +119,7 @@ declare namespace usbManager {
|
||||
*
|
||||
* @syscap SystemCapability.Customization.EnterpriseDeviceManager
|
||||
* @stagemodelonly
|
||||
* @since 13
|
||||
* @since 14
|
||||
*/
|
||||
DEVICE = 1
|
||||
}
|
||||
@ -130,7 +130,7 @@ declare namespace usbManager {
|
||||
* @typedef UsbDeviceType
|
||||
* @syscap SystemCapability.Customization.EnterpriseDeviceManager
|
||||
* @stagemodelonly
|
||||
* @since 13
|
||||
* @since 14
|
||||
*/
|
||||
export interface UsbDeviceType {
|
||||
/**
|
||||
@ -139,7 +139,7 @@ declare namespace usbManager {
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.Customization.EnterpriseDeviceManager
|
||||
* @stagemodelonly
|
||||
* @since 13
|
||||
* @since 14
|
||||
*/
|
||||
baseClass: number;
|
||||
|
||||
@ -149,7 +149,7 @@ declare namespace usbManager {
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.Customization.EnterpriseDeviceManager
|
||||
* @stagemodelonly
|
||||
* @since 13
|
||||
* @since 14
|
||||
*/
|
||||
subClass: number;
|
||||
|
||||
@ -159,7 +159,7 @@ declare namespace usbManager {
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.Customization.EnterpriseDeviceManager
|
||||
* @stagemodelonly
|
||||
* @since 13
|
||||
* @since 14
|
||||
*/
|
||||
protocol: number;
|
||||
|
||||
@ -169,7 +169,7 @@ declare namespace usbManager {
|
||||
* @type { Descriptor }
|
||||
* @syscap SystemCapability.Customization.EnterpriseDeviceManager
|
||||
* @stagemodelonly
|
||||
* @since 13
|
||||
* @since 14
|
||||
*/
|
||||
descriptor: Descriptor;
|
||||
}
|
||||
@ -377,7 +377,7 @@ declare namespace usbManager {
|
||||
* 2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @syscap SystemCapability.Customization.EnterpriseDeviceManager
|
||||
* @stagemodelonly
|
||||
* @since 13
|
||||
* @since 14
|
||||
*/
|
||||
function addDisallowedUsbDevices(admin: Want, usbDevices: Array<UsbDeviceType>): void;
|
||||
|
||||
@ -397,7 +397,7 @@ declare namespace usbManager {
|
||||
* 2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @syscap SystemCapability.Customization.EnterpriseDeviceManager
|
||||
* @stagemodelonly
|
||||
* @since 13
|
||||
* @since 14
|
||||
*/
|
||||
function removeDisallowedUsbDevices(admin: Want, usbDevices: Array<UsbDeviceType>): void;
|
||||
|
||||
@ -416,7 +416,7 @@ declare namespace usbManager {
|
||||
* 2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @syscap SystemCapability.Customization.EnterpriseDeviceManager
|
||||
* @stagemodelonly
|
||||
* @since 13
|
||||
* @since 14
|
||||
*/
|
||||
function getDisallowedUsbDevices(admin: Want): Array<UsbDeviceType>;
|
||||
}
|
||||
|
@ -19,6 +19,7 @@
|
||||
*/
|
||||
|
||||
import { PickerColorMode } from '@ohos.file.PhotoPickerComponent';
|
||||
import photoAccessHelper from '@ohos.file.photoAccessHelper';
|
||||
|
||||
/**
|
||||
* AlbumPickerComponent: can select a certain album and display the images in that album through PhotoPickerComponent
|
||||
@ -48,8 +49,28 @@ export declare struct AlbumPickerComponent {
|
||||
* @since 12
|
||||
*/
|
||||
onAlbumClick?: (albumInfo: AlbumInfo) => boolean;
|
||||
|
||||
/**
|
||||
* Callback when click the empty area of the album component
|
||||
*
|
||||
* @type { ?function }
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onEmptyAreaClick?: EmptyAreaClickCallback;
|
||||
}
|
||||
|
||||
/**
|
||||
* The callback of onEmptyAreaClick event
|
||||
*
|
||||
* @typedef { function } EmptyAreaClickCallback
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
export type EmptyAreaClickCallback = () => void
|
||||
|
||||
/**
|
||||
* AlbumPickerOptions Object
|
||||
*
|
||||
@ -67,6 +88,16 @@ export declare class AlbumPickerOptions {
|
||||
* @since 12
|
||||
*/
|
||||
themeColorMode?: PickerColorMode;
|
||||
|
||||
/**
|
||||
* The type of the content displayed in the album
|
||||
*
|
||||
* @type { ?photoAccessHelper.PhotoViewMIMETypes }
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
filterType?: photoAccessHelper.PhotoViewMIMETypes;
|
||||
}
|
||||
|
||||
|
||||
|
@ -110,6 +110,36 @@ export declare struct PhotoPickerComponent {
|
||||
*/
|
||||
onPhotoBrowserChanged?: (browserItemInfo: BaseItemInfo) => boolean;
|
||||
|
||||
/**
|
||||
* Callback when selected items are deleted
|
||||
*
|
||||
* @type { ?function }
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onSelectedItemsDeleted?: ItemsDeletedCallback;
|
||||
|
||||
/**
|
||||
* Callback when exceed max selected
|
||||
*
|
||||
* @type { ?function }
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onExceedMaxSelected?: ExceedMaxSelectedCallback;
|
||||
|
||||
/**
|
||||
* Callback when the current album is deleted
|
||||
*
|
||||
* @type { ?function }
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onCurrentAlbumDeleted?: CurrentAlbumDeletedCallback
|
||||
|
||||
/**
|
||||
* PickerController
|
||||
*
|
||||
@ -131,6 +161,39 @@ export declare struct PhotoPickerComponent {
|
||||
build(): void;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* The callback of onSelectedItemsDeleted event
|
||||
*
|
||||
* @typedef { function } ItemsDeletedCallback
|
||||
* @param { Array<BaseItemInfo> }
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
export type ItemsDeletedCallback = (baseItemInfos: Array<BaseItemInfo>) => void;
|
||||
|
||||
/**
|
||||
* The callback of onExceedMaxSelected event
|
||||
*
|
||||
* @typedef { function } ItemsDeletedCallback
|
||||
* @param { MaxCountType }
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
export type ExceedMaxSelectedCallback = (exceedMaxCountType: MaxCountType) => void;
|
||||
|
||||
/**
|
||||
* The callback of onCurrentAlbumDeleted event
|
||||
*
|
||||
* @typedef { function } CurrentAlbumDeletedCallback
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
export type CurrentAlbumDeletedCallback = () => void;
|
||||
|
||||
/**
|
||||
* The class for PickerController
|
||||
*
|
||||
@ -171,6 +234,26 @@ export declare class PickerController {
|
||||
* @since 12
|
||||
*/
|
||||
setPhotoBrowserItem(uri: string, photoBrowserRange?: PhotoBrowserRange): void;
|
||||
|
||||
/**
|
||||
* Exit photo browser.
|
||||
*
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
exitPhotoBrowser(): void;
|
||||
|
||||
/**
|
||||
* Sets whether other elements on the photo browser page are visible.
|
||||
*
|
||||
* @param { Array<PhotoBrowserUIElement> } elements - other elements on the photo browser page
|
||||
* @param { boolean } isVisible - visible or not
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
setPhotoBrowserUIElementVisibility(elements: Array<PhotoBrowserUIElement>, isVisible: boolean): void;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -280,6 +363,26 @@ export declare class PickerOptions extends photoAccessHelper.BaseSelectOptions {
|
||||
* @since 12
|
||||
*/
|
||||
maxVideoSelectNumber?: number;
|
||||
|
||||
/**
|
||||
* Support to set sliding selection
|
||||
*
|
||||
* @type { ?boolean }
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
isSlidingSelectionSupported?: boolean;
|
||||
|
||||
/**
|
||||
* Support to set photo browser checkbox position
|
||||
*
|
||||
* @type { ?[number, number] }
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
photoBrowserCheckboxPosition?: [number, number];
|
||||
}
|
||||
|
||||
/**
|
||||
@ -716,3 +819,31 @@ export declare enum PhotoBrowserRange {
|
||||
*/
|
||||
SELECTED_ONLY = 1,
|
||||
}
|
||||
|
||||
/**
|
||||
* PhotoBrowserUIElement. include CHECKBOX and BACK_BUTTON
|
||||
*
|
||||
* @enum { number } PhotoBrowserUIElement
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
export declare enum PhotoBrowserUIElement {
|
||||
/**
|
||||
* CHECKBOX. checkbox
|
||||
*
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
CHECKBOX = 0,
|
||||
|
||||
/**
|
||||
* BACK_BUTTON. back button
|
||||
*
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
BACK_BUTTON = 1
|
||||
}
|
@ -59,6 +59,16 @@ export declare struct RecentPhotoComponent {
|
||||
* @since 12
|
||||
*/
|
||||
onRecentPhotoClick: RecentPhotoClickCallback;
|
||||
|
||||
/**
|
||||
* Callback when check whether photos or videos exists and return the recent photo info
|
||||
*
|
||||
* @type { ?function }
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
onRecentPhotoCheckInfo?: RecentPhotoCheckInfoCallback;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -83,6 +93,18 @@ export type RecentPhotoCheckResultCallback = (recentPhotoExists: boolean) => voi
|
||||
*/
|
||||
export type RecentPhotoClickCallback = (recentPhotoInfo: BaseItemInfo) => boolean;
|
||||
|
||||
/**
|
||||
* The callback of onRecentPhotoCheckInfo event
|
||||
*
|
||||
* @typedef { function } RecentPhotoCheckInfoCallback
|
||||
* @param { boolean } recentPhotoExists - Does the recent photo exist?
|
||||
* @param { RecentPhotoInfo } info - the recent photo info
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
export type RecentPhotoCheckInfoCallback = (recentPhotoExists: boolean, info: RecentPhotoInfo) => void;
|
||||
|
||||
/**
|
||||
* RecentPhotoOptions Object
|
||||
*
|
||||
@ -122,6 +144,35 @@ export declare class RecentPhotoOptions {
|
||||
photoSource?: PhotoSource;
|
||||
}
|
||||
|
||||
/**
|
||||
* Recent photo info
|
||||
*
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
export declare class RecentPhotoInfo {
|
||||
/**
|
||||
* The dateTaken of photos or videos
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
dateTaken?: number;
|
||||
|
||||
/**
|
||||
* The identifier of photos or videos
|
||||
*
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
identifier?: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* Enumeration of PhotoSource type
|
||||
*
|
||||
|
30
api/@ohos.file.cloudSync.d.ts
vendored
30
api/@ohos.file.cloudSync.d.ts
vendored
@ -246,7 +246,7 @@ declare namespace cloudSync {
|
||||
* @throws { BusinessError } 401 - The input parameter is invalid.Possible causes:Incorrect parameter types.
|
||||
* @throws { BusinessError } 22400001 - Cloud status not ready.
|
||||
* @throws { BusinessError } 22400002 - Network unavailable.
|
||||
* @throws { BusinessError } 22400003 - Battery level warning.
|
||||
* @throws { BusinessError } 22400003 - Low battery level.
|
||||
* @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core
|
||||
* @systemapi
|
||||
* @since 10
|
||||
@ -263,7 +263,7 @@ declare namespace cloudSync {
|
||||
* <br>2.Incorrect parameter types.
|
||||
* @throws { BusinessError } 22400001 - Cloud status not ready.
|
||||
* @throws { BusinessError } 22400002 - Network unavailable.
|
||||
* @throws { BusinessError } 22400003 - Battery level warning.
|
||||
* @throws { BusinessError } 22400003 - Low battery level.
|
||||
* @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core
|
||||
* @systemapi
|
||||
* @since 10
|
||||
@ -625,7 +625,7 @@ declare namespace cloudSync {
|
||||
* @throws { BusinessError } 13600001 - IPC error.
|
||||
* @throws { BusinessError } 22400001 - Cloud status not ready.
|
||||
* @throws { BusinessError } 22400002 - Network unavailable.
|
||||
* @throws { BusinessError } 22400003 - Battery level warning.
|
||||
* @throws { BusinessError } 22400003 - Low battery level.
|
||||
* @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core
|
||||
* @since 12
|
||||
*/
|
||||
@ -638,7 +638,7 @@ declare namespace cloudSync {
|
||||
* @throws { BusinessError } 13600001 - IPC error.
|
||||
* @throws { BusinessError } 22400001 - Cloud status not ready.
|
||||
* @throws { BusinessError } 22400002 - Network unavailable.
|
||||
* @throws { BusinessError } 22400003 - Battery level warning.
|
||||
* @throws { BusinessError } 22400003 - Low battery level.
|
||||
* @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core
|
||||
* @since 12
|
||||
*/
|
||||
@ -736,7 +736,7 @@ declare namespace cloudSync {
|
||||
* @throws { BusinessError } 13600001 - IPC error.
|
||||
* @throws { BusinessError } 13900002 - No such file or directory.
|
||||
* @throws { BusinessError } 13900025 - No space left on device.
|
||||
* @throws { BusinessError } 14000002 - Invalid uri.
|
||||
* @throws { BusinessError } 14000002 - Invalid URI.
|
||||
* @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core
|
||||
* @since 11
|
||||
*/
|
||||
@ -751,7 +751,7 @@ declare namespace cloudSync {
|
||||
* @throws { BusinessError } 13600001 - IPC error.
|
||||
* @throws { BusinessError } 13900002 - No such file or directory.
|
||||
* @throws { BusinessError } 13900025 - No space left on device.
|
||||
* @throws { BusinessError } 14000002 - Invalid uri.
|
||||
* @throws { BusinessError } 14000002 - Invalid URI.
|
||||
* @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core
|
||||
* @since 11
|
||||
*/
|
||||
@ -765,7 +765,7 @@ declare namespace cloudSync {
|
||||
* <br>2.Incorrect parameter types.
|
||||
* @throws { BusinessError } 13600001 - IPC error.
|
||||
* @throws { BusinessError } 13900002 - No such file or directory.
|
||||
* @throws { BusinessError } 14000002 - Invalid uri.
|
||||
* @throws { BusinessError } 14000002 - Invalid URI.
|
||||
* @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core
|
||||
* @since 11
|
||||
*/
|
||||
@ -779,7 +779,7 @@ declare namespace cloudSync {
|
||||
* <br>2.Incorrect parameter types.
|
||||
* @throws { BusinessError } 13600001 - IPC error.
|
||||
* @throws { BusinessError } 13900002 - No such file or directory.
|
||||
* @throws { BusinessError } 14000002 - Invalid uri.
|
||||
* @throws { BusinessError } 14000002 - Invalid URI.
|
||||
* @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core
|
||||
* @since 12
|
||||
*/
|
||||
@ -793,7 +793,7 @@ declare namespace cloudSync {
|
||||
* <br>2.Incorrect parameter types.
|
||||
* @throws { BusinessError } 13600001 - IPC error.
|
||||
* @throws { BusinessError } 13900002 - No such file or directory.
|
||||
* @throws { BusinessError } 14000002 - Invalid uri.
|
||||
* @throws { BusinessError } 14000002 - Invalid URI.
|
||||
* @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core
|
||||
* @since 11
|
||||
*/
|
||||
@ -809,7 +809,7 @@ declare namespace cloudSync {
|
||||
* <br>2.Incorrect parameter types.
|
||||
* @throws { BusinessError } 13600001 - IPC error.
|
||||
* @throws { BusinessError } 13900002 - No such file or directory.
|
||||
* @throws { BusinessError } 14000002 - Invalid uri.
|
||||
* @throws { BusinessError } 14000002 - Invalid URI.
|
||||
* @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core
|
||||
* @systemapi
|
||||
* @since 11
|
||||
@ -896,7 +896,7 @@ declare namespace cloudSync {
|
||||
* <br>2.Incorrect parameter types.
|
||||
* @throws { BusinessError } 13600001 - IPC error.
|
||||
* @throws { BusinessError } 13900002 - No such file or directory.
|
||||
* @throws { BusinessError } 14000002 - Invalid uri.
|
||||
* @throws { BusinessError } 14000002 - Invalid URI.
|
||||
* @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core
|
||||
* @systemapi
|
||||
* @since 11
|
||||
@ -914,7 +914,7 @@ declare namespace cloudSync {
|
||||
* <br>2.Incorrect parameter types.
|
||||
* @throws { BusinessError } 13600001 - IPC error.
|
||||
* @throws { BusinessError } 13900002 - No such file or directory.
|
||||
* @throws { BusinessError } 14000002 - Invalid uri.
|
||||
* @throws { BusinessError } 14000002 - Invalid URI.
|
||||
* @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core
|
||||
* @systemapi
|
||||
* @since 11
|
||||
@ -934,7 +934,7 @@ declare namespace cloudSync {
|
||||
* @throws { BusinessError } 13900012 - Permission denied by the file system
|
||||
* @throws { BusinessError } 13900031 - Function not implemented
|
||||
* @throws { BusinessError } 13900042 - Unknown error
|
||||
* @throws { BusinessError } 14000002 - Invalid uri.
|
||||
* @throws { BusinessError } 14000002 - Invalid URI.
|
||||
* @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core
|
||||
* @systemapi
|
||||
* @since 12
|
||||
@ -951,7 +951,7 @@ declare namespace cloudSync {
|
||||
* @throws { BusinessError } 13900001 - Operation not permitted
|
||||
* @throws { BusinessError } 13900002 - No such file or directory.
|
||||
* @throws { BusinessError } 13900012 - Permission denied
|
||||
* @throws { BusinessError } 14000002 - Invalid uri.
|
||||
* @throws { BusinessError } 14000002 - Invalid URI.
|
||||
* @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core
|
||||
* @since 12
|
||||
*/
|
||||
@ -965,7 +965,7 @@ declare namespace cloudSync {
|
||||
* @throws { BusinessError } 13900001 - Operation not permitted
|
||||
* @throws { BusinessError } 13900002 - No such file or directory.
|
||||
* @throws { BusinessError } 13900012 - Permission denied
|
||||
* @throws { BusinessError } 14000002 - Invalid uri.
|
||||
* @throws { BusinessError } 14000002 - Invalid URI.
|
||||
* @syscap SystemCapability.FileManagement.DistributedFileService.CloudSync.Core
|
||||
* @since 12
|
||||
*/
|
||||
|
6
api/@ohos.file.fs.d.ts
vendored
6
api/@ohos.file.fs.d.ts
vendored
@ -6407,7 +6407,7 @@ declare function connectDfs(networkId: string, listeners: DfsListeners): Promise
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 401 - The parameter check failed.Possible causes:1.Mandatory parameters are left unspecified;
|
||||
* <br>2.Incorrect parameter types.
|
||||
* @throws { BusinessError } 13600004 - Failed to unmount.
|
||||
* @throws { BusinessError } 13600004 - Unmount failed.
|
||||
* @syscap SystemCapability.FileManagement.File.FileIO
|
||||
* @since 12
|
||||
*/
|
||||
@ -6646,7 +6646,7 @@ declare interface File {
|
||||
* @readonly
|
||||
* @throws { BusinessError } 13900005 - I/O error
|
||||
* @throws { BusinessError } 13900042 - Unknown error
|
||||
* @throws { BusinessError } 14300002 - Invalid uri
|
||||
* @throws { BusinessError } 14300002 - Invalid URI
|
||||
* @syscap SystemCapability.FileManagement.File.FileIO
|
||||
* @since 10
|
||||
*/
|
||||
@ -6670,7 +6670,7 @@ declare interface File {
|
||||
* @returns { string } Return the parent path of file.
|
||||
* @throws { BusinessError } 13900005 - I/O error
|
||||
* @throws { BusinessError } 13900042 - Unknown error
|
||||
* @throws { BusinessError } 14300002 - Invalid uri
|
||||
* @throws { BusinessError } 14300002 - Invalid URI
|
||||
* @syscap SystemCapability.FileManagement.File.FileIO
|
||||
* @since 11
|
||||
*/
|
||||
|
654
api/@ohos.file.photoAccessHelper.d.ts
vendored
654
api/@ohos.file.photoAccessHelper.d.ts
vendored
File diff suppressed because it is too large
Load Diff
14
api/@ohos.file.picker.d.ts
vendored
14
api/@ohos.file.picker.d.ts
vendored
@ -20,7 +20,7 @@
|
||||
|
||||
import { AsyncCallback, Callback } from './@ohos.base';
|
||||
import Context from './application/Context';
|
||||
|
||||
import { window } from '@kit.ArkUI';
|
||||
/**
|
||||
* Provide the capabilities to use different pickers.
|
||||
*
|
||||
@ -666,6 +666,16 @@ declare namespace picker {
|
||||
*/
|
||||
constructor(context: Context);
|
||||
|
||||
/**
|
||||
* The constructor used to create a DocumentViewPicker object.
|
||||
*
|
||||
* @param { Context } context - represents the context.
|
||||
* @param { window.Window } window - represents the window.
|
||||
* @syscap SystemCapability.FileManagement.UserFileService
|
||||
* @since 13
|
||||
*/
|
||||
constructor(context: Context, window: window.Window);
|
||||
|
||||
/**
|
||||
* Pull up the document picker based on the selection mode.
|
||||
*
|
||||
@ -789,7 +799,7 @@ declare namespace picker {
|
||||
* @syscap SystemCapability.FileManagement.UserFileService
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
getSelectedIndex(): number;
|
||||
}
|
||||
|
@ -20,8 +20,8 @@
|
||||
|
||||
import type Context from './application/Context';
|
||||
import type image from './@ohos.multimedia.image';
|
||||
import lang from '@arkts.lang';
|
||||
import { photoAccessHelper } from '@kit.MediaLibraryKit';
|
||||
import lang from '../arkts/@arkts.lang';
|
||||
import photoAccessHelper from './@ohos.file.photoAccessHelper';
|
||||
|
||||
/**
|
||||
* Helper functions to access image and video assets
|
||||
|
10
api/@ohos.graphics.drawing.d.ts
vendored
10
api/@ohos.graphics.drawing.d.ts
vendored
@ -1084,7 +1084,7 @@ declare namespace drawing {
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* <br>2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @syscap SystemCapability.Graphics.Drawing
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
drawColor(color: number, blendMode?: BlendMode): void;
|
||||
|
||||
@ -2491,7 +2491,7 @@ declare namespace drawing {
|
||||
* <br>2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @static
|
||||
* @syscap SystemCapability.Graphics.Drawing
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
static create(blurRadius: number, x: number, y: number, color: number): ShadowLayer;
|
||||
}
|
||||
@ -2525,7 +2525,7 @@ declare namespace drawing {
|
||||
* <br>2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @static
|
||||
* @syscap SystemCapability.Graphics.Drawing
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
static createBlendModeColorFilter(color: number, mode: BlendMode): ColorFilter;
|
||||
|
||||
@ -2781,7 +2781,7 @@ declare namespace drawing {
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* <br>2. Incorrect parameter types.
|
||||
* @syscap SystemCapability.Graphics.Drawing
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
setColor(color: number): void;
|
||||
|
||||
@ -3051,7 +3051,7 @@ declare namespace drawing {
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* <br>2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @syscap SystemCapability.Graphics.Drawing
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
setColor(color: number): void;
|
||||
|
||||
|
9
api/@ohos.graphics.text.d.ts
vendored
9
api/@ohos.graphics.text.d.ts
vendored
@ -1217,6 +1217,15 @@ declare namespace text {
|
||||
*/
|
||||
getLongestLine(): number;
|
||||
|
||||
/**
|
||||
* Get the longest line of horizontal space this paragraph occupies, and this horizontal space contains the width
|
||||
* of indent.
|
||||
* @returns { number } The longest line with indent of horizontal space this paragraph occupies.
|
||||
* @syscap SystemCapability.Graphics.Drawing
|
||||
* @since 13
|
||||
*/
|
||||
getLongestLineWithIndent(): number;
|
||||
|
||||
/**
|
||||
* Get the min intrinsic width of horizontal space this paragraph occupies.
|
||||
* @returns { number } The min intrinsic width of horizontal space this paragraph occupies.
|
||||
|
14
api/@ohos.graphics.uiEffect.d.ts
vendored
14
api/@ohos.graphics.uiEffect.d.ts
vendored
@ -64,7 +64,8 @@ declare namespace uiEffect {
|
||||
* @param { number } waveCount - The number of waves when the water ripples. The maximum count of waves is 3, the minimum value is 1, default is 2.
|
||||
* @param { number } x - Represents the X-axis position of center point where the water ripple first appears on the screen.
|
||||
* @param { number } y - Represents the Y-axis position of center point where the water ripple first appears on the screen.
|
||||
* @param { WaterRippleMode } rippleMode - Set the mode of water ripple, 0 for mobile to desktop(Receive), 1 for mobile to desktop(Send), 2 for mobile to mobile.
|
||||
* @param { WaterRippleMode } rippleMode - Set the mode of water ripple,
|
||||
* 0 for mobile to desktop(Receive), 1 for mobile to desktop(Send), 2 for mobile to mobile.
|
||||
* @returns { Filter } - Returns water ripple Filter.
|
||||
* @throws { BusinessError } 202 - Permission verification failed. A non-system application calls a system API.
|
||||
* @syscap SystemCapability.Graphics.Drawing
|
||||
@ -85,7 +86,7 @@ declare namespace uiEffect {
|
||||
* @systemapi
|
||||
* @since 12
|
||||
*/
|
||||
flyInFlyOutEffect(degree: number, flyMode: FlyMode ): Filter;
|
||||
flyInFlyOutEffect(degree: number, flyMode: FlyMode): Filter;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -217,6 +218,15 @@ declare namespace uiEffect {
|
||||
backgroundColorBlender(blender: BrightnessBlender): VisualEffect;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines the blending effect.
|
||||
* @typedef Blender
|
||||
* @syscap SystemCapability.Graphics.Drawing
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
type Blender = BrightnessBlender;
|
||||
|
||||
/**
|
||||
* The Blender of backgroundColorEffect.
|
||||
* @typedef BrightnessBlender
|
||||
|
95
api/@ohos.multimedia.audio.d.ts
vendored
95
api/@ohos.multimedia.audio.d.ts
vendored
@ -3138,6 +3138,51 @@ declare namespace audio {
|
||||
interruptNode: number;
|
||||
}
|
||||
|
||||
/**
|
||||
* Desribes audio device block status. By default, the device is consider as unblocked.
|
||||
* @enum { number }
|
||||
* @syscap SystemCapability.Multimedia.Audio.Device
|
||||
* @since 13
|
||||
*/
|
||||
enum DeviceBlockStatus{
|
||||
/**
|
||||
* Device is unblocked.
|
||||
* @syscap SystemCapability.Multimedia.Audio.Device
|
||||
* @since 13
|
||||
*/
|
||||
UNBLOCKED = 0,
|
||||
/**
|
||||
* Device is blocked.
|
||||
* @syscap SystemCapability.Multimedia.Audio.Device
|
||||
* @since 13
|
||||
*/
|
||||
BLOCKED = 1,
|
||||
}
|
||||
|
||||
/**
|
||||
* Desribes audio device block status info.
|
||||
* @typedef DeviceBlockStatusInfo
|
||||
* @syscap SystemCapability.Multimedia.Audio.Device
|
||||
* @since 13
|
||||
*/
|
||||
interface DeviceBlockStatusInfo {
|
||||
/**
|
||||
* Device block status.
|
||||
* @type {DeviceBlockStatus}
|
||||
* @syscap SystemCapability.Multimedia.Audio.Device
|
||||
* @since 13
|
||||
*/
|
||||
blockStatus: DeviceBlockStatus;
|
||||
|
||||
/**
|
||||
* Audio device descriptors whose block status has changed.
|
||||
* @type {AudioDeviceDescriptors}
|
||||
* @syscap SystemCapability.Multimedia.Audio.Device
|
||||
* @since 13
|
||||
*/
|
||||
devices: AudioDeviceDescriptors;
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements audio router management.
|
||||
* @typedef AudioRoutingManager
|
||||
@ -3772,6 +3817,43 @@ declare namespace audio {
|
||||
* @since 12
|
||||
*/
|
||||
getPreferredInputDeviceForCapturerInfoSync(capturerInfo: AudioCapturerInfo): AudioDeviceDescriptors;
|
||||
|
||||
/**
|
||||
* Query whether microphone block detection is supported on current device.
|
||||
* @returns { Promise<boolean> } Promise used to return the result.
|
||||
* @syscap SystemCapability.Multimedia.Audio.Device
|
||||
* @since 13
|
||||
*/
|
||||
isMicBlockDetectionSupported():Promise<boolean>;
|
||||
|
||||
/**
|
||||
* Subscribes microphone blocked events. Before subscribing, users should query whether block detection is supported
|
||||
* on current device. The caller will receive the callback only when it is recording and the used
|
||||
* microphones' block status have changed. Currently, block detecting is only support for microphones located on
|
||||
* the local device.
|
||||
* @param { 'micBlockStatusChanged' } type - Type of the event to listen for.
|
||||
* @param { Callback<DeviceBlockStatusInfo> } callback - Callback used to obtain the microphone block status.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:
|
||||
* 1.Mandatory parameters are left unspecified;
|
||||
* 2.Incorrect parameter types.
|
||||
* @throws { BusinessError } 6800101 - Parameter verification failed.
|
||||
* @syscap SystemCapability.Multimedia.Audio.Device
|
||||
* @since 13
|
||||
*/
|
||||
on(type: 'micBlockStatusChanged', callback: Callback<DeviceBlockStatusInfo>): void;
|
||||
|
||||
/**
|
||||
* Unsubscribes microphone blocked events.
|
||||
* @param { 'microphoneBlockStatusChanged' } type - Type of the event to listen for.
|
||||
* @param { Callback<DeviceBlockStatusInfo> } callback - Callback used to obtain the microphone block status.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:
|
||||
* 1.Mandatory parameters are left unspecified;
|
||||
* 2.Incorrect parameter types.
|
||||
* @throws { BusinessError } 6800101 - Parameter verification failed.
|
||||
* @syscap SystemCapability.Multimedia.Audio.Device
|
||||
* @since 13
|
||||
*/
|
||||
off(type: 'micBlockStatusChanged', callback?: Callback<DeviceBlockStatusInfo>): void;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -7404,8 +7486,8 @@ declare namespace audio {
|
||||
* Temporarily changes the current audio device
|
||||
* This function applys on audiorenderers whose StreamUsage are
|
||||
* STREAM_USAGE_VOICE_COMMUNICATIN/STREAM_USAGE_VIDEO_COMMUNICATION/STREAM_USAGE_VOICE_MESSAGE.
|
||||
* Setting the device will ony takes effect if no other accessory such as headphoes are in use
|
||||
* @param { DeviceType } devicetype - the available deviceTypes are
|
||||
* Setting the device will only takes effect if no other accessory such as headphones are in use
|
||||
* @param { DeviceType } deviceType - the available deviceTypes are
|
||||
* EARPIECE: Built-in earpiece
|
||||
* SPEAKER: Built-in speaker
|
||||
* DEFAULT: System default output device
|
||||
@ -7418,7 +7500,7 @@ declare namespace audio {
|
||||
* @syscap SystemCapability.Multimedia.Audio.Renderer
|
||||
* @since 12
|
||||
*/
|
||||
setDefaultOutputDevice(deviceType: DeviceType): Promise<void>
|
||||
setDefaultOutputDevice(deviceType: DeviceType): Promise<void>;
|
||||
|
||||
/**
|
||||
* Listens for audio interrupt events. This method uses a callback to get interrupt events. The interrupt event is
|
||||
@ -7780,6 +7862,13 @@ declare namespace audio {
|
||||
* @since 12
|
||||
*/
|
||||
SOURCE_TYPE_VOICE_MESSAGE = 10,
|
||||
|
||||
/**
|
||||
* Camcorder source type.
|
||||
* @syscap SystemCapability.Multimedia.Audio.Core
|
||||
* @since 13
|
||||
*/
|
||||
SOURCE_TYPE_CAMCORDER = 13,
|
||||
}
|
||||
|
||||
/**
|
||||
|
774
api/@ohos.multimedia.avsession.d.ts
vendored
774
api/@ohos.multimedia.avsession.d.ts
vendored
@ -796,6 +796,91 @@ declare namespace avSession {
|
||||
*/
|
||||
function stopCasting(session: SessionToken): Promise<void>;
|
||||
|
||||
/**
|
||||
* Begin to write device logs into a file descriptor for the purpose of problem locating.
|
||||
* If the logs exceed max file size, no logs will be written and DEVICE_LOG_FULL event will be omitted.
|
||||
* @param { string } url - The file descriptor to be written.
|
||||
* @param { number } maxSize - The max size to be written in kilobyte.
|
||||
* if not set, then written process will exit when there is no space to write.
|
||||
* @returns { Promise<void> } Promise for the result
|
||||
* @throws { BusinessError } 202 - Not System App.
|
||||
* @throws { BusinessError } 401 - Parameter check failed. 1. Mandatory parameters are left unspecified.
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 6600101 - Session service exception.
|
||||
* @throws { BusinessError } 6600102 - The session does not exist.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
function startDeviceLogging(url: string, maxSize?: number): Promise<void>;
|
||||
|
||||
/**
|
||||
* Stop the current device written even the discovery is ongoing.
|
||||
* @returns { Promise<void> } Promise for the result
|
||||
* @throws { BusinessError } 202 - Not System App.
|
||||
* @throws { BusinessError } 6600101 - Session service exception.
|
||||
* @throws { BusinessError } 6600102 - The session does not exist.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
function stopDeviceLogging(): Promise<void>;
|
||||
|
||||
/**
|
||||
* Register log event callback.
|
||||
* @param { 'deviceLogEvent' } type - Command to register 'deviceLogEvent'.
|
||||
* @param { Callback<DeviceLogEventCode> } callback - Used to handle ('deviceLogEvent') command
|
||||
* @throws { BusinessError } 202 - Not System App.
|
||||
* @throws { BusinessError } 401 - Parameter check failed. 1. Mandatory parameters are left unspecified.
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 6600101 - Session service exception.
|
||||
* @throws { BusinessError } 6600102 - The session does not exist.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
function on(type: 'deviceLogEvent', callback: Callback<DeviceLogEventCode>): void;
|
||||
|
||||
/**
|
||||
* UnRegister log event callback.
|
||||
* @param { 'deviceLogEvent' } type - Command to register 'deviceLogEvent'.
|
||||
* @param { Callback<DeviceLogEventCode> } callback - Used to handle ('deviceLogEvent') command
|
||||
* @throws { BusinessError } 202 - Not System App.
|
||||
* @throws { BusinessError } 401 - Parameter check failed. 1. Mandatory parameters are left unspecified.
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 6600101 - Session service exception.
|
||||
* @throws { BusinessError } 6600102 - The session does not exist.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
function off(type: 'deviceLogEvent', callback?: Callback<DeviceLogEventCode>): void;
|
||||
|
||||
/**
|
||||
* Enumerates device log event code.
|
||||
* @enum { number }
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
enum DeviceLogEventCode {
|
||||
/**
|
||||
* Log is full.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
DEVICE_LOG_FULL = 1,
|
||||
|
||||
/**
|
||||
* Log is written with exception, such as the fd cannot be written and so on.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
DEVICE_LOG_EXCEPTION = 2,
|
||||
}
|
||||
|
||||
/**
|
||||
* Session type, support audio & video
|
||||
* @typedef { 'audio' | 'video' } AVSessionType
|
||||
@ -3265,6 +3350,207 @@ declare namespace avSession {
|
||||
*/
|
||||
off(type: 'error'): void;
|
||||
|
||||
/**
|
||||
* Register listeners for cast control generic error events.
|
||||
* @param { 'castControlGenericError' } type Type of the 'castControlGenericError' to listen for.
|
||||
* @param { ErrorCallback } callback Callback used to listen for the cast control error event.
|
||||
* @throws { BusinessError } 401 - Parameter check failed. 1. Mandatory parameters are left unspecified.
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 6611000 - The error code for cast control is unspecified.
|
||||
* @throws { BusinessError } 6611001 - An unspecified error occurs in the remote player.
|
||||
* @throws { BusinessError } 6611002 - The playback position falls behind the live window.
|
||||
* @throws { BusinessError } 6611003 - The process of cast control times out.
|
||||
* @throws { BusinessError } 6611004 - The runtime check failed.
|
||||
* @throws { BusinessError } 6611100 - Cross-device data transmission is locked.
|
||||
* @throws { BusinessError } 6611101 - The specified seek mode is not supported.
|
||||
* @throws { BusinessError } 6611102 - The position to seek to is out of the range of the media asset
|
||||
* or the specified seek mode is not supported.
|
||||
* @throws { BusinessError } 6611103 - The specified playback mode is not supported.
|
||||
* @throws { BusinessError } 6611104 - The specified playback speed is not supported.
|
||||
* @throws { BusinessError } 6611105 - The action failed because either the media source device or the media sink device has been revoked.
|
||||
* @throws { BusinessError } 6611106 - The parameter is invalid, for example, the url is illegal to play.
|
||||
* @throws { BusinessError } 6611107 - Allocation of memory failed.
|
||||
* @throws { BusinessError } 6611108 - Operation is not allowed.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
on(type: 'castControlGenericError', callback: ErrorCallback): void;
|
||||
|
||||
/**
|
||||
* Unregister listeners for cast control generic error events.
|
||||
* @param { 'castControlGenericError' } type Type of the 'castControlGenericError' to listen for.
|
||||
* @param { ErrorCallback } callback Callback used to listen for the cast control error event.
|
||||
* @throws { BusinessError } 401 - Parameter check failed. 1. Mandatory parameters are left unspecified.
|
||||
* 2. Incorrect parameter types.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
off(type: 'castControlGenericError', callback?: ErrorCallback): void;
|
||||
|
||||
/**
|
||||
* Register listeners for cast control input/output error events.
|
||||
* @param { 'castControlIoError' } type Type of the 'castControlIoError' to listen for.
|
||||
* @param { ErrorCallback } callback Callback used to listen for the cast control error event.
|
||||
* @throws { BusinessError } 401 - Parameter check failed. 1. Mandatory parameters are left unspecified.
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 6612000 - An unspecified input/output error occurs.
|
||||
* @throws { BusinessError } 6612001 - Network connection failure.
|
||||
* @throws { BusinessError } 6612002 - Network timeout.
|
||||
* @throws { BusinessError } 6612003 - Invalid "Content-Type" HTTP header.
|
||||
* @throws { BusinessError } 6612004 - The HTTP server returns an unexpected HTTP response status code.
|
||||
* @throws { BusinessError } 6612005 - The file does not exist.
|
||||
* @throws { BusinessError } 6612006 - No permission is granted to perform the IO operation.
|
||||
* @throws { BusinessError } 6612007 - Access to cleartext HTTP traffic is not allowed by the app's network security configuration.
|
||||
* @throws { BusinessError } 6612008 - Reading data out of the data bound.
|
||||
* @throws { BusinessError } 6612100 - The media does not contain any contents that can be played.
|
||||
* @throws { BusinessError } 6612101 - The media cannot be read, for example, because of dust or scratches.
|
||||
* @throws { BusinessError } 6612102 - This resource is already in use.
|
||||
* @throws { BusinessError } 6612103 - The content using the validity interval has expired.
|
||||
* @throws { BusinessError } 6612104 - Using the requested content to play is not allowed.
|
||||
* @throws { BusinessError } 6612105 - The use of the allowed content cannot be verified.
|
||||
* @throws { BusinessError } 6612106 - The number of times this content has been used as requested has reached the maximum allowed number of uses.
|
||||
* @throws { BusinessError } 6612107 - An error occurs when sending packet from source device to sink device.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
on(type: 'castControlIoError', callback: ErrorCallback): void;
|
||||
|
||||
/**
|
||||
* Unregister listeners for cast control input/output error events.
|
||||
* @param { 'castControlIoError' } type Type of the 'castControlIoError' to listen for.
|
||||
* @param { ErrorCallback } callback Callback used to listen for the cast control error event.
|
||||
* @throws { BusinessError } 401 - Parameter check failed. 1. Mandatory parameters are left unspecified.
|
||||
* 2. Incorrect parameter types.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
off(type: 'castControlIoError', callback?: ErrorCallback): void;
|
||||
|
||||
/**
|
||||
* Register listeners for cast control parsing error events.
|
||||
* @param { 'castControlParsingError' } type Type of the 'castControlParsingError' to listen for.
|
||||
* @param { ErrorCallback } callback Callback used to listen for the cast control error event.
|
||||
* @throws { BusinessError } 401 - Parameter check failed. 1. Mandatory parameters are left unspecified.
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 6613000 - Unspecified error related to content parsing.
|
||||
* @throws { BusinessError } 6613001 - Parsing error associated with media container format bit streams.
|
||||
* @throws { BusinessError } 6613002 - Parsing error associated with the media manifest.
|
||||
* @throws { BusinessError } 6613003 - An error occurs when attempting to extract a file with an unsupported media container format
|
||||
* or an unsupported media container feature.
|
||||
* @throws { BusinessError } 6613004 - Unsupported feature in the media manifest.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
on(type: 'castControlParsingError', callback: ErrorCallback): void;
|
||||
|
||||
/**
|
||||
* Unregister listeners for cast control parsing error events.
|
||||
* @param { 'castControlParsingError' } type Type of the 'castControlParsingError' to listen for.
|
||||
* @param { ErrorCallback } callback Callback used to listen for the cast control error event.
|
||||
* @throws { BusinessError } 401 - Parameter check failed. 1. Mandatory parameters are left unspecified.
|
||||
* 2. Incorrect parameter types.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
off(type: 'castControlParsingError', callback?: ErrorCallback): void;
|
||||
|
||||
/**
|
||||
* Register listeners for cast control decoding error events.
|
||||
* @param { 'castControlDecodingError' } type Type of the 'castControlDecodingError' to listen for.
|
||||
* @param { ErrorCallback } callback Callback used to listen for the cast control error event.
|
||||
* @throws { BusinessError } 401 - Parameter check failed. 1. Mandatory parameters are left unspecified.
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 6614000 - Unspecified decoding error.
|
||||
* @throws { BusinessError } 6614001 - Decoder initialization failed.
|
||||
* @throws { BusinessError } 6614002 - Decoder query failed.
|
||||
* @throws { BusinessError } 6614003 - Decoding the media samples failed.
|
||||
* @throws { BusinessError } 6614004 - The format of the content to decode exceeds the capabilities of the device.
|
||||
* @throws { BusinessError } 6614005 - The format of the content to decode is not supported.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
on(type: 'castControlDecodingError', callback: ErrorCallback): void;
|
||||
|
||||
/**
|
||||
* Unregister listeners for cast control decoding error events.
|
||||
* @param { 'castControlDecodingError' } type Type of the 'castControlDecodingError' to listen for.
|
||||
* @param { ErrorCallback } callback Callback used to listen for the cast control error event.
|
||||
* @throws { BusinessError } 401 - Parameter check failed. 1. Mandatory parameters are left unspecified.
|
||||
* 2. Incorrect parameter types.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
off(type: 'castControlDecodingError', callback?: ErrorCallback): void;
|
||||
|
||||
/**
|
||||
* Register listeners for cast control audio renderer error error events.
|
||||
* @param { 'castControlAudioRendererError' } type Type of the 'castControlAudioRendererError' to listen for.
|
||||
* @param { ErrorCallback } callback Callback used to listen for the cast control error event.
|
||||
* @throws { BusinessError } 401 - Parameter check failed. 1. Mandatory parameters are left unspecified.
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 6615000 - Unspecified errors related to the audio renderer.
|
||||
* @throws { BusinessError } 6615001 - Initializing the audio renderer failed.
|
||||
* @throws { BusinessError } 6615002 - The audio renderer fails to write data.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
on(type: 'castControlAudioRendererError', callback: ErrorCallback): void;
|
||||
|
||||
/**
|
||||
* Unregister listeners for cast control audio renderer error events.
|
||||
* @param { 'castControlAudioRendererError' } type Type of the 'castControlAudioRendererError' to listen for.
|
||||
* @param { ErrorCallback } callback Callback used to listen for the cast control error event.
|
||||
* @throws { BusinessError } 401 - Parameter check failed. 1. Mandatory parameters are left unspecified.
|
||||
* 2. Incorrect parameter types.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
off(type: 'castControlAudioRendererError', callback?: ErrorCallback): void;
|
||||
|
||||
/**
|
||||
* Register listeners for cast control drm error events.
|
||||
* @param { 'castControlDrmError' } type Type of the 'castControlDrmError' to listen for.
|
||||
* @param { ErrorCallback } callback Callback used to listen for the cast control error event.
|
||||
* @throws { BusinessError } 401 - Parameter check failed. 1. Mandatory parameters are left unspecified.
|
||||
* 2. Incorrect parameter types.
|
||||
* @throws { BusinessError } 6616000 - Unspecified error related to DRM.
|
||||
* @throws { BusinessError } 6616001 - The chosen DRM protection scheme is not supported by the device.
|
||||
* @throws { BusinessError } 6616002 - Device provisioning failed.
|
||||
* @throws { BusinessError } 6616003 - The DRM-protected content to play is incompatible.
|
||||
* @throws { BusinessError } 6616004 - Failed to obtain a license.
|
||||
* @throws { BusinessError } 6616005 - The operation is disallowed by the license policy.
|
||||
* @throws { BusinessError } 6616006 - An error occurs in the DRM system.
|
||||
* @throws { BusinessError } 6616007 - The device has revoked DRM privileges.
|
||||
* @throws { BusinessError } 6616008 - The DRM license being loaded into the open DRM session has expired.
|
||||
* @throws { BusinessError } 6616100 - An error occurs when the DRM processes the key response.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
on(type: 'castControlDrmError', callback: ErrorCallback): void;
|
||||
|
||||
/**
|
||||
* Unregister listeners for cast control drm error events.
|
||||
* @param { 'castControlDrmError' } type Type of the 'castControlDrmError' to listen for.
|
||||
* @param { ErrorCallback } callback Callback used to listen for the cast control error event.
|
||||
* @throws { BusinessError } 401 - Parameter check failed. 1. Mandatory parameters are left unspecified.
|
||||
* 2. Incorrect parameter types.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
off(type: 'castControlDrmError', callback?: ErrorCallback): void;
|
||||
|
||||
/**
|
||||
* Register listener for drm key request.
|
||||
* @param { 'keyRequest' } type - Type of the 'keyRequest' to listen for.
|
||||
@ -4835,6 +5121,33 @@ declare namespace avSession {
|
||||
*/
|
||||
deviceType: DeviceType;
|
||||
|
||||
/**
|
||||
* Device manufacturer.
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
manufacturer?: string;
|
||||
|
||||
/**
|
||||
* Device model name.
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
modelName?: string;
|
||||
|
||||
/**
|
||||
* Network id.
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
networkId?: string;
|
||||
|
||||
/**
|
||||
* device ip address if available.
|
||||
* @type { ?string }
|
||||
@ -4887,6 +5200,26 @@ declare namespace avSession {
|
||||
* @since 11
|
||||
*/
|
||||
authenticationStatus?: number;
|
||||
|
||||
/**
|
||||
* Indicates the current device is legacy or not.
|
||||
* @type { ?boolean }
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
isLegacy?: boolean;
|
||||
|
||||
/**
|
||||
* Medium types used to discover devices.
|
||||
* 1: BLE
|
||||
* 2: COAP
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
mediumTypes?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -6901,6 +7234,447 @@ declare namespace avSession {
|
||||
* @since 12
|
||||
*/
|
||||
ERR_CODE_REMOTE_CONNECTION_NOT_EXIST = 6600109,
|
||||
|
||||
/**
|
||||
* The error code for cast control is unspecified.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_UNSPECIFIED = 6611000,
|
||||
|
||||
/**
|
||||
* An unspecified error occurs in the remote player.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_REMOTE_ERROR = 6611001,
|
||||
|
||||
/**
|
||||
* The playback position falls behind the live window.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_BEHIND_LIVE_WINDOW = 6611002,
|
||||
|
||||
/**
|
||||
* The process of cast control times out.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_TIMEOUT = 6611003,
|
||||
|
||||
/**
|
||||
* The runtime check failed.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_RUNTIME_CHECK_FAILED = 6611004,
|
||||
|
||||
/**
|
||||
* Cross-device data transmission is locked.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_PLAYER_NOT_WORKING = 6611100,
|
||||
|
||||
/**
|
||||
* The specified seek mode is not supported.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_SEEK_MODE_UNSUPPORTED = 6611101,
|
||||
|
||||
/**
|
||||
* The position to seek to is out of the range of the media asset or the specified seek mode is not supported.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_ILLEGAL_SEEK_TARGET = 6611102,
|
||||
|
||||
/**
|
||||
* The specified playback mode is not supported.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_PLAY_MODE_UNSUPPORTED = 6611103,
|
||||
|
||||
/**
|
||||
* The specified playback speed is not supported.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_PLAY_SPEED_UNSUPPORTED = 6611104,
|
||||
|
||||
/**
|
||||
* The action failed because either the media source device or the media sink device has been revoked.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_DEVICE_MISSING = 6611105,
|
||||
|
||||
/**
|
||||
* The parameter is invalid, for example, the url is illegal to play.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_INVALID_PARAM = 6611106,
|
||||
|
||||
/**
|
||||
* Allocation of memory failed.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_NO_MEMORY = 6611107,
|
||||
|
||||
/**
|
||||
* Operation is not allowed.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_OPERATION_NOT_ALLOWED = 6611108,
|
||||
|
||||
/**
|
||||
* An unspecified input/output error occurs.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_IO_UNSPECIFIED = 6612000,
|
||||
|
||||
/**
|
||||
* Network connection failure.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_IO_NETWORK_CONNECTION_FAILED = 6612001,
|
||||
|
||||
/**
|
||||
* Network timeout.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_IO_NETWORK_CONNECTION_TIMEOUT = 6612002,
|
||||
|
||||
/**
|
||||
* Invalid "Content-Type" HTTP header.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_IO_INVALID_HTTP_CONTENT_TYPE = 6612003,
|
||||
|
||||
/**
|
||||
* The HTTP server returns an unexpected HTTP response status code.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_IO_BAD_HTTP_STATUS = 6612004,
|
||||
|
||||
/**
|
||||
* The file does not exist.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_IO_FILE_NOT_FOUND = 6612005,
|
||||
|
||||
/**
|
||||
* No permission is granted to perform the IO operation.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_IO_NO_PERMISSION = 6612006,
|
||||
|
||||
/**
|
||||
* Access to cleartext HTTP traffic is not allowed by the app's network security configuration.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_IO_CLEARTEXT_NOT_PERMITTED = 6612007,
|
||||
|
||||
/**
|
||||
* Reading data out of the data bound.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_IO_READ_POSITION_OUT_OF_RANGE = 6612008,
|
||||
|
||||
/**
|
||||
* The media does not contain any contents that can be played.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_IO_NO_CONTENTS = 6612100,
|
||||
|
||||
/**
|
||||
* The media cannot be read, for example, because of dust or scratches.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_IO_READ_ERROR = 6612101,
|
||||
|
||||
/**
|
||||
* This resource is already in use.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_IO_CONTENT_BUSY = 6612102,
|
||||
|
||||
/**
|
||||
* The content using the validity interval has expired.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_IO_CONTENT_EXPIRED = 6612103,
|
||||
|
||||
/**
|
||||
* Using the requested content to play is not allowed.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_IO_USE_FORBIDDEN = 6612104,
|
||||
|
||||
/**
|
||||
* The use of the allowed content cannot be verified.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_IO_NOT_VERIFIED = 6612105,
|
||||
|
||||
/**
|
||||
* The number of times this content has been used as requested has reached the maximum allowed number of uses.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_IO_EXHAUSTED_ALLOWED_USES = 6612106,
|
||||
|
||||
/**
|
||||
* An error occurs when sending packet from source device to sink device.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_IO_NETWORK_PACKET_SENDING_FAILED = 6612107,
|
||||
|
||||
/**
|
||||
* Unspecified error related to content parsing.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_PARSING_UNSPECIFIED = 6613000,
|
||||
|
||||
/**
|
||||
* Parsing error associated with media container format bit streams.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_PARSING_CONTAINER_MALFORMED = 6613001,
|
||||
|
||||
/**
|
||||
* Parsing error associated with the media manifest.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_PARSING_MANIFEST_MALFORMED = 6613002,
|
||||
|
||||
/**
|
||||
* An error occurs when attempting to extract a file with an unsupported media container format
|
||||
* or an unsupported media container feature.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_PARSING_CONTAINER_UNSUPPORTED = 6613003,
|
||||
|
||||
/**
|
||||
* Unsupported feature in the media manifest.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_PARSING_MANIFEST_UNSUPPORTED = 6613004,
|
||||
|
||||
/**
|
||||
* Unspecified decoding error.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_DECODING_UNSPECIFIED = 6614000,
|
||||
|
||||
/**
|
||||
* Decoder initialization failed.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_DECODING_INIT_FAILED = 6614001,
|
||||
|
||||
/**
|
||||
* Decoder query failed.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_DECODING_QUERY_FAILED = 6614002,
|
||||
|
||||
/**
|
||||
* Decoding the media samples failed.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_DECODING_FAILED = 6614003,
|
||||
|
||||
/**
|
||||
* The format of the content to decode exceeds the capabilities of the device.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_DECODING_FORMAT_EXCEEDS_CAPABILITIES = 6614004,
|
||||
|
||||
/**
|
||||
* The format of the content to decode is not supported.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_DECODING_FORMAT_UNSUPPORTED = 6614005,
|
||||
|
||||
/**
|
||||
* Unspecified errors related to the audio renderer.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_AUDIO_RENDERER_UNSPECIFIED = 6615000,
|
||||
|
||||
/**
|
||||
* Initializing the audio renderer failed.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_AUDIO_RENDERER_INIT_FAILED = 6615001,
|
||||
|
||||
/**
|
||||
* The audio renderer fails to write data.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_AUDIO_RENDERER_WRITE_FAILED = 6615002,
|
||||
|
||||
/**
|
||||
* Unspecified error related to DRM.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_DRM_UNSPECIFIED = 6616000,
|
||||
|
||||
/**
|
||||
* The chosen DRM protection scheme is not supported by the device.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_DRM_SCHEME_UNSUPPORTED = 6616001,
|
||||
|
||||
/**
|
||||
* Device provisioning failed.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_DRM_PROVISIONING_FAILED = 6616002,
|
||||
|
||||
/**
|
||||
* The DRM-protected content to play is incompatible.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_DRM_CONTENT_ERROR = 6616003,
|
||||
|
||||
/**
|
||||
* Failed to obtain a license.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_DRM_LICENSE_ACQUISITION_FAILED = 6616004,
|
||||
|
||||
/**
|
||||
* The operation is disallowed by the license policy.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_DRM_DISALLOWED_OPERATION = 6616005,
|
||||
|
||||
/**
|
||||
* An error occurs in the DRM system.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_DRM_SYSTEM_ERROR = 6616006,
|
||||
|
||||
/**
|
||||
* The device has revoked DRM privileges.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_DRM_DEVICE_REVOKED = 6616007,
|
||||
|
||||
/**
|
||||
* The DRM license being loaded into the open DRM session has expired.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_DRM_LICENSE_EXPIRED = 6616008,
|
||||
|
||||
/**
|
||||
* An error occurs when the DRM processes the key response.
|
||||
* @syscap SystemCapability.Multimedia.AVSession.AVCast
|
||||
* @atomicservice
|
||||
* @since 13
|
||||
*/
|
||||
ERR_CODE_CAST_CONTROL_DRM_PROVIDE_KEY_RESPONSE_ERROR = 6616100,
|
||||
}
|
||||
}
|
||||
|
||||
|
1177
api/@ohos.multimedia.camera.d.ts
vendored
1177
api/@ohos.multimedia.camera.d.ts
vendored
File diff suppressed because it is too large
Load Diff
165
api/@ohos.multimedia.image.d.ts
vendored
165
api/@ohos.multimedia.image.d.ts
vendored
@ -3404,7 +3404,7 @@ declare namespace image {
|
||||
*
|
||||
* @typedef PackingOptionsForSequence
|
||||
* @syscap SystemCapability.Multimedia.Image.ImagePacker
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
interface PackingOptionsForSequence {
|
||||
/**
|
||||
@ -3412,7 +3412,7 @@ declare namespace image {
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.Multimedia.Image.ImagePacker
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
frameCount: number;
|
||||
|
||||
@ -3422,7 +3422,7 @@ declare namespace image {
|
||||
*
|
||||
* @type { Array<number> }
|
||||
* @syscap SystemCapability.Multimedia.Image.ImagePacker
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
delayTimeList: Array<number>;
|
||||
|
||||
@ -3431,7 +3431,7 @@ declare namespace image {
|
||||
*
|
||||
* @type { ?Array<number> }
|
||||
* @syscap SystemCapability.Multimedia.Image.ImagePacker
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
disposalTypes?: Array<number>;
|
||||
|
||||
@ -3441,7 +3441,7 @@ declare namespace image {
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.Multimedia.Image.ImagePacker
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
loopCount?: number;
|
||||
}
|
||||
@ -6722,6 +6722,19 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
*/
|
||||
getMetadata(key: HdrMetadataKey): HdrMetadataValue;
|
||||
|
||||
/**
|
||||
* Set pixelmap memory name.
|
||||
*
|
||||
* @param { string } name The name of the memory that needs to be set
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.The length of the input parameter is too long.
|
||||
* 2.Parameter verification failed.
|
||||
* @throws { BusinessError } 501 - Resource unavailable.
|
||||
* @throws { BusinessError } 62980286 - Memory format not supported.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 13
|
||||
*/
|
||||
setMemoryNameSync(name: string): void;
|
||||
|
||||
/**
|
||||
* Set metadata.
|
||||
*
|
||||
@ -6745,7 +6758,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
*
|
||||
* @typedef Picture
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
interface Picture {
|
||||
/**
|
||||
@ -6753,7 +6766,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
*
|
||||
* @returns { PixelMap } Returns the pixel map.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
getMainPixelmap(): PixelMap;
|
||||
|
||||
@ -6764,17 +6777,17 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* @throws { BusinessError } 7600901 - Unknown error.
|
||||
* @throws { BusinessError } 7600201 - Unsupported operation.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
getHdrComposedPixelmap(): Promise<PixelMap>;
|
||||
|
||||
/**
|
||||
* Obtains the gain map pixel map.
|
||||
* @returns { PixelMap|null } Returns the pixel map if the operation is successful; returns null otherwise.
|
||||
* @returns { PixelMap | null } Returns the pixel map if the operation is successful; returns null otherwise.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
getGainmapPixelmap(): PixelMap|null;
|
||||
getGainmapPixelmap(): PixelMap | null;
|
||||
|
||||
/**
|
||||
* Set auxiliary picture.
|
||||
@ -6784,7 +6797,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified.
|
||||
* 2.Incorrect parameter types. 3.Parameter verification failed.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
setAuxiliaryPicture(type: AuxiliaryPictureType, auxiliaryPicture: AuxiliaryPicture): void;
|
||||
|
||||
@ -6792,13 +6805,13 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* Obtains the auxiliary picture based on type.
|
||||
*
|
||||
* @param { AuxiliaryPictureType } type The type of auxiliary picture.
|
||||
* @returns { AuxiliaryPicture|null } Returns the auxiliary picture object.
|
||||
* @returns { AuxiliaryPicture | null } Returns the auxiliary picture object.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified.
|
||||
* 2.Incorrect parameter types. 3.Parameter verification failed.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
getAuxiliaryPicture(type: AuxiliaryPictureType): AuxiliaryPicture|null;
|
||||
getAuxiliaryPicture(type: AuxiliaryPictureType): AuxiliaryPicture | null;
|
||||
|
||||
/**
|
||||
* Set the metadata of main picture.
|
||||
@ -6810,7 +6823,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* 2.Incorrect parameter types. 3.Parameter verification failed.
|
||||
* @throws { BusinessError } 7600202 - Unsupported metadata. Possible causes: Unsupported metadata type.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
setMetadata(metadataType: MetadataType, metadata: Metadata): Promise<void>
|
||||
|
||||
@ -6823,7 +6836,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* 2.Incorrect parameter types. 3.Parameter verification failed.
|
||||
* @throws { BusinessError } 7600202 - Unsupported metadata. Possible causes: Unsupported metadata type.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
getMetadata(metadataType: MetadataType): Promise<Metadata>
|
||||
|
||||
@ -6835,14 +6848,14 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* 2.Incorrect parameter types; 3.Parameter verification failed.
|
||||
* @throws { BusinessError } 62980097 - IPC error.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
marshalling(sequence: rpc.MessageSequence): void
|
||||
|
||||
/**
|
||||
* Releases this Picture object.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
release(): void
|
||||
}
|
||||
@ -6855,7 +6868,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* @throws { BusinessError } 401 - Parameter error.Possible causes: 1.Mandatory parameters are left unspecified.
|
||||
* 2.Incorrect parameter types; 3.Parameter verification failed.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
function createPicture(mainPixelmap : PixelMap): Picture;
|
||||
|
||||
@ -6868,7 +6881,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* 2.Incorrect parameter types; 3.Parameter verification failed.
|
||||
* @throws { BusinessError } 62980097 - IPC error.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
function createPictureFromParcel(sequence: rpc.MessageSequence): Picture;
|
||||
|
||||
@ -6882,16 +6895,16 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* @throws { BusinessError } 401 - Parameter error.Possible causes: 1.Mandatory parameters are left unspecified.
|
||||
* 2.Incorrect parameter types; 3.Parameter verification failed.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
function createAuxiliaryPicture(buffer: ArrayBuffer, size: Size, type: AuxiliaryPictureType): AuxiliaryPicture
|
||||
function createAuxiliaryPicture(buffer: ArrayBuffer, size: Size, type: AuxiliaryPictureType): AuxiliaryPicture;
|
||||
|
||||
/**
|
||||
* AuxiliaryPicture instance.
|
||||
*
|
||||
* @typedef AuxiliaryPicture
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
interface AuxiliaryPicture {
|
||||
/**
|
||||
@ -6906,7 +6919,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* @throws { BusinessError } 7600301 - Memory alloc failed.
|
||||
* @throws { BusinessError } 7600302 - Memory copy failed.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
writePixelsFromBuffer(data: ArrayBuffer): Promise<void>;
|
||||
|
||||
@ -6918,7 +6931,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* @throws { BusinessError } 7600301 - Memory alloc failed.
|
||||
* @throws { BusinessError } 7600302 - Memory copy failed.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
readPixelsToBuffer(): Promise<ArrayBuffer>;
|
||||
|
||||
@ -6927,7 +6940,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
*
|
||||
* @returns { AuxiliaryPictureType } Returns the type of auxiliary picture.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
getType(): AuxiliaryPictureType;
|
||||
|
||||
@ -6942,7 +6955,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* @throws { BusinessError } 7600202 - Unsupported metadata. Possible causes: 1. Unsupported metadata type. 2. The
|
||||
* metadata type does not match the auxiliary picture type.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
setMetadata(metadataType: MetadataType, metadata: Metadata): Promise<void>
|
||||
|
||||
@ -6956,7 +6969,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* @throws { BusinessError } 7600202 - Unsupported metadata. Possible causes: 1. Unsupported metadata type. 2. The
|
||||
* metadata type does not match the auxiliary picture type.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
getMetadata(metadataType: MetadataType): Promise<Metadata>
|
||||
|
||||
@ -6966,7 +6979,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* @returns { AuxiliaryPictureInfo } Returns the auxiliary picture information. If the operation fails, an error
|
||||
* message is returned.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
getAuxiliaryPictureInfo(): AuxiliaryPictureInfo;
|
||||
|
||||
@ -6977,14 +6990,14 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* @throws { BusinessError } 401 - Parameter error.Possible causes: 1.Mandatory parameters are left unspecified.
|
||||
* 2.Incorrect parameter types. 3.Parameter verification failed.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
setAuxiliaryPictureInfo(info: AuxiliaryPictureInfo): void
|
||||
|
||||
/**
|
||||
* Releases this AuxiliaryPicture object.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
release():void
|
||||
}
|
||||
@ -6994,14 +7007,14 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
*
|
||||
* @enum { number }
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
enum AuxiliaryPictureType {
|
||||
/**
|
||||
* Gain map.
|
||||
*
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
GAINMAP = 1,
|
||||
|
||||
@ -7009,7 +7022,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* Depth map.
|
||||
*
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
DEPTH_MAP = 2,
|
||||
|
||||
@ -7017,7 +7030,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* Unrefocus map.
|
||||
*
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
UNREFOCUS_MAP = 3,
|
||||
|
||||
@ -7025,7 +7038,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* Linear map.
|
||||
*
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
LINEAR_MAP = 4,
|
||||
|
||||
@ -7033,7 +7046,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* Fragment map.
|
||||
*
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
FRAGMENT_MAP = 5,
|
||||
}
|
||||
@ -7043,14 +7056,14 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
*
|
||||
* @enum { number }
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
enum MetadataType {
|
||||
/**
|
||||
* EXIF metadata.
|
||||
*
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
EXIF_METADATA = 1,
|
||||
|
||||
@ -7058,7 +7071,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* Fragment metadata.
|
||||
*
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
FRAGMENT_METADATA = 2,
|
||||
}
|
||||
@ -7068,7 +7081,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
*
|
||||
* @typedef Metadata
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
interface Metadata {
|
||||
/**
|
||||
@ -7076,20 +7089,20 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* of records.
|
||||
*
|
||||
* @param { Array<string> } key Name of the properties whose value is to be obtained.
|
||||
* @returns { Promise<Record<string, string|null>> } Array of Records instance used to return the property values.
|
||||
* @returns { Promise<Record<string, string | null>> } Array of Records instance used to return the property values.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified.
|
||||
* 2.Incorrect parameter types. 3.Parameter verification failed.
|
||||
* @throws { BusinessError } 7600202 - Unsupported metadata. Possible causes: 1. Unsupported metadata type. 2. The
|
||||
* metadata type does not match the auxiliary picture type.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
getProperties(key: Array<string>): Promise<Record<string, string|null>>
|
||||
getProperties(key: Array<string>): Promise<Record<string, string | null>>
|
||||
|
||||
/**
|
||||
* Modify the value of properties in an image with the specified keys.
|
||||
*
|
||||
* @param { Record<string, string|null> } records Array of the property Records whose values are to
|
||||
* @param { Record<string, string | null> } records Array of the property Records whose values are to
|
||||
* be modified.
|
||||
* @returns { Promise<void> } A Promise instance used to return the operation result.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1.Mandatory parameters are left unspecified.
|
||||
@ -7097,19 +7110,19 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* @throws { BusinessError } 7600202 - Unsupported metadata. Possible causes: 1. Unsupported metadata type. 2. The
|
||||
* metadata type does not match the auxiliary picture type.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
setProperties(records: Record<string, string|null>): Promise<void>
|
||||
setProperties(records: Record<string, string | null>): Promise<void>
|
||||
|
||||
/**
|
||||
* Obtains the value of all properties in an image. This method uses a promise to return the property values
|
||||
* in array of records.
|
||||
*
|
||||
* @returns { Promise<Record<string, string|null>> } Array of Records instance used to return the property values.
|
||||
* @returns { Promise<Record<string, string | null>> } Array of Records instance used to return the property values.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
getAllProperties(): Promise<Record<string, string|null>>
|
||||
getAllProperties(): Promise<Record<string, string | null>>
|
||||
|
||||
/**
|
||||
* Obtains a clone of metadata. This method uses a promise to return the metadata.
|
||||
@ -7118,7 +7131,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* @throws { BusinessError } 7600301 - Memory alloc failed.
|
||||
* @throws { BusinessError } 7600302 - Memory copy failed.
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
clone(): Promise<Metadata>
|
||||
}
|
||||
@ -7128,40 +7141,40 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
*
|
||||
* @enum { string }
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
enum FragmentMapPropertyKey {
|
||||
/**
|
||||
* The x-coordinate of the top left corner of the mark cup map in the original image.
|
||||
*
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
X_IN_ORIGINAL = "XInOriginal",
|
||||
X_IN_ORIGINAL = 'XInOriginal',
|
||||
|
||||
/**
|
||||
* The y-coordinate of the top left corner of the mark cup map in the original image.
|
||||
*
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
Y_IN_ORIGINAL = "YInOriginal",
|
||||
Y_IN_ORIGINAL = 'YInOriginal',
|
||||
|
||||
/**
|
||||
* Mark cut map width.
|
||||
*
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
WIDTH = "FragmentImageWidth",
|
||||
WIDTH = 'FragmentImageWidth',
|
||||
|
||||
/**
|
||||
* Mark cut map width.
|
||||
*
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
HEIGHT = "FragmentImageHeight"
|
||||
HEIGHT = 'FragmentImageHeight'
|
||||
}
|
||||
|
||||
/**
|
||||
@ -7169,7 +7182,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
*
|
||||
* @typedef DecodingOptionsForPicture
|
||||
* @syscap SystemCapability.Multimedia.Image.ImageSource
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
interface DecodingOptionsForPicture {
|
||||
/**
|
||||
@ -7177,7 +7190,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
*
|
||||
* @type { Array<AuxiliaryPictureType> }
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
desiredAuxiliaryPictures: Array<AuxiliaryPictureType>;
|
||||
}
|
||||
@ -7187,7 +7200,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
*
|
||||
* @typedef AuxiliaryPictureInfo
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
interface AuxiliaryPictureInfo {
|
||||
/**
|
||||
@ -7195,7 +7208,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
*
|
||||
* @type { AuxiliaryPictureType }
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
auxiliaryPictureType: AuxiliaryPictureType;
|
||||
|
||||
@ -7204,7 +7217,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
*
|
||||
* @type { Size }
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
size: Size;
|
||||
|
||||
@ -7213,7 +7226,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
rowStride: number;
|
||||
|
||||
@ -7222,7 +7235,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
*
|
||||
* @type { PixelMapFormat }
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
pixelFormat: PixelMapFormat;
|
||||
|
||||
@ -7231,7 +7244,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
*
|
||||
* @type { colorSpaceManager.ColorSpaceManager }
|
||||
* @syscap SystemCapability.Multimedia.Image.Core
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
colorSpace: colorSpaceManager.ColorSpaceManager;
|
||||
}
|
||||
@ -8248,7 +8261,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* 2.Incorrect parameter types; 3.Parameter verification failed.
|
||||
* @throws { BusinessError } 7700301 - Decode failed.
|
||||
* @syscap SystemCapability.Multimedia.Image.ImageSource
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
createPicture(options?: DecodingOptionsForPicture): Promise<Picture>
|
||||
|
||||
@ -8430,7 +8443,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* @param { PackingOptionsForSequence } options Options for image packing.
|
||||
* @returns { Promise<ArrayBuffer> } A Promise instance used to return the operation result.
|
||||
* @syscap SystemCapability.Multimedia.Image.ImagePacker
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
packing(pixelmapSequence: Array<PixelMap>, options: PackingOptionsForSequence): Promise<ArrayBuffer>;
|
||||
|
||||
@ -8494,7 +8507,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* @param { PackingOptionsForSequence } options Options for image packing.
|
||||
* @returns { Promise<void> } A Promise instance used to return the operation result.
|
||||
* @syscap SystemCapability.Multimedia.Image.ImagePacker
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
packToFile(pixelmapSequence: Array<PixelMap>, fd: number, options: PackingOptionsForSequence): Promise<void>;
|
||||
|
||||
@ -8542,7 +8555,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* 2.Incorrect parameter types. 3.Parameter verification failed.
|
||||
* @throws { BusinessError } 7800301 - Encode failed.
|
||||
* @syscap SystemCapability.Multimedia.Image.ImagePacker
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
packing(picture: Picture, options: PackingOption): Promise<ArrayBuffer>;
|
||||
|
||||
@ -8557,7 +8570,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* 2.Incorrect parameter types. 3.Parameter verification failed.
|
||||
* @throws { BusinessError } 7800301 - Encode failed.
|
||||
* @syscap SystemCapability.Multimedia.Image.ImagePacker
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
packToFile(picture: Picture, fd: number, options: PackingOption): Promise<void>
|
||||
|
||||
@ -8769,7 +8782,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* @param { 'imageArrival' } type - Event type.
|
||||
* @param { AsyncCallback<void> } callback Callback to be removed.
|
||||
* @syscap SystemCapability.Multimedia.Image.ImageReceiver
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
off(type: 'imageArrival', callback?: AsyncCallback<void>): void;
|
||||
|
||||
@ -8872,7 +8885,7 @@ function createUnpremultipliedPixelMap(src: PixelMap, dst: PixelMap): Promise<vo
|
||||
* @param { 'imageRelease' } type - Event type.
|
||||
* @param { AsyncCallback<void> } callback Callback to be removed.
|
||||
* @syscap SystemCapability.Multimedia.Image.ImageCreator
|
||||
* @since 12
|
||||
* @since 13
|
||||
*/
|
||||
off(type: 'imageRelease', callback?: AsyncCallback<void>): void;
|
||||
|
||||
|
2
api/@ohos.multimedia.media.d.ts
vendored
2
api/@ohos.multimedia.media.d.ts
vendored
@ -37,7 +37,7 @@ import type drm from './@ohos.multimedia.drm';
|
||||
*/
|
||||
/**
|
||||
* @namespace media
|
||||
* @syscap SystemCapability.Multimedia.Media
|
||||
* @syscap SystemCapability.Multimedia.Media.Core
|
||||
* @crossplatform
|
||||
* @atomicservice
|
||||
* @since 12
|
||||
|
207
api/@ohos.multimedia.systemSoundManager.d.ts
vendored
207
api/@ohos.multimedia.systemSoundManager.d.ts
vendored
@ -318,6 +318,123 @@ declare namespace systemSoundManager {
|
||||
*/
|
||||
GENTLE = 1,
|
||||
}
|
||||
/**
|
||||
* Type definition of haptics in tone scenario.
|
||||
*
|
||||
* @typedef {RingtoneType | SystemToneType} ToneHapticsType
|
||||
* @syscap SystemCapability.Multimedia.SystemSound.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
type ToneHapticsType = RingtoneType | SystemToneType;
|
||||
|
||||
/**
|
||||
* Enum for haptics mode in tone scenario.
|
||||
* @enum {number}
|
||||
* @syscap SystemCapability.Multimedia.SystemSound.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
enum ToneHapticsMode {
|
||||
/**
|
||||
* None haptics mode.
|
||||
* @syscap SystemCapability.Multimedia.SystemSound.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
NONE = 0,
|
||||
/**
|
||||
* Haptics is synchronized with tone.
|
||||
* @syscap SystemCapability.Multimedia.SystemSound.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
SYNC = 1,
|
||||
|
||||
/**
|
||||
* Haptics is out of synchronize with tone.
|
||||
* @syscap SystemCapability.Multimedia.SystemSound.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
NON_SYNC = 2,
|
||||
}
|
||||
/**
|
||||
* Haptics settings in tone scenario.
|
||||
* @typedef ToneHapticsSettings
|
||||
* @syscap SystemCapability.Multimedia.SystemSound.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
interface ToneHapticsSettings {
|
||||
/**
|
||||
* Haptics mode.
|
||||
* @type { ToneHapticsMode }
|
||||
* @syscap SystemCapability.Multimedia.SystemSound.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
mode: ToneHapticsMode;
|
||||
/**
|
||||
* Haptics uri. Users can set/get this parameter when {@link ToneHapticsSettings#mode} is
|
||||
* {@link ToneHapticsMode#NON_SYC}. In other cases, this uri is useless and should be ignored.
|
||||
* @type { ?string }
|
||||
* @syscap SystemCapability.Multimedia.SystemSound.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
hapticsUri?: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* Haptics attributes in tone scenario.
|
||||
* @typedef ToneHapticsAttrs
|
||||
* @syscap SystemCapability.Multimedia.SystemSound.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
interface ToneHapticsAttrs {
|
||||
/**
|
||||
* Get haptics uri.
|
||||
* @returns { string } Haptics uri.
|
||||
* @throws { BusinessError } 202 - Caller is not a system application.
|
||||
* @syscap SystemCapability.Multimedia.SystemSound.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
getUri(): string;
|
||||
|
||||
/**
|
||||
* Get title of haptics.
|
||||
* @returns { string } Haptics title.
|
||||
* @throws { BusinessError } 202 - Caller is not a system application.
|
||||
* @syscap SystemCapability.Multimedia.SystemSound.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
getTitle(): string;
|
||||
|
||||
/**
|
||||
* Get file name of haptics.
|
||||
* @returns { string } Haptics title.
|
||||
* @throws { BusinessError } 202 - Caller is not a system application.
|
||||
* @syscap SystemCapability.Multimedia.SystemSound.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
getFileName(): string;
|
||||
}
|
||||
|
||||
/**
|
||||
* Type definition of tone haptics array.
|
||||
*
|
||||
* @typedef { Array<ToneHapticsAttrs> } ToneHapticsAttrsArray
|
||||
* @syscap SystemCapability.Multimedia.SystemSound.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
type ToneHapticsAttrsArray = Array<ToneHapticsAttrs>;
|
||||
|
||||
|
||||
/**
|
||||
* Gets system sound manager for all type sound.
|
||||
@ -737,6 +854,96 @@ declare namespace systemSoundManager {
|
||||
* @since 12
|
||||
*/
|
||||
removeCustomizedTone(context: BaseContext, uri:string): Promise<void>;
|
||||
|
||||
/**
|
||||
* Get haptics settings.
|
||||
* @param { BaseContext } context - Current application context.
|
||||
* @param { ToneHapticsType } type - Tone haptics type.
|
||||
* @returns { Promise<ToneHapticsSettings> } Promise used to return results of this call.
|
||||
* @throws { BusinessError } 202 - Caller is not a system application.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:
|
||||
* 1.Mandatory parameters are left unspecified;
|
||||
* 2.Incorrect parameter types.
|
||||
* @throws { BusinessError } 5400103 - I/O error.
|
||||
* @throws { BusinessError } 20700003 - Unsupported operation.
|
||||
* @syscap SystemCapability.Multimedia.SystemSound.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
getToneHapticsSettings(context: BaseContext, type: ToneHapticsType): Promise<ToneHapticsSettings>;
|
||||
|
||||
/**
|
||||
* Set haptics settings.
|
||||
* @param { BaseContext } context - Current application context.
|
||||
* @param { ToneHapticsType } type - Tone haptics type.
|
||||
* @param { ToneHapticsSettings } settings - Tone haptics settings.
|
||||
* @returns { Promise<void> } Promise used to return results of this call.
|
||||
* @throws { BusinessError } 202 - Caller is not a system application.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:
|
||||
* 1.Mandatory parameters are left unspecified;
|
||||
* 2.Incorrect parameter types.
|
||||
* @throws { BusinessError } 5400102 - Operation not allowed. For example, the input URI is not valid.
|
||||
* @throws { BusinessError } 5400103 - I/O error.
|
||||
* @throws { BusinessError } 20700003 - Unsupported operation.
|
||||
* @syscap SystemCapability.Multimedia.SystemSound.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
setToneHapticsSettings(context: BaseContext, type: ToneHapticsType, settings: ToneHapticsSettings): Promise<void>;
|
||||
|
||||
/**
|
||||
* Get haptics list.
|
||||
* @param { BaseContext } context - Current application context.
|
||||
* @param { boolean } isSynced - The queried haptics is synchronized with tone or not.
|
||||
* @returns { Promise<ToneHapticsAttrsArray> } Promise used to return ToneHapticsAttrsArray.
|
||||
* @throws { BusinessError } 202 - Caller is not a system application.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:
|
||||
* 1.Mandatory parameters are left unspecified;
|
||||
* 2.Incorrect parameter types.
|
||||
* @throws { BusinessError } 5400103 - I/O error.
|
||||
* @throws { BusinessError } 20700003 - Unsupported operation.
|
||||
* @syscap SystemCapability.Multimedia.SystemSound.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
getToneHapticsList(context: BaseContext, isSynced: boolean): Promise<ToneHapticsAttrsArray>;
|
||||
|
||||
/**
|
||||
* Get attributes of haptics which is synchronized with one tone. If no haptics is found, then the attributes in
|
||||
* the returned ToneHapticsAttrs is empty.
|
||||
* @param { BaseContext } context - Current application context.
|
||||
* @param { string } toneUri - Uri of tone to query.
|
||||
* @returns { Promise<ToneHapticsAttrs> } Promise used to return ToneHapticsAttrs.
|
||||
* @throws { BusinessError } 202 - Caller is not a system application.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:
|
||||
* 1.Mandatory parameters are left unspecified;
|
||||
* 2.Incorrect parameter types.
|
||||
* @throws { BusinessError } 5400102 - Operation not allowed. For example, the input URI is not used for tones.
|
||||
* @throws { BusinessError } 5400103 - I/O error.
|
||||
* @throws { BusinessError } 20700003 - Unsupported operation.
|
||||
* @syscap SystemCapability.Multimedia.SystemSound.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
getHapticsAttrsSyncedWithTone(context: BaseContext, toneUri: string): Promise<ToneHapticsAttrs>;
|
||||
|
||||
/**
|
||||
* Open haptics.
|
||||
* @param { BaseContext } context - Current application context.
|
||||
* @param { string } hapticsUri - Uri of haptics to open.
|
||||
* @returns { Promise<number> } Promise used to return fd.
|
||||
* @throws { BusinessError } 202 - Caller is not a system application.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:
|
||||
* 1.Mandatory parameters are left unspecified;
|
||||
* 2.Incorrect parameter types.
|
||||
* @throws { BusinessError } 5400102 - Operation not allowed. For example, the input URI is not one for haptics.
|
||||
* @throws { BusinessError } 5400103 - I/O error.
|
||||
* @throws { BusinessError } 20700003 - Unsupported operation.
|
||||
* @syscap SystemCapability.Multimedia.SystemSound.Core
|
||||
* @systemapi
|
||||
* @since 13
|
||||
*/
|
||||
openToneHaptics(context: BaseContext, hapticsUri: string): Promise<number>;
|
||||
}
|
||||
|
||||
/**
|
||||
|
96
api/@ohos.multimodalInput.gestureEvent.d.ts
vendored
96
api/@ohos.multimodalInput.gestureEvent.d.ts
vendored
@ -191,6 +191,102 @@ export declare interface ThreeFingersTap {
|
||||
type: ActionType;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines a touchscreen gesture event.
|
||||
*
|
||||
* @interface TouchGestureEvent
|
||||
* @syscap SystemCapability.MultimodalInput.Input.Core
|
||||
* @systemapi hide for inner use
|
||||
* @since 13
|
||||
*/
|
||||
export declare interface TouchGestureEvent {
|
||||
/**
|
||||
* Gesture action type.
|
||||
*
|
||||
* @type { TouchGestureAction }
|
||||
* @syscap SystemCapability.MultimodalInput.Input.Core
|
||||
* @systemapi hide for inner use
|
||||
* @since 13
|
||||
*/
|
||||
action: TouchGestureAction;
|
||||
/**
|
||||
* Collection of all touch points upon completion of the gesture.
|
||||
*
|
||||
* @type { Touch[] }
|
||||
* @syscap SystemCapability.MultimodalInput.Input.Core
|
||||
* @systemapi hide for inner use
|
||||
* @since 13
|
||||
*/
|
||||
touches: Touch[];
|
||||
}
|
||||
|
||||
/**
|
||||
* Enumerates touchscreen gesture action types.
|
||||
*
|
||||
* @enum { number }
|
||||
* @syscap SystemCapability.MultimodalInput.Input.Core
|
||||
* @systemapi hide for inner use
|
||||
* @since 13
|
||||
*/
|
||||
export declare enum TouchGestureAction {
|
||||
/**
|
||||
* Swiping down with multiple fingers.
|
||||
*
|
||||
* @syscap SystemCapability.MultimodalInput.Input.Core
|
||||
* @systemapi hide for inner use
|
||||
* @since 13
|
||||
*/
|
||||
SWIPE_DOWN = 0,
|
||||
/**
|
||||
* Swiping up with multiple fingers.
|
||||
*
|
||||
* @syscap SystemCapability.MultimodalInput.Input.Core
|
||||
* @systemapi hide for inner use
|
||||
* @since 13
|
||||
*/
|
||||
SWIPE_UP,
|
||||
/**
|
||||
* Swiping left with multiple fingers.
|
||||
*
|
||||
* @syscap SystemCapability.MultimodalInput.Input.Core
|
||||
* @systemapi hide for inner use
|
||||
* @since 13
|
||||
*/
|
||||
SWIPE_LEFT,
|
||||
/**
|
||||
* Swiping right with multiple fingers.
|
||||
*
|
||||
* @syscap SystemCapability.MultimodalInput.Input.Core
|
||||
* @systemapi hide for inner use
|
||||
* @since 13
|
||||
*/
|
||||
SWIPE_RIGHT,
|
||||
/**
|
||||
* Multi-finger pinching closed.
|
||||
*
|
||||
* @syscap SystemCapability.MultimodalInput.Input.Core
|
||||
* @systemapi hide for inner use
|
||||
* @since 13
|
||||
*/
|
||||
PINCH_CLOSED,
|
||||
/**
|
||||
* Multi-finger pinching opened.
|
||||
*
|
||||
* @syscap SystemCapability.MultimodalInput.Input.Core
|
||||
* @systemapi hide for inner use
|
||||
* @since 13
|
||||
*/
|
||||
PINCH_OPENED,
|
||||
/**
|
||||
* The gesture ends.
|
||||
*
|
||||
* @syscap SystemCapability.MultimodalInput.Input.Core
|
||||
* @systemapi hide for inner use
|
||||
* @since 13
|
||||
*/
|
||||
GESTURE_END
|
||||
}
|
||||
|
||||
/**
|
||||
* Gesture action type
|
||||
*
|
||||
|
77
api/@ohos.multimodalInput.inputConsumer.d.ts
vendored
77
api/@ohos.multimodalInput.inputConsumer.d.ts
vendored
@ -25,8 +25,7 @@ import { Callback } from './@ohos.base';
|
||||
*
|
||||
* @namespace inputConsumer
|
||||
* @syscap SystemCapability.MultimodalInput.Input.InputConsumer
|
||||
* @systemapi hide for inner use
|
||||
* @since 8
|
||||
* @since 13
|
||||
*/
|
||||
declare namespace inputConsumer {
|
||||
/**
|
||||
@ -89,6 +88,42 @@ declare namespace inputConsumer {
|
||||
isRepeat?: boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* Defines the shortcut key structure.
|
||||
*
|
||||
* @typedef HotkeyOptions
|
||||
* @syscap SystemCapability.MultimodalInput.Input.InputConsumer
|
||||
* @since 13
|
||||
*/
|
||||
interface HotkeyOptions {
|
||||
/**
|
||||
* Defines modifier keys. One or two modifier keys are supported.
|
||||
*
|
||||
* @type { Array<number> }
|
||||
* @syscap SystemCapability.MultimodalInput.Input.InputConsumer
|
||||
* @since 13
|
||||
*/
|
||||
preKeys: Array<number>;
|
||||
|
||||
/**
|
||||
* Defines modified keys.
|
||||
*
|
||||
* @type { number }
|
||||
* @syscap SystemCapability.MultimodalInput.Input.InputConsumer
|
||||
* @since 13
|
||||
*/
|
||||
finalKey: number;
|
||||
|
||||
/**
|
||||
* Whether to report repeated key events. By default, the value is true if it is left unspecified.
|
||||
*
|
||||
* @type { ?boolean }
|
||||
* @syscap SystemCapability.MultimodalInput.Input.InputConsumer
|
||||
* @since 13
|
||||
*/
|
||||
isRepeat?: boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* Shield mode.
|
||||
*
|
||||
@ -194,6 +229,44 @@ declare namespace inputConsumer {
|
||||
* @since 11
|
||||
*/
|
||||
function getShieldStatus(shieldMode: ShieldMode): boolean;
|
||||
|
||||
/**
|
||||
* Obtains all system hotkeys. This API uses a promise to return the result.
|
||||
*
|
||||
* @Returns { Promise<Array<HotkeyOptions>> } All system hotkeys.
|
||||
* @syscap SystemCapability.MultimodalInput.Input.InputConsumer
|
||||
* @since 13
|
||||
*/
|
||||
function getAllSystemHotkeys(): Promise<Array<HotkeyOptions>>;
|
||||
|
||||
/**
|
||||
* Listening for hotkey event changes.
|
||||
*
|
||||
* @param { 'hotkeyChange' } type - Type of the hotkey events.
|
||||
* @param { HotkeyOptions } hotkeyOptions - hotkey events.
|
||||
* @param { Callback<HotkeyOptions> } callback - Callback used to return hotkey events.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* <br>2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @throws { BusinessError } 4200002 - The hotkey has been used by the system. You can call the {@Link
|
||||
* <br> GetAllSystemHotkeys} interface to query all system hotkeys.
|
||||
* @throws { BusinessError } 4200003 - The hotkey has been subscribed to by another.
|
||||
* @syscap SystemCapability.MultimodalInput.Input.InputConsumer
|
||||
* @since 13
|
||||
*/
|
||||
function on(type: 'hotkeyChange', hotkeyOptions: HotkeyOptions, callback: Callback<HotkeyOptions>): void
|
||||
|
||||
/**
|
||||
* Unsubscribe from hotkey event changes.
|
||||
*
|
||||
* @param { 'hotkeyChange' } type - Type of the hotkey events.
|
||||
* @param { HotkeyOptions } hotkeyOptions - Hotkey events.
|
||||
* @param { Callback<HotkeyOptions> } callback - Callback used to return hotkey events.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified;
|
||||
* <br>2. Incorrect parameter types; 3. Parameter verification failed.
|
||||
* @syscap SystemCapability.MultimodalInput.Input.InputConsumer
|
||||
* @since 13
|
||||
*/
|
||||
function off(type: 'hotkeyChange', hotkeyOptions: HotkeyOptions, callback?: Callback<HotkeyOptions>): void
|
||||
}
|
||||
|
||||
export default inputConsumer;
|
9
api/@ohos.multimodalInput.inputDevice.d.ts
vendored
9
api/@ohos.multimodalInput.inputDevice.d.ts
vendored
@ -627,6 +627,15 @@ declare namespace inputDevice {
|
||||
* @since 10
|
||||
*/
|
||||
function getKeyboardRepeatRate(): Promise<number>;
|
||||
|
||||
/**
|
||||
* Obtains the interval since the last input.
|
||||
*
|
||||
* @returns { Promise<number> } Promise used to return the interval since the last input.
|
||||
* @syscap SystemCapability.MultimodalInput.Input.InputDevice
|
||||
* @since 13
|
||||
*/
|
||||
function getIntervalSinceLastInput(): Promise<number>;
|
||||
}
|
||||
|
||||
export default inputDevice;
|
74
api/@ohos.multimodalInput.inputMonitor.d.ts
vendored
74
api/@ohos.multimodalInput.inputMonitor.d.ts
vendored
@ -23,7 +23,7 @@ import { MouseEvent } from './@ohos.multimodalInput.mouseEvent';
|
||||
import type display from './@ohos.display';
|
||||
import type { TouchEvent } from './@ohos.multimodalInput.touchEvent';
|
||||
import type { Rotate, Pinch, ThreeFingersSwipe, FourFingersSwipe, SwipeInward } from './@ohos.multimodalInput.gestureEvent';
|
||||
import type { ThreeFingersTap } from './@ohos.multimodalInput.gestureEvent';
|
||||
import type { ThreeFingersTap, TouchGestureEvent } from './@ohos.multimodalInput.gestureEvent';
|
||||
import type { FingerprintEvent } from './@ohos.multimodalInput.shortKey';
|
||||
|
||||
/**
|
||||
@ -462,5 +462,77 @@ declare namespace inputMonitor {
|
||||
* @since 12
|
||||
*/
|
||||
function off(type: 'swipeInward', receiver?: Callback<SwipeInward>): void;
|
||||
|
||||
/**
|
||||
* Enables listening touchscreen swipe gesture events.
|
||||
*
|
||||
* @permission ohos.permission.INPUT_MONITORING
|
||||
* @param { 'touchscreenSwipe' } type - Touchscreen gesture type.
|
||||
* @param { number } fingers - Number of fingers.
|
||||
* @param { Callback<TouchGestureEvent> } receiver - Callback used to receive reported data.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 202 - Caller is not a system application.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:
|
||||
* 1.Mandatory parameters are left unspecified;
|
||||
* 2.Incorrect parameter types.
|
||||
* @syscap SystemCapability.MultimodalInput.Input.InputMonitor
|
||||
* @systemapi hide for inner use
|
||||
* @since 13
|
||||
*/
|
||||
function on(type: 'touchscreenSwipe', fingers: number, receiver: Callback<TouchGestureEvent>): void;
|
||||
|
||||
/**
|
||||
* Disables listening touchscreen swipe gesture events.
|
||||
*
|
||||
* @permission ohos.permission.INPUT_MONITORING
|
||||
* @param { 'touchscreenSwipe' } type - Touchscreen gesture type.
|
||||
* @param { number } fingers - Number of fingers.
|
||||
* @param { Callback<TouchGestureEvent> } receiver - Callback used to receive reported data.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 202 - Caller is not a system application.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:
|
||||
* 1.Mandatory parameters are left unspecified;
|
||||
* 2.Incorrect parameter types.
|
||||
* @syscap SystemCapability.MultimodalInput.Input.InputMonitor
|
||||
* @systemapi hide for inner use
|
||||
* @since 13
|
||||
*/
|
||||
function off(type: 'touchscreenSwipe', fingers: number, receiver?: Callback<TouchGestureEvent>): void;
|
||||
|
||||
/**
|
||||
* Enables listening touchscreen pinch gesture events.
|
||||
*
|
||||
* @permission ohos.permission.INPUT_MONITORING
|
||||
* @param { 'touchscreenPinch' } type - Touch screen gesture type.
|
||||
* @param { number } fingers - Number of fingers.
|
||||
* @param { Callback<TouchGestureEvent> } receiver - Callback used to receive reported data.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 202 - Caller is not a system application.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:
|
||||
* 1.Mandatory parameters are left unspecified;
|
||||
* 2.Incorrect parameter types.
|
||||
* @syscap SystemCapability.MultimodalInput.Input.InputMonitor
|
||||
* @systemapi hide for inner use
|
||||
* @since 13
|
||||
*/
|
||||
function on(type: 'touchscreenPinch', fingers: number, receiver: Callback<TouchGestureEvent>): void;
|
||||
|
||||
/**
|
||||
* Disables listening touchscreen pinch gesture events.
|
||||
*
|
||||
* @permission ohos.permission.INPUT_MONITORING
|
||||
* @param { 'touchscreenPinch' } type - Touchscreen gesture type.
|
||||
* @param { number } fingers - Number of fingers.
|
||||
* @param { Callback<TouchGestureEvent> } receiver - Callback used to receive reported data.
|
||||
* @throws { BusinessError } 201 - Permission denied.
|
||||
* @throws { BusinessError } 202 - Caller is not a system application.
|
||||
* @throws { BusinessError } 401 - Parameter error. Possible causes:
|
||||
* 1.Mandatory parameters are left unspecified;
|
||||
* 2.Incorrect parameter types.
|
||||
* @syscap SystemCapability.MultimodalInput.Input.InputMonitor
|
||||
* @systemapi hide for inner use
|
||||
* @since 13
|
||||
*/
|
||||
function off(type: 'touchscreenPinch', fingers: number, receiver?: Callback<TouchGestureEvent>): void;
|
||||
}
|
||||
export default inputMonitor;
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user