From: EMail A. <ar...@ga...> - 2011-06-02 18:09:08
|
This is long and complicated .. if I reach a resolution, I promise I'll put a full description into the Wiki for others. I don't want to appear lazy; I know I can read the code for some of this, but it's really arcane and an explanation from someone already deeply familiar with it would be better .. many thanks, Gavin _________________________________________________________ WITHOUT WOOGNL I was introduced to Apple's version of inline bindings before I found WOOgnl, and have been using them for several years -- the WOOgnl framework has not been part of my apps and, just to be sure, "ognl.active=false" in Properties. I have a component with the following HTML: <wo:textField value="[username]" size="20" /> which has been behaving itself for years! Believing it to be a more popular syntax, and that Apple's mechanism dealt with both, I recently switched such elements to the "$..." form (corresponding to the conventional WOOgln syntax): <wo:textField value="$username" size="20" /> and I get the error: <er.extensions.components._private.ERXWOTextField> 'value' attribute not present or is a constant So far, I've not brought WOOgnl into play -- ___________________ Am I wrong believing that Apple's inline binding syntax will be triggered by either "[...]" or "$..." ? I deduce that I am because ERXWOTextField appears to see "$..." as a literal constant string. ___________________ Is Apple's inline binding described/documented anywhere at all ? I have hunted high and low (but maybe it is in the middle somewhere!) ___________________ Am I correct in my conclusion that the prefix/suffix setting in the "WOLIPS Development" pane of my project properties has no relationship to the "Apple" in-line binding mechanism ? I deduce I am because changing it has no effect on the above error. ___________________ Am I correct in my belief that Apple's inline binding mechanism is invoked only by having an empty (or absent) *.wod file for the component in question -- no flags, switches, properties, etc ? I believe I am because (a) a WebObjects engineer told me that a few years ago, and (b) that seems to be how it works. _________________________________________________________ WITH WOOGNL NOW: Add the WOOgln framework and "ognl.active=true" & "ognl.inlineBindings=true" and this happens: Prefix/Suffix : "$" and "" --- <wo:textField value="$username" size="20" /> -- success, as expected Prefix/Suffix : "[" and "]" --- <wo:textField value="$username" size="20" /> -- success [1] Prefix/Suffix : "$" and "" --- <wo:textField value="[username]" size="20" /> -- failure, as expected [2] Prefix/Suffix : "[" and "]" --- <wo:textField value="[username]" size="20" /> -- failure [3] Success [1] and Failure [3] above are not what I expected, unless WOOgnl ignores the Prefix/Suffix setting. With WOOgnl active, is the Apple mechanism defeated ? Failures [2] and [3] would imply Apple's mechanism is defeated otherwise it would have caught the "[...]" usage when WOOgnl didn't. Am I correct in my belief that WOOgnl's inline binding mechanism is invoked only by "ognl.active=true" & "ognl.inlineBindings=true" ? |