public Actor(ProcessId parent, ProcessName name, Func <S, T, S> actor, Func <S> setup) { if (setup == null) { throw new ArgumentNullException(nameof(setup)); } if (actor == null) { throw new ArgumentNullException(nameof(actor)); } actorFn = actor; setupFn = setup; Parent = parent; Name = name; Id = new ProcessId(parent.Value + "/" + name); StartMailboxes(); ActorContext.AddToStore(Id, this); }