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 akka.http.scaladsl | |
| import java.io.File | |
| import akka.http.scaladsl.unmarshalling.Unmarshal | |
| import akka.util.ByteString | |
| import scala.concurrent.duration._ | |
| import akka.actor.ActorSystem |
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
| Verifying that +johanprinsloo is my openname (Bitcoin username). https://onename.com/johanprinsloo |
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
| #!/bin/sh | |
| SCRIPT="$(cd "${0%/*}" 2>/dev/null; echo "$PWD"/"${0##*/}")" | |
| DIR=`dirname "${SCRIPT}"}` | |
| exec scala -savecompiled $0 $DIR $SCRIPT | |
| ::!# | |
| import scala.xml._ | |
| object App { | |
| def main(args: Array[String]): Unit = { |
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 += { | |
| val typesafeRepoUrl = new java.net.URL("http://repo.typesafe.com/typesafe/releases") | |
| val pattern = Patterns(false, "[organisation]/[module]/[sbtversion]/[revision]/[type]s/[module](-[classifier])-[revision].[ext]") | |
| Resolver.url("Typesafe Repository", typesafeRepoUrl)(pattern) | |
| } | |
| resolvers += "sbt-idea-repo" at "http://mpeltonen.github.com/maven/" | |
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 sbt._ | |
| object PluginDef extends Build { | |
| override def projects = Seq(root) | |
| lazy val root = Project("plugins", file(".")) .dependsOn( growl ) | |
| .dependsOn( np ) | |
| .dependsOn( proguard ) | |
| lazy val growl = uri("git://github.com/softprops/sbt-growl-plugin.git#0.1.2") | |
| lazy val np = uri("git://github.com/softprops/np.git#0.1.0") | |
| lazy val proguard = uri("git://github.com/siasia/xsbt-proguard-plugin.git") |
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
| /** | |
| * Linear system model | |
| * b = Ax | |
| * solve for x | |
| */ | |
| class LinearModel(size: Int) extends Model | |
| { | |
| var b = DenseVector.rand(size) | |
| var x = DenseVector.rand(size) |
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
| class TestActor extends Actor { | |
| var loadreport: List[Double] = List.empty | |
| var reportcount = 0 | |
| def act = { | |
| loop { | |
| react { | |
| case load_report: CPUloadReport => { | |
| loadreport = load_report.cpuloads |
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 org.scratch.act | |
| import actors.Actor | |
| case class Register(actor: Actor) | |
| case class Unregister(actor: Actor) | |
| case class Message( contents: String ) | |
| object ActorRegistry extends Actor{ | |
| var registry: Set[Actor] = Set.empty |
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
| <lift:surround with="default" at="content"> | |
| <h2>Dynamic Simulation UI - Tree Components...</h2> | |
| <p> | |
| <lift:TimeStamp.stab> | |
| <span><i>Generated at <b:time/></i></span> | |
| </lift:TimeStamp.stab> | |
| </p> | |
| </lift:surround> | |
| class TimeStamp { |
NewerOlder