ReadiumError class

Constructors

ReadiumError(String message, {String? code, Map<String, dynamic>? details})
ReadiumError.fromJson(Map<String, dynamic> json)
factory
ReadiumError.fromPlatformException(PlatformException ex)
factory

Properties

attempt int?
The current retry attempt number, for informational recovery events (e.g. audioStreamRetry).
no setter
code String?
Raw wire code as sent by the native side. Kept for backwards compatibility and debugging; prefer codeEnum for typed handling.
final
codeEnum ReadiumErrorCode
Typed classification of code, parsed once at construction time. Falls back to ReadiumErrorCode.unknown for unrecognised or missing codes — never throws.
final
details Map<String, dynamic>?
Structured supplementary payload. All fields are optional and producer specific — see docs/api-reference/error-codes.md. Prefer the typed getters (href, attempt, maxAttempts, httpStatus) over reading this map directly.
final
hashCode int
The hash code for this object.
no setteroverride
href String?
The resource href the error relates to, if any (e.g. the audio resource being streamed).
no setter
httpStatus int?
The HTTP status code that triggered the error, when known.
no setter
isFatal bool
Mirrors ReadiumErrorCode.isFatal for convenience when handling stream events or exception payloads directly.
no setter
isInformational bool
Mirrors ReadiumErrorCode.isInformational for convenience when handling stream events or exception payloads directly.
no setter
maxAttempts int?
The maximum number of retry attempts, for informational recovery events (e.g. audioStreamRetry).
no setter
message String
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
toString() String
A string representation of this object.
override

Operators

operator ==(covariant Object other) bool
The equality operator.
override