All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.log4s.log4sjs.ExceptionInfo.scala Maven / Gradle / Ivy

package org.log4s
package log4sjs

import scala.scalajs.js

sealed abstract class ExceptionInfo extends js.Object
object ExceptionInfo {
  def apply(t: Throwable): ExceptionInfo = {
    Option(t).map(new ThrowableException(_)).getOrElse(NoException)
  }
  def apply(e: js.Error): ExceptionInfo = {
    Option(e).map(new JsErrorException(_)).getOrElse(NoException)
  }

  object NoException extends ExceptionInfo
  class ThrowableException(val throwable: Throwable) extends ExceptionInfo
  class JsErrorException(val error: js.Error) extends ExceptionInfo
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy