UNPKG

xud

Version:
42 lines (41 loc) 1.18 kB
/// <reference types="node" /> import { EventEmitter } from 'events'; import Service from './service/Service'; interface Xud { on(event: 'shutdown', listener: () => void): this; emit(event: 'shutdown'): boolean; } /** Class representing a complete Exchange Union daemon. */ declare class Xud extends EventEmitter { service: Service; private logger; private config; private db; private pool; private orderBook; private rpcServer?; private httpServer?; private grpcAPIProxy?; private swaps; private shuttingDown; private swapClientManager?; private unitConverter?; private simnetChannels$?; /** * Create an Exchange Union daemon. */ constructor(); /** * Start all processes necessary for the operation of an Exchange Union node. * @param args optional arguments to override configuration parameters. */ start: (args?: { [argName: string]: any; } | undefined) => Promise<void>; private shutdown; /** * Initiate graceful shutdown of xud. Emits the `shutdown` event when shutdown is complete. */ beginShutdown: () => void; } export default Xud;