import type { ADB } from 'appium-adb';
import type { SettingsApp } from '../client';
import type { StartMediaProjectionRecordingOpts } from './types';
/**
 * Creates a new instance of the MediaProjection-based recorder.
 * The recorder only works since Android API 29+
 *
 * @returns The recorder instance
 */
export declare function makeMediaProjectionRecorder(this: SettingsApp): MediaProjectionRecorder;
/**
 * Adjusts the necessary permissions for the Media Projection-based recording service.
 * This method only applies to devices running Android API 29 or higher.
 *
 * @returns True if permissions were adjusted, false if device API level is below 29
 */
export declare function adjustMediaProjectionServicePermissions(this: SettingsApp): Promise<boolean>;
/**
 * Media projection recorder for capturing device screen recordings.
 * This class provides methods to start, stop, and manage screen recordings
 * using Android's MediaProjection API (API 29+).
 */
export declare class MediaProjectionRecorder {
    private readonly adb;
    /**
     * Creates a new MediaProjectionRecorder instance.
     *
     * @param adb - ADB instance for device communication
     */
    constructor(adb: ADB);
    /**
     * Checks if the recording is currently running.
     */
    isRunning(): Promise<boolean>;
    /**
     * Starts the media projection recording.
     * If a recording is already running, this method will return false without starting a new one.
     *
     * @param opts Recording options including filename, resolution, duration, and priority
     * @returns True if recording was started successfully, false if already running
     * @throws {Error} If recording fails to start within the timeout period
     */
    start(opts?: StartMediaProjectionRecordingOpts): Promise<boolean>;
    /**
     * Cleans up old recording files.
     */
    cleanup(): Promise<void>;
    /**
     * Pulls the most recent recording file from the device.
     *
     * @returns Path to the pulled file, or null if no recordings exist
     */
    pullRecent(): Promise<string | null>;
    /**
     * Stops the current recording.
     *
     * @returns True if recording was stopped successfully, false if no recording was running
     * @throws {Error} If the recording fails to stop within the timeout period
     */
    stop(): Promise<boolean>;
}
//# sourceMappingURL=media-projection.d.ts.map