Skip to content

Commit 9186de5

Browse files
committed
Bumping to 0.5.5
1 parent d84410c commit 9186de5

File tree

3 files changed

+12
-12
lines changed

3 files changed

+12
-12
lines changed

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -235,11 +235,11 @@ how to create a DCI project.
235235

236236
## Using Scala DCI in your project
237237

238-
ScalaDCI is available for Scala 2.11.6 at [Sonatype](https://oss.sonatype.org/content/repositories/releases/org/scaladci/scaladci_2.11/0.5.4/).
238+
ScalaDCI is available for Scala 2.11.6 at [Sonatype](https://oss.sonatype.org/content/repositories/releases/org/scaladci/scaladci_2.11/0.5.5/).
239239
To start coding with DCI in Scala add the following to your SBT build file:
240240

241241
libraryDependencies ++= Seq(
242-
"org.scaladci" %% "scaladci" % "0.5.4"
242+
"org.scaladci" %% "scaladci" % "0.5.5"
243243
),
244244
addCompilerPlugin("org.scalamacros" % "paradise" % "2.1.0-M5" cross CrossVersion.full)
245245

@@ -254,7 +254,7 @@ git clone https://github.com/DCI/scaladci.git
254254
Have fun!
255255

256256
Marc Grue<br>
257-
March 2015
257+
April 2015
258258

259259
### DCI resources
260260
Discussions - [Object-composition](https://groups.google.com/forum/?fromgroups#!forum/object-composition)<br>

examples/src/test/scala/scaladci/examples/ShoppingCart7.scala

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -72,9 +72,9 @@ Deviations
7272
// 4 basic "dumb" Data types - Company now has a bank account
7373
object ShoppingCartModel7 {
7474
case class Product(name: String, price: Int)
75-
case class Person(name: String, var cash: Int, owns: mutable.Map[Int, Product] = mutable.Map())
76-
case class Company(name: String, var bankAccount: Int, stock: mutable.Map[Int, Product], goldMembers: mutable.Set[Person])
77-
case class Order(customer: Person, items: mutable.Map[Int, Product] = mutable.Map())
75+
case class User(name: String, var cash: Int, owns: mutable.Map[Int, Product] = mutable.Map())
76+
case class Company(name: String, var bankAccount: Int, stock: mutable.Map[Int, Product], goldMembers: mutable.Set[User])
77+
case class Order(customer: User, items: mutable.Map[Int, Product] = mutable.Map())
7878
}
7979

8080
// Setup for each test
@@ -83,15 +83,15 @@ trait ShoppingCart7setup extends Scope {
8383
val (p1, p2, p3) = (1, 2, 3)
8484
val (wax, tires, bmw) = (p1 -> Product("Wax", 40), p2 -> Product("Tires", 600), p3 -> Product("BMW", 50000))
8585
val shop = Company("Don's Auto shop", 100000, mutable.Map(wax, tires, bmw), mutable.Set())
86-
val customer = Person("Matthew", 20000)
86+
val customer = User("Matthew", 20000)
8787
}
8888

8989
class ShoppingCart7 extends Specification {
9090
import ShoppingCartModel7._
9191

9292
{
9393
@context
94-
class PlaceOrder(comp: Company, person: Person) {
94+
class PlaceOrder(comp: Company, user: User) {
9595

9696
// Trigger methods
9797
def processProductSelection(desiredProductId: Int): Option[Product] = {
@@ -116,9 +116,9 @@ class ShoppingCart7 extends Specification {
116116
// Roles (in order of "appearance")
117117
private val warehouse = comp
118118
private val company = comp
119-
private val customer = person
120-
private val cart = Order(person)
121-
private val paymentGateway = comp
119+
private val customer = user
120+
private val cart = Order(user)
121+
private val paymentGateway = comp // would be played by something else in a real-world application...
122122
private val companyAccount = comp
123123

124124
role warehouse {

project/build.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ object ScalaDciBuild extends Build with Publishing {
4141

4242
lazy val commonSettings = Defaults.coreDefaultSettings ++ Seq(
4343
organization := "org.scaladci",
44-
version := "0.5.4",
44+
version := "0.5.5",
4545
scalaVersion := "2.11.6",
4646
scalacOptions := Seq("-unchecked", "-deprecation", "-feature"),
4747
resolvers ++= Seq(Resolver.sonatypeRepo("releases"), Resolver.sonatypeRepo("snapshots")),

0 commit comments

Comments
 (0)