a possible solution is: add to your application module class public static void bind(ServiceBinder binder) { binder.bind(User.class, UserImpl.class); }
2008/6/27 Kheldar666 <[EMAIL PROTECTED]>: > > Hello, > > When i use Tapestry, almost my Bean are Interfaces (ex : UserImpl > implements > User ). That causes me a problem sometimes, specially when using > BeanEditForm (ex : with @Parameter private User _user ). > > When I submit the form after editing a User, I have this error : > > Exception instantiating instance of org.libermundi.User (for component > 'Index:beaneditform.editor'): Class org.libermundi.User does not contain a > public constructor needed to autobuild. > > This is normal ! User is a interface... > > So, how do I tell Tapestry how to instantiate such objects ? > > I tried with Alias... doesn't work at all. The only way I could make this > work is when the User is an ApplicationStateObject because I contribute to > the ApplicationStateManager. > > Any idea ? Am I wrong when trying to make everything an Interface ? > > Thanks for your answers. > > Regards, > > Martin > -- > View this message in context: > http://www.nabble.com/-T5--Instantiate-%22Interfaces%22-tp18153603p18153603.html > Sent from the Tapestry - User mailing list archive at Nabble.com. > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- with regards Sven Homburg http://tapestry5-components.googlecode.com http://chenillekit.googlecode.com