1. Installation
Table of contents
Setting up your project using sbt
The following instructions will use sbt as the build tool to manage your project and its dependencies.
After installing sbt (see their documentation for more information on that) run the following shell commands to create a new sbt project.
$ mkdir my-chat-app
$ cd my-chat-app
$ touch build.sbt
Getting ScalaLoci
Now there are a few steps needed to install the ScalaLoci language for use in your Scala project. (Those are copied from the ScalaLoci Github repository so you might want to check there too just in case anything changes.)
-
Enable the Macro Paradise Plugin (for macro annotations) in your
build.sbt
addCompilerPlugin("org.scalamacros" % "paradise" % "2.1.1" cross CrossVersion.patch)
-
Add the resolver for the ScalaLoci dependencies to your
build.sbt
resolvers += Resolver.bintrayRepo("stg-tud", "maven")
-
Add the ScalaLoci dependencies that you need for your system to your
build.sbt
-
ScalaLoci language (always required)
libraryDependencies += "de.tuda.stg" %% "scala-loci-lang" % "0.3.0"
-
Transmitter for the types of values to be accessed remotely (built-in Scala types and standard collections are directly supported without additional dependencies)
-
REScala reactive events and signals
libraryDependencies += "de.tuda.stg" %% "scala-loci-lang-transmitter-rescala" % "0.3.0"
-
-
Network communicators to connect the different components of the distributed system
-
TCP [JVM only]
libraryDependencies += "de.tuda.stg" %% "scala-loci-communicator-tcp" % "0.3.0"
-
WebSocket (using Akka HTTP on the JVM) [server: JVM only, client: JVM and JS web browser APIs]
libraryDependencies += "de.tuda.stg" %% "scala-loci-communicator-ws-akka" % "0.3.0"
-
WebSocket (Play integration) [server: JVM only, client: JVM and JS web browser APIs]
libraryDependencies += "de.tuda.stg" %% "scala-loci-communicator-ws-akka-play" % "0.3.0"
-
WebRTC [JS web browser APIs only]
libraryDependencies += "de.tuda.stg" %% "scala-loci-communicator-webrtc" % "0.3.0"
-
-
Serializer for network communication
-