UNPKG

@fast-china/axios

Version:

Fast Axios 请求工具库.

3 lines (2 loc) 659 B
"use strict";var e=Object.defineProperty,t=(t,s,h)=>((t,s,h)=>s in t?e(t,s,{enumerable:!0,configurable:!0,writable:!0,value:h}):t[s]=h)(t,"symbol"!=typeof s?s+"":s,h);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});exports.CacheManage=class{constructor(){t(this,"_handle"),t(this,"get"),t(this,"set"),t(this,"_cacheRecord",new Map),this._handle={get:e=>this._cacheRecord.has(e)?this._cacheRecord.get(e):null,set:(e,t)=>{this._cacheRecord.set(e,t)}};const e=e=>{this._handle.get(e)};e.use=e=>{this._handle.get=e},this.get=e;const s=(e,t)=>{this._handle.set(e,t)};s.use=e=>{this._handle.set=e},this.set=s}}; //# sourceMappingURL=cache.js.map