public RoomActor(RoomCommandHandler commandHandler) { _projectionEngine = Context.System.ActorSelection("/user/ConsoleUi/projectionEngine"); _commandHandler = commandHandler; // kill the actor after inactivity Receive <ReceiveTimeout>(timeout => Self.Tell(PoisonPill.Instance)); ReceiveAsync <EnableBookingCommand>(Handle); ReceiveAsync <DisableBookingCommand>(Handle); ReceiveAsync <BookRoomCommand>(Handle); }
public RoomsController(RoomCommandHandler handler, ILoggingService loggingService) : base(handler, loggingService) { }