ElCacheExtra class

请求缓存额外配置数据

Inheritance

Constructors

ElCacheExtra({bool? enableCache, bool? useCache, bool? printCacheLog, Duration? cacheExpire})
const
ElCacheExtra.fromJson(Map<String, dynamic>? json)
factory

Properties

cacheExpire Duration?
缓存时间
final
enableCache bool?
是否开启缓存,若为true,接口响应成功后数据将会保存于本地
final
hashCode int
The hash code for this object.
no setterinherited
printCacheLog bool?
是否打印缓存日志
final
printExceptionLog bool?
打印异常日志
finalinherited
printReqLog bool?
打印请求日志
finalinherited
printResLog bool?
打印响应日志
finalinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
useCache bool?
是否使用缓存数据,如果本地存在数据,ElCacheInterceptor 会则直接响应本地数据。
final

Methods

fromJson(Map<String, dynamic>? json) ElCacheExtra
将 Map 转成对象
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
将对象转成 Map 键值对
override
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited