[Wicket-user] Fwd: [Wicket-develop] [ wicket-Feature Requests-1350014 ] Add IModel in BookmarablePageLink constructor

2005-11-07 Thread Juergen Donnerstag
What is the use case for that change? Why do need to IModel with bookmarkable links? Juergen -- Forwarded message -- From: SourceForge.net [EMAIL PROTECTED] Date: Nov 7, 2005 8:36 AM Subject: [Wicket-develop] [ wicket-Feature Requests-1350014 ] Add IModel in BookmarablePageLink

AW: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread sven
IMHO pages are standing on the borderline between a stateful GUI and the rest of the application in form of stateless services. DI should be done by the IoC container, creating the pages can better be done the standard Wicket way (e.g. with PageParameters). As described before I'm using a

Re: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Igor Vaynberg
and you have to have the pages defined as beans in the application context? with their properties specified? -Igor On 11/7/05, Igor Vaynberg [EMAIL PROTECTED] wrote: but how does the above handle deserealization of pages? there is nothing to reinject the dependencies. -Igor On 11/7/05, [EMAIL

Re: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Igor Vaynberg
but how does the above handle deserealization of pages? there is nothing to reinject the dependencies. -Igor On 11/7/05, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: IMHO pages are standing on the borderline between a stateful GUI and the rest of the application in form of stateless services.DI

Re: [Wicket-user] simple bookmarkable url

2005-11-07 Thread Johan Compagner
there is already support for page aliasses see ApplicationPages On 11/4/05, Jeff Miller [EMAIL PROTECTED] wrote: Is there a way to create bookmarkable page without embedding any of the Wicket implementation details in the url? For example, the template example page 2 url is:

Re: [Wicket-user] Allow forcing of PageMap where Page will be added on creation?

2005-11-07 Thread Johan Compagner
in 1.2 we will have support for partial rendering So then you don't need it to wrap around a page. On 11/6/05, Janne Hietamäki [EMAIL PROTECTED] wrote: Hi,I'm doing some AJAX-stuff, and because there is not yet real support ofrendering single components (and having a URL for a Component) I'm

Re: [Wicket-user] Re: PageExpiredErrorPage

2005-11-07 Thread pepone pepone
Can you post your solution to help others that have the same problem thanks On 11/3/05, Francis Amanfo [EMAIL PROTECTED] wrote: I've solved the problem! Francis On 11/3/05, Francis Amanfo [EMAIL PROTECTED] wrote: Hi, I know with getPages().setPageExpiredErrorPage(Class) I can

[Wicket-user] redirect to previous url

2005-11-07 Thread pepone pepone
Hello i have a form in my border to do login/logout I wan to redirect user to same url before login the url that i use are allways bookmarkable and i wan to mantain the url whith the same parameters i thinking in same thing like void onSubmit() { //Form logic goes here //before is procesed

Re: [Wicket-user] Allow forcing of PageMap where Page will be added on creation?

2005-11-07 Thread Juergen Donnerstag
It is already in CVS HEAD, though not yet accesible through a URL. The method to call RequestCycle.render(component). It is the first implementation, so please bare with us if is not perfect yet. Hence, we appreciate any feedback. Juergen On 11/7/05, Johan Compagner [EMAIL PROTECTED] wrote: in

Re: [Wicket-user] redirect to previous url

2005-11-07 Thread Juergen Donnerstag
Please see the signin2 example. Juergen On 11/7/05, pepone pepone [EMAIL PROTECTED] wrote: Hello i have a form in my border to do login/logout I wan to redirect user to same url before login the url that i use are allways bookmarkable and i wan to mantain the url whith the same parameters

Re: [Wicket-user] Allow forcing of PageMap where Page will be added on creation?

2005-11-07 Thread Janne Hietamäki
Juergen Donnerstag wrote: It is already in CVS HEAD, though not yet accesible through a URL. The method to call RequestCycle.render(component). It is the first implementation, so please bare with us if is not perfect yet. Hence, we appreciate any feedback. Yep, I have tried that, and I'm

Re: [Wicket-user] Allow forcing of PageMap where Page will be added on creation?

2005-11-07 Thread Juergen Donnerstag
The page must be rendered completly at least once. Thus components can only be re-rendered. src/test/.../Simple*Test provides some examples. Juergen On 11/7/05, Janne Hietamäki [EMAIL PROTECTED] wrote: Juergen Donnerstag wrote: It is already in CVS HEAD, though not yet accesible through a

Re: [Wicket-user] Allow forcing of PageMap where Page will be added on creation?

2005-11-07 Thread Juergen Donnerstag
To answer you question: components must be attached to a page. This is required to find the markup. I don't think we are able to support all different kind of components without an attached page. Think about Label etc which don't have an attached markup file. Juergen On 11/7/05, Juergen

Re: [Wicket-user] Allow forcing of PageMap where Page will be added on creation?

2005-11-07 Thread Janne Hietamäki
Juergen Donnerstag wrote: To answer you question: components must be attached to a page. This is required to find the markup. I don't think we are able to support all different kind of components without an attached page. Think about Label etc which don't have an attached markup file. Juergen

Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Eduardo Rocha
2005/11/6, Eelco Hillenius [EMAIL PROTECTED]: I see absolutely nothing wrong with lookups at that level. It's less code than you would need for any component configuration and it's more efficient too. And there are just no disadvantages, are there? The Application class have references to all

Re: [Wicket-user] Allow forcing of PageMap where Page will be added on creation?

2005-11-07 Thread Juergen Donnerstag
On 11/7/05, Janne Hietamäki [EMAIL PROTECTED] wrote: Juergen Donnerstag wrote: To answer you question: components must be attached to a page. This is required to find the markup. I don't think we are able to support all different kind of components without an attached page. Think about

Re: [Wicket-user] Allow forcing of PageMap where Page will be added on creation?

2005-11-07 Thread Johan Compagner
Not a markup container but a panel (that is besides page the one with there own markup) should be able to render itself completely standalone. But maybe i am mistaken? juergen? On 11/7/05, Juergen Donnerstag [EMAIL PROTECTED] wrote: On 11/7/05, Janne Hietamäki [EMAIL PROTECTED] wrote: Juergen

Re: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Christian Essl
Hi Igor, I looked through your code. Thanks for implementing it. I am not sure wheter readObject() is the right place to do the (re)injection. According to the servlet-spec in SVR 7.7.2 readObject() is not guaranteed to be called on session-attributes. (Instead session attributes which

Re: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Johan Compagner
And there is also a thing like XML Serialization Which also doesn't use the java read/write object at all. On 11/7/05, Christian Essl [EMAIL PROTECTED] wrote: Hi Igor,I looked through your code. Thanks for implementing it. I am not surewheter readObject() is the right place to do the

AW: Re: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread sven
and you have to have the pages defined as beans in the application context? with their properties specified? Yes, I configure most wicket stuff in a separate context, which is bootstrapped by a custom application factory: bean class=XYPage singleton=false property name=service

Re: [Wicket-user] Allow forcing of PageMap where Page will be added on creation?

2005-11-07 Thread Juergen Donnerstag
On 11/7/05, Johan Compagner [EMAIL PROTECTED] wrote: Not a markup container but a panel (that is besides page the one with there own markup) should be able to render itself completely standalone. But maybe i am mistaken? juergen? Page and Panel are the only components that could be rendered

Re: [Wicket-user] simple bookmarkable url

2005-11-07 Thread Jeff Miller
Where would I find an example? I could not find any on wiki, wicket.sourceforge.net, or in examples. The javadoc isnot clear how to use ApplicationPages except that I need to use putClassAlias method. What object, if any, needs reference to the ApplicationPages object with the aliases? Thanks,

Re: [Wicket-user] Allow forcing of PageMap where Page will be added on creation?

2005-11-07 Thread Janne Hietamäki
Juergen Donnerstag wrote: Are you sure? Usually you render a page and a textbox which provides autocompletion. Will you ever render the textbox without prior rendering a page? Juergen Well, yes, I could add all those components to my Page, but that can be few hundred Panels, and that

AW: Re: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread sven
Hi Igor, here is something i threw together that solves the deserialization andability to use the new operator to create pages. thanks for your work on this. Regretfully it's still a solution I wouldn't like to use: IMHO dependency injection should not be done by the object which has the

Re: [Wicket-user] Allow forcing of PageMap where Page will be added on creation?

2005-11-07 Thread Juergen Donnerstag
Well, yes, I could add all those components to my Page, but that can be few hundred Panels, and that sound like an overkill to construct. Specially when probably only few of them will ever be rendered. Not sure I understand your comment. Lets say you have a standard wicket application with

Re: Re: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Juergen Donnerstag
Maybe RequestCycle.onBegin/EndRequest is what you are looking for? Juergen On 11/7/05, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Hi Igor, here is something i threw together that solves the deserialization andability to use the new operator to create pages. thanks for your work on this.

Re: [Wicket-user] Unexpected behaviour when using AjaxHandler's getBodyOnloadContribution()

2005-11-07 Thread Marco van de Haar
I dived into the wicket core code and I ended up in WebComponent.renderHead(). Since I noticed that getBodyOnLoad() was only called for FormComponents and WebMarkupContainers I expected a difference in renderHead() for WebComponent and WebMarkupContainer... and I found it.

Re: [Wicket-user] Unexpected behaviour when using AjaxHandler's getBodyOnloadContribution()

2005-11-07 Thread Juergen Donnerstag
I guess it would make sense to provide just a single implementation to be used by both components, avoiding problems while trying to keep them in sync. Juergen On 11/7/05, Ruud Booltink [EMAIL PROTECTED] wrote: I think adding this code to WebComponent's renderHead() would solve this problem.

Re: [Wicket-user] redirect to previous url

2005-11-07 Thread pepone pepone
what i don´t understand is when i must call redirectToInterceptPage beacause my sigin panel is allways in the border and documentation says that continueToOriginal only works with a previous call to redirectToInterceptPage On 11/7/05, Johan Compagner [EMAIL PROTECTED] wrote: We are redirecting

Re: [Wicket-user] simple bookmarkable url

2005-11-07 Thread Juergen Donnerstag
you may take a look at WebRequestWithCryptedUrl or WebRequestCrawlerSave as well. They are experimental only, but may point you into the right direction. Any improvements on this code are of course wellcome. Juergen On 11/7/05, Jeff Miller [EMAIL PROTECTED] wrote: putClassAlias is close to

Re: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Christian Essl
On Mon, 7 Nov 2005 15:25:29 +0100, Johan Compagner [EMAIL PROTECTED] wrote: And there is also a thing like XML Serialization Which also doesn't use the java read/write object at all. Does this mean that the readObject is guaranteed to be called on Page because it is serialized through the

Re: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Igor Vaynberg
I think with xml sereialization getobject is never called so there we still have a problem. But i think when the pagemap will deserialize the page if normal serialization is used then the readobject will be called on the page. The serialization closure, i think, reffers to the fact that container

Re: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Christian Essl
Thanks for the clarification and sorry for the confusion. So readObject() as you have it in your code is fine. To get the bean context i simply make my applicationbean implement applicationcontextaware and then i use ((MyApplication)Application.get()).getBeanContext() static lookup which works

Re: [Wicket-user] redirect to previous url

2005-11-07 Thread pepone pepone
What i trying to do is maintain the clean url that i have before form submit i don´t want that my app has not bookmarkable urls wiht path o version in it On 11/7/05, pepone pepone [EMAIL PROTECTED] wrote: what i don´t understand is when i must call redirectToInterceptPage beacause my sigin

Re: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Igor Vaynberg
what interface would you use for the proxy though? -Igor On 11/7/05, Christian Essl [EMAIL PROTECTED] wrote: Thanks for the clarification and sorry for the confusion. So readObject()as you have it in your code is fine. To get the bean context i simply make my applicationbean implement

[Wicket-user] where do I put controller/dispatcher logic?

2005-11-07 Thread Steven McNeel
Hello,I think I've read all of the pertinent articles in the documentation, especially http://www.wicket-wiki.org.uk/wiki/index.php/Lifecycle. On each request to my app, I first need to run a database query,the parameters of which are dependent on the parameters in the Request. Then I need to

Re: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Christian Essl
The interface of the setter parameter or of the field type. Of course a restriction. If you want more you could use cglib (or spring aop). Don't know. On Mon, 7 Nov 2005 11:27:28 -0800, Igor Vaynberg [EMAIL PROTECTED] wrote: what interface would you use for the proxy though? -Igor On

Re: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Igor Vaynberg
yeah, i was thinking cglib and extract at runtime never used cglib before though that way you just wrap the page with the proxy after you create it and there is no need to worry about serialization/deserialiation garbage -Igor On 11/7/05, Christian Essl [EMAIL PROTECTED] wrote: The interface of

Re: [Wicket-user] where do I put controller/dispatcher logic?

2005-11-07 Thread Juergen Donnerstag
On 11/7/05, Steven McNeel [EMAIL PROTECTED] wrote: Hello, I think I've read all of the pertinent articles in the documentation, especially http://www.wicket-wiki.org.uk/wiki/index.php/Lifecycle. On each request to my app, I first need to run a database query,the parameters of which are

Re: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Christian Essl
Do you mean when you construct the page you do something like MyPage page = (MyPage) wrapInProxy(new MyPage(..)); and wrapInProxy does create the Proxy and does all the injection? On Mon, 7 Nov 2005 11:56:23 -0800, Igor Vaynberg [EMAIL PROTECTED] wrote: yeah, i was thinking cglib and

Re: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Igor Vaynberg
yes. but instead of doing the injection right away the proxy would do injection-on-first-access. that way you get lazy injection and strongly typed pages. so you would annotate getter functions with the @SpringBean annot, and the proxy would first call the getter ... if the getter returns null

Re: [Wicket-user] where do I put controller/dispatcher logic?

2005-11-07 Thread Eelco Hillenius
And you are sure the queries you want to run are page/ component independent, right? What you are doing is request based, which is fine, but which is not nescesarily a component based way of doing things. Eelco On 11/7/05, Steven McNeel [EMAIL PROTECTED] wrote: Hello, I think I've read all

Re: [Wicket-user] Validation messages

2005-11-07 Thread Sven Meier
Hello Juergen, maybe it shouldn't - but currently it does ;). I debugged the new algorithm of ComponentStringResourceLoader today. As I already suspected, the id of the validated component is duplicated in the prefixKey, since both DefaultValidatorResourceKeyFactory and

Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Sven Meier
Hello Igor, I must object to your statement that my proposed page factory is not IoC: Nobody says that a Spring context is the only valid container in an application. The page factory just becomes part of the this logical container, it is aware of and cooperates with the Sprint context.

Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Eelco Hillenius
That kind of hooks exist. One of our goals for 1.2 is to further formalize this, and also have better pluggable support for url handling and state handling. We are getting some ideas on how this could look, but it is stuff you really have to think through well. Eelco On 11/7/05, Sven Meier

Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Igor Vaynberg
On 11/7/05, Sven Meier [EMAIL PROTECTED] wrote: Hello Igor,I must object to your statement that my proposed page factory is not IoC:Nobody says that a Spring context is the only valid container in anapplication. The page factory just becomes part of the this logical container, it is aware of and

Re: [Wicket-user] redirect to previous url

2005-11-07 Thread Johan Compagner
then you have to make sure that you always redirect to a bookmarkable url at all places! (form submits, link clicks) A form submit will always be a path=x thing So if that form submit is the page before youre redirectToIntercept (so a user submits a form but should login first) Then it will be

Re: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Igor Vaynberg
I agree. This is how the project im working on right now works. We have an iwebapplicationfactory that lets spring create the application object and pulls in all the services in with it. Then a getter in the page looks something like this: UserService getUserService() {

Re: [Wicket-user] where do I put controller/dispatcher logic?

2005-11-07 Thread Christian Essl
It confused me just until 10 minutes ago. I agree with you that it should be renamed if it is not already a too late. Christian I also think it is confusing if not misleading. On Mon, 7 Nov 2005 23:53:16 +0100, Johan Compagner [EMAIL PROTECTED] wrote: ahh yes i see it Got confused with

Re: [Wicket-user] redirect to previous url

2005-11-07 Thread pepone pepone
In my current aplication all links are bookmarkables or redirects to a bookmarkable pagte and i only want this for the SingInForm user that are not signedin can only access tow forms RegisterForm and SignIn form the register form redirect allways to a page that show the result of regitration or

Re: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Christian Essl
That's right. That's propably the cleanest way and you can use it on each component. The problem why I came up with the constructor aproach initially was that generally all the subcomponents are created and setup in the constructor. And it would than be IMO more wicket like if you can also

Re: Re: [Wicket-user] My take on Spring integration

2005-11-07 Thread Christian Essl
I think there should be both of your implementations. IMO the constructor based impl should have the protected doInject method, because to me it seems to be the easiest way to inject manually services in the constructor without the need to manually proxy them. Yes with cglib we'll hit the

[Wicket-user] Re: Allow forcing of PageMap where Page will be added on creation?

2005-11-07 Thread Dan Gould
Igor Vaynberg wrote: ahh yes, the web2.0 page as the application. ick. maybe we can add requestcycle.replaceAndRender(Component c) ? It seems to me that Janne's use-case would be better addressed by allowing Page.add(Component) and Page.remove(component) at runtime. So, using AJAX, you

[Wicket-user] Strange wicket.markup.MarkupException: Tag expected exception

2005-11-07 Thread Ralf Ebert
Hi, I'm seeing this exception when leaving a page via setResponsePage (concreteOtherPage) from a link component... The markup is alright and the error is missing something from the markup of the page which is left at that very moment (I don't even know why wicket looks at the markup of

Re: [Wicket-user] Re: Allow forcing of PageMap where Page will be added on creation?

2005-11-07 Thread Igor Vaynberg
thats exactly why i suggest the replace and render. you dont have a problem with markup if you are doing a replace. -Igor On 11/7/05, Dan Gould [EMAIL PROTECTED] wrote: Igor Vaynberg wrote: ahh yes, the web2.0 page as the application. ick. maybe we can add requestcycle.replaceAndRender(Component

Re: [Wicket-user] Validation messages

2005-11-07 Thread Juergen Donnerstag
It works on my side. I created unit tests and I think they are ok. I enabled logging for the package and it doesn't happen. I tested the formInput example and it works without changes. Did you update AbstractValidator as well? Juergen On 11/7/05, Sven Meier [EMAIL PROTECTED] wrote: Hello

Re: [Wicket-user] redirect to previous url

2005-11-07 Thread Juergen Donnerstag
If you are sure that you are realy not interested in path=xxx, may be it worth if you create your own WebRequest/WebResponse (see WebRequestCrawlerSaver for an example what can be done) Juergen On 11/8/05, pepone pepone [EMAIL PROTECTED] wrote: In my current aplication all links are

Re: [Wicket-user] Strange wicket.markup.MarkupException: Tag expected exception

2005-11-07 Thread Juergen Donnerstag
It is a redirect you do and the response gets rendered. Based on the stack trace something is wrong in one of the headers. Within head/head or wicket:head/wicket:head. In order to track it down: set a breakpoint at wicket.markup.html.HtmlHeaderContainer.resolve (HtmlHeaderContainer.java:196) and

Re: [Wicket-user] Strange wicket.markup.MarkupException: Tag expected exception

2005-11-07 Thread Dorel Vaida
I've got that exception in cases where the generated HTML is not valid XML. I didn't have time to dig into this but closing the tag with valid xml, like / or /close solved the problem. Ralf Ebert wrote: Hi, I'm seeing this exception when leaving a page via setResponsePage

Re: [Wicket-user] Validation messages

2005-11-07 Thread Juergen Donnerstag
yes, that is a bug Juergen On 11/8/05, Ingram Chen [EMAIL PROTECTED] wrote: I check out latest CVS HEAD, but find strange behavior: If a MyPage.properties as below: RequiredValidator = ${label} is required myForm.bookId = Book ID then validation message work well and is Book ID is