コード例 #1
0
 private void RegisterHandlers(IObjectContainer objectContainer)
 {
     objectContainer.AddHandler <IMockEventOne, MockEventHandler <IMockEventOne>, MockEventOne>();
     objectContainer.AddHandler <IMockEventTwo, MockEventHandler <IMockEventTwo>, MockEventTwo>();
     objectContainer.AddHandler <IMockEventThree, MockEventHandler <IMockEventThree>, MockEventThree>();
     objectContainer.AddHandler <IMockEventFour, MockEventHandler <IMockEventFour>, MockEventFour>();
     _ = objectContainer.AddResolver <IHandlerDispatcher>();
     _ = objectContainer.AddResolver <IPayloadStorageProviderService>();
     objectContainer.RegisterTypeAs <PayloadStorageProviderService <IGroupTransactionEvent, GroupTransactionEvent>, IPayloadStorageProviderService>(nameof(IGroupTransactionEvent));
 }
コード例 #2
0
        private void RegisterHandlers(IObjectContainer objectContainer)
        {
            objectContainer.AddHandler <IBulkClashCreatedOrUpdated, BulkClashCreatedOrUpdatedEventHandler, BulkClashCreatedOrUpdated>();
            objectContainer.AddHandler <IBulkClashDeleted, BulkClashDeletedEventHandler, BulkClashDeleted>();
            objectContainer.AddHandler <IClashUpdated, ClashUpdatedEventHandler, ClashUpdated>();
            objectContainer.AddHandler <IClashTruncated, BulkClashTruncatedEventHandler, ClashTruncated>();

            objectContainer.AddHandler <IBulkBreakCreated, BulkBreakCreatedEventHandler, BulkBreakCreated>();
            objectContainer.AddHandler <IBulkBreaksDeleted, BulkBreaksDeletedEventHandler, BulkBreaksDeleted>();
            objectContainer.RegisterTypeAs <BulkBreakDeletedBatchingHandler, IBatchingHandler <IBulkBreaksDeleted> >();

            objectContainer.AddHandler <IBulkProductCreatedOrUpdated, SqlServerBulkProductCreatedOrUpdatedEventHandler, BulkProductCreatedOrUpdated>();
            objectContainer.AddHandler <IBulkProductDeleted, BulkProductDeletedEventHandler, BulkProductDeleted>();

            objectContainer.AddHandler <IBulkHolidayCreated, BulkHolidayCreatedEventHandler, BulkHolidayCreated>();
            objectContainer.AddHandler <IBulkHolidayDeleted, BulkHolidayDeletedEventHandler, BulkHolidayDeleted>();

            objectContainer.AddHandler <IBulkDemographicCreatedOrUpdated, BulkDemographicCreatedOrUpdatedEventHandler, BulkDemographicCreatedOrUpdated>();
            objectContainer.AddHandler <IDemographicUpdated, DemographicUpdatedEventHandler, DemographicUpdated>();
            objectContainer.AddHandler <IBulkDemographicDeleted, BulkDemographicDeletedEventHandler, BulkDemographicDeleted>();

            objectContainer.AddHandler <IBulkProgrammeCreated, BulkProgrammeCreatedEventHandler, BulkProgrammeCreated>();
            objectContainer.RegisterTypeAs <BulkProgrammeCreatedBatchingHandler, IBatchingHandler <IBulkProgrammeCreated> >();

            objectContainer.AddHandler <IBulkProgrammeUpdated, BulkProgrammeUpdatedEventHandler, BulkProgrammeUpdated>();
            objectContainer.AddHandler <IBulkProgrammeDeleted, BulkProgrammeDeletedEventHandler, BulkProgrammeDeleted>();
            objectContainer.RegisterTypeAs <BulkProgrammeDeletedBatchingHandler, IBatchingHandler <IBulkProgrammeDeleted> >();

            objectContainer.AddHandler <IBulkProgrammeClassificationCreated, BulkProgrammeClassificationCreatedEventHandler, BulkProgrammeClassificationCreated>();
            objectContainer.AddHandler <IDeleteAllProgrammeClassification, DeleteAllProgrammeClassificationEventHandler, DeleteAllProgrammeClassification>();

            objectContainer.AddHandler <IBulkUniverseCreated, BulkUniverseCreatedEventHandler, BulkUniverseCreated>();
            objectContainer.AddHandler <IBulkUniverseDeleted, BulkUniverseDeletedEventHandler, BulkUniverseDeleted>();

            objectContainer.AddHandler <IBulkRestrictionCreatedOrUpdated, BulkRestrictionCreatedOrUpdatedEventHandler, BulkRestrictionCreatedOrUpdated>();
            objectContainer.AddHandler <IBulkRestrictionDeleted, BulkRestrictionDeletedEventHandler, BulkRestrictionDeleted>();

            objectContainer.AddHandler <IBulkSpotCreatedOrUpdated, BulkSpotCreatedOrUpdatedEventHandler, BulkSpotCreatedOrUpdated>();
            objectContainer.AddHandler <IBulkSpotDeleted, BulkSpotDeletedEventHandler, BulkSpotDeleted>();

            objectContainer.AddHandler <IBulkRatingsPredictionSchedulesCreated, BulkRatingsPredictionSchedulesCreatedEventHandler, BulkRatingsPredictionScheduleCreated>();
            objectContainer.AddHandler <IBulkRatingsPredictionSchedulesDeleted, BulkRatingsPredictionSchedulesDeletedEventHandler, BulkRatingsPredictionSchedulesDeleted>();

            objectContainer.AddHandler <IBulkSalesAreaCreatedOrUpdated, BulkSalesAreaCreatedOrUpdatedHandler, BulkSalesAreaCreatedOrUpdated>();
            objectContainer.AddHandler <IBulkSalesAreaDeleted, BulkSalesAreaDeletedEventHandler, BulkSalesAreaDeleted>();
            objectContainer.AddHandler <ISalesAreaUpdated, SalesAreaUpdatedEventHandler, SalesAreaUpdated>();

            objectContainer.AddHandler <IBulkClashExceptionCreated, BulkClashExceptionCreatedEventHandler, BulkClashExceptionCreated>();
            objectContainer.AddHandler <IBulkClashExceptionDeleted, BulkClashExceptionDeletedEventHandler, BulkClashExceptionDeleted>();

            objectContainer.AddHandler <IBulkCampaignCreatedOrUpdated, SqlBulkCampaignCreatedOrUpdatedEventHandler, BulkCampaignCreatedOrUpdated>();
            objectContainer.RegisterTypeAs <CampaignCreatedOrUpdatedBatchingHandler, IBatchingHandler <IBulkCampaignCreatedOrUpdated> >();

            objectContainer.AddHandler <IBulkCampaignDeleted, BulkCampaignDeletedEventHandler, BulkCampaignDeleted>();

            objectContainer.AddHandler <IBulkBookingPositionGroupCreated, BulkBookingPositionGroupCreatedEventHandler, BulkBookingPositionGroupCreated>();
            objectContainer.AddHandler <IBulkBookingPositionGroupDeleted, BulkBookingPositionGroupDeletedEventHandler, BulkBookingPositionGroupDeleted>();
            objectContainer.AddHandler <IBookingPositionGroupTruncated, BookingPositionGroupTruncatedEventHandler, BookingPositionGroupTruncated>();

            objectContainer.AddHandler <IBulkProgrammeCategoryCreated, BulkProgrammeCategoryCreatedEventHandler, BulkProgrammeCategoryCreated>();
            objectContainer.AddHandler <IBulkProgrammeCategoryDeleted, BulkProgrammeCategoryDeletedEventHandler, BulkProgrammeCategoryDeleted>();

            objectContainer.AddHandler <IBulkLockTypeCreated, BulkLockTypeCreatedEventHandler, BulkLockTypeCreated>();
            objectContainer.AddHandler <IBulkLockTypeDeleted, BulkLockTypeDeletedEventHandler, BulkLockTypeDeleted>();

            objectContainer.AddHandler <IBulkInventoryTypeCreated, BulkInventoryTypeCreatedEventHandler, BulkInventoryTypeCreated>();
            objectContainer.AddHandler <IBulkInventoryTypeDeleted, BulkInventoryTypeDeletedEventHandler, BulkInventoryTypeDeleted>();

            objectContainer.AddHandler <IBulkInventoryLockCreated, BulkInventoryLockCreatedEventHandler, BulkInventoryLockCreated>();
            objectContainer.AddHandler <IBulkInventoryLockDeleted, BulkInventoryLockDeletedEventHandler, BulkInventoryLockDeleted>();

            objectContainer.AddHandler <IBulkTotalRatingCreated, BulkTotalRatingCreatedEventHandler, BulkTotalRatingCreated>();
            objectContainer.AddHandler <IBulkTotalRatingDeleted, BulkTotalRatingDeletedEventHandler, BulkTotalRatingDeleted>();

            objectContainer.AddHandler <IBulkBreakTypeCreated, BulkBreakTypeCreatedEventHandler, BulkBreakTypeCreated>();
            objectContainer.AddHandler <IBulkBreakTypeDeleted, BulkBreakTypeDeletedEventHandler, BulkBreakTypeDeleted>();

            objectContainer.AddHandler <IBulkStandardDayPartCreated, BulkStandardDayPartCreatedEventHandler, BulkStandardDayPartCreated>();
            objectContainer.AddHandler <IBulkStandardDayPartDeleted, BulkStandardDayPartDeletedEventHandler, BulkStandardDayPartDeleted>();

            objectContainer.AddHandler <IBulkStandardDayPartGroupCreated, BulkStandardDayPartGroupCreatedEventHandler, BulkStandardDayPartGroupCreated>();
            objectContainer.AddHandler <IBulkStandardDayPartGroupDeleted, BulkStandardDayPartGroupDeletedEventHandler, BulkStandardDayPartGroupDeleted>();

            objectContainer.AddHandler <IBulkSpotBookingRuleCreated, BulkSpotBookingRuleCreatedEventHandler, BulkSpotBookingRuleCreated>();
            objectContainer.AddHandler <IBulkSpotBookingRuleDeleted, BulkSpotBookingRuleDeletedEventHandler, BulkSpotBookingRuleDeleted>();

            objectContainer.AddHandler <IBulkLengthFactorCreated, BulkLengthFactorCreatedEventHandler, BulkLengthFactorCreated>();
            objectContainer.AddHandler <IBulkLengthFactorDeleted, BulkLengthFactorDeletedEventHandler, BulkLengthFactorDeleted>();

            _ = objectContainer.AddResolver <IHandlerDispatcher>();
            _ = objectContainer.AddResolver <IPayloadStorageProviderService>();
            objectContainer.RegisterTypeAs <PayloadStorageProviderService <IGroupTransactionEvent, GroupTransactionEvent>, IPayloadStorageProviderService>(nameof(IGroupTransactionEvent));
        }