Tuesday, August 21, 2007

Duncan Says

Few will enjoy this post or even make sense of it. It is about writing J2EE application using Oracle ADF/JSF framework. The frame work is good and productive, but has it own problems as well. Ducans Mills is one of the people whose finger prints are all over the ADF framwork and he writes below about what is know as Drop Down list.. and a reply at the end

Duncan says
"List bindings are a very powerful feature of ADF. They make it really easy to automatically manage the population of select-type components such as dropdown lists, radio groups and so forth from a collection of data you have in your model. ADF manages the mapping between your collection type and the format of the mini-model used by the controls themselves. There is, however, one problem with list bindings. They are intensely private. What I mean by this is that if you try and get the value of the list binding directly say using an expression (in the JSF case) of #{bindings.deptList.inputValue}, it will return you an index number which reflects the position of the selected item on the list - not the value of that selection as you might expect. This can catch you unawares, particularly if your values are already numerical - you could easily miss this and end up with weird bugs."

and i say
"The issue here is that when binding is explained using ADF framework, they are explained in a generic way. #{bindings.EmpView1Deptno.inputValue} means the value of an input item, and this works well for DNAME if you try it. How in the world am i expected to know that in the case of a list item, it returns an index. A human mind can only be useful if it can learn little things and then infer big things the follow similar behaviour. For example, Newton learned and explained a lot about gravity by watch an apple drop. All object drop in the direction of the gravitational force, if some object go up aginst gravitational force without any external force, then Newton would have been confused. The beauty is when things are exact and consistent as is the case with our universe. Well, the Universe is the creation of God, and ADF is the Creation on Man. Therefore, we strongly ask Oracle to write GOOD manuales that explain and pinpoint in great extend the behaviour of their frameworks with lots of example and therefore, make the learning curve less steep, because as things are designed in ADF, one cannot necessarily extends his understanding of EL binding and arrive to the fact that accessing the inputValue of a list item would return and index value.i hope i was able to give an insight about the difficulty that we can be facing. After saying all of that, i am still a firm believer of the future of ADF "

ammar

4 comments:

Anonymous said...

now I can say that .NET is a blessing :))

Anonymous said...

are you sure that .NET does not exhibit the same bahaviour?

Anonymous said...

.NET is the most flexible framework I've ever used & never had a strange behavious as the stated here. Everything is smooth. U can find built-in methods for more than what u expect.Even if u didn't find a ready object to drag or method 2 select u'll find sthing so close which is v helpful.
MS makes life easier ;)
"Even if u r not a MS fan, but do not deny it".

Ammar said...

I feel more content to be around IBM, Oracle and SUN

Playing around with ADF dataControl

While trying to figure out what one of our ex-colleagues at REALSOFT is programming a business rule engine admin screen for the Health Insu...