import { EventInterface } from 'microevent.ts'; import StellaConfig from '../../../machine/stella/Config'; import CartridgeInfo from '../../../machine/stella/cartridge/CartridgeInfo'; import EmulationContextInterface from './EmulationContextInterface'; interface EmulationServiceInterface { init(): Promise; start(buffer: { [i: number]: number; length: number; }, config: EmulationServiceInterface.Config, cartridgeType?: CartridgeInfo.CartridgeType): Promise; stop(): Promise; pause(): Promise; resume(): Promise; reset(): Promise; setRateLimit(enforce: boolean): Promise; getRateLimit(): boolean; getState(): EmulationServiceInterface.State; getLastError(): Error; getEmulationContext(): EmulationContextInterface; getFrequency(): number; stateChanged: EventInterface; frequencyUpdate: EventInterface; } declare namespace EmulationServiceInterface { enum State { stopped = "stopped", running = "running", paused = "paused", error = "error" } interface Config extends StellaConfig { asyncIO?: boolean; } } export { EmulationServiceInterface as default };