<br><br><div class="gmail_quote">On Wed, Mar 23, 2011 at 3:02 PM, Marek Śmigielski <span dir="ltr"><<a href="mailto:marek.smigielski@gmail.com">marek.smigielski@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Hi,<br>
<br>
In last few day I have deeply thought over wicket modul features<br>
essential to fully integrate with wicket framework. In wicket<br>
architecture there is idea of model as a state bean. Its quite<br>
different in terms of live cycle from scopes provided by CDI.<br>
<br>
1. It is page scope (in some cirumstances more than one http request)<br>
2. It is serialized after each request and store in session or disk.<br>
<br>
Wicket modules misses integration throught model object with wicket<br>
architecture so I've developed some integration with it. The idea is<br>
that you can achieve CDI beans exactly in the same way like in JSF,<br>
through expressionLanguage. So you can inject any named or other el<br>
bean via:<br>
<br>
@Inject @ModelExpression("#{nameBean}")<br>
private SeamModel<String> label;<br>
<br>
and later use it on your page directly:<br>
<br>
Label label = new Label("headerLabel", headerLabelModel);<br>
<br>
or wrap it by other wicket model:<br>
<br>
@Inject @ModelExpression("#{registartion}")<br>
private SeamModel<Registartion> registartion;<br>
<br>
<br>
Form registrationForm = new Form("registartionForm", new<br>
CompoundPropertyModel(registartion));<br>
<br>
and later use it on whole form.<br>
<br></blockquote><div><br></div><div>I'm not sure what benefit this provides. The wicket page instance is already a scope, if you wanted something specific to the page, you could just add it as a field to the page or component. And EL as a referencing mechanism is a little too JSF-esque (weakly bound, not refactoring safe) to be well suited to a wicket integration layer.</div>
<div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<br>
As I follow seam 3 for some time now I understand that this is time<br>
for bugfix rather than adding new features. Is it possible to merge<br>
this code before final realese?<br>
<br>
Second feature is rather small and not soo excited as previous one.<br>
I've prepared possiblity to inject ResourceStreamLocator. Deafault is<br>
exactly the same as in wicket but I had also developed alternative<br>
one, which enables throught configuration to change the place where<br>
html file are stored. In my opinion it's also simplification.<br>
<br></blockquote><div><br></div><div> Wicket already has a way to register resource stream locators, I don't see why we need a yet another way to do it. Can you elaborate?</div><div> </div><div>-Clint</div></div>