Example #1
0
 internal void Initialize(string id, IActorSystem system, ActorEndpoint endpoint, ActorPrototype prototype)
 {
     Id       = id;
     System   = system;
     Endpoint = endpoint;
     _        = prototype;
 }
Example #2
0
 internal void Initialize(string id, IActorSystem system, ActorEndpoint endpoint, ActorPrototype prototype)
 {
     Id = id;
     System = system;
     Endpoint = endpoint;
     Proto = prototype;
 }
Example #3
0
        internal static ActorPrototype Of(Type actor)
        {
            ActorPrototype prototype = cache.Find(actor);

            return(prototype ?? CreatePrototype(CreateInstance(actor)));
        }
Example #4
0
 internal void Initialize(string id, IActorRuntime runtime, ActorPrototype prototype)
 {
     Id      = id;
     Runtime = runtime;
     _       = prototype;
 }
Example #5
0
 Func <RequestEnvelope, Task <ResponseEnvelope> > Receive(object message)
 {
     return(ActorPrototype.Of(Path.Type).IsReentrant(message)
                ? (Func <RequestEnvelope, Task <ResponseEnvelope> >)endpoint.ReceiveReentrant
                : endpoint.Receive);
 }
Example #6
0
        static Func <object, bool> DeclaredHandlerOnlyFilter(string actorCode)
        {
            var actor = ActorPrototype.Of(actorCode);

            return(x => actor.DeclaresHandlerFor(x.GetType()));
        }