import { HttpClient, HttpEvent, HttpHeaders, HttpParams, HttpProgressEvent, HttpResponse } from '@angular/common/http'; import { Observable } from 'rxjs'; import { MessageResource } from './interface/message-resource'; import * as i0 from "@angular/core"; export declare type Headers = HttpHeaders | { [header: string]: string | Array; }; export declare type Params = HttpParams | ObjectParams; export declare type ResponseType = 'json' | 'hal'; export interface ObjectParams { [param: string]: string | Array; } export declare enum ProgressType { UPLOAD = "upload", DOWNLOAD = "download" } export interface ProviderProgress { type: ProgressType; loaded: number; total?: number; progress?: number; } export declare abstract class AbstractResourceProvider { protected httpClient: HttpClient; protected constructor(httpClient: HttpClient); private static addLastSlash; private static removeFirstSlash; static sanitizeUrl(endpoint?: string, url?: string): string; /** * Combines two instances of {@link Params} type into one. * If a parameter is declared in both instances uses the value of the `highPriorityParams` in the result. * @param highPriorityParams parameters with the higher priority * @param lowPriorityParams parameters with the lower priority * @returns combination of botch parameters. Uses the value of the higher priority parameters if the keys are in conflict. */ static combineParams(highPriorityParams: Params, lowPriorityParams: Params): HttpParams; /** * Converts {@link HttpParams} instance into a simple object. * @param params instance to convert * @returns simple object with keys and values from the input argument */ static convertHttpParamsToObjectParams(params: HttpParams): ObjectParams; static getProgress(event: HttpProgressEvent): ProviderProgress; static processMessageResource(response: MessageResource | HttpResponse): MessageResource; get$(endpoint?: string, url?: string, params?: Params, headers?: Headers, responseType?: ResponseType): Observable; getBlob$(endpoint?: string, url?: string, params?: Params, headers?: Headers): Observable>; post$(endpoint?: string, url?: string, body?: object, params?: Params, headers?: Headers, responseType?: ResponseType): Observable; postWithEvent$(endpoint?: string, url?: string, body?: object, params?: Params, headers?: Headers, responseType?: ResponseType): Observable>; put$(endpoint?: string, url?: string, body?: object, params?: Params, headers?: Headers, responseType?: ResponseType): Observable; delete$(endpoint?: string, url?: string, params?: Params, headers?: Headers, responseType?: ResponseType, body?: object): Observable; } export declare class ResourceProvider extends AbstractResourceProvider { constructor(httpClient: HttpClient); static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; }