diff options
author | Jakob Odersky <jodersky@gmail.com> | 2013-07-25 17:59:44 +0200 |
---|---|---|
committer | Jakob Odersky <jodersky@gmail.com> | 2013-07-25 17:59:44 +0200 |
commit | 9efeb44063001d4df0fb7a665a52bfcc52d5a290 (patch) | |
tree | b7815d86108031ab7bd95506523889d0c073a4f2 /flow-main/src | |
parent | 0e90e8868ae11284e1fe8926e2a7490195267cc7 (diff) | |
download | akka-serial-9efeb44063001d4df0fb7a665a52bfcc52d5a290.tar.gz akka-serial-9efeb44063001d4df0fb7a665a52bfcc52d5a290.tar.bz2 akka-serial-9efeb44063001d4df0fb7a665a52bfcc52d5a290.zip |
add explicit reference to operator in open command
Diffstat (limited to 'flow-main/src')
-rw-r--r-- | flow-main/src/main/scala/com/github/jodersky/flow/Serial.scala | 2 | ||||
-rw-r--r-- | flow-main/src/main/scala/com/github/jodersky/flow/SerialManager.scala | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/flow-main/src/main/scala/com/github/jodersky/flow/Serial.scala b/flow-main/src/main/scala/com/github/jodersky/flow/Serial.scala index f8305c2..54fea6b 100644 --- a/flow-main/src/main/scala/com/github/jodersky/flow/Serial.scala +++ b/flow-main/src/main/scala/com/github/jodersky/flow/Serial.scala @@ -37,7 +37,7 @@ object Serial extends ExtensionKey[SerialExt] { * @param twoStopBits set to use two stop bits instead of one * @param parity type of parity to use with serial port */ - case class Opened(port: String, baud: Int, characterSize: Int, twoStopBits: Boolean, parity: Parity.Parity) extends Event + case class Opened(port: String, baud: Int, characterSize: Int, twoStopBits: Boolean, parity: Parity.Parity, operator: ActorRef) extends Event case class Register(receiver: ActorRef) extends Command diff --git a/flow-main/src/main/scala/com/github/jodersky/flow/SerialManager.scala b/flow-main/src/main/scala/com/github/jodersky/flow/SerialManager.scala index ce75cc0..0d69213 100644 --- a/flow-main/src/main/scala/com/github/jodersky/flow/SerialManager.scala +++ b/flow-main/src/main/scala/com/github/jodersky/flow/SerialManager.scala @@ -36,7 +36,7 @@ class SerialManager extends Actor with ActorLogging { case Failure(t) => sender ! CommandFailed(c, t) case Success(serial) => { val operator = context.actorOf(Props(classOf[SerialOperator], serial), name = escapePortString(port)) - val opened = Opened(serial.port, serial.baud, serial.characterSize, serial.twoStopBits, Parity(serial.parity)) + val opened = Opened(serial.port, serial.baud, serial.characterSize, serial.twoStopBits, Parity(serial.parity), operator) sender.tell(opened, operator) } } |