예제 #1
0
파일: ImdbHub.cs 프로젝트: bnayae/SDP-2015
        public async Task SendMovieAsync(TwittData  data)
        {
            IImdbEvents e = GetEvent<IImdbEvents>();

            // Clients can listen for the event 
            // (events shouldn't be used for Actor's internal communication)
            // when ready Rx 3 will be the publication mechanism
            e.LikeMovie(data);

            #region Log

            var logId = Constants.Singleton;
            var logProxy = ActorProxy.Create<IImdbFaults>(logId);
            await logProxy.Report($"Raise Movie Event: {data.Name}");

            #endregion // Log
        }
예제 #2
0
파일: ImdbHub.cs 프로젝트: bnayae/SDP-2015
        public async Task SendStarAsync(TwittData data)
        {
            ActorEventSource.Current.ActorMessage(this, data.Name);

            // Clients can listen for the event 
            // (events shouldn't be used for Actor's internal communication)
            // when ready Rx 3 will be the publication mechanism
            IImdbEvents e = GetEvent<IImdbEvents>();
            e.LikeStar(data);

            #region Log

            var logId = Constants.Singleton;
            var logProxy = ActorProxy.Create<IImdbFaults>(logId);
            await logProxy.Report($"Raise Star Event: {data.Name}");

            #endregion // Log
        }