This repository has been archived on 2025-11-10. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
lol-cup-pick-ban-ui/apps/backend/data/league/connector/Connector.ts
T
mmacierzanka 3e62256988 Initial commit
This includes changes that were made in the forked version. Commit history from that time is not accessible.
2023-01-25 19:12:39 +01:00

25 lines
573 B
TypeScript

import { EventEmitter } from 'events';
import { RequestOptions, Response } from 'league-connect';
export class ConnectionInfo {
port!: number;
username!: string;
password!: string;
}
export class ConnectorOptions {
leaguePath?: string;
}
declare interface Connector extends EventEmitter {
options: ConnectorOptions;
start(): void;
on(event: 'disconnect', listener: () => void): this;
on(event: 'connect', listener: (info: ConnectionInfo) => void): this;
request(args: RequestOptions): Promise<Response<any> | undefined>;
}
export default Connector;