stormy_core
library
Classes
AdapterSpec <T >
Configuration that specifies the generation of a TypeAdapter
AnsiPen
Pen attributes for foreground and background colors.
AnyNotifier <StateT , ValueT >
Notifiers
A base class for all "notifiers".
AppLifecycleManager
App 生命周期管理器 - 单例模式
AppLifecycleStateListener
App 生命周期状态监听器
AsyncData <ValueT >
Core
Creates an AsyncValue with a data.
AsyncError <ValueT >
Core
Creates an AsyncValue in the error state.
AsyncLoading <ValueT >
Core
Creates an AsyncValue in loading state.
AsyncNotifier <StateT >
Notifiers
A Notifier implementation that is asynchronously initialized.
AsyncNotifierProvider <NotifierT extends AsyncNotifier <ValueT > , ValueT >
Providers
A provider which creates and listen to an AsyncNotifier .
AsyncResult <ValueT >
A variant of AsyncValue that excludes AsyncLoading .
AsyncValue <ValueT >
Core
A utility for safely manipulating asynchronous data.
AuthInterceptor
鉴权与动态头拦截器
负责全局的 Token 和 Header 分发管理,支持异步等待直至配置完成才发起请求
BackgroundTransformer
The default Transformer for Dio .
BaseOptions
A set of base settings for each Dio().
BaseOptions and Options will be merged into one RequestOptions before
sending the requests. See Options.compose .
BinaryReader
The BinaryReader is used to bring data back from the binary format on the
disk.
BinaryWriter
The BinaryWriter is used to encode data to the binary format.
Box <E >
Boxes contain all of your data. In the browser, each box has its own
IndexedDB database. On all other platforms, each Box is stored in a
separate file in the Hive home directory.
BoxBase <E >
Boxes contain all of your data. In the browser, each box has its own
IndexedDB database. On all other platforms, each Box is stored in a
seperate file in the Hive home directory.
BoxCollection
TODO: Document this!
BoxEvent
A event representing a change in a box.
CancelToken
Controls cancellation of Dio 's requests.
CollectionBox <V >
represents a Box being part of a BoxCollection
ColoredLoggerFormatter
This formatter makes messages colorful
if this setting is enabled in the settings TalkerLoggerSettings
ConsoleUtils
Class that contains methods for working with console output
DataParser <T >
数据解析器抽象基础协议
专门用于处理经过 ResponseParser 基础脱壳后(即抛弃了最外层 code、message 后)的纯净业务 Data。
DefaultTalkerHistory
Base implementation of TalkerHistory
to save the history locally
DependencyGraph
依赖分析器 — 封装拓扑排序和循环依赖检测
Dio
Dio enables you to make HTTP requests easily.
DioMixin
DirectParser <T >
直接透传解析器
不进行任何映射,直接泛型强转。适用于外部不需要模型转换的快速开发场景。
ErrorHandler
全局错误处理器
ErrorInterceptorHandler
The handler for interceptors to handle error occurred during the request.
ExtendedLoggerFormatter
This formatter makes messages colorful
if this setting is enabled in the settings TalkerLoggerSettings
FormData
A class to create readable "multipart/form-data" streams.
It can be used to submit forms and file uploads to http server.
FuncUtils
函数工具类
FusedTransformer
A Transformer that has a fast path for decoding UTF8-encoded JSON.
If the response is utf8-encoded JSON and no custom decoder is specified in the RequestOptions , this transformer
is significantly faster than the default SyncTransformer and the BackgroundTransformer .
This improvement is achieved by using a fused Utf8Decoder and JsonDecoder to decode the response,
which is faster than decoding the utf8-encoded JSON in two separate steps, since
Dart uses a special fast decoder for this case.
See https://github.com/dart-lang/sdk/blob/5b2ea0c7a227d91c691d2ff8cbbeb5f7f86afdb9/sdk/lib/_internal/vm/lib/convert_patch.dart#L40
FutureProvider <ValueT >
Providers
A provider that asynchronously creates a value.
GenerateAdapters
Annotation to generate TypeAdapters for the given specs
The headers class for requests and responses.
HiveAesCipher
Default encryption algorithm. Uses AES256 CBC with PKCS7 padding.
HiveCipher
Abstract cipher can be implemented to customize encryption.
HiveCollection <E extends HiveObjectMixin >
List containing HiveObjectMixin s.
HiveField
Annotate all fields you want to persist with HiveField .
HiveInterface
The main API interface of Hive. Available through the Hive constant.
HiveList <E extends HiveObjectMixin >
Allows defining references to other HiveObjectMixin s.
HiveObject
TODO: Document this!
HiveType
Annotate classes with HiveType to generate a TypeAdapter.
HttpClientAdapter
HttpAdapter is a bridge between Dio and HttpClient .
Interceptor
Interceptor helps to deal with RequestOptions , Response ,
and DioException during the lifecycle of a request
before it reaches users.
Interceptors
A Queue-Model list for Interceptor s.
InterceptorsWrapper
A helper class to create interceptors in ease.
IsolatedBox <E >
Isolated version of Box
IsolatedBoxBase <E >
Isolated version of BoxBase
IsolatedCompactionStrategy
A sendable description of a CompactionStrategy
IsolatedHiveInterface
Interface for IsolatedHive
IsolatedLazyBox <E >
Isolated version of LazyBox
IsolateNameServer
An abstraction of the IsolateNameServer
IStorageEngine
存储引擎规范,定义底层具体实现的存储驱动(如 Hive、SharedPreferences)行为
JsonListParser <T >
标准 JSON 列表解析器
用于解析 [ { "id": 1 }, { "id": 2 } ] 格式的列表。
JsonPageParser <T >
标准分页列表解析器
用于解析结构如:
{ "list": [{...}, {...}], "page": 1, "total": 100 }
或
{ "content": [{...}], "page": { "number": 1, "totalElements": 100 } }
JsonParser <T >
标准 JSON 对象解析器
用于解析 { "id": 1, "name": "foo" } 格式的对象。
LazyBox <E >
LazyBox es don't keep the values in memory like normal boxes. Each time a
value is read, it is loaded from the backend.
LevelLogFilter
日志等级过滤器
ListParam <T >
Indicates a param being used as queries or form data,
and how does it gets formatted.
LogDetails
A class for transporting data
about an log message
LogFilter
日志过滤器接口
LoggerFilter
Abstract filter for messages logging.
LoggerFormatter
Responsible for formatting message before output
LoggingInterceptor
日志拦截器工厂类
封装 TalkerDioLogger 以便提供高颜值且符合项目规范的日志
LogInterceptor
LogInterceptor is used to print logs during network requests.
It should be the last interceptor added,
otherwise modifications by following interceptors will not be logged.
This is because the execution of interceptors is in the order of addition.
LogLevelFilter
This filter checks that current message level
is above certain LogLevel setting in TalkerLoggerSettings
LogSettings
日志配置类
MoneyFormat
MultipartFile
An upload content that is a part of MultipartRequest.
This doesn't need to correspond to a physical file.
Notifier <ValueT >
Notifiers
A class which exposes a state that can change over time.
NotifierProvider <NotifierT extends Notifier <ValueT > , ValueT >
Providers
A provider that exposes a synchronous Notifier .
Options
The configuration for a single request.
BaseOptions and Options will be merged into one RequestOptions before
sending the requests. See Options.compose .
PaginatedResult <T >
分页包装结果
分页元数据信息
PrefixLogFilter
日志前缀过滤器
PreloadConfig
预加载全局配置
PreloadEngine
预加载执行引擎 — 封装任务验证、依赖解析、执行、重试逻辑
PreloadExecutionResult
预加载执行结果
PreloadManager
预加载管理器 — Facade 模式,负责任务注册、状态流转、对外 API
PreloadProgress
预加载进度信息
PreloadSemaphore
并发控制信号量 — 实现真正的并发数限制
修复原设计中 maxConcurrentTasks 定义但从未生效的问题
PreloadTask <T >
预加载任务 — 通用任务模型
PreloadTracker
进度追踪器 — 监听任务状态变更,计算并推送进度更新
Provider <ValueT >
Providers
A provider that exposes a read-only value.
ProviderContainer
Core
An object that stores the state of the providers and allows overriding the
behavior of a specific provider.
ProviderObserver
Core
An object that listens to the changes of a ProviderContainer .
ProviderObserverContext
Core
Information about the ProviderObserver event.
ProviderReference
The response of ProviderContainer.allProviders .
ProviderSubscription <OutT >
Core
Represents the subscription to a ProviderListenable.
QueuedInterceptor
Interceptor in queue.
QueuedInterceptorsWrapper
A helper class to create QueuedInterceptor in ease.
RedirectRecord
A record that records the redirection happens during requests,
including status code, request method, and the location.
Ref
Core
An object used by providers to interact with other providers and the life-cycles
of the application.
RequestInterceptorHandler
The handler for interceptors to handle before the request has been sent.
RequestOptions
The internal request option class that is the eventual result after
BaseOptions and Options are composed.
Response <T >
The Response class contains the payload (could be transformed)
that respond from the request, and other information of the response.
ResponseBody
The response wrapper class for adapters.
ResponseInterceptorHandler
The handler for interceptors to handle after respond.
ResponseParser
响应字段解析器
用于根据配置拆包外层格式,提取真实 data,或报错抛出业务异常。
ResponseParsingConfig
响应字段解析配置
RetryInterceptor
请求重试拦截器
当发生网络层错误进行有限策略重试
StorageBucket
StorageBucketAccessor
分区访问控制器代理类
StorageEntry <T >
存储条目 - 用于封装带过期时间的数据
StormyListStorage <T >
专门用于处理列表数据的存储封装
StormyLog
日志工具类
StormyNetworkClient
Stormy 统一业务底层网络请求客户端
StormyNetworkConfig
网络配置类
StormyServices
Optional default services; applications can also own independent clients.
StormyStorage
StormyStorage - 统一存储总控入口
采用面相对象模型与 Accessor 返回隔离实例执行工作。
StormyStorage 本身混入了 StorageOperations ,可以直接对设定的 Default Bucket 操作键值对。
StormyStorageConfig
Storage Config - 存储配置
用于配置本地存储的相关参数
StreamNotifier <ValueT >
Notifiers
A variant of AsyncNotifier which has build creating a Stream .
StreamNotifierProvider <NotifierT extends StreamNotifier <ValueT > , ValueT >
Providers
A provider which creates and listen to an StreamNotifier .
StreamProvider <ValueT >
Providers
Creates a stream and exposes its latest event.
SyncTransformer
If you want to custom the transformation of request/response data,
you can provide a Transformer by your self, and replace
the transformer by setting the Dio.transformer .
Talker
Talker - advanced exception handling and logging
for dart/flutter applications
TalkerData
Base Talker Data transfer object
Objects of this type are passed through
handlers observer and stream
TalkerDateTimeFormatter
Utility class for DateTime formatting.
TalkerError
Base implementation of TalkerData
to handle ONLY Error s
TalkerErrorHandler
TalkerException
Base implementation of TalkerData
to handle ONLY Exceptionss
TalkerFilter
TalkerHistory
Base class for create your own implementation of history
TalkerJsonFormatter
Formatter for converting data to pretty JSON strings.
TalkerKey
TalkerKey - String key of log type (After 5.0.0)
TalkerLogType (Before 5.0.0)
TalkerLog
Base implementation of TalkerData
to create Logs
TalkerLogger
TalkerLoggerSettings
Logger customization settings
TalkerObserver
Base observer class for
to create your own observers
TalkerSettings
This class used for setup Talker configuration
TaskConfig
TaskExecutionContext
任务执行上下文 — 管理单个任务的执行状态
替代原 PreloadTask 的可变内部状态
Transformer
Transformer allows changes to the request/response data before
it is sent/received to/from the server.
TypeAdapter <T >
Type adapters can be implemented to support non primitive values.
TypeLogFilter
日志类型过滤器
TypeRegistry
TypeRegistries contain the TypeAdapter s associated with a typeId.
Uuid
uuid for Dart
Author: Yulian Kuncheff
Released under MIT License.
UuidUtils
UuidValue
WatchBoxBuilder
A general-purpose widget which rebuilds itself when the box or a specific
key change.
Typedefs
BoxWidgetBuilder <T >
= Widget Function(BuildContext context , Box <T > box )
Signature for a function that builds a widget given a Box .
CompactionStrategy
= bool Function(int entries , int deletedEntries )
A function which decides when to compact a box.
DefaultTransformer
= SyncTransformer
DioError
= DioException
DioError describes the exception info when a request failed.
DioErrorType
= DioExceptionType
Deprecated in favor of DioExceptionType and will be removed in future major versions.
DioExceptionReadableStringBuilder
= String Function(DioException e )
The readable string builder's signature of
DioException.readableStringBuilder .
DioMediaType
= MediaType
The type (alias) for specifying the content-type of the MultipartFile.
The signature that iterates header fields.
HiveLogger
= Logger
Hive's logger
HiveLoggerLevel
= LoggerLevel
Hive's logger level
InterceptorErrorCallback
= void Function(DioException error , ErrorInterceptorHandler handler )
The signature of Interceptor.onError .
InterceptorSendCallback
= void Function(RequestOptions options , RequestInterceptorHandler handler )
The signature of Interceptor.onRequest .
InterceptorSuccessCallback
= void Function(Response response , ResponseInterceptorHandler handler )
The signature of Interceptor.onResponse .
JsonDecodeCallback
= FutureOr Function(String )
The callback definition for decoding a JSON string.
JsonEncodeCallback
= FutureOr <String > Function(Object )
The callback definition for encoding a JSON object.
KeyComparator
= int Function(dynamic key1 , dynamic key2 )
LoggerOutput
= void Function(String message )
OnUnauthorized
= Future <void > Function(DioException error )
ProgressCallback
= void Function(int count , int total )
The type of a progress listening callback when sending or receiving data.
RequestEncoder
= FutureOr <List <int > > Function(String request , RequestOptions options )
The type of a request encoding callback.
ResponseDecoder
= FutureOr <String ? > Function(List <int > responseBytes , RequestOptions options , ResponseBody responseBody )
The type of a response decoding callback.
RetryEvaluator
= Future <bool > Function(DioException error , int attempt )
ValidateStatus
= bool Function(int ? status )
The type of a response status code validate callback.