Ejemplo n.º 1
0
        private IActorRef CreateActor(string actorTypeName, string?name = null)
        {
            var actorType = Type.GetType(actorTypeName);

            if (actorType == null)
            {
                throw new InvalidOperationException($"Couldn't get a Type for type name '{actorTypeName}'");
            }
            var props = dependencyResolver.CreateActorProps(actorType, actorSystem);

            return(actorSystem.ActorOf(props, name));
        }