class AsyncErrorEvent
package openfl.events
extends ErrorEvent › TextEvent › Event
Available on all platforms
An object dispatches an AsyncErrorEvent when an exception is thrown from
native asynchronous code, which could be from, for example,
LocalConnection, NetConnection, SharedObject, or NetStream. There is only
one type of asynchronous error event: AsyncErrorEvent.ASYNC_ERROR
.
Static variables
staticinlineread onlyASYNC_ERROR:EventType<AsyncErrorEvent> = "asyncError"
The AsyncErrorEvent.ASYNC_ERROR
constant defines the value of the
type
property of an asyncError
event object.
This event has the following properties:
Property | Value |
---|---|
bubbles | false |
cancelable | false ; there is no default behavior to cancel. |
currentTarget | The object that is actively processing the Event object with an event listener. |
target | The object dispatching the event. |
error | The error that triggered the event. |
Constructor
new(type:String, bubbles:Bool = false, cancelable:Bool = false, text:String = "", ?error:Dynamic)
Creates an AsyncErrorEvent object that contains information about asyncError events. AsyncErrorEvent objects are passed as parameters to event listeners.
Parameters:
type | The type of the event. Event listeners can access
this information through the inherited |
---|---|
bubbles | Determines whether the Event object bubbles. Event
listeners can access this information through the
inherited |
cancelable | Determines whether the Event object can be canceled.
Event listeners can access this information through
the inherited |
text | Text to be displayed as an error message. Event
listeners can access this information through the
|
error | The exception that occurred. If error is non-null,
the event's |