import { ResourceProvider } from '../resource-provider.service'; import { ConfigurationService } from '../../configuration/configuration.service'; import { Page } from '../interface/page'; /** * The class that contains behavior common to all resource services. * * Mostly endpoint URL resolution and utility functions for response parsing. */ export declare abstract class AbstractResourceService { protected _resourceProvider: ResourceProvider; protected _configService: ConfigurationService; private readonly _SERVER_URL; /** * @param resourceName the identifier of the desired endpoint from configuration, found in * {@link SetAuthAndResourcesAddress}.[resources]{@link Resources}. * @param _resourceProvider `ResourceProvider` instance * @param _configService `ConfigurationService` instance */ protected constructor(resourceName: string, _resourceProvider: ResourceProvider, _configService: ConfigurationService); protected get SERVER_URL(): string; /** * Get URL form nae.json - resources * @param name - ID property */ protected getResourceAddress(name: string): string; /** * Parses a response `r` into a {@link Page} instance * @param r - response object * @param propertiesParams - plural form of the resource name, that is used to extract the data. Eg. "cases". */ protected getResourcePage(r: any, propertiesParams: string): Page; /** * Extracts data from the response `r` into an object with better usability. * @param r - response object * @param propertiesParams - plural form of the resource name, that is used to extract the data. Eg. "cases". */ protected changeType(r: any, propertiesParams: string): T; }