• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C# IEventBus类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中IEventBus的典型用法代码示例。如果您正苦于以下问题:C# IEventBus类的具体用法?C# IEventBus怎么用?C# IEventBus使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



IEventBus类属于命名空间,在下文中一共展示了IEventBus类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: SetUp

 public void SetUp()
 {
     channelMock = MockRepository.GenerateStub<IModel>();
     eventBus = MockRepository.GenerateStub<IEventBus>();
     
     publisher = new PublisherBasic(eventBus);
 }
开发者ID:akzhigitov,项目名称:EasyNetQ,代码行数:7,代码来源:PublisherConfirmsTests.cs


示例2: ExclusiveConsumer

  public ExclusiveConsumer(
      IQueue queue,
      Func<byte[], MessageProperties, MessageReceivedInfo, Task> onMessage,
      IPersistentConnection connection,
      IConsumerConfiguration configuration,
      IInternalConsumerFactory internalConsumerFactory,
      IEventBus eventBus
      )
  {
      Preconditions.CheckNotNull(queue, "queue");
      Preconditions.CheckNotNull(onMessage, "onMessage");
      Preconditions.CheckNotNull(connection, "connection");
      Preconditions.CheckNotNull(internalConsumerFactory, "internalConsumerFactory");
      Preconditions.CheckNotNull(eventBus, "eventBus");
      Preconditions.CheckNotNull(configuration, "configuration");
 
      this.queue = queue;
      this.onMessage = onMessage;
      this.connection = connection;
      this.configuration = configuration;
      this.internalConsumerFactory = internalConsumerFactory;
      this.eventBus = eventBus;
      timer = new Timer(s =>
          {
              StartConsumer();
              ((Timer)s).Change(10000, -1);
          });
      timer.Change(10000, -1);
  }
开发者ID:hippasus,项目名称:EasyNetQ,代码行数:29,代码来源:ExclusiveConsumer.cs


示例3: GlobalSettingsProvider

 public GlobalSettingsProvider(
   IToolsOptionsPageProvider visualStudioPackageProvider,
   IEventBus eventBus) {
   _visualStudioPackageProvider = visualStudioPackageProvider;
   _eventBus = eventBus;
   _globalSettings = new Lazy<GlobalSettings>(CreateGlobalSettings);
 }
开发者ID:mbbill,项目名称:vs-chromium,代码行数:7,代码来源:GlobalSettingsProvider.cs


示例4: MongoEventStore

 public MongoEventStore(IMongoConfiguration mongoConfiguration, IEventBus eventBus)
     : base(eventBus)
 {
     _server = MongoServer.Create(mongoConfiguration.Url);
     var mongoDatabaseSettings = _server.CreateDatabaseSettings(mongoConfiguration.DatabaseName);
     _database = _server.GetDatabase(mongoDatabaseSettings);
 }
开发者ID:mastoj,项目名称:TJ.CQRS,代码行数:7,代码来源:MongoEventStore.cs


示例5: SourceExplorerHierarchyControllerFactory

 public SourceExplorerHierarchyControllerFactory(
   ISynchronizationContextProvider synchronizationContextProvider,
   IFileSystemTreeSource fileSystemTreeSource,
   IVisualStudioPackageProvider visualStudioPackageProvider,
   IVsGlyphService vsGlyphService,
   IImageSourceFactory imageSourceFactory,
   IOpenDocumentHelper openDocumentHelper,
   IFileSystem fileSystem,
   IClipboard clipboard,
   IWindowsExplorer windowsExplorer,
   IUIRequestProcessor uiRequestProcessor,
   IEventBus eventBus,
   IGlobalSettingsProvider globalSettingsProvider,
   IDelayedOperationProcessor delayedOperationProcessor,
   IUIThread uiThread) {
   _synchronizationContextProvider = synchronizationContextProvider;
   _fileSystemTreeSource = fileSystemTreeSource;
   _visualStudioPackageProvider = visualStudioPackageProvider;
   _vsGlyphService = vsGlyphService;
   _imageSourceFactory = imageSourceFactory;
   _openDocumentHelper = openDocumentHelper;
   _fileSystem = fileSystem;
   _clipboard = clipboard;
   _windowsExplorer = windowsExplorer;
   _uiRequestProcessor = uiRequestProcessor;
   _eventBus = eventBus;
   _globalSettingsProvider = globalSettingsProvider;
   _delayedOperationProcessor = delayedOperationProcessor;
   _uiThread = uiThread;
 }
开发者ID:mbbill,项目名称:vs-chromium,代码行数:30,代码来源:SourceExplorerHierarchyControllerFactory.cs


示例6: DiagnosticsManager

		internal DiagnosticsManager(IDebugLogService logService, IEventBus eventBus, IConfigurationManager configurationManager, ILogger logger)
		{
			_logService = logService;
			_configurationManager = configurationManager;
			eventBus.Subscribe<ErrorEvent>(HandleErrorEvent);
		    _logger = logger;
		}
开发者ID:Donky-Network,项目名称:DonkySDK-Xamarin-Modular,代码行数:7,代码来源:DiagnosticsManager.cs


示例7: SqlServerPersistenceManager

 public SqlServerPersistenceManager(string connectionString, IContext context, IEventBus eventBus, IContainer container)
 {
     this.connectionString = connectionString;
     this.context = context;
     this.eventBus = eventBus;
     this.container = container;
 }
开发者ID:robsiera,项目名称:TransitioningToEventSourcing,代码行数:7,代码来源:SqlServerPersistenceManager.cs


示例8: NinjectedCommandBus

        public NinjectedCommandBus(IEventBus eventBus, IKernel kernel)
            : base(eventBus)
        {
            _kernel = kernel;

            RegisterHandler<EmployeeAggregate>();
        }
开发者ID:dilillo,项目名称:Benefits,代码行数:7,代码来源:NinjectedCommandBus.cs


示例9: StorEvilGlossaryJob

 public StorEvilGlossaryJob(IStepProvider stepProvider, IStepDescriber stepDescriber, IEventBus bus, IGlossaryFormatter formatter)
 {
     _stepProvider = stepProvider;
     _stepDescriber = stepDescriber;
     _bus = bus;
     _formatter = formatter;
 }
开发者ID:paulbatum,项目名称:storevil,代码行数:7,代码来源:StorEvilGlossaryJob.cs


示例10: RegistrationManager

        internal RegistrationManager(
            IRegistrationContext registrationContext, 
            IModuleManager moduleManager,
            IPublicRegistrationService publicRegistrationService, 
            ISdkInformation sdkInformation,
            IEnvironmentInformation environmentInformation, 
            IServiceContext serviceContext,
            ISecureRegistrationService secureRegistrationService, 
            IConfigurationManager configurationManager,
            IEventBus eventBus, 
            IRefreshToken tokenRefresher, 
            ILogger logger,
			IJsonSerialiser serialiser)
        {
            _registrationContext = registrationContext;
            _moduleManager = moduleManager;
            _publicRegistrationService = publicRegistrationService;
            _sdkInformation = sdkInformation;
            _environmentInformation = environmentInformation;
            _serviceContext = serviceContext;
            _secureRegistrationService = secureRegistrationService;
            _configurationManager = configurationManager;
            _eventBus = eventBus;
            _tokenRefresher = tokenRefresher;
            _logger = logger;
			_serialiser = serialiser;
        }
开发者ID:Donky-Network,项目名称:DonkySDK-Xamarin-Modular,代码行数:27,代码来源:RegistrationManager.cs


示例11: ServicesManager

        public ServicesManager(
            INutConfiguration configurationManager,
            Infrastructure.ConfigurationManagement.DbConfigurationSettings.Factory dbConfigurationSettingsFactory,
            IEventBus eventBus,
            IEnumerable<IReportPeriodically> pushServices,
            IEnumerable<IRemoteInvocationService> remoteInvokedServices,
            Services.IGlobalSettingsService globalSettings,
            Func<RegisteredPackagesPollingClient> packagesPollerFactory,
            Func<PollingClientCollection> pollingCollectionFactory,
            Repositories.IPackageRepository packageRepository,
            IHoardeManager hoardeManager)
        {
            _log = LogProvider.For<ServicesManager>();

            _configurationManager = configurationManager;
            _dbConfigurationSettingsFactory = dbConfigurationSettingsFactory;
            _eventBus = eventBus;
            _pushServices = pushServices;
            _remoteInvokedServices = remoteInvokedServices;
            _globalSettings = globalSettings;

            _packagesPollerFactory = packagesPollerFactory;
            _pollingCollectionFactory = pollingCollectionFactory;

            _packageRepository = packageRepository;

            _hoardeManager = hoardeManager;
        }
开发者ID:dealproc,项目名称:Drey,代码行数:28,代码来源:ServicesManager.cs


示例12: Configure

        /// <summary>
        /// Configuration routine of the autofac container.
        /// </summary>
        /// <param name="eventBus">The event bus.</param>
        /// <param name="hoardeManager">The hoarde manager.</param>
        /// <param name="configurationManager">The host's configuration manager.</param>
        public static void Configure(IEventBus eventBus, ServiceModel.IHoardeManager hoardeManager, INutConfiguration configurationManager)
        {
            var builder = new ContainerBuilder();

            builder.RegisterInstance(eventBus);
            builder.RegisterInstance(hoardeManager);
            builder.RegisterInstance(configurationManager);

            builder.RegisterType<ServiceModel.ServicesManager>().AsImplementedInterfaces().SingleInstance();
            builder.RegisterType<ServiceModel.PollingClientCollection>().AsSelf().SingleInstance();
            builder.RegisterType<ServiceModel.RegisteredPackagesPollingClient>().AsSelf().SingleInstance();
            builder.RegisterType<ServiceModel.ReleasesPollingClient>();
            builder.RegisterType<ConfigurationManagement.DbConfigurationSettings>();

            // we will apply most of the configuration in one or more assembly modules.
            builder.RegisterAssemblyModules(typeof(AutofacConfig).Assembly);

            switch (configurationManager.Mode)
            {
                case ExecutionMode.Development:
                    builder.RegisterType<Repositories.OnDisk.OnDiskPackageRepository>().AsImplementedInterfaces().InstancePerLifetimeScope();
                    break;
                case ExecutionMode.Production:
                    builder.RegisterType<Repositories.SQLiteRepositories.PackageRepository>().AsImplementedInterfaces().InstancePerLifetimeScope();
                    break;
                default:
                    builder.RegisterType<Repositories.SQLiteRepositories.PackageRepository>().AsImplementedInterfaces().InstancePerLifetimeScope();
                    _log.WarnFormat("Unknown execution mode '{mode}'.  Registered Sqlite Repository.", configurationManager.Mode);
                    break;
            }

            _container = builder.Build();
        }
开发者ID:dealproc,项目名称:Drey,代码行数:39,代码来源:AutofacConfig.cs


示例13: InPlaceCompilingStoryRunner

 public InPlaceCompilingStoryRunner(IRemoteHandlerFactory factory, IScenarioPreprocessor preprocessor, IStoryFilter filter, ISessionContext context, IEventBus eventBus)
 {
     _factory = factory;
     _preprocessor = preprocessor;
     _filter = filter;
     _eventBus = eventBus;
 }
开发者ID:pawelpabich,项目名称:storevil,代码行数:7,代码来源:InPlaceCompilingStoryRunner.cs


示例14: FacebookAccountRepository

 public FacebookAccountRepository(IAccountRepository accountRepository,
                                  IFacebookDataRepository facebookDataRepository, IEventBus eventBus)
 {
     this.accountRepository = accountRepository;
     this.facebookDataRepository = facebookDataRepository;
     this.eventBus = eventBus;
 }
开发者ID:burkhartt,项目名称:Jellyfish,代码行数:7,代码来源:IFacebookAccountDataRepository.cs


示例15: BaseModule

        public BaseModule(IEventBus eventBus, Services.IGlobalSettingsService globalSettingsService, string modulePath, bool verifyConfigured) : base(modulePath)
        {
            EventBus = eventBus;
            GlobalSettingsService = globalSettingsService;

            WireSetupPipeline(verifyConfigured);
        }
开发者ID:dealproc,项目名称:Drey,代码行数:7,代码来源:BaseModule.cs


示例16: InPlaceStoryRunner

 public InPlaceStoryRunner(ScenarioInterpreter scenarioInterpreter,
     IStoryFilter filter,
     ISessionContext context,
     IEventBus eventBus)
     : base(filter, context, eventBus)
 {
     _scenarioRunner = new InPlaceScenarioRunner(eventBus, scenarioInterpreter);
 }
开发者ID:heinrichbreedt,项目名称:storevil,代码行数:8,代码来源:InPlaceStoryRunner.cs


示例17: FileRegistrationRequestService

 public FileRegistrationRequestService(
   IUIRequestProcessor uiRequestProcessor,
   IFileSystem fileSystem,
   IEventBus eventBus) {
   _uiRequestProcessor = uiRequestProcessor;
   _fileSystem = fileSystem;
   _eventBus = eventBus;
 }
开发者ID:mbbill,项目名称:vs-chromium,代码行数:8,代码来源:FileRegistrationRequestService.cs


示例18: GcmRemoteNotificationChannel

		public GcmRemoteNotificationChannel(IEventBus eventBus, IJsonSerialiser serialiser, IConfigurationManager configurationManager)
		{
			_eventBus = eventBus;
			_serialiser = serialiser;
			_configurationManager = configurationManager;

			eventBus.Subscribe<GcmNotificationReceivedEvent>(HandleGcmNotification);
		}
开发者ID:Donky-Network,项目名称:DonkySDK-Xamarin-Modular,代码行数:8,代码来源:GcmRemoteNotificationChannel.cs


示例19: ApnsRemoteNotificationChannel

		public ApnsRemoteNotificationChannel(IEventBus eventBus)
		{
			_eventBus = eventBus;

			eventBus.Subscribe<ApnsRegistrationChangedEvent>(HandleApnsRegistrationChanged);
			eventBus.Subscribe<ApnsNotificationReceivedEvent>(HandleApnsNotificationReceived);
			eventBus.Subscribe<RefreshApnsConfigurationEvent>(HandleRefreshApnsConfiguration);
		}
开发者ID:Donky-Network,项目名称:DonkySDK-Xamarin-Modular,代码行数:8,代码来源:ApnsRemoteNotificationChannel.cs


示例20: TestFixtureSetUp

        public virtual void TestFixtureSetUp()
        {
            _context = new XmlApplicationContext(ConfigFiles);
            _bus = _context.GetObject("IEventBus") as IEventBus;

            //Hack so that we don't have to validate the Anubis server certificate.
            ServicePointManager.ServerCertificateValidationCallback = delegate { return true; };
        }
开发者ID:Berico-Technologies,项目名称:AMP,代码行数:8,代码来源:GtsAnubisAndTwoWaySSLforRabbit.cs



注:本文中的IEventBus类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# IEventHandler类代码示例发布时间:2022-05-24
下一篇:
C# IEventBinding类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap