two-slot-extended-mags/types/helpers/HttpServerHelper.d.ts

33 lines
865 B
TypeScript
Raw Normal View History

import { IHttpConfig } from "@spt/models/spt/config/IHttpConfig";
import { ConfigServer } from "@spt/servers/ConfigServer";
2023-06-11 15:10:34 +10:00
export declare class HttpServerHelper {
protected configServer: ConfigServer;
protected httpConfig: IHttpConfig;
protected mime: {
css: string;
bin: string;
html: string;
jpg: string;
js: string;
json: string;
png: string;
svg: string;
txt: string;
};
constructor(configServer: ConfigServer);
getMimeText(key: string): string;
2023-10-09 20:21:00 +11:00
/**
* Combine ip and port into address
2023-10-09 20:21:00 +11:00
* @returns url
*/
2023-06-11 15:10:34 +10:00
buildUrl(): string;
2023-10-09 20:21:00 +11:00
/**
* Prepend http to the url:port
* @returns URI
*/
2023-06-11 15:10:34 +10:00
getBackendUrl(): string;
2023-10-09 20:21:00 +11:00
/** Get websocket url + port */
2023-06-11 15:10:34 +10:00
getWebsocketUrl(): string;
sendTextJson(resp: any, output: any): void;
}