ErrorEvent

constructor(code: String, message: String?, data: Any? = null, postEvent: () -> Unit? = null)


constructor(error: NRError, postEvent: () -> Unit? = null)

Creates an event from error. code is taken from NRError.errorCode, message from NRError.reason or, if that is null, from NRError.description. error is set as the event's data.