This file contains hidden or 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
| test |
This file contains hidden or 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
| net = require "net" | |
| hashring = require "hashring" | |
| zkplus = require "zkplus" | |
| bouncy = require "bouncy" | |
| {_} = require "UnderscoreKit" | |
| ring = new hashring() | |
| client = zkplus.createClient | |
| servers: [{ |
This file contains hidden or 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 Network.HTTP | |
| import Text.HTML.TagSoup | |
| import System | |
| import System.Process | |
| import Control.Monad | |
| import IO | |
| hackerNewsRSSFeedURL = "http://news.ycombinator.com/rss" | |
| fileURLCache = ".hnCache" |
This file contains hidden or 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
| package com.plasmaconduit.pipelines | |
| sealed trait Pipeline[E, A] { | |
| def map[B](f: A => A): Pipeline[E, A] = this match { | |
| case Continue(n) => Continue(f(n)) | |
| case Done(n) => Done(n) | |
| case Error(e) => Error(e) | |
| } |
This file contains hidden or 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
| var trait = require("../../util/trait"); | |
| module.exports = trait("UserServiceInterface", [ | |
| "createUser", | |
| "createUserFromForm", | |
| "getUserByEmail", | |
| "authenticateUser", | |
| "authenticateUserFromForm", | |
| "isUserAdmin" | |
| ]); |
This file contains hidden or 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
| <?php | |
| $loop = PureLoop::loop(); | |
| $ticked = $loop->flatMap(function(PureLoop $loop) { | |
| return $loop->nextTick(function(PureLoop $loop) { | |
| return StdIO::putStrLn("Hello from tick")->then(IO::of($loop)); | |
| }); | |
| }); | |
| $timed = $ticked->flatMap(function(PureLoop $loop) { |
This file contains hidden or 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
| package com.blackboxsociety.http | |
| import scala.util.parsing.combinator._ | |
| sealed trait HttpMethod | |
| case object HttpGet extends HttpMethod | |
| case object HttpHead extends HttpMethod | |
| case object HttpPost extends HttpMethod | |
| case object HttpPut extends HttpMethod | |
| case object HttpDelete extends HttpMethod |
This file contains hidden or 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 scalaz._ | |
| import scalaz.concurrent._ | |
| import Future._ | |
| object Main { | |
| def lamePrint(s: String): Future[Unit] = async { next => | |
| println(s) | |
| next() | |
| } |
This file contains hidden or 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
| <?hh // strict | |
| namespace traitorous; | |
| use traitorous\algebraic\Applicative; | |
| use traitorous\algebraic\Functor; | |
| use traitorous\algebraic\Monad; | |
| use traitorous\algebraic\MonadOps; | |
| final class IO<T> implements Functor<T>, Applicative<T>, Monad<T> { |
This file contains hidden or 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
| resolvers += "Plasma Conduit Repository" at "http://dl.bintray.com/plasmaconduit/releases", | |
| libraryDependencies += "com.plasmaconduit" %% "plasmaconduit-framework" % "0.50.0" |
OlderNewer