angular-odata
Version:
Client side OData typescript library for Angular
20 lines (19 loc) • 721 B
TypeScript
import { ODataRequest, ODataResponse } from '../resources';
import { ODataCache } from './cache';
export declare class ODataInMemoryCache extends ODataCache {
constructor({ timeout }?: {
timeout?: number;
});
/**
* Store the response in the cache
* @param req The request with the resource to store the response
* @param res The response to store in the cache
*/
putResponse(req: ODataRequest<any>, res: ODataResponse<any>): void;
/**
* Restore the response from the cache
* @param req The request with the resource to get the response
* @returns The response from the cache
*/
getResponse(req: ODataRequest<any>): ODataResponse<any> | undefined;
}