Skip to content

Instantly share code, notes, and snippets.

Avatar

Johannes Rudolph jrudolph

View GitHub Profile
View API-proposal.scala
object Tcp {
trait ConnectionDescriptor {
def remoteAddress: InetSocketAddress
def localAddress: InetSocketAddress
}
sealed trait ConnectionFlow extends Flow[ByteString, ByteString] {
def remoteAddress(mMap: MaterializedMap): InetSocketAddress
def localAddress(mMap: MaterializedMap): InetSocketAddress
View spray-chunked-test.scala
package ru.metahouse.metabus
import akka.actor._
import akka.io.IO
import spray.can.Http
import spray.routing.HttpServiceActor
import spray.http._
import spray.http.MediaTypes._
import scala.concurrent.ExecutionContext.Implicits.global
import spray.http.ChunkedResponseStart
View SslEchoClient.scala
package spray.examples
import scala.concurrent.duration.Duration
import scala.concurrent.duration._
import akka.actor._
import akka.pattern.ask
import spray.util._
import spray.io._
import akka.event.LoggingAdapter
import akka.util.Timeout
@jrudolph
jrudolph / .gitignore
Created Oct 19, 2012
Regression bug in Scala 2.10.0-RC1
View .gitignore
/.idea/
target/
lib_managed/
src_managed/
test-output/
*.iml
@jrudolph
jrudolph / gist:1097283
Created Jul 21, 2011
Show the non-Existential Of God
View gist:1097283
abstract class Action
case object Eat extends Action
case object Speak extends Action
case object Move extends Action
abstract class Creature (val action: Action)
case class Fish (a: Action, val size: String) extends Creature (a)
case class Dog (a: Action, val sound: String) extends Creature (a)
View Problem.scala
package wolv.parserlibproblem
import util.parsing.ast.AbstractSyntax
import util.parsing.combinator.syntactical.TokenParsers
import util.parsing.combinator.lexical.Lexical
import util.parsing.combinator.token.Tokens
trait SimpleTokens extends Tokens {
case class Foo extends Token
case class Bar extends Token
You can’t perform that action at this time.