161847f8eSopenharmony_ci/*
261847f8eSopenharmony_ci * Copyright (c) 2020-2023 Huawei Device Co., Ltd.
361847f8eSopenharmony_ci * Licensed under the Apache License, Version 2.0 (the "License");
461847f8eSopenharmony_ci * you may not use this file except in compliance with the License.
561847f8eSopenharmony_ci * You may obtain a copy of the License at
661847f8eSopenharmony_ci *
761847f8eSopenharmony_ci *     http://www.apache.org/licenses/LICENSE-2.0
861847f8eSopenharmony_ci *
961847f8eSopenharmony_ci * Unless required by applicable law or agreed to in writing, software
1061847f8eSopenharmony_ci * distributed under the License is distributed on an "AS IS" BASIS,
1161847f8eSopenharmony_ci * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1261847f8eSopenharmony_ci * See the License for the specific language governing permissions and
1361847f8eSopenharmony_ci * limitations under the License.
1461847f8eSopenharmony_ci */
1561847f8eSopenharmony_ci
1661847f8eSopenharmony_ci/**
1761847f8eSopenharmony_ci * @file
1861847f8eSopenharmony_ci * @kit ArkUI
1961847f8eSopenharmony_ci */
2061847f8eSopenharmony_ci
2161847f8eSopenharmony_ci/**
2261847f8eSopenharmony_ci * Defines the animator options.
2361847f8eSopenharmony_ci * @interface AnimatorOptions
2461847f8eSopenharmony_ci * @syscap SystemCapability.ArkUI.ArkUI.Full
2561847f8eSopenharmony_ci * @since 6
2661847f8eSopenharmony_ci */
2761847f8eSopenharmony_ci/**
2861847f8eSopenharmony_ci * Defines the animator options.
2961847f8eSopenharmony_ci * @interface AnimatorOptions
3061847f8eSopenharmony_ci * @syscap SystemCapability.ArkUI.ArkUI.Full
3161847f8eSopenharmony_ci * @crossplatform
3261847f8eSopenharmony_ci * @since 10
3361847f8eSopenharmony_ci */
3461847f8eSopenharmony_ci/**
3561847f8eSopenharmony_ci * Defines the animator options.
3661847f8eSopenharmony_ci * @interface AnimatorOptions
3761847f8eSopenharmony_ci * @syscap SystemCapability.ArkUI.ArkUI.Full
3861847f8eSopenharmony_ci * @crossplatform
3961847f8eSopenharmony_ci * @atomicservice
4061847f8eSopenharmony_ci * @since 11
4161847f8eSopenharmony_ci */
4261847f8eSopenharmony_ciexport interface AnimatorOptions {
4361847f8eSopenharmony_ci  /**
4461847f8eSopenharmony_ci   * Duration of the animation, in milliseconds.
4561847f8eSopenharmony_ci   * The default value is 0.
4661847f8eSopenharmony_ci   * @type {number}
4761847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
4861847f8eSopenharmony_ci   * @since 6
4961847f8eSopenharmony_ci   */
5061847f8eSopenharmony_ci  /**
5161847f8eSopenharmony_ci   * Duration of the animation, in milliseconds.
5261847f8eSopenharmony_ci   * The default value is 0.
5361847f8eSopenharmony_ci   * @type {number}
5461847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
5561847f8eSopenharmony_ci   * @crossplatform
5661847f8eSopenharmony_ci   * @since 10
5761847f8eSopenharmony_ci   */
5861847f8eSopenharmony_ci  /**
5961847f8eSopenharmony_ci   * Duration of the animation, in milliseconds.
6061847f8eSopenharmony_ci   * The default value is 0.
6161847f8eSopenharmony_ci   * @type {number}
6261847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
6361847f8eSopenharmony_ci   * @crossplatform
6461847f8eSopenharmony_ci   * @atomicservice
6561847f8eSopenharmony_ci   * @since 11
6661847f8eSopenharmony_ci   */
6761847f8eSopenharmony_ci  duration: number;
6861847f8eSopenharmony_ci
6961847f8eSopenharmony_ci  /**
7061847f8eSopenharmony_ci   * Time curve of the animation. For details about the supported types.
7161847f8eSopenharmony_ci   * linear The animation speed keeps unchanged.
7261847f8eSopenharmony_ci   * ease The animation starts and ends at a low speed, cubic-bezier(0.25, 0.1, 0.25, 1.0).
7361847f8eSopenharmony_ci   * ease-in The animation starts at a low speed, cubic-bezier(0.42, 0.0, 1.0, 1.0).
7461847f8eSopenharmony_ci   * ease-out The animation ends at a low speed, cubic-bezier(0.0, 0.0, 0.58, 1.0).
7561847f8eSopenharmony_ci   * ease-in-out The animation starts and ends at a low speed, cubic-bezier(0.42, 0.0, 0.58, 1.0).
7661847f8eSopenharmony_ci   * fast-out-slow-in Standard curve, cubic-bezier(0.4, 0.0, 0.2, 1.0).
7761847f8eSopenharmony_ci   * linear-out-slow-in Deceleration curve, cubic-bezier(0.0, 0.0, 0.2, 1.0).
7861847f8eSopenharmony_ci   * fast-out-linear-in Acceleration curve, cubic-bezier(0.4, 0.0, 1.0, 1.0).
7961847f8eSopenharmony_ci   * friction Damping curve, cubic-bezier(0.2, 0.0, 0.2, 1.0).
8061847f8eSopenharmony_ci   * extreme-deceleration Extreme deceleration curve, cubic-bezier(0.0, 0.0, 0.0, 1.0).
8161847f8eSopenharmony_ci   * sharp Sharp curve, cubic-bezier(0.33, 0.0, 0.67, 1.0).
8261847f8eSopenharmony_ci   * rhythm Rhythm curve, cubic-bezier(0.7, 0.0, 0.2, 1.0).
8361847f8eSopenharmony_ci   * smooth Smooth curve, cubic-bezier(0.4, 0.0, 0.4, 1.0).
8461847f8eSopenharmony_ci   * cubic-bezier(x1, y1, x2, y2) You can customize an animation speed curve in the cubic-bezier() function. The x and y values of each input parameter must be between 0 and 1.
8561847f8eSopenharmony_ci   * Step curve. The number must be set and only an integer is supported, step-position is optional. It can be set to start or end. The default value is end.
8661847f8eSopenharmony_ci   * The default value is ease.
8761847f8eSopenharmony_ci   * @type {string}
8861847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
8961847f8eSopenharmony_ci   * @since 6
9061847f8eSopenharmony_ci   */
9161847f8eSopenharmony_ci  /**
9261847f8eSopenharmony_ci   * Time curve of the animation. For details about the supported types.
9361847f8eSopenharmony_ci   * linear The animation speed keeps unchanged.
9461847f8eSopenharmony_ci   * ease The animation starts and ends at a low speed, cubic-bezier(0.25, 0.1, 0.25, 1.0).
9561847f8eSopenharmony_ci   * ease-in The animation starts at a low speed, cubic-bezier(0.42, 0.0, 1.0, 1.0).
9661847f8eSopenharmony_ci   * ease-out The animation ends at a low speed, cubic-bezier(0.0, 0.0, 0.58, 1.0).
9761847f8eSopenharmony_ci   * ease-in-out The animation starts and ends at a low speed, cubic-bezier(0.42, 0.0, 0.58, 1.0).
9861847f8eSopenharmony_ci   * fast-out-slow-in Standard curve, cubic-bezier(0.4, 0.0, 0.2, 1.0).
9961847f8eSopenharmony_ci   * linear-out-slow-in Deceleration curve, cubic-bezier(0.0, 0.0, 0.2, 1.0).
10061847f8eSopenharmony_ci   * fast-out-linear-in Acceleration curve, cubic-bezier(0.4, 0.0, 1.0, 1.0).
10161847f8eSopenharmony_ci   * friction Damping curve, cubic-bezier(0.2, 0.0, 0.2, 1.0).
10261847f8eSopenharmony_ci   * extreme-deceleration Extreme deceleration curve, cubic-bezier(0.0, 0.0, 0.0, 1.0).
10361847f8eSopenharmony_ci   * sharp Sharp curve, cubic-bezier(0.33, 0.0, 0.67, 1.0).
10461847f8eSopenharmony_ci   * rhythm Rhythm curve, cubic-bezier(0.7, 0.0, 0.2, 1.0).
10561847f8eSopenharmony_ci   * smooth Smooth curve, cubic-bezier(0.4, 0.0, 0.4, 1.0).
10661847f8eSopenharmony_ci   * cubic-bezier(x1, y1, x2, y2) You can customize an animation speed curve in the cubic-bezier() function. The x and y values of each input parameter must be between 0 and 1.
10761847f8eSopenharmony_ci   * Step curve. The number must be set and only an integer is supported, step-position is optional. It can be set to start or end. The default value is end.
10861847f8eSopenharmony_ci   * The default value is ease.
10961847f8eSopenharmony_ci   * @type {string}
11061847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
11161847f8eSopenharmony_ci   * @crossplatform
11261847f8eSopenharmony_ci   * @since 10
11361847f8eSopenharmony_ci   */
11461847f8eSopenharmony_ci  /**
11561847f8eSopenharmony_ci   * Time curve of the animation. For details about the supported types.
11661847f8eSopenharmony_ci   * linear The animation speed keeps unchanged.
11761847f8eSopenharmony_ci   * ease The animation starts and ends at a low speed, cubic-bezier(0.25, 0.1, 0.25, 1.0).
11861847f8eSopenharmony_ci   * ease-in The animation starts at a low speed, cubic-bezier(0.42, 0.0, 1.0, 1.0).
11961847f8eSopenharmony_ci   * ease-out The animation ends at a low speed, cubic-bezier(0.0, 0.0, 0.58, 1.0).
12061847f8eSopenharmony_ci   * ease-in-out The animation starts and ends at a low speed, cubic-bezier(0.42, 0.0, 0.58, 1.0).
12161847f8eSopenharmony_ci   * fast-out-slow-in Standard curve, cubic-bezier(0.4, 0.0, 0.2, 1.0).
12261847f8eSopenharmony_ci   * linear-out-slow-in Deceleration curve, cubic-bezier(0.0, 0.0, 0.2, 1.0).
12361847f8eSopenharmony_ci   * fast-out-linear-in Acceleration curve, cubic-bezier(0.4, 0.0, 1.0, 1.0).
12461847f8eSopenharmony_ci   * friction Damping curve, cubic-bezier(0.2, 0.0, 0.2, 1.0).
12561847f8eSopenharmony_ci   * extreme-deceleration Extreme deceleration curve, cubic-bezier(0.0, 0.0, 0.0, 1.0).
12661847f8eSopenharmony_ci   * sharp Sharp curve, cubic-bezier(0.33, 0.0, 0.67, 1.0).
12761847f8eSopenharmony_ci   * rhythm Rhythm curve, cubic-bezier(0.7, 0.0, 0.2, 1.0).
12861847f8eSopenharmony_ci   * smooth Smooth curve, cubic-bezier(0.4, 0.0, 0.4, 1.0).
12961847f8eSopenharmony_ci   * cubic-bezier(x1, y1, x2, y2) You can customize an animation speed curve in the cubic-bezier() function. The x and y values of each input parameter must be between 0 and 1.
13061847f8eSopenharmony_ci   * Step curve. The number must be set and only an integer is supported, step-position is optional. It can be set to start or end. The default value is end.
13161847f8eSopenharmony_ci   * interpolating-spring(velocity, mass, stiffness, damping), interpolating spring curve.
13261847f8eSopenharmony_ci   * The default value is ease.
13361847f8eSopenharmony_ci   * @type {string}
13461847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
13561847f8eSopenharmony_ci   * @crossplatform
13661847f8eSopenharmony_ci   * @atomicservice
13761847f8eSopenharmony_ci   * @since 11
13861847f8eSopenharmony_ci   */
13961847f8eSopenharmony_ci  easing: string;
14061847f8eSopenharmony_ci
14161847f8eSopenharmony_ci  /**
14261847f8eSopenharmony_ci   * Delay for the animation start. The default value indicates no delay.
14361847f8eSopenharmony_ci   * The default value is 0.
14461847f8eSopenharmony_ci   * @type {number}
14561847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
14661847f8eSopenharmony_ci   * @since 6
14761847f8eSopenharmony_ci   */
14861847f8eSopenharmony_ci  /**
14961847f8eSopenharmony_ci   * Delay for the animation start. The default value indicates no delay.
15061847f8eSopenharmony_ci   * The default value is 0.
15161847f8eSopenharmony_ci   * @type {number}
15261847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
15361847f8eSopenharmony_ci   * @crossplatform
15461847f8eSopenharmony_ci   * @since 10
15561847f8eSopenharmony_ci   */
15661847f8eSopenharmony_ci  /**
15761847f8eSopenharmony_ci   * Delay for the animation start. The default value indicates no delay.
15861847f8eSopenharmony_ci   * The default value is 0.
15961847f8eSopenharmony_ci   * @type {number}
16061847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
16161847f8eSopenharmony_ci   * @crossplatform
16261847f8eSopenharmony_ci   * @atomicservice
16361847f8eSopenharmony_ci   * @since 11
16461847f8eSopenharmony_ci   */
16561847f8eSopenharmony_ci  delay: number;
16661847f8eSopenharmony_ci
16761847f8eSopenharmony_ci  /**
16861847f8eSopenharmony_ci   * Whether to resume to the initial state after the animation is executed.
16961847f8eSopenharmony_ci   * none: The initial state is restored after the animation is executed.
17061847f8eSopenharmony_ci   * forwards: The state at the end of the animation (defined in the last key frame) is retained after the animation is executed.
17161847f8eSopenharmony_ci   * @type {"none" | "forwards" | "backwards" | "both"}
17261847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
17361847f8eSopenharmony_ci   * @since 6
17461847f8eSopenharmony_ci   */
17561847f8eSopenharmony_ci  /**
17661847f8eSopenharmony_ci   * Whether to resume to the initial state after the animation is executed.
17761847f8eSopenharmony_ci   * none: The initial state is restored after the animation is executed.
17861847f8eSopenharmony_ci   * forwards: The state at the end of the animation (defined in the last key frame) is retained after the animation is executed.
17961847f8eSopenharmony_ci   * @type {"none" | "forwards" | "backwards" | "both"}
18061847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
18161847f8eSopenharmony_ci   * @crossplatform
18261847f8eSopenharmony_ci   * @since 10
18361847f8eSopenharmony_ci   */
18461847f8eSopenharmony_ci  /**
18561847f8eSopenharmony_ci   * Whether to resume to the initial state after the animation is executed.
18661847f8eSopenharmony_ci   * none: The initial state is restored after the animation is executed.
18761847f8eSopenharmony_ci   * forwards: The state at the end of the animation (defined in the last key frame) is retained after the animation is executed.
18861847f8eSopenharmony_ci   * @type {"none" | "forwards" | "backwards" | "both"}
18961847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
19061847f8eSopenharmony_ci   * @crossplatform
19161847f8eSopenharmony_ci   * @atomicservice
19261847f8eSopenharmony_ci   * @since 11
19361847f8eSopenharmony_ci   */
19461847f8eSopenharmony_ci  fill: "none" | "forwards" | "backwards" | "both";
19561847f8eSopenharmony_ci
19661847f8eSopenharmony_ci  /**
19761847f8eSopenharmony_ci   * The animation playback mode.
19861847f8eSopenharmony_ci   * The default value is "normal".
19961847f8eSopenharmony_ci   * @type {"normal" | "reverse" | "alternate" | "alternate-reverse"}
20061847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
20161847f8eSopenharmony_ci   * @since 6
20261847f8eSopenharmony_ci   */
20361847f8eSopenharmony_ci  /**
20461847f8eSopenharmony_ci   * The animation playback mode.
20561847f8eSopenharmony_ci   * The default value is "normal".
20661847f8eSopenharmony_ci   * @type {"normal" | "reverse" | "alternate" | "alternate-reverse"}
20761847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
20861847f8eSopenharmony_ci   * @crossplatform
20961847f8eSopenharmony_ci   * @since 10
21061847f8eSopenharmony_ci   */
21161847f8eSopenharmony_ci  /**
21261847f8eSopenharmony_ci   * The animation playback mode.
21361847f8eSopenharmony_ci   * The default value is "normal".
21461847f8eSopenharmony_ci   * @type {"normal" | "reverse" | "alternate" | "alternate-reverse"}
21561847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
21661847f8eSopenharmony_ci   * @crossplatform
21761847f8eSopenharmony_ci   * @atomicservice
21861847f8eSopenharmony_ci   * @since 11
21961847f8eSopenharmony_ci   */
22061847f8eSopenharmony_ci  direction: "normal" | "reverse" | "alternate" | "alternate-reverse";
22161847f8eSopenharmony_ci
22261847f8eSopenharmony_ci  /**
22361847f8eSopenharmony_ci   * Number of times the animation will be played. number indicates a fixed number of playback operations, and -1 an unlimited number of playback operations.
22461847f8eSopenharmony_ci   * The default value is 1.
22561847f8eSopenharmony_ci   * @type {number}
22661847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
22761847f8eSopenharmony_ci   * @since 6
22861847f8eSopenharmony_ci   */
22961847f8eSopenharmony_ci  /**
23061847f8eSopenharmony_ci   * Number of times the animation will be played. number indicates a fixed number of playback operations, and -1 an unlimited number of playback operations.
23161847f8eSopenharmony_ci   * The default value is 1.
23261847f8eSopenharmony_ci   * @type {number}
23361847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
23461847f8eSopenharmony_ci   * @crossplatform
23561847f8eSopenharmony_ci   * @since 10
23661847f8eSopenharmony_ci   */
23761847f8eSopenharmony_ci  /**
23861847f8eSopenharmony_ci   * Number of times the animation will be played. number indicates a fixed number of playback operations, and -1 an unlimited number of playback operations.
23961847f8eSopenharmony_ci   * The default value is 1.
24061847f8eSopenharmony_ci   * @type {number}
24161847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
24261847f8eSopenharmony_ci   * @crossplatform
24361847f8eSopenharmony_ci   * @atomicservice
24461847f8eSopenharmony_ci   * @since 11
24561847f8eSopenharmony_ci   */
24661847f8eSopenharmony_ci  iterations: number;
24761847f8eSopenharmony_ci
24861847f8eSopenharmony_ci  /**
24961847f8eSopenharmony_ci   * Starting point of animator interpolation.
25061847f8eSopenharmony_ci   * The default value is 0.
25161847f8eSopenharmony_ci   * @type {number}
25261847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
25361847f8eSopenharmony_ci   * @since 6
25461847f8eSopenharmony_ci   */
25561847f8eSopenharmony_ci  /**
25661847f8eSopenharmony_ci   * Starting point of animator interpolation.
25761847f8eSopenharmony_ci   * The default value is 0.
25861847f8eSopenharmony_ci   * @type {number}
25961847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
26061847f8eSopenharmony_ci   * @crossplatform
26161847f8eSopenharmony_ci   * @since 10
26261847f8eSopenharmony_ci   */
26361847f8eSopenharmony_ci  /**
26461847f8eSopenharmony_ci   * Starting point of animator interpolation.
26561847f8eSopenharmony_ci   * The default value is 0.
26661847f8eSopenharmony_ci   * @type {number}
26761847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
26861847f8eSopenharmony_ci   * @crossplatform
26961847f8eSopenharmony_ci   * @atomicservice
27061847f8eSopenharmony_ci   * @since 11
27161847f8eSopenharmony_ci   */
27261847f8eSopenharmony_ci  begin: number;
27361847f8eSopenharmony_ci
27461847f8eSopenharmony_ci  /**
27561847f8eSopenharmony_ci   * Ending point of Dynamic Interpolation
27661847f8eSopenharmony_ci   * The default value is 1.
27761847f8eSopenharmony_ci   * @type {number}
27861847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
27961847f8eSopenharmony_ci   * @since 6
28061847f8eSopenharmony_ci   */
28161847f8eSopenharmony_ci  /**
28261847f8eSopenharmony_ci   * Ending point of Dynamic Interpolation
28361847f8eSopenharmony_ci   * The default value is 1.
28461847f8eSopenharmony_ci   * @type {number}
28561847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
28661847f8eSopenharmony_ci   * @crossplatform
28761847f8eSopenharmony_ci   * @since 10
28861847f8eSopenharmony_ci   */
28961847f8eSopenharmony_ci  /**
29061847f8eSopenharmony_ci   * Ending point of Dynamic Interpolation
29161847f8eSopenharmony_ci   * The default value is 1.
29261847f8eSopenharmony_ci   * @type {number}
29361847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
29461847f8eSopenharmony_ci   * @crossplatform
29561847f8eSopenharmony_ci   * @atomicservice
29661847f8eSopenharmony_ci   * @since 11
29761847f8eSopenharmony_ci   */
29861847f8eSopenharmony_ci  end: number;
29961847f8eSopenharmony_ci}
30061847f8eSopenharmony_ci
30161847f8eSopenharmony_ci/**
30261847f8eSopenharmony_ci * Defines the Animator result interface.
30361847f8eSopenharmony_ci * @interface AnimatorResult
30461847f8eSopenharmony_ci * @syscap SystemCapability.ArkUI.ArkUI.Full
30561847f8eSopenharmony_ci * @since 6
30661847f8eSopenharmony_ci */
30761847f8eSopenharmony_ci/**
30861847f8eSopenharmony_ci * Defines the Animator result interface.
30961847f8eSopenharmony_ci * @interface AnimatorResult
31061847f8eSopenharmony_ci * @syscap SystemCapability.ArkUI.ArkUI.Full
31161847f8eSopenharmony_ci * @crossplatform
31261847f8eSopenharmony_ci * @since 10
31361847f8eSopenharmony_ci */
31461847f8eSopenharmony_ci/**
31561847f8eSopenharmony_ci * Defines the Animator result interface.
31661847f8eSopenharmony_ci * @interface AnimatorResult
31761847f8eSopenharmony_ci * @syscap SystemCapability.ArkUI.ArkUI.Full
31861847f8eSopenharmony_ci * @crossplatform
31961847f8eSopenharmony_ci * @atomicservice
32061847f8eSopenharmony_ci * @since 11
32161847f8eSopenharmony_ci */
32261847f8eSopenharmony_ciexport interface AnimatorResult {
32361847f8eSopenharmony_ci  /**
32461847f8eSopenharmony_ci   * Update the options for current animator.
32561847f8eSopenharmony_ci   * @param { AnimatorOptions } options - Options.
32661847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
32761847f8eSopenharmony_ci   * @since 6
32861847f8eSopenharmony_ci   * @deprecated since 9
32961847f8eSopenharmony_ci   * @useinstead ohos.animator.reset
33061847f8eSopenharmony_ci   */
33161847f8eSopenharmony_ci  update(options: AnimatorOptions): void;
33261847f8eSopenharmony_ci
33361847f8eSopenharmony_ci  /**
33461847f8eSopenharmony_ci   * Reset the options for current animator.
33561847f8eSopenharmony_ci   * @param { AnimatorOptions } options - Options.
33661847f8eSopenharmony_ci   * @throws { BusinessError } 401 - Parameter error. Possible causes: 
33761847f8eSopenharmony_ci   * <br> 1. Mandatory parameters are left unspecified.
33861847f8eSopenharmony_ci   * <br> 2. Incorrect parameters types.
33961847f8eSopenharmony_ci   * <br> 3. Parameter verification failed.
34061847f8eSopenharmony_ci   * @throws { BusinessError } 100001 - The specified page is not found or the object property list is not obtained.
34161847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
34261847f8eSopenharmony_ci   * @since 9
34361847f8eSopenharmony_ci   */
34461847f8eSopenharmony_ci  /**
34561847f8eSopenharmony_ci   * Reset the options for current animator.
34661847f8eSopenharmony_ci   * @param { AnimatorOptions } options - Options.
34761847f8eSopenharmony_ci   * @throws { BusinessError } 401 - Parameter error. Possible causes: 
34861847f8eSopenharmony_ci   * <br> 1. Mandatory parameters are left unspecified.
34961847f8eSopenharmony_ci   * <br> 2. Incorrect parameters types.
35061847f8eSopenharmony_ci   * <br> 3. Parameter verification failed.
35161847f8eSopenharmony_ci   * @throws { BusinessError } 100001 - The specified page is not found or the object property list is not obtained.
35261847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
35361847f8eSopenharmony_ci   * @crossplatform
35461847f8eSopenharmony_ci   * @since 10
35561847f8eSopenharmony_ci   */
35661847f8eSopenharmony_ci  /**
35761847f8eSopenharmony_ci   * Reset the options for current animator.
35861847f8eSopenharmony_ci   * @param { AnimatorOptions } options - Options.
35961847f8eSopenharmony_ci   * @throws { BusinessError } 401 - Parameter error. Possible causes: 
36061847f8eSopenharmony_ci   * <br> 1. Mandatory parameters are left unspecified.
36161847f8eSopenharmony_ci   * <br> 2. Incorrect parameters types.
36261847f8eSopenharmony_ci   * <br> 3. Parameter verification failed.
36361847f8eSopenharmony_ci   * @throws { BusinessError } 100001 - The specified page is not found or the object property list is not obtained.
36461847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
36561847f8eSopenharmony_ci   * @crossplatform
36661847f8eSopenharmony_ci   * @atomicservice
36761847f8eSopenharmony_ci   * @since 11
36861847f8eSopenharmony_ci   */
36961847f8eSopenharmony_ci  reset(options: AnimatorOptions): void;
37061847f8eSopenharmony_ci
37161847f8eSopenharmony_ci  /**
37261847f8eSopenharmony_ci   * Starts the animation.
37361847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
37461847f8eSopenharmony_ci   * @since 6
37561847f8eSopenharmony_ci   */
37661847f8eSopenharmony_ci  /**
37761847f8eSopenharmony_ci   * Starts the animation.
37861847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
37961847f8eSopenharmony_ci   * @crossplatform
38061847f8eSopenharmony_ci   * @since 10
38161847f8eSopenharmony_ci   */
38261847f8eSopenharmony_ci  /**
38361847f8eSopenharmony_ci   * Starts the animation.
38461847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
38561847f8eSopenharmony_ci   * @crossplatform
38661847f8eSopenharmony_ci   * @atomicservice
38761847f8eSopenharmony_ci   * @since 11
38861847f8eSopenharmony_ci   */
38961847f8eSopenharmony_ci  play(): void;
39061847f8eSopenharmony_ci
39161847f8eSopenharmony_ci  /**
39261847f8eSopenharmony_ci   * Ends the animation.
39361847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
39461847f8eSopenharmony_ci   * @since 6
39561847f8eSopenharmony_ci   */
39661847f8eSopenharmony_ci  /**
39761847f8eSopenharmony_ci   * Ends the animation.
39861847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
39961847f8eSopenharmony_ci   * @crossplatform
40061847f8eSopenharmony_ci   * @since 10
40161847f8eSopenharmony_ci   */
40261847f8eSopenharmony_ci  /**
40361847f8eSopenharmony_ci   * Ends the animation.
40461847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
40561847f8eSopenharmony_ci   * @crossplatform
40661847f8eSopenharmony_ci   * @atomicservice
40761847f8eSopenharmony_ci   * @since 11
40861847f8eSopenharmony_ci   */
40961847f8eSopenharmony_ci  finish(): void;
41061847f8eSopenharmony_ci
41161847f8eSopenharmony_ci  /**
41261847f8eSopenharmony_ci   * Pauses the animation.
41361847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
41461847f8eSopenharmony_ci   * @since 6
41561847f8eSopenharmony_ci   */
41661847f8eSopenharmony_ci  /**
41761847f8eSopenharmony_ci   * Pauses the animation.
41861847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
41961847f8eSopenharmony_ci   * @crossplatform
42061847f8eSopenharmony_ci   * @since 10
42161847f8eSopenharmony_ci   */
42261847f8eSopenharmony_ci  /**
42361847f8eSopenharmony_ci   * Pauses the animation.
42461847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
42561847f8eSopenharmony_ci   * @crossplatform
42661847f8eSopenharmony_ci   * @atomicservice
42761847f8eSopenharmony_ci   * @since 11
42861847f8eSopenharmony_ci   */
42961847f8eSopenharmony_ci  pause(): void;
43061847f8eSopenharmony_ci
43161847f8eSopenharmony_ci  /**
43261847f8eSopenharmony_ci   * Cancels the animation.
43361847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
43461847f8eSopenharmony_ci   * @since 6
43561847f8eSopenharmony_ci   */
43661847f8eSopenharmony_ci  /**
43761847f8eSopenharmony_ci   * Cancels the animation.
43861847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
43961847f8eSopenharmony_ci   * @crossplatform
44061847f8eSopenharmony_ci   * @since 10
44161847f8eSopenharmony_ci   */
44261847f8eSopenharmony_ci  /**
44361847f8eSopenharmony_ci   * Cancels the animation.
44461847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
44561847f8eSopenharmony_ci   * @crossplatform
44661847f8eSopenharmony_ci   * @atomicservice
44761847f8eSopenharmony_ci   * @since 11
44861847f8eSopenharmony_ci   */
44961847f8eSopenharmony_ci  cancel(): void;
45061847f8eSopenharmony_ci
45161847f8eSopenharmony_ci  /**
45261847f8eSopenharmony_ci   * Plays the animation in reverse direction.
45361847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
45461847f8eSopenharmony_ci   * @since 6
45561847f8eSopenharmony_ci   */
45661847f8eSopenharmony_ci  /**
45761847f8eSopenharmony_ci   * Plays the animation in reverse direction.
45861847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
45961847f8eSopenharmony_ci   * @crossplatform
46061847f8eSopenharmony_ci   * @since 10
46161847f8eSopenharmony_ci   */
46261847f8eSopenharmony_ci  /**
46361847f8eSopenharmony_ci   * Plays the animation in reverse direction.
46461847f8eSopenharmony_ci   * Invalid when using interpolating-spring curve.
46561847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
46661847f8eSopenharmony_ci   * @crossplatform
46761847f8eSopenharmony_ci   * @atomicservice
46861847f8eSopenharmony_ci   * @since 11
46961847f8eSopenharmony_ci   */
47061847f8eSopenharmony_ci  reverse(): void;
47161847f8eSopenharmony_ci
47261847f8eSopenharmony_ci  /**
47361847f8eSopenharmony_ci   * Trigger when vsync callback.
47461847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
47561847f8eSopenharmony_ci   * @since 6
47661847f8eSopenharmony_ci   */
47761847f8eSopenharmony_ci  /**
47861847f8eSopenharmony_ci   * Trigger when vsync callback.
47961847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
48061847f8eSopenharmony_ci   * @crossplatform
48161847f8eSopenharmony_ci   * @since 10
48261847f8eSopenharmony_ci   */
48361847f8eSopenharmony_ci  /**
48461847f8eSopenharmony_ci   * Trigger when vsync callback.
48561847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
48661847f8eSopenharmony_ci   * @crossplatform
48761847f8eSopenharmony_ci   * @atomicservice
48861847f8eSopenharmony_ci   * @since 11
48961847f8eSopenharmony_ci   * @deprecated since 12
49061847f8eSopenharmony_ci   * @useinstead ohos.animator.onFrame
49161847f8eSopenharmony_ci   */
49261847f8eSopenharmony_ci  onframe: (progress: number) => void;
49361847f8eSopenharmony_ci
49461847f8eSopenharmony_ci  /**
49561847f8eSopenharmony_ci   * Trigger when vSync callback.
49661847f8eSopenharmony_ci   *
49761847f8eSopenharmony_ci   * @type { function }
49861847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
49961847f8eSopenharmony_ci   * @crossplatform
50061847f8eSopenharmony_ci   * @atomicservice
50161847f8eSopenharmony_ci   * @since 12
50261847f8eSopenharmony_ci   */
50361847f8eSopenharmony_ci  onFrame: (progress: number) => void;
50461847f8eSopenharmony_ci
50561847f8eSopenharmony_ci  /**
50661847f8eSopenharmony_ci   * The animation is finished.
50761847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
50861847f8eSopenharmony_ci   * @since 6
50961847f8eSopenharmony_ci   */
51061847f8eSopenharmony_ci  /**
51161847f8eSopenharmony_ci   * The animation is finished.
51261847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
51361847f8eSopenharmony_ci   * @crossplatform
51461847f8eSopenharmony_ci   * @since 10
51561847f8eSopenharmony_ci   */
51661847f8eSopenharmony_ci  /**
51761847f8eSopenharmony_ci   * The animation is finished.
51861847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
51961847f8eSopenharmony_ci   * @crossplatform
52061847f8eSopenharmony_ci   * @atomicservice
52161847f8eSopenharmony_ci   * @since 11
52261847f8eSopenharmony_ci   * @deprecated since 12
52361847f8eSopenharmony_ci   * @useinstead ohos.animator.onFinish
52461847f8eSopenharmony_ci   */
52561847f8eSopenharmony_ci  onfinish: () => void;
52661847f8eSopenharmony_ci
52761847f8eSopenharmony_ci  /**
52861847f8eSopenharmony_ci   * The animation is finished.
52961847f8eSopenharmony_ci   *
53061847f8eSopenharmony_ci   * @type { function }
53161847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
53261847f8eSopenharmony_ci   * @crossplatform
53361847f8eSopenharmony_ci   * @atomicservice
53461847f8eSopenharmony_ci   * @since 12
53561847f8eSopenharmony_ci   */
53661847f8eSopenharmony_ci  onFinish: () => void;
53761847f8eSopenharmony_ci
53861847f8eSopenharmony_ci  /**
53961847f8eSopenharmony_ci   * The animation is canceled.
54061847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
54161847f8eSopenharmony_ci   * @since 6
54261847f8eSopenharmony_ci   */
54361847f8eSopenharmony_ci  /**
54461847f8eSopenharmony_ci   * The animation is canceled.
54561847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
54661847f8eSopenharmony_ci   * @crossplatform
54761847f8eSopenharmony_ci   * @since 10
54861847f8eSopenharmony_ci   */
54961847f8eSopenharmony_ci  /**
55061847f8eSopenharmony_ci   * The animation is canceled.
55161847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
55261847f8eSopenharmony_ci   * @crossplatform
55361847f8eSopenharmony_ci   * @atomicservice
55461847f8eSopenharmony_ci   * @since 11
55561847f8eSopenharmony_ci   * @deprecated since 12
55661847f8eSopenharmony_ci   * @useinstead ohos.animator.onCancel
55761847f8eSopenharmony_ci   */
55861847f8eSopenharmony_ci  oncancel: () => void;
55961847f8eSopenharmony_ci
56061847f8eSopenharmony_ci  /**
56161847f8eSopenharmony_ci   * The animation is canceled.
56261847f8eSopenharmony_ci   *
56361847f8eSopenharmony_ci   * @type { function }
56461847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
56561847f8eSopenharmony_ci   * @crossplatform
56661847f8eSopenharmony_ci   * @atomicservice
56761847f8eSopenharmony_ci   * @since 12
56861847f8eSopenharmony_ci   */
56961847f8eSopenharmony_ci  onCancel: () => void;
57061847f8eSopenharmony_ci
57161847f8eSopenharmony_ci  /**
57261847f8eSopenharmony_ci   * The animation is repeated.
57361847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
57461847f8eSopenharmony_ci   * @since 6
57561847f8eSopenharmony_ci   */
57661847f8eSopenharmony_ci  /**
57761847f8eSopenharmony_ci   * The animation is repeated.
57861847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
57961847f8eSopenharmony_ci   * @crossplatform
58061847f8eSopenharmony_ci   * @since 10
58161847f8eSopenharmony_ci   */
58261847f8eSopenharmony_ci  /**
58361847f8eSopenharmony_ci   * The animation is repeated.
58461847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
58561847f8eSopenharmony_ci   * @crossplatform
58661847f8eSopenharmony_ci   * @atomicservice
58761847f8eSopenharmony_ci   * @since 11
58861847f8eSopenharmony_ci   * @deprecated since 12
58961847f8eSopenharmony_ci   * @useinstead ohos.animator.onRepeat
59061847f8eSopenharmony_ci   */
59161847f8eSopenharmony_ci  onrepeat: () => void;
59261847f8eSopenharmony_ci
59361847f8eSopenharmony_ci  /**
59461847f8eSopenharmony_ci   * The animation is repeated.
59561847f8eSopenharmony_ci   *
59661847f8eSopenharmony_ci   * @type { function }
59761847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
59861847f8eSopenharmony_ci   * @crossplatform
59961847f8eSopenharmony_ci   * @atomicservice
60061847f8eSopenharmony_ci   * @since 12
60161847f8eSopenharmony_ci   */
60261847f8eSopenharmony_ci  onRepeat: () => void;
60361847f8eSopenharmony_ci
60461847f8eSopenharmony_ci  /**
60561847f8eSopenharmony_ci   * The expected frame rate of dynamical of rate range.
60661847f8eSopenharmony_ci   * @param { ExpectedFrameRateRange } rateRange - Indicates ExpectedFrameRateRange.
60761847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
60861847f8eSopenharmony_ci   * @atomicservice
60961847f8eSopenharmony_ci   * @since 12
61061847f8eSopenharmony_ci   */
61161847f8eSopenharmony_ci  setExpectedFrameRateRange(rateRange: ExpectedFrameRateRange): void;
61261847f8eSopenharmony_ci}
61361847f8eSopenharmony_ci
61461847f8eSopenharmony_ci/**
61561847f8eSopenharmony_ci * Defines the Animator class.
61661847f8eSopenharmony_ci * @syscap SystemCapability.ArkUI.ArkUI.Full
61761847f8eSopenharmony_ci * @since 6
61861847f8eSopenharmony_ci */
61961847f8eSopenharmony_ci/**
62061847f8eSopenharmony_ci * Defines the Animator class.
62161847f8eSopenharmony_ci * @syscap SystemCapability.ArkUI.ArkUI.Full
62261847f8eSopenharmony_ci * @crossplatform
62361847f8eSopenharmony_ci * @since 10
62461847f8eSopenharmony_ci */
62561847f8eSopenharmony_ci/**
62661847f8eSopenharmony_ci * Defines the Animator class.
62761847f8eSopenharmony_ci * @syscap SystemCapability.ArkUI.ArkUI.Full
62861847f8eSopenharmony_ci * @crossplatform
62961847f8eSopenharmony_ci * @atomicservice
63061847f8eSopenharmony_ci * @since 11
63161847f8eSopenharmony_ci */
63261847f8eSopenharmony_ciexport default class Animator {
63361847f8eSopenharmony_ci  /**
63461847f8eSopenharmony_ci   * Create an animator object for custom animation.
63561847f8eSopenharmony_ci   * @param { AnimatorOptions } options - Options.
63661847f8eSopenharmony_ci   * @returns { AnimatorResult } animator result
63761847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
63861847f8eSopenharmony_ci   * @since 6
63961847f8eSopenharmony_ci   * @deprecated since 9
64061847f8eSopenharmony_ci   * @useinstead ohos.animator.create
64161847f8eSopenharmony_ci   */
64261847f8eSopenharmony_ci  static createAnimator(options: AnimatorOptions): AnimatorResult;
64361847f8eSopenharmony_ci
64461847f8eSopenharmony_ci  /**
64561847f8eSopenharmony_ci   * Create an animator object for custom animation.
64661847f8eSopenharmony_ci   * @param { AnimatorOptions } options - Options.
64761847f8eSopenharmony_ci   * @returns { AnimatorResult } animator result
64861847f8eSopenharmony_ci   * @throws { BusinessError } 401 - Parameter error. Possible causes: 
64961847f8eSopenharmony_ci   * <br> 1. Mandatory parameters are left unspecified.
65061847f8eSopenharmony_ci   * <br> 2. Incorrect parameters types.
65161847f8eSopenharmony_ci   * <br> 3. Parameter verification failed.
65261847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
65361847f8eSopenharmony_ci   * @since 9
65461847f8eSopenharmony_ci   */
65561847f8eSopenharmony_ci  /**
65661847f8eSopenharmony_ci   * Create an animator object for custom animation.
65761847f8eSopenharmony_ci   * @param { AnimatorOptions } options - Options.
65861847f8eSopenharmony_ci   * @returns { AnimatorResult } animator result
65961847f8eSopenharmony_ci   * @throws { BusinessError } 401 - Parameter error. Possible causes: 
66061847f8eSopenharmony_ci   * <br> 1. Mandatory parameters are left unspecified.
66161847f8eSopenharmony_ci   * <br> 2. Incorrect parameters types.
66261847f8eSopenharmony_ci   * <br> 3. Parameter verification failed.
66361847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
66461847f8eSopenharmony_ci   * @crossplatform
66561847f8eSopenharmony_ci   * @since 10
66661847f8eSopenharmony_ci   */
66761847f8eSopenharmony_ci  /**
66861847f8eSopenharmony_ci   * Create an animator object for custom animation.
66961847f8eSopenharmony_ci   * @param { AnimatorOptions } options - Options.
67061847f8eSopenharmony_ci   * @returns { AnimatorResult } animator result
67161847f8eSopenharmony_ci   * @throws { BusinessError } 401 - Parameter error. Possible causes: 
67261847f8eSopenharmony_ci   * <br> 1. Mandatory parameters are left unspecified.
67361847f8eSopenharmony_ci   * <br> 2. Incorrect parameters types.
67461847f8eSopenharmony_ci   * <br> 3. Parameter verification failed.
67561847f8eSopenharmony_ci   * @syscap SystemCapability.ArkUI.ArkUI.Full
67661847f8eSopenharmony_ci   * @crossplatform
67761847f8eSopenharmony_ci   * @atomicservice
67861847f8eSopenharmony_ci   * @since 11
67961847f8eSopenharmony_ci   */
68061847f8eSopenharmony_ci  static create(options: AnimatorOptions): AnimatorResult;
68161847f8eSopenharmony_ci}
682