On Jan 2, 2008, at 11:50 AM, Archibal Singleton wrote:

Now if I override synchronizesVariablesWithBindings() in UserName.java to return false, everything works. But I see lots of examples (e.g. WOTable and WOCheckboxMatrix) where subcomponent using the ^ don't override synchronizesVariablesWithBindings() to return false. And I assume that they work (I haven't tested them).

What am I missing here?

   public boolean isStateless() {
       return true;
   }

"By default, stateless components don't synchronize. So, if you override this method to return true and you want the component to synchronize, you must also override synchronizesVariablesWithBindings and return true."

Thanks a lot Chuck, this explains it.

The API docs for WOComponent.synchronizesVariablesWithBindings() says: "This method returns false for stateless components (unless you override isStateless and return true), and true otherwise."

Which, to this non-native english speaker, seems contradictory!

Shouldn't it read "... (unless you override *synchronizesVariablesWithBindings* and return true)?!?


I read that several times. It is nonsensical. The correct statement would be something like this:

This method returns false for stateless components and true otherwise. Override this method to create a non-synchronizing, stateful component (return false), or a synchronizing stateless component (return true).


If this is confirmed, I can file a documentation bug @ radar.

Please do.

Chuck

--

Practical WebObjects - for developers who want to increase their overall knowledge of WebObjects or who are trying to solve specific problems.
http://www.global-village.net/products/practical_webobjects





_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to