[Seaside] break out of task

Lukas Renggli renggli at gmail.com
Mon Jul 9 11:15:33 UTC 2007

> > WATask answers what your method #go is returning, which is self if you
> > don't specify anything else. However if there is nobody that calls the
> > task, it is simply restarted.
> Ok, now I know that I have to do a call: on the task. This not how
> my logic works. It would expect the task to just return and the
> following statements set up new components to show.

A task expects you to override #go and do a #call: somewhere in there.
Otherwise a task doesn't make much sense. See the class comment.

> > What would you expect otherwise? To get an empty component?
> In general I would expect the task to end. I understand a task as
> "do these things and then you are finished so exit". The place
> where the task was could be nil then and it would displayed nothing
> (as long as this would work). In my case I just set up components
> in the background which will show automatically as soon as the task
> exits.

That should be  a last step of your task then.

> Or I would expect to work like normal WAComponents. If I'm not wrong
> they render themselves as long as no answer is called.

A WATask also answers when the method #go ends.


Lukas Renggli

More information about the Seaside mailing list