예제 #1
0
 public ActorMetaData(string name, ActorMetaData parent, bool useBuildInId)
 {
     SetActorMetaData(name, parent, useBuildInId);
 }
예제 #2
0
        public static ActorSelection ActorSelection(this IUntypedActorContext context, ActorMetaData targetActorMetaData)
        {
            var pathWithOutAdress = context.Self.Path.ToString().Replace(context.Self.Path.Address.ToString(), "");
            var source            = pathWithOutAdress.TrimStart('/').Split('/').ToList();

            source.Reverse();

            var target = new List <string>();
            var currentActorMetaData = targetActorMetaData;

            while (currentActorMetaData != null)
            {
                if (currentActorMetaData.Name != null)
                {
                    target.Add(currentActorMetaData.Name);
                }
                else
                {
                    target.Add(null);
                }
                currentActorMetaData = currentActorMetaData.Parent;
            }
            target.Add("user");
            string relativePath = CreateInterpretedRelativePath(source, target);

            return(context.ActorSelection(relativePath));
        }
예제 #3
0
 public ActorMetaData(string name, ActorMetaData parent)
 {
     SetActorMetaData(name, parent);
 }