Ask

cc.otavia.core.message.Ask
trait Ask[R <: Reply] extends Call

A Call that expects a reply of type R. When an actor receives an Ask, it must eventually call stack.return(reply) to deliver a R back to the sender.

The match type ReplyOf extracts R from an Ask at compile time, enabling type-safe request-response patterns without manual casting:

case class GetUser(id: Long) extends Ask[User]
// ReplyOf[GetUser] resolves to User at compile time

Type parameters

R

the expected reply type

Attributes

Graph
Supertypes
trait Call
trait Message
trait Serializable
class Object
trait Matchable
class Any
Show all
Known subtypes
class Bind
trait Connect
class HttpRequest[C, R]
trait Command[R]
class Auth
class Del
class Get
class HGetAll
class HSet
class Info
class Select
class Set
class ExecuteCursor[R]
trait PrepareQuery[T]
trait SimpleQuery[T]
Show all
In this article