Created
May 17, 2011 22:52
-
-
Save moreindirection/977598 to your computer and use it in GitHub Desktop.
Dataflow Futures
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import actors.Futures | |
class DataflowFuture[A] private(f : => A) { | |
val future = Futures.future(f) | |
} | |
object DataflowFuture { | |
def apply[A](f : => A) = new DataflowFuture[A](f) | |
implicit def dataflowFutureToVal[A](df : DataflowFuture[A]) : A = df.future.apply() | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment