Re: [Wicket-user] Playing with models:)/wicket.extensions.markup.html.form.palette.Palette;

2006-07-18 Thread Nino Wael
Ill like to take you up on the discussion. I see the following pros and cons with this approach: Pro setObject: Allows the user to implement logic into the model If so desired Special conversions to satishfy wicket components needs, for example, wicket component needs one

Re: [Wicket-user] Wicket in large scale production scenarios?

2006-07-18 Thread Martijn Dashorst
Hi Peter, I've done some performance/load tests with Wicket for our current project. Wicket itself isn't the problem in this regard, usually it is the amount of data you want to present on your pages. That data typically comes from a database and the number of queries and the amount of data to be

Re: [Wicket-user] Wicket in large scale production scenarios?

2006-07-18 Thread Peter Neubauer
Martijn, thanks for the good reply, will try to make something out of it to present to the customer. Thanks a lot! /peter On 7/18/06, Martijn Dashorst [EMAIL PROTECTED] wrote: Hi Peter, I've done some performance/load tests with Wicket for our current project. Wicket itself isn't the problem

Re: [Wicket-user] Wicket Hibernate Application Transactions

2006-07-18 Thread Iman Rahmatizadeh
Nathan Hamblen wrote: As others have pointed out, the magic of IModel works better than you think (or thought) it does. I often have two constructors for pages, one taking bookmarkable parameters and another taking an IModel so that I don't always have to reload DB objects page to page. It's a

Re: [Wicket-user] Wicket Hibernate Application Transactions

2006-07-18 Thread Eelco Hillenius
I don't think models have to be implementation details. Sometimes that makes sense, and in that case I usually like to embed the model class in the component itself. But lots of other times, you can make the model so that it can easily be reused by other components, possibly at the same time. This

Re: [Wicket-user] ListView#accept() proposal

2006-07-18 Thread Johan Compagner
But then you need to pre filter the list. Because what would size() return??But going with something out of the repeater package would be better.But then still you need to filter up front because all those Repeaters do want to know the total size? And filtering on demand doesn't work then.johanOn

Re: [Wicket-user] Model and setObject?

2006-07-18 Thread Nino Wael
Please see the other mail I sent.. Re: [Wicket-user] Playing withmodels:)/wicket.extensions.markup.html.form.palette.Palette; From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Johan Compagner Sent: 18. juli 2006 12:48 To: wicket-user@lists.sourceforge.net Subject:

Re: [Wicket-user] ajax the wiki

2006-07-18 Thread Gwyn Evans
Not sure about Best Practice, but DropDownChoice_Examples/More_Examples on the wiki (http://www.wicket-wiki.org.uk/wiki/index.php/DropDownChoice_Examples#More_Examples) shows the onSelectionChanged method and then the Ajax methods of handling the changes where you have two DropDownChoice

Re: [Wicket-user] Playing with models:)/wicket.extensions.markup.html.form.palette.Palette;

2006-07-18 Thread Johan Compagner
yes you are right.But in 1.2 this couldn't be done because of some code that was sitting in the way (modelChanging/changed double called and so on)in 2.0 we pretty much have fixed that part i believe. now. Have to look at it further. johanOn 7/18/06, Nino Wael [EMAIL PROTECTED] wrote:

Re: [Wicket-user] Modal Dialog

2006-07-18 Thread Johan Compagner
Like a Swing modal dialog? So that exeuction of code stops until the dialog is closedand then resumes again! CooljohanP.S. or is that called something else Cont.. ;) On 7/17/06, Eelco Hillenius [EMAIL PROTECTED] wrote: Not at this time. Shouldn't be too hard to do, but we're still

Re: [Wicket-user] Modal Dialog

2006-07-18 Thread Matej Knopp
Once I made a component like this. here is demonstration http://ruzin.fei.tuke.sk:8080/majcher/app the source code should be here, http://knopp.sk/modal.zip but a) it's wicket 1.1 b) there could be some glitches on java side Once I finish the tree I might rework it to make the modal

Re: [Wicket-user] Modal Dialog

2006-07-18 Thread Eelco Hillenius
Yay for Matej! Eelco On 7/18/06, Matej Knopp [EMAIL PROTECTED] wrote: Once I made a component like this. here is demonstration http://ruzin.fei.tuke.sk:8080/majcher/app the source code should be here, http://knopp.sk/modal.zip but a) it's wicket 1.1 b) there could be some

Re: [Wicket-user] Wicket Hibernate Application Transactions

2006-07-18 Thread Igor Vaynberg
its my 2c as well this is not a wicket-related problem anyhow - its http related problem. -Igor On 7/18/06, Eelco Hillenius [EMAIL PROTECTED] wrote: I don't think models have to be implementation details. Sometimes thatmakes sense, and in that case I usually like to embed the model classin the

[Wicket-user] RequestCycle scope

2006-07-18 Thread Aaron Hiniker
Is there a way to attach objects to a request cycle... I'm interested in creating session beans that live only during the duration of the request Aaron - Take Surveys. Earn Cash. Influence the Future of IT Join

Re: [Wicket-user] RequestCycle scope

2006-07-18 Thread Igor Vaynberg
you can create your own subclass of the request cycle and tell wicket to use that instead.you can do that by overriding WebApplication.getDefaultRequesteCycleFactory and returning your own instance of the factory. -IgorOn 7/18/06, Aaron Hiniker [EMAIL PROTECTED] wrote: Is there a way to

Re: [Wicket-user] RequestCycle scope

2006-07-18 Thread Igor Vaynberg
alternatively you can override WebSession.getRequestCycleFactory()-IgorOn 7/18/06, Igor Vaynberg [EMAIL PROTECTED] wrote:you can create your own subclass of the request cycle and tell wicket to use that instead. you can do that by overriding WebApplication.getDefaultRequesteCycleFactory and

[Wicket-user] java.io.NotSerializableException on my session object

2006-07-18 Thread Steve Moitozo
I just changed the log4j log level for wicket to DEBUG and now my application craps out with the following error: Internal error cloning object. Make sure all dependent objects implement Serializable. Class: mystuff.wicketapp.MyWebSession Am I to assume that the entire hierarchy of class

Re: [Wicket-user] java.io.NotSerializableException on my session object

2006-07-18 Thread Igor Vaynberg
this is not a requiremenet of wicket per se but that of the servlet containers. anything you keep in http session must be serializable. since wicket keeps most of its entities in session they must be serializable.when you set level to debug you tripped this: HttpSessionStore:47public void

Re: [Wicket-user] Wicket Hibernate Application Transactions

2006-07-18 Thread Nathan Hamblen
Agreed. I don't think there's anything here that needs fixing. I was just saying that if Iman or anyone else wants to experiment with extended Hibernate sessions, I think that would be cool. (Reattaching orphaned Hibernate objects is not a road I would want to go down.) In the mean time our

Re: [Wicket-user] java.io.NotSerializableException on my session object

2006-07-18 Thread Steve Moitozo
Thanks for the quick response. Do you know if there's a way to tell Java which parts of an object are vital during serialization and which can be ignored. I'm thinking about how Detachable Models work. Am I correct in assuming that if I do not correct this my app will continue to work in a

Re: [Wicket-user] java.io.NotSerializableException on my session object

2006-07-18 Thread Eelco Hillenius
There is a DEBUG level logger in wicket.protocol.http.HttpSessionStore that tries to serialize any attribute that is set. The development version - soon 1.2.1 - has a fix so that it doesn't depend on the log level, but instead on an application setting: if

Re: [Wicket-user] java.io.NotSerializableException on my session object

2006-07-18 Thread Eelco Hillenius
On 7/18/06, Steve Moitozo [EMAIL PROTECTED] wrote: Thanks for the quick response. Do you know if there's a way to tell Java which parts of an object are vital during serialization and which can be ignored. yep, the transient keyword. Transient fields will not be serialized (and thus null

Re: [Wicket-user] java.io.NotSerializableException on my session object

2006-07-18 Thread Igor Vaynberg
Thanks for the quick response. Do you know if there's a way to tell Java which parts of an object are vital during serialization and which can be ignored. I'm thinking about how Detachable Models work.not really sure what you mean or why you would have to do that. what is the usecase for having

Re: [Wicket-user] java.io.NotSerializableException on my session object

2006-07-18 Thread Igor Vaynberg
i would be careful about using transient since you will have to implement null checks anytime you access that field.-IgorOn 7/18/06, Eelco Hillenius [EMAIL PROTECTED] wrote: On 7/18/06, Steve Moitozo [EMAIL PROTECTED] wrote: Thanks for the quick response. Do you know if there's a way to tell

Re: [Wicket-user] java.io.NotSerializableException on my session object

2006-07-18 Thread Steve Moitozo
not really sure what you mean or why you would have to do that. what is the usecase for having something that is not serializable in session? As I trace this issue through my code it's becoming apparent that since pages are added to the session any properties that is in a page that isn't

Re: [Wicket-user] java.io.NotSerializableException on my session object

2006-07-18 Thread Igor Vaynberg
well, now that you are aware of this going should get better.in case you are storing beans from other framework that are not serializable i really dont see an easy way. the creators of those projects should make sure their objects are serializable. the only thing i see that you can do is to create

[Wicket-user] set static values on DropDownChoice

2006-07-18 Thread Vincent Jenks
This seems like a lame question but I'm struggling again w/ the DropDownChoice control (using 1.2). I simply want to set static values to a DropDownChoice control so they can be drawn out later in the form's input class when it's submitted. I thought I had done this before but can't find that I

[Wicket-user] More examples of sorting?

2006-07-18 Thread Vincent Jenks
Is there something smaller simpler out there I could refer to for sorting? I've glanced at the DataView example a few times and once I start digging in it just seems unwieldly to me. I'm simply trying to sort a List of entities and the getContactsDB() stuff in the examples is a bit complicated

Re: [Wicket-user] More examples of sorting?

2006-07-18 Thread Igor Vaynberg
what could be simpler then the dataview? its just like a listview only instead of being fed off the list it is fed from the idataprovider.class mydataprovider implements idataprovider() { iterator iterator(int first, int count) { return mydao.findcontacts(first, count).iterator(); } int size() {

Re: [Wicket-user] More examples of sorting?

2006-07-18 Thread Vincent Jenks
Currently I don't have anything like the ContactsDatabase class in 'examples' - I'm just pulling a list of data and displaying in a ListViewbut it appears now that I'm browsing through I'm going to have to create one and implement some of the methods like you have in order to get

Re: [Wicket-user] More examples of sorting?

2006-07-18 Thread Igor Vaynberg
yep, you have to code your daos with paging and sorting in mind, it cannot be slapped on as an afterthought.let me give you some cluessee the attached QueryParam class, all my finder dao methods take it so that they can page/sort accordingly. hope it gets you started-IgorOn 7/18/06, Vincent Jenks

Re: [Wicket-user] More examples of sorting?

2006-07-18 Thread Vincent Jenks
Well, I don't have DAOs in this particular project - it's an EJB3 project where I'm simply using SLSBs as DAOsso I have the EntityManager to work from and I should be able to bring the two together to facilitate this... This may be easier than I thought On 7/18/06, Igor Vaynberg [EMAIL

Re: [Wicket-user] More examples of sorting?

2006-07-18 Thread Igor Vaynberg
then the only semidifficult part is the sorting - you need to come up with some utils that append the sort for you.as far as paging it would translate directly tosession.setFirstResult(queryparam.getFirst()).setMaxResults( queryparam.getCount());-IgorOn 7/18/06, Vincent Jenks [EMAIL PROTECTED]

Re: [Wicket-user] More examples of sorting?

2006-07-18 Thread Vincent Jenks
Wow...ok...I'm making a total disaster of this. I can't help but think there's an easier way. :( I've got this method in what we could call a dao: public ListIncident getFiltered(int first, int count, String orderBy) { String query = select i from Incident i

Re: [Wicket-user] More examples of sorting?

2006-07-18 Thread Vincent Jenks
I appreciate it Frank, however I'm not familiar w/ DataTable or the SortableDataProvider - this is my first run. Really what I need is to see sorting working and I haven't even gotten that far. I'd be willing to take a lookit might be easier to see it working w/ plain JDBC to get a view of