本文整理汇总了C#中IEventAggregator类的典型用法代码示例。如果您正苦于以下问题:C# IEventAggregator类的具体用法?C# IEventAggregator怎么用?C# IEventAggregator使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
IEventAggregator类属于命名空间,在下文中一共展示了IEventAggregator类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: Shell
public Shell(IUnityContainer container, IEventAggregator evtAggregator)
{
InitializeComponent();
container.RegisterInstance<Panel>("MainRegion", m_MainRegionPanel);
container.RegisterInstance<Panel>("SecondRegion", m_SecondRegionPanel);
evtAggregator.GetEvent<ProductSavedEvent>().Subscribe(OnProductSaved,ThreadOption.SubscriberAffinityThread);
}
开发者ID:ahszn,项目名称:Prism-4-with-WinForms,代码行数:7,代码来源:Shell.cs
示例2: GeoRegionMaintenanceViewModel
public GeoRegionMaintenanceViewModel(IModuleController moduleController, IDataRepository repository, IEventAggregator eventAggregator)
{
_moduleController = moduleController;
_repository = repository;
_eventAggregator = eventAggregator;
ShowView = _moduleController.ShowViewCommand;
NavigationDetails = _moduleController.NavigationDetails;
ChangeMetaPanel = new DelegateCommand<bool?>(ChangeMetaViewPanel);
ChangeGeoPanel = new DelegateCommand<bool?>(ChangeGeoViewPanel);
DeleteMetaRegionCommand = new DelegateCommand(DeleteMetaRegion);
EditMetaRegionCommand = new DelegateCommand(EditMetaRegion);
AddNewMetaRegionCommand = new DelegateCommand(AddNewMetaRegion);
DeleteMetaRegionMappingCommand = new DelegateCommand(DeleteMetaRegionMapping);
AddMetaRegionMappingCommand = new DelegateCommand(AddMetaRegionMapping);
DeleteGeoRegionCommand = new DelegateCommand(DeleteGeoRegion);
EditGeoRegionCommand = new DelegateCommand(EditGeoRegion);
CreateNewGeoRegionCommand = new DelegateCommand(CreateNewGeoRegion);
_metaRegions = new ObservableCollection<t033_meta_region>();
_metaRegionMappings = new ObservableCollection<t031_geo_code>();
_geoRegions = new ObservableCollection<GeoRegionViewModel>();
_moduleController.SwitchPanel(MaintenanceRegionNames.MetaRegionRegion, MaintenanceViewNames.MetaRegionView);
_moduleController.SwitchPanel(MaintenanceRegionNames.GeoRegionRegion, MaintenanceViewNames.GeoRegionView);
_moduleController.SwitchPanel(MaintenanceRegionNames.MetaRegionMappingRegion, MaintenanceViewNames.MetaRegionMappingView);
_eventAggregator.GetEvent<RefreshRegionsEvent>().Subscribe(InitializeData);
}
开发者ID:nzjamesk,项目名称:Nephila,代码行数:31,代码来源:GeoRegionMaintenanceViewModel.cs
示例3: EntityListPageViewModel
public EntityListPageViewModel(IEntityRepository entityRepository, INavigationService navService, IEventAggregator eventAggregator) {
_entityRepository = entityRepository;
_navService = navService;
_eventAggregator = eventAggregator;
NavCommand = new DelegateCommand<Entity>(OnNavCommand);
EntityDetailNavCommand = new DelegateCommand(() => _navService.Navigate("EntityDetail", 0));
}
开发者ID:ronlemire2,项目名称:PrismRT-CodeGen,代码行数:7,代码来源:EntityListPageViewModel.cs
示例4: EditCollectionTemplateViewModel
public EditCollectionTemplateViewModel(IServer server, IEventAggregator events,
IDocumentTemplateProvider templateProvider)
{
this.server = server;
this.events = events;
this.templateProvider = templateProvider;
}
开发者ID:nzdunic,项目名称:ravendb,代码行数:7,代码来源:EditCollectionTemplateViewModel.cs
示例5: DebugWindowViewModel
public DebugWindowViewModel(IEventAggregator eventAggregator) {
_eventAggregator = eventAggregator;
DebugStrings = new ObservableCollection<string>();
_eventAggregator.GetEvent<SetDebugMessageEvent>().Subscribe(SetMessage);
SendCloseMessageCommand = new DelegateCommand(SendCloseMessage);
ExportListCommand = new DelegateCommand(ExportList);
}
开发者ID:Rushman1,项目名称:PictureViewer,代码行数:7,代码来源:DebugWindowViewModel.cs
示例6: PivotRunTimeCalculatorViewModel
public PivotRunTimeCalculatorViewModel(INavigationService navigationService, IEventAggregator eventAggregator, string title)
: base(navigationService, eventAggregator, title)
{
_navigationService = navigationService;
_eventAggregator = eventAggregator;
initializePivotRunTimeCalculatorViewModel();
}
开发者ID:benediktfunk,项目名称:RunTimeCalc,代码行数:7,代码来源:PivotRunTimeCalculatorViewModel.cs
示例7: ModuleInit
public ModuleInit(IRegionManager regionManager, IUnityContainer container, IEventAggregator eventAggregator, IModuleManager moduleManager)
{
this.regionManager = regionManager;
this.container = container;
this.eventAggregator = eventAggregator;
this.moduleManager = moduleManager;
}
开发者ID:skidamian,项目名称:Projekt-SI,代码行数:7,代码来源:ModuleInit.cs
示例8: SalesModule
public SalesModule(IEventAggregator eventAggregator, INavigationService navigationService, IUnityContainer container, IRegionManager regionManager)
{
_container = container;
_regionManager = regionManager;
_navigationService = navigationService;
_eventAggregator = eventAggregator;
}
开发者ID:cstrahan,项目名称:openpos,代码行数:7,代码来源:SalesModule.cs
示例9: ViewModelBase
public ViewModelBase(IPersonService personService, IDispatcher dispatcher, IEventAggregator aggregator, IDialogService dialogService)
{
if (personService == null)
{
throw new ArgumentNullException("personService");
}
if (dispatcher == null)
{
throw new ArgumentNullException("dispatcher");
}
if (aggregator == null)
{
throw new ArgumentNullException("aggregator");
}
if (dialogService == null)
{
throw new ArgumentNullException("dialogService");
}
this.personService = personService;
this.dispatcher = dispatcher;
this.aggregator = aggregator;
this.dialogService = dialogService;
isBusy = false;
}
开发者ID:yovannyr,项目名称:mvvm-unittesting,代码行数:29,代码来源:ViewModelBase.cs
示例10: MenuRegionController
public MenuRegionController(IUnityContainer container,
[Dependency(ShellRegionNames.MenuRegion)] IRegion menuRegion)
{
_container = container;
_eventAggregator = _container.Resolve<IEventAggregator>();
_menuRegion = menuRegion;
}
开发者ID:CHOUAiB,项目名称:WPF-Framework,代码行数:7,代码来源:MenuRegionController.cs
示例11: MainMenuViewModel
public MainMenuViewModel()
{
Groups = new BindableCollection<MenuGroup>();
if (!Windows.ApplicationModel.DesignMode.DesignModeEnabled)
{
_running = IoC.Get<RunExperimentViewModel>();
_runThresholdTest = IoC.Get<RunThresholdTestViewModel>();
_permutations = IoC.Get<PermutationViewModel>();
_nbsmConfig = IoC.Get<NBSmConfigViewModel>();
_eventAggregator = IoC.Get<IEventAggregator>();
_navService = IoC.Get<INavigationService>();
_regionService = IoC.Get<IRegionService>();
_subjectService = IoC.Get<ISubjectDataService>();
_subjectFilterService = IoC.Get<ISubjectFilterService>();
_computeService = IoC.Get<IComputeService>();
var regionsVM = IoC.Get<RegionsViewModel>();
Groups.Add(new MenuGroup { Title = "Source", Items = { regionsVM, IoC.Get<SubjectsViewModel>(), IoC.Get<GroupsViewModel>() } });
Groups.Add(new MenuGroup { Title = "Config", Items = { _permutations, _nbsmConfig } });
Groups.Add(new MenuGroup { Title = "Compute", Items = { _runThresholdTest, _running } });
Groups.Add(new MenuGroup { Title = "Global", Items = { IoC.Get<GlobalStrengthViewModel>() } });
Groups.Add(new MenuGroup { Title = "Component", Items = { IoC.Get<IntermodalViewModel>(), IoC.Get<IntraSummaryViewModel>()/*, new MenuItem { Title = "Associations" },*/ } });
Groups.Add(new MenuGroup { Title = "Nodal", Items = { IoC.Get<NodalStrengthDataTypeViewModel>() } });
Groups.Add(new MenuGroup { Title = "Edge", Items = { IoC.Get<EdgeSignificanceViewModel>() } });
}
}
开发者ID:digitalnelson,项目名称:BrainGraph,代码行数:29,代码来源:MainMenuViewModel.cs
示例12: UpdaterModuleBootstraper
public UpdaterModuleBootstraper(IUpdater updater, RegionManager regionManager,IEventAggregator eventAggregator)
{
// use injected services from Nomad, instead of using IServiceLocator mechanism
_updater = updater;
_regionManager = regionManager;
_eventAggregator = eventAggregator;
}
开发者ID:NomadPL,项目名称:Nomad,代码行数:7,代码来源:UpdaterModuleBootstraper.cs
示例13: WatchListViewModel
public WatchListViewModel(IWatchListService watchListService, IMarketFeedService marketFeedService, IRegionManager regionManager, IEventAggregator eventAggregator)
{
if (watchListService == null)
{
throw new ArgumentNullException("watchListService");
}
if (eventAggregator == null)
{
throw new ArgumentNullException("eventAggregator");
}
this.HeaderInfo = Resources.WatchListTitle;
this.WatchListItems = new ObservableCollection<WatchItem>();
this.marketFeedService = marketFeedService;
this.regionManager = regionManager;
this.watchList = watchListService.RetrieveWatchList();
this.watchList.CollectionChanged += delegate { this.PopulateWatchItemsList(this.watchList); };
this.PopulateWatchItemsList(this.watchList);
this.eventAggregator = eventAggregator;
this.eventAggregator.GetEvent<MarketPricesUpdatedEvent>().Subscribe(this.MarketPricesUpdated, ThreadOption.UIThread);
this.removeWatchCommand = new DelegateCommand<string>(this.RemoveWatch);
this.watchListItems.CollectionChanged += this.WatchListItems_CollectionChanged;
}
开发者ID:eslahi,项目名称:prism,代码行数:29,代码来源:WatchListViewModel.cs
示例14: PasswordGeneratorViewModel
public PasswordGeneratorViewModel(IPasswordGenerator passwordGenerator, IEventAggregator events)
{
this.events = events;
this.passwordGenerator = passwordGenerator;
this.DisplayName = "Generator";
this.Length = 6;
}
开发者ID:TheAngryByrd,项目名称:MetroPass,代码行数:7,代码来源:PasswordGeneratorViewModel.cs
示例15: DownloadService
public DownloadService(IProvideDownloadClient downloadClientProvider,
IEventAggregator eventAggregator, Logger logger)
{
_downloadClientProvider = downloadClientProvider;
_eventAggregator = eventAggregator;
_logger = logger;
}
开发者ID:Kiljoymccoy,项目名称:NzbDrone,代码行数:7,代码来源:DownloadService.cs
示例16: HtmlTokenizer
/// <summary>
/// See 8.2.4 Tokenization
/// </summary>
/// <param name="source">The source code manager.</param>
/// <param name="events">The event aggregator to use.</param>
public HtmlTokenizer(TextSource source, IEventAggregator events)
: base(source, events)
{
_state = HtmlParseMode.PCData;
_acceptsCharacterData = false;
_lastStartTag = String.Empty;
}
开发者ID:JBTech,项目名称:AngleSharp,代码行数:12,代码来源:HtmlTokenizer.cs
示例17: GroupWidget
public GroupWidget()
{
this.InitializeComponent();
_eventAggregator = App.Current.Container.Resolve<IEventAggregator>();
this.Tapped += OnTapped;
this.DataContextChanged += OnDataContextChanged;
}
开发者ID:altima,项目名称:openhabUWP,代码行数:7,代码来源:GroupWidget.xaml.cs
示例18: GettingStartedViewModel
public GettingStartedViewModel(IEventAggregator eventAggregator, INavigate navigator )
{
this.eventAggregator = eventAggregator;
this.navigator = navigator;
ReturnToLoginScreenCommand = new DelegateCommand<object>(ReturnToLoginScreen, CanReturnToLoginScreen);
}
开发者ID:erwilleke,项目名称:ocu.angellight.code,代码行数:7,代码来源:GettingStartedViewModel.cs
示例19: WCFClient
public WCFClient(IEventAggregator eventBus) {
_eventBus = eventBus;
_pipeFactory = new ChannelFactory<IUpdaterWCF>(new NetNamedPipeBinding(), new EndpointAddress(
"net.pipe://localhost/UpdaterWCF_Pipe"));
_pipeProxy = _pipeFactory.CreateChannel();
}
开发者ID:MaHuJa,项目名称:withSIX.Desktop,代码行数:7,代码来源:WCFClient.cs
示例20: TrendLinePresentationModel
public TrendLinePresentationModel(ITrendLineView view, IMarketHistoryService marketHistoryService, IEventAggregator eventAggregator)
{
this.View = view;
this.View.Model = this;
this._marketHistoryService = marketHistoryService;
eventAggregator.GetEvent<TickerSymbolSelectedEvent>().Subscribe(this.TickerSymbolChanged);
}
开发者ID:eslahi,项目名称:prism,代码行数:7,代码来源:TrendLinePresentationModel.cs
注:本文中的IEventAggregator类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论