AI-generated Key Takeaways
-
cast.framework.events.ErrorEvent
provides data for errors occurring within the Cast framework. -
It includes properties like
detailedErrorCode
,error
,reason
, andseverity
for detailed error information. -
These properties help developers understand the cause and severity of errors, aiding in debugging and error handling.
-
Constructor parameters allow for setting these properties when creating a new
ErrorEvent
instance.
cast.framework.events. ErrorEvent
Event data for a cast.framework.events.EventType.ERROR
event.
Constructor
ErrorEvent
new ErrorEvent(detailedErrorCode, error, reason, severity)
Parameter |
|
---|---|
detailedErrorCode |
Optional cast.framework.events.DetailedErrorCode Value must not be null. |
error |
Optional Object Value must not be null. |
reason |
Optional cast.framework.messages.ErrorReason Value must not be null. |
severity |
Optional cast.framework.events.ErrorSeverity Value must not be null. |
Properties
detailedErrorCode
(non-null cast.framework.events.DetailedErrorCode or undefined)
An error code representing the cause of the error.
error
(non-null Error, non-null Object, or undefined)
The error object. This could be an Error
object (for example, if an
Error
was thrown in an event handler) or an object with error
information (for example, if the receiver received an invalid command).
reason
(non-null cast.framework.messages.ErrorReason or undefined)
Optional error reason.
severity
(non-null cast.framework.events.ErrorSeverity or undefined)
Optional error severity.