export interface Identifyable { id: any; } export interface IFetchConfig { protocol: string; ip: string; port?: number; api?: string; } export interface IFetchBase { delete(item: T): Promise; find(id: any): Promise; findAll(suffix?: string): Promise; get(queryParams?: string): Promise; head(item: T): Promise; post(item: T): Promise; put(item: T): Promise; } export declare abstract class FetchBase implements IFetchBase { private config; protected endpoint: string; protected requestMode: RequestMode; constructor(config: IFetchConfig); head(item: T): Promise; findAll(suffix?: string): Promise; find(id: any): Promise; get(queryParams?: string): Promise; put(item: T): Promise; post(item: T): Promise; delete(item: T): Promise; getUrl(resource?: T, queryParams?: string): string; protected rejectErrorPromise(reason: Error): Promise; protected jsonResponse(json: any): Promise; protected handleFetchResponse(response: Response): Promise; protected handleHeadFetchResponse(response: Response): Promise; protected headOptions(): RequestInit; protected getOptions(): RequestInit; protected postOptions(item: T): RequestInit; protected putOptions(item: T): RequestInit; protected deleteOptions(): RequestInit; protected getRequestInit(method: string, body?: string): RequestInit; }