123456789101112131415161718192021222324252627282930313233343536373839404142434445 |
- import './_version.js';
- export interface CacheableResponseOptions {
- statuses?: number[];
- headers?: {
- [headerName: string]: string;
- };
- }
- declare class CacheableResponse {
- private readonly _statuses?;
- private readonly _headers?;
-
- constructor(config?: CacheableResponseOptions);
- /**
- * Checks a response to see whether it's cacheable or not, based on this
- * object's configuration.
- *
- * @param {Response} response The response whose cacheability is being
- * checked.
- * @return {boolean} `true` if the `Response` is cacheable, and `false`
- * otherwise.
- */
- isResponseCacheable(response: Response): boolean;
- }
- export { CacheableResponse };
|