コード例 #1
0
        public void Check()
        {
            using (ListComponent <long> list = EntityFactory.Create <ListComponent <long> >(Domain))
            {
                long timeNow = TimeHelper.CurrentLocalMilliseconds();
                foreach ((long key, Entity value) in Children)
                {
                    ActorLocationSender actorLocationMessageSender = (ActorLocationSender)value;

                    if (timeNow > actorLocationMessageSender.LastSendOrRecvTime + TIMEOUT_TIME)
                    {
                        list.List.Add(key);
                    }
                }

                foreach (long id in list.List)
                {
                    Remove(id);
                }
            }
        }
コード例 #2
0
        public async Task <IActorResponse> Call(long entityId, IActorLocationRequest message)
        {
            ActorLocationSender actorLocationSender = Get(entityId);

            return(await actorLocationSender.Call(message));
        }
コード例 #3
0
        public void Send(long entityId, IActorLocationMessage message)
        {
            ActorLocationSender actorLocationSender = Get(entityId);

            actorLocationSender.Send(message);
        }