on 08-15-2006 1:00 AM
Hi Friends,
the data to provide in context for every view controller and component controller.. can bemaintained in different ways.
1. to map the view controller fields with component controller only when it is required at both the places to be accessed.
rest all fields which do not need to be accessed at both the places may not be maped.
or:- Whats the advantage of not mapping the fields between view controllers and component controller?
2.
instead of fields as value attributes, one Value Node may be used as a grouping for a particular group of fields. is is best practice to group the fields into value node as per screen grouping?
for example screen has three sub parts, so three value node.. and each value ndoe may contain different value attributes. which scenario should be consider as best practice?
Thanks!
Hi Nav,
1) Advantage of not mapping is perfomance;
2) WD is model-view-controller paradigm driven framework. So, you design your context accroding to the data model you use. Usually it means - business object with properties. If you need to create some "helper" attributes, like visibility or enable flags, group them to one node with cardinality 1..1 to improve granularity.
Best regards, Maksim Rashchynski.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
<i>1) Advantage of not mapping is perfomance;</i>
Very weak argument. There is no any significant performance lost when mapping used (I bet you save less then a percent comparing to "direct" access).
Just put simple: your business data originates from controller. You must to show it on view, hence the need for mapping.
Also view may require certain context nodes just to setup and control UI elements. Declare these nodes directly in view controller and you'll need no mapping in this case.
Valery Silaev
EPAM Systems
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.