UNPKG

@silver-zepp/easy-media

Version:

EasyMedia - Sound Player and Recorder Library for ZeppOS.

96 lines (95 loc) 2.74 kB
export namespace __SPExtra { export { Get }; export { Set }; } export type GetSP_T = { /** * - Get the current playback volume. */ volume: () => number; /** * - Get the total duration of the currently playing media file. */ duration: () => number; /** * - Get the title of the currently playing media file. */ title: () => string; /** * - Get the artist of the currently playing media file. */ artist: () => string; /** * - Get the media info of the currently playing media file. */ mediaInfo: () => any; /** * - Get the current status of the player. */ status: () => number; /** * - Get the current status name of the player. */ statusName: () => string; /** * - Check if the player is currently playing. */ isPlaying: () => boolean; /** * - Check if the player is currently paused. */ isPaused: () => boolean; /** * - Check if the player is currently stopped or idle. */ isStopped: () => boolean; }; export type SetSP_T = { /** * - Set the playback volume. */ volume: (vol: number) => boolean; }; /** * @typedef {Object} GetSP_T * @property {() => number} volume - Get the current playback volume. * @property {() => number} duration - Get the total duration of the currently playing media file. * @property {() => string} title - Get the title of the currently playing media file. * @property {() => string} artist - Get the artist of the currently playing media file. * @property {() => Object} mediaInfo - Get the media info of the currently playing media file. * @property {() => number} status - Get the current status of the player. * @property {() => string} statusName - Get the current status name of the player. * @property {() => boolean} isPlaying - Check if the player is currently playing. * @property {() => boolean} isPaused - Check if the player is currently paused. * @property {() => boolean} isStopped - Check if the player is currently stopped or idle. */ /** * @typedef {Object} SetSP_T * @property {(vol: number) => boolean} volume - Set the playback volume. */ /** * Class representing getter methods for Sound Player. */ declare class Get { constructor(player: any, get_IsPlaying: any); volume(): any; duration(): any; title(): any; artist(): any; mediaInfo(): any; status(): any; statusName(): any; isPlaying(): any; isPaused(): boolean; isStopped(): boolean; #private; } /** * Class representing setter methods for Sound Player. */ declare class Set { constructor(player: any); volume(vol: any): any; #private; } export {};