FayeError class

Faye error class for handling Bayeux protocol errors

Implemented types

Constructors

FayeError(String code, String message, {List<String>? params, Map<String, dynamic>? args, int? httpCode, String? httpBody, StackTrace? stackTrace})
FayeError.authentication(String message)
Create an authentication error
factory
FayeError.channel(String channel, String reason)
Create a channel error
factory
FayeError.fromBayeux(Map<String, dynamic> error)
Create an error from a Bayeux error response
factory
FayeError.fromHttp(int statusCode, String body)
Create an error from HTTP response
factory
FayeError.network(String message, {StackTrace? stackTrace})
Create a network error
factory
FayeError.protocol(String message)
Create a protocol error
factory
FayeError.publication(String channel, String reason)
Create a publication error
factory
FayeError.subscription(String channel, String reason)
Create a subscription error
factory
FayeError.timeout(String operation)
Create a timeout error
factory

Properties

args → Map<String, dynamic>?
Error arguments (optional)
final
code → String
Error code (3-digit number)
final
hashCode → int
The hash code for this object.
no setteroverride
httpBody → String?
HTTP response body (optional)
final
httpCode → int?
HTTP status code (optional)
final
isAuthenticationError → bool
Check if this is an authentication error
no setter
isChannelError → bool
Check if this is a channel error
no setter
isNetworkError → bool
Check if this is a network error
no setter
isProtocolError → bool
Check if this is a protocol error
no setter
isPublicationError → bool
Check if this is a publication error
no setter
isSubscriptionError → bool
Check if this is a subscription error
no setter
isTimeoutError → bool
Check if this is a timeout error
no setter
message → String
Error message
final
params → List<String>?
Error parameters (optional)
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
stackTrace → StackTrace?
Stack trace
final

Methods

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

Operators

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