VibecallError class

Base error class for the VibeCall SDK

This class provides detailed information about errors that occur within the SDK, including error codes, severity levels, and recovery actions.

Implemented types

Constructors

VibecallError({required String message, required ErrorCode code, ErrorSeverity severity = ErrorSeverity.error, RecoveryAction? recoveryAction, Future<RecoveryResult> recoveryFunction()?, StackTrace? stackTrace, dynamic originalException, Map<String, dynamic>? context})
Creates a new VibeCall error with the specified details
VibecallError.camera(String details, {ErrorCode code = ErrorCode.cameraError, ErrorSeverity severity = ErrorSeverity.error, RecoveryAction? recoveryAction, Future<RecoveryResult> recoveryFunction()?, StackTrace? stackTrace, dynamic originalException, Map<String, dynamic>? context})
Factory constructor for creating camera-related errors
factory
VibecallError.faceDetection(String details, {ErrorCode code = ErrorCode.faceDetectionError, ErrorSeverity severity = ErrorSeverity.error, RecoveryAction? recoveryAction, Future<RecoveryResult> recoveryFunction()?, StackTrace? stackTrace, dynamic originalException, Map<String, dynamic>? context})
Factory constructor for creating face detection related errors
factory
VibecallError.media(String details, {ErrorCode code = ErrorCode.mediaError, ErrorSeverity severity = ErrorSeverity.error, RecoveryAction? recoveryAction, Future<RecoveryResult> recoveryFunction()?, StackTrace? stackTrace, dynamic originalException, Map<String, dynamic>? context})
Factory constructor for creating media-related errors
factory
VibecallError.network(String details, {ErrorCode code = ErrorCode.networkError, ErrorSeverity severity = ErrorSeverity.error, RecoveryAction? recoveryAction = RecoveryAction.retry, Future<RecoveryResult> recoveryFunction()?, StackTrace? stackTrace, dynamic originalException, Map<String, dynamic>? context})
Factory constructor for creating network-related errors
factory
VibecallError.permission(String details, {ErrorCode code = ErrorCode.permissionDenied, ErrorSeverity severity = ErrorSeverity.error, RecoveryAction? recoveryAction = RecoveryAction.requestPermission, Future<RecoveryResult> recoveryFunction()?, StackTrace? stackTrace, dynamic originalException, Map<String, dynamic>? context})
Factory constructor for creating permission-related errors
factory
VibecallError.segmentation(String details, {ErrorCode code = ErrorCode.segmentationError, ErrorSeverity severity = ErrorSeverity.error, RecoveryAction? recoveryAction, Future<RecoveryResult> recoveryFunction()?, StackTrace? stackTrace, dynamic originalException, Map<String, dynamic>? context})
Factory constructor for creating segmentation-related errors
factory
VibecallError.signaling(String details, {ErrorCode code = ErrorCode.signalingError, ErrorSeverity severity = ErrorSeverity.error, RecoveryAction? recoveryAction, Future<RecoveryResult> recoveryFunction()?, StackTrace? stackTrace, dynamic originalException, Map<String, dynamic>? context})
Factory constructor for creating signaling-related errors
factory
VibecallError.webrtc(String details, {ErrorCode code = ErrorCode.webrtcError, ErrorSeverity severity = ErrorSeverity.error, RecoveryAction? recoveryAction, Future<RecoveryResult> recoveryFunction()?, StackTrace? stackTrace, dynamic originalException, Map<String, dynamic>? context})
Factory constructor for creating WebRTC-related errors
factory

Properties

canRecover bool
Whether a recovery action is available for this error
no setter
code ErrorCode
Error code that identifies the type of error
final
context Map<String, dynamic>?
Additional context information about the error
final
hashCode int
The hash code for this object.
no setterinherited
isCritical bool
Whether this error is considered critical
no setter
message String
Human-readable error message
final
originalException → dynamic
Original exception that caused this error, if any
final
recoveryAction RecoveryAction?
Action that can be taken to recover from the error, if any
final
requiresUserIntervention bool
Whether this error requires user intervention to resolve
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
severity ErrorSeverity
Severity level of the error
final
stackTrace StackTrace?
Stack trace where the error occurred, if available
final

Methods

attemptRecovery() Future<RecoveryResult>
Attempts to recover from this error using the registered recovery function
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
override

Operators

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