当前位置:网站首页>Prism framework
Prism framework
2022-06-26 03:44:00 【yuyue5945】
Prism Framework application - Basic knowledge
Prism Frame concept
prism was the code name for the guidance formally known as the Composite Application Guidance for WPF and Silverlight. For brevity and conciseness, and due to customer demand, this guidance is now referred to simply as Prism.
Prism Used to develop multiple interfaces 、 Rich data and interactive features WPF and Silverlight The specific presentation and business logic of the application .
Prism The purpose of the framework application is
- Decoupling between modules
- UI Decouple from background development
- Reduce functional coupling at the beginning of programming
Prism Frame details
Frame diagram

Introduction to framework module
Modoules:Modules Is able to independently develop 、 test 、 Deployed functional units ,Modules Modules that can be designed to implement specific business logic ( Such as Profile Management), It can also be designed as a module to implement a common infrastructure or service ( Such as Logging、Exception Management)
Module Catalog: stay Prism in ,Module Catalog It is indicated that Load Which? Module, In what order Load these Module.
Shell:Shell It's the host application (host application),modules Will be load To Shell in .Shell Defines the overall layout and structure of the application , And don't care about the boarders Module,Shell It is usually implemented in general application service and infrastructure, The logic of application is realized in the concrete Module in , meanwhile ,Shell It also provides a top-level window for the application .
Views:Views It's a view that shows specific functions in the application , It shows UI、 Define interaction behavior , And through data binding with ViewModel Interact .
Regions:Regions It's the app UI The logical region of , It's very much like a PlaceHolder,Views stay Regions Show , Many kinds of controls can be used as Region:ContentControl、ItemsControl、ListBox、TabControl.Views Can be in Regions Programming or auto rendering ,Prism Also provided Region Navigation support .
Navigation:Prism Support two kinds of navigation :state-based Navigation and view-switching Navigation .
EventAggregator: Components usually communicate with other components or services . So ,Prism Provides
EventAggregator Components , This component implements pub-sub Event mechanism , Allow some components to publish Events , Other components subscribe to events without a reference between the two components .
Dependency Injection container:Prism Use dependency injection pattern to manage dependencies between components ,Prism Designed to use Unity、Mef And so on .
Services:Services It's used to realize non UI The logic of the relevant functions , for example logging、exception management、data access.Services Can be defined in an application or Module in ,Services Usually registered in a dependency injection container , Make it easy for other components to locate this service .
Controllers:Controller Used to control in Region Which one of them View Will be presented , Control this at the same time View Creation and initialization of .
MVVM Related modules
View Model and Presenters:View Model To encapsulate an application UI Logic and its state .
Model:Model Is used to encapsulate data and corresponding validation , And relevant business rules to ensure the consistency and correctness of the data .
Commands:Command Is used to encapsulate application functions ,Prism Provides Delegate Command and CompositeCommand Two classes .
Bootstrapper:Bootstrapper To initialize application level components and services , It is also used to configure and initialize module catalog and Shell Of View and View Model. The function is shown in the figure :
To configure and initialize module catalog and Shell Of View and View Model. The function is shown in the figure :

边栏推荐
- 图扑软件数字孪生海上风电 | 向海图强,奋楫争先
- Plug in installation and shortcut keys of jupyter notebook
- 云计算基础-0
- MySQL addition, deletion, query and modification (primary level)
- WebRTC系列-网络传输之6-Connections裁剪
- 计组笔记——CPU的指令流水
- 360 second understanding of smartx hyper converged infrastructure
- redux-thunk 简单案例,优缺点和思考
- 开通基金账户是安全的吗?怎么申请呢
- Request object, send request
猜你喜欢

Non H5 end of uni app, regional setting of status bar on the top of mobile phone

优化——多目标规划

Click event

双碳红利+基建大年 | 图扑深耕水利水电绿色智能装备领域

"Renegotiation" agreement

You cannot call Glide. get() in registerComponents(), use the provided Glide instance instead

Uni app QR code scanning and identification function
![[hash table] a very simple zipper hash structure, so that the effect is too poor, there are too many conflicts, and the linked list is too long](/img/82/6a81e5b0d5117d780ce5910698585a.jpg)
[hash table] a very simple zipper hash structure, so that the effect is too poor, there are too many conflicts, and the linked list is too long

机器学习笔记 - 时间序列的趋势分量

Add an "open search description" to the site to adapt to the browser's "site search"“
随机推荐
Nepal graph learning Chapter 3_ Multithreading completes 6000w+ relational data migration
Qt 中 deleteLater 使用总结
mysql存儲過程
Navicat16 wireless trial
点击事件
Group note data representation and operation check code
Binary search
jupyter notebook的插件安装以及快捷键
显卡、GPU、CPU、CUDA、显存、RTX/GTX及查看方式
[paper notes] supersizing self supervision: learning to grasp from 50K tries and 700 robot hours
机器学习笔记 - 时间序列的趋势分量
Uni app QR code scanning and identification function
开通基金账户是安全的吗?怎么申请呢
【Appium踩坑】io.appium.uiautomator2.common.exceptions.InvalidArgumentException: ‘capabilities‘ are mand
Deletelater Usage Summary in QT
Do you want to add a key to the applet or for sequence?
【LOJ#6718】九个太阳「弱」化版(循环卷积,任意模数NTT)
mysql存储过程
[hash table] improved, zipper hash structure - directly use two indexes to search, instead of hashing and% every time
Procédures stockées MySQL