class TwitterFuture[+T] extends FutureBase[T]
Linear Supertypes
Ordering
- Alphabetic
- By Inheritance
Inherited
- TwitterFuture
- FutureBase
- Future
- AnyRef
- Any
- Hide All
- Show All
Visibility
- Public
- Protected
Instance Constructors
- new TwitterFuture(f: com.twitter.util.Future[T])
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##(): Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- def flatMap[S](f: (T) => Future[S]): Future[S]
- Definition Classes
- TwitterFuture → Future
- def flatMapSuccess[A, B](p: Promise[B], f: (A) => Future[B], value: A): Unit
- Attributes
- protected
- Definition Classes
- FutureBase
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def handle[U >: T](pf: PartialFunction[Throwable, U]): Future[U]
- Definition Classes
- TwitterFuture → Future
- def handleFailure[U >: T](p: Promise[U], pf: PartialFunction[Throwable, U], t: Throwable): Unit
- Attributes
- protected
- Definition Classes
- FutureBase
- def handleWith[U >: T](pf: PartialFunction[Throwable, Future[U]]): Future[U]
Creates a new future that will handle any matching throwable that this future might contain by assigning it a value of another future.
Creates a new future that will handle any matching throwable that this future might contain by assigning it a value of another future.
If there is no match, or if this future contains a valid result then the new future will contain the same result.
Example:
val f = future { Int.MaxValue } future (6 / 0) handle { case e: ArithmeticException => f } // result: Int.MaxValue
Like recoverWith from std lib, related to rescue/handle in twitter.
- Definition Classes
- TwitterFuture → Future
- def handleWithFailure[U >: T](p: Promise[U], pf: PartialFunction[Throwable, Future[U]], t: Throwable): Any
- Attributes
- protected
- Definition Classes
- FutureBase
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- val inner: com.twitter.util.Future[T]
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def map[S](f: (T) => S): Future[S]
- Definition Classes
- TwitterFuture → Future
- def mapSuccess[A, B](promise: Promise[B], f: (A) => B, value: A): Unit
- Attributes
- protected
- Definition Classes
- FutureBase
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- def onComplete[U](func: (Try[T]) => U): Unit
- Definition Classes
- TwitterFuture → Future
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()