Beispiel #1
0
 public static void RegisterHandler <TEventType>(this IAfEventHub afEventHub,
                                                 Action <ILifetimeScope, IAfEvent> action)
     where TEventType : class, IAfEvent
 {
     afEventHub.RegisterHandler <TEventType>(
         (scope, e, sourceMessage) => { action.Invoke(scope, (TEventType)e); });
 }
 public NotificationCenterCore(
     INotificationRecordService notificationRecordService,
     IAfEventHub afEventHub,
     ILPCClient <INotificationRecordServer> lpcClient)
 {
     _notificationRecordService = notificationRecordService;
     _afEventHub = afEventHub;
     _lpcClient  = lpcClient;
 }
 public NotificationRecordService(IIndexedDbRepo <NotificationRecord, long> notificationRepo,
                                  IClock clock,
                                  ISimpleDataStorage simpleDataStorage,
                                  IAfEventHub afEventHub)
 {
     _notificationRepo  = notificationRepo;
     _clock             = clock;
     _simpleDataStorage = simpleDataStorage;
     _afEventHub        = afEventHub;
 }
Beispiel #4
0
 public HandleUserClickIconJob(
     ILogger <HandleUserClickIconJob> logger,
     IAfEventHub afEventHub,
     ISimpleDataStorage simpleDataStorage,
     IClock clock)
 {
     _logger            = logger;
     _afEventHub        = afEventHub;
     _simpleDataStorage = simpleDataStorage;
     _clock             = clock;
 }
Beispiel #5
0
 public ServerJob(ILogger <ServerJob> logger,
                  ILPCServer lpcServer,
                  IBkSearcherServer bkSearcherServer,
                  IAfEventHub afEventHub,
                  ISmallCache smallCache,
                  INotificationRecordServer notificationRecordServer)
 {
     _logger                   = logger;
     _lpcServer                = lpcServer;
     _bkSearcherServer         = bkSearcherServer;
     _afEventHub               = afEventHub;
     _smallCache               = smallCache;
     _notificationRecordServer = notificationRecordServer;
 }
Beispiel #6
0
 public static void RegisterHandler <TEventType>(this IAfEventHub afEventHub, Func <TEventType, Task> handler)
     where TEventType : class, IAfEvent
 {
     afEventHub.RegisterHandler <TEventType>((scope, e) => { handler.Invoke((TEventType)e); });
 }