import { Projector } from '../projector.ts'; /** * File patch. */ export interface IFilePatch { /** * Check if player file path matches. * * @param file File path. * @returns If matched. */ match: (file: string) => boolean; /** * Modify data, possibly inplace. * * @param data The data to modify. * @returns Modified data. */ modify: (data: Uint8Array) => Promise | Uint8Array; /** * Run after all patches. */ after: () => Promise | void; } /** * File filter. */ export interface IFileFilter { /** * Check if player file path matches. * * @param file File path. * @returns If excluded. */ match: (file: string) => boolean; } /** * ProjectorSa object. */ export declare abstract class ProjectorSa extends Projector { /** * ProjectorSa Player. */ player: string | null; /** * Movie data. */ movieData: Readonly | (() => Readonly) | (() => Promise>) | null; /** * Movie file. */ movieFile: string | null; /** * ProjectorSa constructor. * * @param path Output path. */ constructor(path: string); /** * The movie appended magic. * * @returns Magic integer. */ get movieMagic(): number; /** * @inheritdoc */ write(): Promise; /** * Get movie file data. * * @returns Movie data or null. */ getMovieData(): Promise | null>; /** * Check that output path is valid, else throws. */ protected _checkOutput(): Promise; /** * Encode movie data for the projector. * Format string characters: * - d: Movie data. * - m: Magic, 32LE. * - M: Magic, 32BE. * - i: Magic, 64LE. * - I: Magic, 64BE. * - s: Size, 32LE. * - S: Size, 32BE. * - l: Size, 64LE. * - L: Size, 64BE. * * @param data Movie data. * @param format Format string. * @returns Encoded data. */ protected _encodeMovieData(data: Readonly, format: string): Uint8Array; /** * Projector file extension. * * @returns File extension. */ abstract get extension(): string; /** * Write the projector player. * * @param player Player path. */ protected abstract _writePlayer(player: string): Promise; }