/// /// import { Server } from "http"; import { ServerOptions } from "https"; import { ContextOptions, Constructor, EventOptions, SkhailService, ServiceFunctions } from "@skhail/core"; import { HTTPProtocols } from "../client/types"; import { IRequestHandler } from "./types"; export type HTTPServiceOptions = { port: number; allowedOrigins: string[]; } & ({ protocol: HTTPProtocols.HTTP; } | { protocol: HTTPProtocols.HTTPS; tls: ServerOptions; }); export declare const defaultHTTPOptions: HTTPServiceOptions; export declare class HTTPService extends SkhailService { static identifier: string; protected httpServer?: Server; protected options: HTTPServiceOptions; protected handlers: IRequestHandler[]; constructor(options?: Partial); private requestHandler; prepare(): Promise; cleanup(): Promise; registerRoute>(route: string, service: Constructor, method: keyof ServiceFunctions, raw?: boolean): void; }