declare module 'ffmpeg-kit-react-native' { export abstract class AbstractSession implements Session { static createFFmpegSession(argumentsArray: Array, logRedirectionStrategy?: LogRedirectionStrategy): Promise; static createFFmpegSessionFromMap(sessionMap: { [key: string]: any }): FFmpegSession; static createFFprobeSession(argumentsArray: Array, logRedirectionStrategy?: LogRedirectionStrategy): Promise; static createFFprobeSessionFromMap(sessionMap: { [key: string]: any }): FFprobeSession; static createMediaInformationSession(argumentsArray: Array): Promise; static createMediaInformationSessionFromMap(sessionMap: { [key: string]: any }): MediaInformationSession; getLogCallback(): LogCallback; getSessionId(): number; getCreateTime(): Date; getStartTime(): Date; getEndTime(): Promise; getDuration(): Promise; getArguments(): Array; getCommand(): string; getAllLogs(waitTimeout ?: number): Promise>; getLogs(): Promise>; getAllLogsAsString(waitTimeout?: number): Promise; getLogsAsString(): Promise; getOutput(): Promise; getState(): Promise; getReturnCode(): Promise; getFailStackTrace(): Promise; getLogRedirectionStrategy(): LogRedirectionStrategy; thereAreAsynchronousMessagesInTransmit(): Promise; isFFmpeg(): boolean; isFFprobe(): boolean; isMediaInformation(): boolean; cancel(): Promise; } export class ArchDetect { static getArch(): Promise; } export type FFmpegSessionCompleteCallback = (session: FFmpegSession) => void; export type FFprobeSessionCompleteCallback = (session: FFprobeSession) => void; export type MediaInformationSessionCompleteCallback = (session: MediaInformationSession) => void; export class FFmpegKit { static execute(command: string): Promise; static executeWithArguments(commandArguments: string[]): Promise; static executeAsync(command: string, completeCallback?: FFmpegSessionCompleteCallback, logCallback?: LogCallback, statisticsCallback?: StatisticsCallback): Promise; static executeWithArgumentsAsync(commandArguments: string[], completeCallback?: FFmpegSessionCompleteCallback, logCallback?: LogCallback, statisticsCallback?: StatisticsCallback): Promise; static cancel(sessionId?: number): Promise; static listSessions(): Promise; } export class FFmpegKitConfig { static init(): Promise; static uninit(): Promise; static enableRedirection(): Promise; static disableRedirection(): Promise; static setFontconfigConfigurationPath(path: string): Promise; static setFontDirectory(path: string, mapping?: { [key: string]: string }): Promise; static setFontDirectoryList(fontDirectoryList: string[], mapping?: { [key: string]: string }): Promise; static registerNewFFmpegPipe(): Promise; static closeFFmpegPipe(ffmpegPipePath: string): Promise; static getFFmpegVersion(): Promise; static getVersion(): Promise; static isLTSBuild(): Promise; static getBuildDate(): Promise; static setEnvironmentVariable(name: string, value: string): Promise; static ignoreSignal(signal: Signal): Promise; static ffmpegExecute(session: FFmpegSession): Promise; static ffprobeExecute(session: FFprobeSession): Promise; static getMediaInformationExecute(session: MediaInformationSession, waitTimeout?: number): Promise; static asyncFFmpegExecute(session: FFmpegSession): Promise; static asyncFFprobeExecute(session: FFprobeSession): Promise; static asyncGetMediaInformationExecute(session: MediaInformationSession, waitTimeout?: number): Promise; static enableLogCallback(logCallback: LogCallback): void; static enableStatisticsCallback(statisticsCallback: StatisticsCallback): void; static enableFFmpegSessionCompleteCallback(completeCallback: FFmpegSessionCompleteCallback): void; static getFFmpegSessionCompleteCallback(): FFmpegSessionCompleteCallback; static enableFFprobeSessionCompleteCallback(completeCallback: FFprobeSessionCompleteCallback): void; static getFFprobeSessionCompleteCallback(): FFprobeSessionCompleteCallback; static enableMediaInformationSessionCompleteCallback(completeCallback: MediaInformationSessionCompleteCallback): void; static getMediaInformationSessionCompleteCallback(): MediaInformationSessionCompleteCallback; static getLogLevel(): Level; static setLogLevel(level: Level): Promise; static getSafParameterForRead(uriString: String): Promise; static getSafParameterForWrite(uriString: String): Promise; static getSafParameter(uriString: String, openMode: String): Promise; static getSessionHistorySize(): Promise; static setSessionHistorySize(sessionHistorySize: number): Promise; static getSession(sessionId: number): Promise; static getLastSession(): Promise; static getLastCompletedSession(): Promise; static getSessions(): Promise; static clearSessions(): Promise; static getFFmpegSessions(): Promise; static getFFprobeSessions(): Promise; static getMediaInformationSessions(): Promise; static getSessionsByState(state): Promise; static getLogRedirectionStrategy(): LogRedirectionStrategy; static setLogRedirectionStrategy(logRedirectionStrategy: LogRedirectionStrategy); static messagesInTransmit(sessionId: number): Promise; static sessionStateToString(state): string; static parseArguments(command: string): string[]; static argumentsToString(commandArguments: string[]): string; static enableLogs(): Promise; static disableLogs(): Promise; static enableStatistics(): Promise; static disableStatistics(): Promise; static getPlatform(): Promise; static writeToPipe(inputPath: string, pipePath: string): Promise; static selectDocumentForRead(type?: string, extraTypes?: string[]): Promise; static selectDocumentForWrite(title?: string, type?: string, extraTypes?: string[]): Promise; } export class FFmpegSession extends AbstractSession implements Session { static create(argumentsArray: Array, completeCallback?: FFmpegSessionCompleteCallback, logCallback?: LogCallback, statisticsCallback?: StatisticsCallback, logRedirectionStrategy?: LogRedirectionStrategy): Promise; getStatisticsCallback(): StatisticsCallback; getCompleteCallback(): FFmpegSessionCompleteCallback; getAllStatistics(waitTimeout?: number): Promise>; getStatistics(): Promise>; getLastReceivedStatistics(): Promise; isFFmpeg(): boolean; isFFprobe(): boolean; isMediaInformation(): boolean; } export class FFprobeKit { static execute(command: string): Promise; static executeWithArguments(commandArguments: string[]): Promise; static executeAsync(command: string, completeCallback?: FFprobeSessionCompleteCallback, logCallback?: LogCallback): Promise; static executeWithArgumentsAsync(commandArguments: string[], completeCallback?: FFprobeSessionCompleteCallback, logCallback?: LogCallback): Promise; static getMediaInformation(path: string, waitTimeout?: number): Promise; static getMediaInformationFromCommand(command: string, waitTimeout?: number): Promise; static getMediaInformationFromCommandArguments(commandArguments: string[], waitTimeout?: number): Promise; static getMediaInformationAsync(path: string, completeCallback?: FFprobeSessionCompleteCallback, logCallback?: LogCallback, waitTimeout?: number): Promise; static getMediaInformationFromCommandAsync(command: string, completeCallback?: FFprobeSessionCompleteCallback, logCallback?: LogCallback, waitTimeout?: number): Promise; static getMediaInformationFromCommandArgumentsAsync(commandArguments: string[], completeCallback?: FFprobeSessionCompleteCallback, logCallback?: LogCallback, waitTimeout?: number): Promise; static listFFprobeSessions(): Promise; static listMediaInformationSessions(): Promise; } export class FFprobeSession extends AbstractSession implements Session { static create(argumentsArray: Array, completeCallback?: FFprobeSessionCompleteCallback, logCallback?: LogCallback, logRedirectionStrategy?: LogRedirectionStrategy): Promise; getCompleteCallback(): FFprobeSessionCompleteCallback; isFFmpeg(): boolean; isFFprobe(): boolean; isMediaInformation(): boolean; } export class Level { static readonly AV_LOG_STDERR: number; static readonly AV_LOG_QUIET: number; static readonly AV_LOG_PANIC: number; static readonly AV_LOG_FATAL: number; static readonly AV_LOG_ERROR: number; static readonly AV_LOG_WARNING: number; static readonly AV_LOG_INFO: number; static readonly AV_LOG_VERBOSE: number; static readonly AV_LOG_DEBUG: number; static readonly AV_LOG_TRACE: number; static levelToString(number: number): string; } export class Log { constructor(sessionId: number, level: number, message: String); getSessionId(): number; getLevel(): number; getMessage(): String; } export type LogCallback = (log: Log) => void; export enum LogRedirectionStrategy { ALWAYS_PRINT_LOGS = 0, PRINT_LOGS_WHEN_NO_CALLBACKS_DEFINED = 1, PRINT_LOGS_WHEN_GLOBAL_CALLBACK_NOT_DEFINED = 2, PRINT_LOGS_WHEN_SESSION_CALLBACK_NOT_DEFINED = 3, NEVER_PRINT_LOGS = 4 } export class MediaInformation { static readonly KEY_FORMAT_PROPERTIES: string; static readonly KEY_FILENAME: string; static readonly KEY_FORMAT: string; static readonly KEY_FORMAT_LONG: string; static readonly KEY_START_TIME: string; static readonly KEY_DURATION: string; static readonly KEY_SIZE: string; static readonly KEY_BIT_RATE: string; static readonly KEY_TAGS: string; constructor(properties: Record); getFilename(): string; getFormat(): string; getLongFormat(): string; getDuration(): number; getStartTime(): string; getSize(): string; getBitrate(): string; getTags(): Record; getStreams(): Array; getChapters(): Array; getStringProperty(key: string): string; getNumberProperty(key: string): number; getProperty(key: string): any; getStringFormatProperty(key: string): string; getNumberFormatProperty(key: string): number; getFormatProperty(key: string): any; getFormatProperties(): Record; getAllProperties(): Record; } export class MediaInformationJsonParser { static from(ffprobeJsonOutput: string): Promise; static fromWithError(ffprobeJsonOutput: string): Promise; } export class MediaInformationSession extends AbstractSession implements Session { static create(argumentsArray: Array, completeCallback?: MediaInformationSessionCompleteCallback, logCallback?: LogCallback): Promise; getMediaInformation(): MediaInformation; setMediaInformation(mediaInformation: MediaInformation): void; getCompleteCallback(): MediaInformationSessionCompleteCallback; isFFmpeg(): boolean; isFFprobe(): boolean; isMediaInformation(): boolean; } export class Packages { static getPackageName(): Promise; static getExternalLibraries(): Promise; } export class ReturnCode { static readonly SUCCESS: number; static readonly CANCEL: number; constructor(value: number); static isSuccess(returnCode: ReturnCode): boolean; static isCancel(returnCode: ReturnCode): boolean; getValue(): number; isValueSuccess(): boolean; isValueError(): boolean; isValueCancel(): boolean; } export interface Session { getLogCallback(): LogCallback; getSessionId(): number; getCreateTime(): Date; getStartTime(): Date; getEndTime(): Promise; getDuration(): Promise; getArguments(): Array; getCommand(): String; getAllLogs(waitTimeout ?: number): Promise>; getLogs(): Promise>; getAllLogsAsString(waitTimeout?: number): Promise; getLogsAsString(): Promise; getOutput(): Promise; getState(): Promise; getReturnCode(): Promise; getFailStackTrace(): Promise; getLogRedirectionStrategy(): LogRedirectionStrategy; thereAreAsynchronousMessagesInTransmit(): Promise; isFFmpeg(): boolean; isFFprobe(): boolean; isMediaInformation(): boolean; cancel(): Promise; } export enum SessionState { CREATED = 0, RUNNING = 1, FAILED = 2, COMPLETED = 3 } export enum Signal { SIGINT = 2, SIGQUIT = 3, SIGPIPE = 13, SIGTERM = 15, SIGXCPU = 24 } export class Statistics { constructor(sessionId: number, videoFrameNumber: number, videoFps: number, videoQuality: number, size: number, time: number, bitrate: number, speed: number); getSessionId(): number; setSessionId(sessionId: number): void; getVideoFrameNumber(): number; setVideoFrameNumber(videoFrameNumber: number): void; getVideoFps(): number; setVideoFps(videoFps: number): void; getVideoQuality(): number; setVideoQuality(videoQuality: number): void; getSize(): number; setSize(size: number): void; getTime(): number; setTime(time: number): void; getBitrate(): number; setBitrate(bitrate: number): void; getSpeed(): number; setSpeed(speed: number): void; } export type StatisticsCallback = (statistics: Statistics) => void; export class StreamInformation { static readonly KEY_INDEX: string; static readonly KEY_TYPE: string; static readonly KEY_CODEC: string; static readonly KEY_CODEC_LONG: string; static readonly KEY_FORMAT: string; static readonly KEY_WIDTH: string; static readonly KEY_HEIGHT: string; static readonly KEY_BIT_RATE: string; static readonly KEY_SAMPLE_RATE: string; static readonly KEY_SAMPLE_FORMAT: string; static readonly KEY_CHANNEL_LAYOUT: string; static readonly KEY_SAMPLE_ASPECT_RATIO: string; static readonly KEY_DISPLAY_ASPECT_RATIO: string; static readonly KEY_AVERAGE_FRAME_RATE: string; static readonly KEY_REAL_FRAME_RATE: string; static readonly KEY_TIME_BASE: string; static readonly KEY_CODEC_TIME_BASE: string; static readonly KEY_TAGS: string; constructor(properties: Record); getIndex(): number; getType(): string; getCodec(): string; getCodecLong(): string; getFormat(): string; getWidth(): number; getHeight(): number; getBitrate(): string; getSampleRate(): string; getSampleFormat(): string; getChannelLayout(): string; getSampleAspectRatio(): string; getDisplayAspectRatio(): string; getAverageFrameRate(): string; getRealFrameRate(): string; getTimeBase(): string; getCodecTimeBase(): string; getTags(): Record; getStringProperty(key): string; getNumberProperty(key): number; getProperty(key): any; getAllProperties(): Record; } export class Chapter { static readonly KEY_ID: string; static readonly KEY_TIME_BASE: string; static readonly KEY_START: string; static readonly KEY_START_TIME: string; static readonly KEY_END: string; static readonly KEY_END_TIME: string; static readonly KEY_TAGS: string; constructor(properties: Record); getId(): number; getTimeBase(): string; getStart(): number; getStartTime(): string; getEnd(): number; getEndTime(): string; getTags(): Record; getStringProperty(key): string; getNumberProperty(key): number; getProperty(key): any; getAllProperties(): Record; } }