when you click a link the url contains the page id in the pagemap, the component path of the link object you clicked and what kind of interface to invoke on the component that is pointed to by the path ( in this case a link). from this information wicket can lookup the page that the link belongs to from the pagemap, find the right component, and then execute a callback method on it. in this case it would result in Link's onClick() handler being invoked.
similar happens for forms.
hope this helps, if you have more questions fire away.
-Igor
On 12/20/05, karthik Guru <
[EMAIL PROTECTED]> wrote:
I'm still on the HelloWorld example. I can see that wicket has a component that corresponds to all the HTML tags in the html template file and they are being added to the HelloPage component in the constructor. I guess an instance of HelloPage is probably created (and with that all the contained components) when i request the html and then the page can pull the data from the model and render it.What happens after that , is the HelloWorldPage instance discarded? When i submit, does wicket again instantiate a HelloWorldPage instance or pull it from some cache it has internally? Does it look at the html template, check the component hierarchy in the template, and then go look for an equivalent java component in the Page hierarchy and fill up the values from the request?and wicket knows somehow that the form has been submitted and hence onSubmit needs to be called?Can someone explain the behaviour.thank you.regards,karthik
