Is this safe?

2008-01-21 Thread Martijn Lindhout
Hi all,

I wonder if this will work:

add(new CartPanel(cart, new PropertyModel(s, cart)));

where 's' is my app specific session, containing the method getCart() which
checks the session for an existing cart, and if not found creates one.

Is this enough to handle load/detach? Or do I have to write my own
LoadableModel

-- 
Martijn Lindhout
JointEffort IT Services
http://www.jointeffort.nl
[EMAIL PROTECTED]
+31 (0)6 18 47 25 29


RE: We are adopting Wicket in our Organization

2008-01-21 Thread dvd
I fully agree. I used JSF/SEAM before switching to Wicket.
My experience is that Wicket is JSF-Done-Right



As I've stated before in a previous post, I work a for a company that
develops software for the health care industry.  It was a battle between
JSF/Seam and Wicket as the framework of choice for the rewrite of the
company's portal.  After a whitepaper written by a colleague of mine that
compared the two implementations, Wicket was the clear winner. (I also
presented a demo of the Wicket framework to the team a couple months back).

I'd like to thank the authors of the framework for building such a fine
tool.  After years of struts development, developing web applications with
Wicket is a breath of fresh air.  Keep up the fine work.

I'll update this forum with our experience in developing/deploying web apps
using Wicket.

- rm3 
-- 
View this message in context: 
http://www.nabble.com/We-are-adopting-Wicket-in-our-Organization-tp14988751p149
88751.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Is this safe?

2008-01-21 Thread Johan Compagner
What would you like to detach?
What is inside that card object? I guess thats a temp storage object
of shopping items?

Do remenber that getting the card object from the session isnt thread
safe! (mutating it can be done from more then one thread if different
pagemaps and so on are used)

On 1/21/08, Martijn Lindhout [EMAIL PROTECTED] wrote:
 Hi all,

 I wonder if this will work:

 add(new CartPanel(cart, new PropertyModel(s, cart)));

 where 's' is my app specific session, containing the method getCart() which
 checks the session for an existing cart, and if not found creates one.

 Is this enough to handle load/detach? Or do I have to write my own
 LoadableModel

 --
 Martijn Lindhout
 JointEffort IT Services
 http://www.jointeffort.nl
 [EMAIL PROTECTED]
 +31 (0)6 18 47 25 29


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Link to last version of a page of a given type/class.

2008-01-21 Thread Ned Collyer

Hi,

I may be overlooking something, however I am having a bit of trouble linking
to the last current version of a page unless I use the method outlined by
igor, which isn't practical for what I am trying to achieve (see his method
below from
http://www.nabble.com/pageMap-question---td13541168.html#a13554232)


igor.vaynberg wrote:
 
 for scenarios like those simply pass the page instance to another page
 
 class secondsteppage extends webpage {
   public secondsteppage(page first) {
 add(new link(go-back) { onclick() { setresponsepage(first); }});
   }
 }
 
 -igor
 

For example, say I have a page of search criteria (the form is in a reusable
panel), and its filled and i navigate around a bit.  The next time I come to
the search criteria page, I want it to remember the last search (ie, return
the last version of the search criteria page).

I have been able to do this in a rudimentary way by passing the page
instance of the search criteria page through to the constructor of the
destination page via a forms onSubmit().

This means I can then call the
setResponsePage(searchPage.getVersion(Page.LATEST_VERSION)); on the onClick
of a link in the destination page.

However this will only work from the destination page - not if i navigate
around to other pages.  Without specifying a version  a new instance is
being created.

 (ie PageLink(SearchPage.class) creates a new SearchPage instance).

Surely there is a way of retrieving the latest existing version of a page
given a class type.  I've trawled google and the examples and api - I'm
feeling stupid - like i've missed something obvious, or inadvertently broken
the expected behaviour.
-- 
View this message in context: 
http://www.nabble.com/Link-to-last-version-of-a-page-of-a-given-type-class.-tp14994042p14994042.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: We are adopting Wicket in our Organization

2008-01-21 Thread Joshua Jackson
SEAM is not that bad actually. Though it still has some quirks.

On 1/21/08, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
 I fully agree. I used JSF/SEAM before switching to Wicket.
 My experience is that Wicket is JSF-Done-Right

-- 
It's not going to be like this forever

Blog: http://joshuajava.wordpress.com/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Link to last version of a page of a given type/class.

2008-01-21 Thread Johan Compagner
Just remember  in a simple valuesholder class the page id and pagmap
for a page (and version if you want that) and then ask through the
session for that page. If many pages (or big pages) are created in
between, it could return nothing.. Depending on the size of the
diskpage session/pagmap file.

On 1/21/08, Ned Collyer [EMAIL PROTECTED] wrote:

 Hi,

 I may be overlooking something, however I am having a bit of trouble linking
 to the last current version of a page unless I use the method outlined by
 igor, which isn't practical for what I am trying to achieve (see his method
 below from
 http://www.nabble.com/pageMap-question---td13541168.html#a13554232)


 igor.vaynberg wrote:
 
  for scenarios like those simply pass the page instance to another page
 
  class secondsteppage extends webpage {
public secondsteppage(page first) {
  add(new link(go-back) { onclick() { setresponsepage(first); }});
}
  }
 
  -igor
 

 For example, say I have a page of search criteria (the form is in a reusable
 panel), and its filled and i navigate around a bit.  The next time I come to
 the search criteria page, I want it to remember the last search (ie, return
 the last version of the search criteria page).

 I have been able to do this in a rudimentary way by passing the page
 instance of the search criteria page through to the constructor of the
 destination page via a forms onSubmit().

 This means I can then call the
 setResponsePage(searchPage.getVersion(Page.LATEST_VERSION)); on the onClick
 of a link in the destination page.

 However this will only work from the destination page - not if i navigate
 around to other pages.  Without specifying a version  a new instance is
 being created.

  (ie PageLink(SearchPage.class) creates a new SearchPage instance).

 Surely there is a way of retrieving the latest existing version of a page
 given a class type.  I've trawled google and the examples and api - I'm
 feeling stupid - like i've missed something obvious, or inadvertently broken
 the expected behaviour.
 --
 View this message in context:
 http://www.nabble.com/Link-to-last-version-of-a-page-of-a-given-type-class.-tp14994042p14994042.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Is this safe?

2008-01-21 Thread Martijn Lindhout
ok, and if the session isn't thread safe, where do I store my temporal data?


2008/1/21, Johan Compagner [EMAIL PROTECTED]:

 The session. Because the property exp is used when you ask for the value

 On 1/21/08, Martijn Lindhout [EMAIL PROTECTED] wrote:
  you're right. It contains a shoppingcart. What is stored in the
  propertymodel, the session? Or the result of evaluating the expression
  s.cart - session.getCart().
 
  And if the session isn't thread safe, where do I store my temporal data?
 
  2008/1/21, Johan Compagner [EMAIL PROTECTED]:
  
   What would you like to detach?
   What is inside that card object? I guess thats a temp storage object
   of shopping items?
  
   Do remenber that getting the card object from the session isnt thread
   safe! (mutating it can be done from more then one thread if different
   pagemaps and so on are used)
  
   On 1/21/08, Martijn Lindhout [EMAIL PROTECTED] wrote:
Hi all,
   
I wonder if this will work:
   
add(new CartPanel(cart, new PropertyModel(s, cart)));
   
where 's' is my app specific session, containing the method
 getCart()
   which
checks the session for an existing cart, and if not found creates
 one.
   
Is this enough to handle load/detach? Or do I have to write my own
LoadableModel
   
--
Martijn Lindhout
JointEffort IT Services
http://www.jointeffort.nl
[EMAIL PROTECTED]
+31 (0)6 18 47 25 29
   
  
   -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
  
  
 
 
  --
  Martijn Lindhout
  JointEffort IT Services
  http://www.jointeffort.nl
  [EMAIL PROTECTED]
  +31 (0)6 18 47 25 29
 

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




-- 
Martijn Lindhout
JointEffort IT Services
http://www.jointeffort.nl
[EMAIL PROTECTED]
+31 (0)6 18 47 25 29


Re: Questions for permission of using the design of wicket-example

2008-01-21 Thread Johan Compagner
Cool to hear that it is such a big success!

I cant believe that you couldnt use those things if they are all also
released under apache license but lets wait for martijn. (you could
drop the apache form the apache wicket name)

On 1/20/08, Tsutomu Yano [EMAIL PROTECTED] wrote:
   Hi,

   Few days ago, we (I and my friends) organize a user group of Wicket
 in Japan(Wicket User Group Japan aka Wicket-JA) and already 80+
 people join with us.

   https://sourceforge.jp/projects/wicket-ja

   We are creating the group-site now (we haven't it yet. only mailing
 lists).

   The wicket framework is so hot now in Japan! We would like to expand
 the number of users in japan by providing wicket-related information
 to our members in japanese language and at some time would like to
 contribute to the Apache Wicket project by sending you some bug-fixing
 or function-expanding code.

   We have some questions to the wicket team. and I could not find out
 the contact address on wicket site. I hope that the members of wicket
 team will read this message...

   Our questions:

   1. We would like to make our pages visually 'wicket-like'. So we
 would like to use the design and background images of your 'wicket-
 example' like http://www.wicketstuff.org/wicket13/captcha/ . May I do
 that?

   2. Can we use your Wicket Logo mark on our site? or is it under any
 kind of protections? If it is possible, we would like to put the logo
 mark on our top page.



   Thank you.


 -
 Tsutomu YANO
 mailto:benbrand at mac.com





 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Is this safe?

2008-01-21 Thread Martijn Lindhout
you're right. It contains a shoppingcart. What is stored in the
propertymodel, the session? Or the result of evaluating the expression
s.cart - session.getCart().

And if the session isn't thread safe, where do I store my temporal data?

2008/1/21, Johan Compagner [EMAIL PROTECTED]:

 What would you like to detach?
 What is inside that card object? I guess thats a temp storage object
 of shopping items?

 Do remenber that getting the card object from the session isnt thread
 safe! (mutating it can be done from more then one thread if different
 pagemaps and so on are used)

 On 1/21/08, Martijn Lindhout [EMAIL PROTECTED] wrote:
  Hi all,
 
  I wonder if this will work:
 
  add(new CartPanel(cart, new PropertyModel(s, cart)));
 
  where 's' is my app specific session, containing the method getCart()
 which
  checks the session for an existing cart, and if not found creates one.
 
  Is this enough to handle load/detach? Or do I have to write my own
  LoadableModel
 
  --
  Martijn Lindhout
  JointEffort IT Services
  http://www.jointeffort.nl
  [EMAIL PROTECTED]
  +31 (0)6 18 47 25 29
 

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




-- 
Martijn Lindhout
JointEffort IT Services
http://www.jointeffort.nl
[EMAIL PROTECTED]
+31 (0)6 18 47 25 29


Re: Is this safe?

2008-01-21 Thread Johan Compagner
The session. Because the property exp is used when you ask for the value

On 1/21/08, Martijn Lindhout [EMAIL PROTECTED] wrote:
 you're right. It contains a shoppingcart. What is stored in the
 propertymodel, the session? Or the result of evaluating the expression
 s.cart - session.getCart().

 And if the session isn't thread safe, where do I store my temporal data?

 2008/1/21, Johan Compagner [EMAIL PROTECTED]:
 
  What would you like to detach?
  What is inside that card object? I guess thats a temp storage object
  of shopping items?
 
  Do remenber that getting the card object from the session isnt thread
  safe! (mutating it can be done from more then one thread if different
  pagemaps and so on are used)
 
  On 1/21/08, Martijn Lindhout [EMAIL PROTECTED] wrote:
   Hi all,
  
   I wonder if this will work:
  
   add(new CartPanel(cart, new PropertyModel(s, cart)));
  
   where 's' is my app specific session, containing the method getCart()
  which
   checks the session for an existing cart, and if not found creates one.
  
   Is this enough to handle load/detach? Or do I have to write my own
   LoadableModel
  
   --
   Martijn Lindhout
   JointEffort IT Services
   http://www.jointeffort.nl
   [EMAIL PROTECTED]
   +31 (0)6 18 47 25 29
  
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 


 --
 Martijn Lindhout
 JointEffort IT Services
 http://www.jointeffort.nl
 [EMAIL PROTECTED]
 +31 (0)6 18 47 25 29


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Questions for permission of using the design of wicket-example

2008-01-21 Thread Peter Thomas
On 1/21/08, Johan Compagner [EMAIL PROTECTED] wrote:

 Cool to hear that it is such a big success!

 I cant believe that you couldnt use those things if they are all also
 released under apache license but lets wait for martijn. (you could
 drop the apache form the apache wicket name)


Can some official Wicket buttons be made available to add to sites and
applications powered by Wicket and the like?

The Spring Framework buttons can be found here:
http://www.springframework.org/spring-buttons

Oh and by the way I noticed a poll on the Spring front page:
http://www.springframework.org/ that asks the question which web templating
framework do you use and Wicket is one of the choices :)

- Peter

On 1/20/08, Tsutomu Yano [EMAIL PROTECTED] wrote:
Hi,
 
Few days ago, we (I and my friends) organize a user group of Wicket
  in Japan(Wicket User Group Japan aka Wicket-JA) and already 80+
  people join with us.
 
https://sourceforge.jp/projects/wicket-ja
 
We are creating the group-site now (we haven't it yet. only mailing
  lists).
 
The wicket framework is so hot now in Japan! We would like to expand
  the number of users in japan by providing wicket-related information
  to our members in japanese language and at some time would like to
  contribute to the Apache Wicket project by sending you some bug-fixing
  or function-expanding code.
 
We have some questions to the wicket team. and I could not find out
  the contact address on wicket site. I hope that the members of wicket
  team will read this message...
 
Our questions:
 
1. We would like to make our pages visually 'wicket-like'. So we
  would like to use the design and background images of your 'wicket-
  example' like http://www.wicketstuff.org/wicket13/captcha/ . May I do
  that?
 
2. Can we use your Wicket Logo mark on our site? or is it under any
  kind of protections? If it is possible, we would like to put the logo
  mark on our top page.
 
 
 
Thank you.
 
 
  -
  Tsutomu YANO
  mailto:benbrand at mac.com
 
 
 
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




Re: Link to last version of a page of a given type/class.

2008-01-21 Thread Ned Collyer

Hi Johan,

Thank you for the reply.

This suggestion will work, but it seems like something that the framework
should do automatically.  The whole maintaining state thing is meant to
maintain state between requests without the extra dev overhead of manually
plugging stuff into, and pulling out of the session.  I'm happy to get a new
instance of the page if its been cleansed from the session - thats not a
problem, but I was under the impression that wicket should already be
maintaining this state - I just need a link generated.

I find it a bit bizarre that methods like Page.getVersion(int num) exist,
but because its not static.. i need an instance of the page to retrieve a
previously versioned instances of the page. (rather than
Page.getVersion(Class clazz, int version)).

Does wicket not support linking to the last version of a given class type? 
If not, I would find this quite useful.

Something like

new PageLink(search-criteria-link, SearchCriteriaPage.class,
Page.LATEST_VERSION)

Would be exactly what I'm after.  (I'm still optimistic that this feature
exists and its me being stupid not able to find it. ;))


Rgds

Ned


Johan Compagner wrote:
 
 Just remember  in a simple valuesholder class the page id and pagmap
 for a page (and version if you want that) and then ask through the
 session for that page. If many pages (or big pages) are created in
 between, it could return nothing.. Depending on the size of the
 diskpage session/pagmap file.
 

-- 
View this message in context: 
http://www.nabble.com/Link-to-last-version-of-a-page-of-a-given-type-class.-tp14994042p14994505.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Is this safe?

2008-01-21 Thread Martijn Lindhout
custom request cycle?

2008/1/21, Martijn Dashorst [EMAIL PROTECTED]:

 Typically a custom request cycle for the actual object and store the key
 for
 getting access to the object in the session.
 If the cart is not a hibernate entity, but something really transient, I
 don't think there is any harm in putting it in the session, as long as you
 are certain you won't be doing resouce updates based on the session.
 Typically add/remove from carts are single requests that are synchronized
 on
 the session.

 As for the property model, you can do this as well:

 add(new ShoppingCartPanel(panel, new PropertyModel(this, session.cart
 )));


 Martijn

 On 1/21/08, Martijn Lindhout [EMAIL PROTECTED] wrote:
 
  ok, and if the session isn't thread safe, where do I store my temporal
  data?
 
 
  2008/1/21, Johan Compagner [EMAIL PROTECTED]:
  
   The session. Because the property exp is used when you ask for the
 value
  
   On 1/21/08, Martijn Lindhout [EMAIL PROTECTED] wrote:
you're right. It contains a shoppingcart. What is stored in the
propertymodel, the session? Or the result of evaluating the
 expression
s.cart - session.getCart().
   
And if the session isn't thread safe, where do I store my temporal
  data?
   
2008/1/21, Johan Compagner [EMAIL PROTECTED]:

 What would you like to detach?
 What is inside that card object? I guess thats a temp storage
 object
 of shopping items?

 Do remenber that getting the card object from the session isnt
  thread
 safe! (mutating it can be done from more then one thread if
  different
 pagemaps and so on are used)

 On 1/21/08, Martijn Lindhout [EMAIL PROTECTED] wrote:
  Hi all,
 
  I wonder if this will work:
 
  add(new CartPanel(cart, new PropertyModel(s, cart)));
 
  where 's' is my app specific session, containing the method
   getCart()
 which
  checks the session for an existing cart, and if not found
 creates
   one.
 
  Is this enough to handle load/detach? Or do I have to write my
 own
  LoadableModel
 
  --
  Martijn Lindhout
  JointEffort IT Services
  http://www.jointeffort.nl
  [EMAIL PROTECTED]
  +31 (0)6 18 47 25 29
 


  -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


   
   
--
Martijn Lindhout
JointEffort IT Services
http://www.jointeffort.nl
[EMAIL PROTECTED]
+31 (0)6 18 47 25 29
   
  
   -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
  
  
 
 
  --
  Martijn Lindhout
  JointEffort IT Services
  http://www.jointeffort.nl
  [EMAIL PROTECTED]
  +31 (0)6 18 47 25 29
 



 --
 Buy Wicket in Action: http://manning.com/dashorst
 Apache Wicket 1.3.0 is released
 Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0




-- 
Martijn Lindhout
JointEffort IT Services
http://www.jointeffort.nl
[EMAIL PROTECTED]
+31 (0)6 18 47 25 29


Re: Questions for permission of using the design of wicket-example

2008-01-21 Thread Martijn Dashorst
Actually, Wicket as it pertains to Apache Wicket is protected. I'm just
not sure to what extent. It may even be that new open source projects many
not call them WicketFoo, but rather Foo for Apache Wicket. It all has to
do with protecting the trademark.
However, I'm still waiting for a reply from the PRC.

Martijn

On 1/21/08, Johan Compagner [EMAIL PROTECTED] wrote:

 Cool to hear that it is such a big success!

 I cant believe that you couldnt use those things if they are all also
 released under apache license but lets wait for martijn. (you could
 drop the apache form the apache wicket name)

 On 1/20/08, Tsutomu Yano [EMAIL PROTECTED] wrote:
Hi,
 
Few days ago, we (I and my friends) organize a user group of Wicket
  in Japan(Wicket User Group Japan aka Wicket-JA) and already 80+
  people join with us.
 
https://sourceforge.jp/projects/wicket-ja
 
We are creating the group-site now (we haven't it yet. only mailing
  lists).
 
The wicket framework is so hot now in Japan! We would like to expand
  the number of users in japan by providing wicket-related information
  to our members in japanese language and at some time would like to
  contribute to the Apache Wicket project by sending you some bug-fixing
  or function-expanding code.
 
We have some questions to the wicket team. and I could not find out
  the contact address on wicket site. I hope that the members of wicket
  team will read this message...
 
Our questions:
 
1. We would like to make our pages visually 'wicket-like'. So we
  would like to use the design and background images of your 'wicket-
  example' like http://www.wicketstuff.org/wicket13/captcha/ . May I do
  that?
 
2. Can we use your Wicket Logo mark on our site? or is it under any
  kind of protections? If it is possible, we would like to put the logo
  mark on our top page.
 
 
 
Thank you.
 
 
  -
  Tsutomu YANO
  mailto:benbrand at mac.com
 
 
 
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0


Re: Questions for permission of using the design of wicket-example

2008-01-21 Thread Martijn Dashorst
On 1/21/08, Peter Thomas [EMAIL PROTECTED] wrote:

 Oh and by the way I noticed a poll on the Spring front page:
 http://www.springframework.org/ that asks the question which web
 templating
 framework do you use and Wicket is one of the choices :)


And of course the poll is rather skewed... Who are primarily going to look
at the site? Spring MVC devs.

If we would put a poll on our site, guess who would be the most popular
framework?

Martijn


-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0


Re: Security violations and ERROR: filterStart with Tomcat deployment on Debian Etch

2008-01-21 Thread Martijn Dashorst
You might want to skip the packaged version (IMO linux packagers don't get
the Java packaging), and just unzip a tarball in /opt/tomcat/tomcat-5.5.20
Then you are in complete control over how the server runs.

Martijn

On 1/21/08, Daniel Walmsley [EMAIL PROTECTED] wrote:

 I blogged this, and Eelco wisely suggested I post it here. This is both a
 warning and plea for help - what's the best way to configure Tomcat on
 Debian for Wicket?


 Was up until 3am last night banging my head against another frustrating
 go-nowhere issue deploying Wicket on Debian Etch's default Tomcat5.5.


 Apparently the latest version (5.5.20-2etch1) has additional security
 headaches features which prevent wicket from functioning properly
 out-of-the-box:


 * First of all, there's still an (as-yet-unsolved) mystery around why
 I couldn't get Wicket to start up as a filter. Just the mysterious ERROR:
 filterStart which makes me want to feed Tomcat to angry lions. Worked
 around it by using Wicket in Servlet mode instead.
 * Tomcat's juli.jar can't access WEB-INF/classes/logging.properties.
 Fixed (in sledgehammer-like way) by adding permission
 java.security.AllPermission; to
 /etc/tomcat5.5/policy.d/03catalina.policy, in the Juli section.
 * Tomcat security prevents webapps from accessing all sorts of
 features and methods by default, including wicket.properties, methods
 inside shipped jars, etc. Not being a Tomcat expert, and trusting the innate
 security of the server and millions of lines of third party code (i.e. I'm
 an idiot) I again just popped a java.security.AllPermission; in
 appropriate spots in /etc/tomcat5.5/policy.d/04webapps.policy. Let the
 flames commence!


 If Tomcat was a little more helpful in its error messages, this would
 never have been so painful. Jetty has always run my Wicket apps without
 complaint (though I've never tried the official Debian Jetty packages -
 maybe they're crippleware secure too?).


 The only reason I use Tomcat at all is the remote management and
 deployment features, which are well-supported by Cargo. Now that these
 issues are out of the way (mostly) I can take another few steps towards my
 dream of a seamless, fire-and-forget, auto-deploying, smoke-tested,
 pluggable and modular web app deployment system.


 Any ideas on how to better configure Tomcat?


 Any ideas on how to get more information about that ERROR: filterStart
 problem? I'd really like to do things the recommended way, instead of having
 to use WicketServlet.


 Cheers,
 Dan

 *Daniel Walmsley
 Director, Firesyde http://firesyde.com/
 e: [EMAIL PROTECTED]
 m: +61404864141
 *







-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0


Re: Questions for permission of using the design of wicket-example

2008-01-21 Thread Peter Thomas
On 1/21/08, Martijn Dashorst [EMAIL PROTECTED] wrote:

 On 1/21/08, Peter Thomas [EMAIL PROTECTED] wrote:
 
  Oh and by the way I noticed a poll on the Spring front page:
  http://www.springframework.org/ that asks the question which web
  templating
  framework do you use and Wicket is one of the choices :)
 

 And of course the poll is rather skewed... Who are primarily going to look

 at the site? Spring MVC devs.

 If we would put a poll on our site, guess who would be the most popular
 framework?

 Martijn


Well not exactly, the poll question I am referring to for web templating
has JSP, Velocity, FreeMarker, GWT, JSF, Tapestry, Wicket and Others are
the choices.

But you have a point - Spring MVC developers would have to choose between
JSP, Velocity or FreeMarker and sure enough - JSP has an impressive lead.
JSF comes in as a clear second though.  This must be the Spring WebFlow
users ? :)

--
 Buy Wicket in Action: http://manning.com/dashorst
 Apache Wicket 1.3.0 is released
 Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0



Re: Security violations and ERROR: filterStart with Tomcat deployment on Debian Etch

2008-01-21 Thread Johan Compagner
Take then the latest 6
5 is getting pretty old

On 1/21/08, Martijn Dashorst [EMAIL PROTECTED] wrote:
 You might want to skip the packaged version (IMO linux packagers don't get
 the Java packaging), and just unzip a tarball in /opt/tomcat/tomcat-5.5.20
 Then you are in complete control over how the server runs.

 Martijn

 On 1/21/08, Daniel Walmsley [EMAIL PROTECTED] wrote:
 
  I blogged this, and Eelco wisely suggested I post it here. This is both a
  warning and plea for help - what's the best way to configure Tomcat on
  Debian for Wicket?
 
 
  Was up until 3am last night banging my head against another frustrating
  go-nowhere issue deploying Wicket on Debian Etch's default Tomcat5.5.
 
 
  Apparently the latest version (5.5.20-2etch1) has additional security
  headaches features which prevent wicket from functioning properly
  out-of-the-box:
 
 
  * First of all, there's still an (as-yet-unsolved) mystery around why
  I couldn't get Wicket to start up as a filter. Just the mysterious ERROR:
  filterStart which makes me want to feed Tomcat to angry lions. Worked
  around it by using Wicket in Servlet mode instead.
  * Tomcat's juli.jar can't access WEB-INF/classes/logging.properties.
  Fixed (in sledgehammer-like way) by adding permission
  java.security.AllPermission; to
  /etc/tomcat5.5/policy.d/03catalina.policy, in the Juli section.
  * Tomcat security prevents webapps from accessing all sorts of
  features and methods by default, including wicket.properties, methods
  inside shipped jars, etc. Not being a Tomcat expert, and trusting the
 innate
  security of the server and millions of lines of third party code (i.e. I'm
  an idiot) I again just popped a java.security.AllPermission; in
  appropriate spots in /etc/tomcat5.5/policy.d/04webapps.policy. Let the
  flames commence!
 
 
  If Tomcat was a little more helpful in its error messages, this would
  never have been so painful. Jetty has always run my Wicket apps without
  complaint (though I've never tried the official Debian Jetty packages -
  maybe they're crippleware secure too?).
 
 
  The only reason I use Tomcat at all is the remote management and
  deployment features, which are well-supported by Cargo. Now that these
  issues are out of the way (mostly) I can take another few steps towards my
  dream of a seamless, fire-and-forget, auto-deploying, smoke-tested,
  pluggable and modular web app deployment system.
 
 
  Any ideas on how to better configure Tomcat?
 
 
  Any ideas on how to get more information about that ERROR: filterStart
  problem? I'd really like to do things the recommended way, instead of
 having
  to use WicketServlet.
 
 
  Cheers,
  Dan
 
  *Daniel Walmsley
  Director, Firesyde http://firesyde.com/
  e: [EMAIL PROTECTED]
  m: +61404864141
  *
 
 
 
 



 --
 Buy Wicket in Action: http://manning.com/dashorst
 Apache Wicket 1.3.0 is released
 Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0


-- 
Sent from Gmail for mobile | mobile.google.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Link to last version of a page of a given type/class.

2008-01-21 Thread Johan Compagner
Wicket does maintain state, but what you want is something different
and currently not supported. We dont have 'static' pages for a
specific page class. You are in full control.

About pag.getversion those methods shouldnt be used by users of wicket
at all. If you want something like this because you dont want to keep
references to the pages itself use session.getPage method

On 1/21/08, Ned Collyer [EMAIL PROTECTED] wrote:

 Hi Johan,

 Thank you for the reply.

 This suggestion will work, but it seems like something that the framework
 should do automatically.  The whole maintaining state thing is meant to
 maintain state between requests without the extra dev overhead of manually
 plugging stuff into, and pulling out of, the session.  I'm happy to get a
 new instance of the page if its been cleansed from the session - thats not a
 problem, but I was under the impression that wicket should already be
 maintaining this state - I just need a link generated.

 I find it a bit bizarre that methods like Page.getVersion(int num) exist,
 but because its not static.. i need an instance of the page to retrieve a
 previously versioned instances of the page. (rather than
 Page.getVersion(Class clazz, int version)).

 Does wicket not support linking to the last version of a given class type?
 If not, I would find this quite useful.

 Something like

 new PageLink(search-criteria-link, SearchCriteriaPage.class,
 Page.LATEST_VERSION)

 Would be exactly what I'm after.  (I'm still optimistic that this feature
 exists and its me being stupid not able to find it. ;))


 Rgds

 Ned


 Johan Compagner wrote:
 
  Just remember  in a simple valuesholder class the page id and pagmap
  for a page (and version if you want that) and then ask through the
  session for that page. If many pages (or big pages) are created in
  between, it could return nothing.. Depending on the size of the
  diskpage session/pagmap file.
 

 --
 View this message in context:
 http://www.nabble.com/Link-to-last-version-of-a-page-of-a-given-type-class.-tp14994042p14994505.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-- 
Sent from Gmail for mobile | mobile.google.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Security violations and ERROR: filterStart with Tomcat deployment on Debian Etch

2008-01-21 Thread C.

On Mon, 2008-01-21 at 11:31 +0100, Martijn Dashorst wrote:
 You might want to skip the packaged version (IMO linux packagers don't
 get the Java packaging), and just unzip a tarball
 in /opt/tomcat/tomcat-5.5.20
 
 
 Then you are in complete control over how the server runs.
 
-1

Some distro packaging systems while admittedly are lacking in certain
areas are there for a reason.

1) Tomcat is not perfect software and thus may have some security issue
either in core or in the default context that's enabled by default and
thus not everyone follows such alerts/advisories for a living. (Trusting
that the distro will issue an update and the system is regularly
maintained.)
2) I'm not sure this takes into account the install of tomcat native
libs and also any distro related changes there

etc etc...
 
 Martijn
 
snip /
 
  
 Apparently the latest version ( 5.5.20-2etch1) has additional
 security headaches features which prevent wicket from
 functioning properly out-of-the-box:

I consider this a positive thing as it means some forethought has
actually gone into this package.

snip /

  
 Any ideas on how to better configure Tomcat?

Not at the moment.  The best I can offer is give me about a week and
I'll see if I can get deb etch installed in vmware and have a look.


Good luck,

./C


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Security violations and ERROR: filterStart with Tomcat deployment on Debian Etch

2008-01-21 Thread C.

On Mon, 2008-01-21 at 11:52 +0100, Johan Compagner wrote:
 Take then the latest 6
 5 is getting pretty old

I know from first hand experience with a couple Linux distros are still
on 5 as it's 'stable'.  More to the point is that they probably can't
support slotted upgrades where half of the community wants 5.x and the
other half wants 6.x so they are erring on the conservative side.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Override HTML in html fragment

2008-01-21 Thread Sam Hough

We want to switch an input field between input type=text and textarea
depending on how large the existing data is. Is there any way to do this
without needing a spurious placeholder element? ie We would rather not have
a  but rather just get the text or textarea in the final HTML .

So anything I can do in onComponentTag etc to change the tag name in the
HTML file?

Cheers

Sam
-- 
View this message in context: 
http://www.nabble.com/Override-HTML-in-html-fragment-tp14995403p14995403.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Security violations and ERROR: filterStart with Tomcat deployment on Debian Etch

2008-01-21 Thread Martijn Dashorst
So your advise is to run a *very* outdated version because the packagers
haven't updated their software?
Sounds like a great way to open up your system to hackers.

Martijn

On 1/21/08, C. Bergström [EMAIL PROTECTED] wrote:


 On Mon, 2008-01-21 at 11:31 +0100, Martijn Dashorst wrote:
  You might want to skip the packaged version (IMO linux packagers don't
  get the Java packaging), and just unzip a tarball
  in /opt/tomcat/tomcat-5.5.20
 
 
  Then you are in complete control over how the server runs.
 
 -1

 Some distro packaging systems while admittedly are lacking in certain
 areas are there for a reason.

 1) Tomcat is not perfect software and thus may have some security issue
 either in core or in the default context that's enabled by default and
 thus not everyone follows such alerts/advisories for a living. (Trusting
 that the distro will issue an update and the system is regularly
 maintained.)
 2) I'm not sure this takes into account the install of tomcat native
 libs and also any distro related changes there

 etc etc...
 
  Martijn
 
 snip /
 
 
  Apparently the latest version ( 5.5.20-2etch1) has additional
  security headaches features which prevent wicket from
  functioning properly out-of-the-box:

 I consider this a positive thing as it means some forethought has
 actually gone into this package.

 snip /

 
  Any ideas on how to better configure Tomcat?

 Not at the moment.  The best I can offer is give me about a week and
 I'll see if I can get deb etch installed in vmware and have a look.


 Good luck,

 ./C


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0


Re: Security violations and ERROR: filterStart with Tomcat deployment on Debian Etch

2008-01-21 Thread C.

On Mon, 2008-01-21 at 12:13 +0100, Martijn Dashorst wrote:
 So your advise is to run a *very* outdated version because the packagers
 haven't updated their software?
 Sounds like a great way to open up your system to hackers.

That's a very broad and sweeping statement.

1) I'm sure if there were known issues the distro package maintainer
*should* issue an update with a fix
2) Looking at http://tomcat.apache.org/whichversion.html it appears 5.x
is still supported

I'll agree that a best practice to use latest stable, but not all
organizations get it right living on the bleeding edge of custom
packages and SVN Trunk or CVS HEAD if you prefer..

I'm trying to give sensible advice that is generic enough to not lead
someone astray or with other caveats which could result in bad pratices
or more problems down the road.

Now if I look at his original email and wonder why deb is still on
5.5.20-2etch1 when the apache site lists 5.5.25 as current I have no
idea.

./C


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Security violations and ERROR: filterStart with Tomcat deployment on Debian Etch

2008-01-21 Thread Johan Compagner
Completely not working is a great security fix yes...
If that distro is still in 5.5 mode then i question there updates

On 1/21/08, C. Bergström [EMAIL PROTECTED] wrote:

 On Mon, 2008-01-21 at 11:31 +0100, Martijn Dashorst wrote:
  You might want to skip the packaged version (IMO linux packagers don't
  get the Java packaging), and just unzip a tarball
  in /opt/tomcat/tomcat-5.5.20
 
 
  Then you are in complete control over how the server runs.
 
 -1

 Some distro packaging systems while admittedly are lacking in certain
 areas are there for a reason.

 1) Tomcat is not perfect software and thus may have some security issue
 either in core or in the default context that's enabled by default and
 thus not everyone follows such alerts/advisories for a living. (Trusting
 that the distro will issue an update and the system is regularly
 maintained.)
 2) I'm not sure this takes into account the install of tomcat native
 libs and also any distro related changes there

 etc etc...
 
  Martijn
 
 snip /
 
 
  Apparently the latest version ( 5.5.20-2etch1) has additional
  security headaches features which prevent wicket from
  functioning properly out-of-the-box:

 I consider this a positive thing as it means some forethought has
 actually gone into this package.

 snip /

 
  Any ideas on how to better configure Tomcat?

 Not at the moment.  The best I can offer is give me about a week and
 I'll see if I can get deb etch installed in vmware and have a look.


 Good luck,

 ./C


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-- 
Sent from Gmail for mobile | mobile.google.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Ext JS, form submit

2008-01-21 Thread Murat Yücel
Hi Flemming

I have also tried to integrate ExtJS and wicket, but i dont think it is
possible if you need to post
or edit content on a page. The best way to post a form is to use xml between
ext and wicket
but then it doesnt makes sense to use wicket.

Wicket needs markup, ext doesnt have any markup, thats why you can only use
readonly ext
widgets.

Maybe the wicket team should do the same as google. Talk with the ext devs
and make
and integration.

/Murat

2008/1/18, Flemming Boller [EMAIL PROTECTED]:

 Hi


 Having glazed at the ExtJS components you can not help, but feel I must
 try
 and integrate this into wicket.

 However  when I started at  trying to submit data to  wicket from the
 Ext.form.FormPanel, lots of trouble appeared.

 I can not make Ext.FormPanel apply to  a form tag , only a div tag.
 With
 div tag I can not in wicket use the Form Component.

 Also the id´s of elements change after Ext.onReady() has been performed,
 which I think is not good for wicket :-)


 Anyway the million dollar question is: Has anyone made a successfully
 'form' submit from Ext to a wicket component ?


 Regards
 Flemming



Re: Security violations and ERROR: filterStart with Tomcat deployment on Debian Etch

2008-01-21 Thread Martijn Dashorst
I think that most linux packagers don't work with Java projects and do
whatever they like. What Daniel is experiencing is an overzealous packager
that shuts down the most basic service tomcat needs to provide: run a web
application that does more than serve static pages. Packagers often make any
documentation that is available for a Java project worthless because they
move everything all over the disk.
This is akin to a mysql installation where you can't start a database and
run queries against.


Also, AFAIK 5.5.20 is about 1.5 years old. To me that is an indication that
packagers don't provide the most secure and workable solution, especially
when the latest 5.5.x (5.5.25) is already 6 months out.


Conservatism is a great thing for production servers, but running 1.5 years
behind the curve...?

Of course, the converse could be said for Java developers not getting linux
packaging, and in a sense we can learn a great deal from the tried and
tested unix package management. But even that is something that is still
evolving. For instance maven's repository infrastructure could (should?) be
pushed to a RPM/jpackage/apt service. The way I see it is that maven has
reinvented the wheel, and managed to make it a bit bumpier...

Martijn

On 1/21/08, C. Bergström  [EMAIL PROTECTED] wrote:


 On Mon, 2008-01-21 at 12:13 +0100, Martijn Dashorst wrote:
  So your advise is to run a *very* outdated version because the packagers

  haven't updated their software?
  Sounds like a great way to open up your system to hackers.

 That's a very broad and sweeping statement.

 1) I'm sure if there were known issues the distro package
 maintainer
 *should* issue an update with a fix
 2) Looking at http://tomcat.apache.org/whichversion.html it
 appears 5.x
 is still supported

 I'll agree that a best practice to use latest stable, but not all
 organizations get it right living on the bleeding edge of custom
 packages and SVN Trunk or CVS HEAD if you prefer..

 I'm trying to give sensible advice that is generic enough to not lead
 someone astray or with other caveats which could result in bad pratices
 or more problems down the road.

 Now if I look at his original email and wonder why deb is still on
 5.5.20-2etch1 when the apache site lists 5.5.25 as current I have no
 idea.

 ./C


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0


Re: Security violations and ERROR: filterStart with Tomcat deployment on Debian Etch

2008-01-21 Thread C.

On Mon, 2008-01-21 at 12:28 +0100, Johan Compagner wrote:
 Completely not working is a great security fix yes...
 If that distro is still in 5.5 mode then i question there updates

Here's the wishlist item for why there isn't currently 6.x in deb etch

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=413906

From what I can tell this package is pretty diligently updated for
security issues and saying anything about 5.5.x being a hackers risk is
fud unless it can be backed up with evidence.
http://packages.debian.org/stable/allpackages?format=txt.gz


Since others know best I'm going to step aside on this.  I assume this
is a user configuration issue, but

1) I don't use debian (and was trying to be helpful)
2) My distro of choice *does* have tc 6 (which I'm not sure matters in
this case)
3) I don't use tc for production


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Different views in wicket

2008-01-21 Thread Mathias P.W Nilsson

Hi!

I'm developing a site that has different views and languages. How does this
fit in the wicket framework?

When adding a WebPage you get a default .html view. Is there anyway on
having multiple views for a wicket page? How do you develop a site with same
model but different views?

// Mathias
-- 
View this message in context: 
http://www.nabble.com/Different-views-in-wicket-tp14997475p14997475.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



bookmarkable link keep recreate the objects.

2008-01-21 Thread dvd
Hi:  
On a Home page menu bar, I put a FAQ link
add(new Bookmarkablelinl(id,FAQ.class)    it is not an external static html 
file link since it would includes a few other bookmarkable links/buttons.  It 
is content does not change, but in the same session, say every second, when I 
click on the FAQ link, a new FAQ object is created and content is resent to 
browser even if the content is the same. FAQ.html template is basically static 
except a few wicket:link. This is obviouly a huge performance issue. What 
would be the best way to resolve this.  So far, Wicket's link handling has been 
the biggest issue compared to more convertional approaches but I guess I am 
just not getting it well enough.
Thanks

RE: bookmarkable link keep recreate the objects.

2008-01-21 Thread dvd
To simpplify the issue, Consider the following Home.html
html span wicket:id=text//html
Home.java

add(new Label(text, StaticText)

Everytime the home page is accessed, Home.java is created anew
and so is the text label even though the content should remain the same
through the session. How can I make the Home page object reusable for each user 
seassion after the first access.

Hi:  
On a Home page menu bar, I put a FAQ link
add(new Bookmarkablelinl(id,FAQ.class)    it is not an external static html 
file link since it would includes a few other bookmarkable links/buttons.  It 
is content does not change, but in the same session, say every second, when I 
click on the FAQ link, a new FAQ object is created and content is resent to 
browser even if the content is the same. FAQ.html template is basically static 
except a few wicket:link. This is obviouly a huge performance issue. What 
would be the best way to resolve this.  So far, Wicket's link handling has 
been the biggest issue compared to more convertional approaches but I guess I 
am just not getting it well enough.
Thanks

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Jboss Portal + Wicket (Portlet)

2008-01-21 Thread Markqt

Hi Suli,

Thanks much for the details. Where did you get calss
JbossPortletResourceURLFactory? This is exactly what I am missing. I can't
find it in jboss portal, wicket1.3 download, or apache portal bridge1.04. If
this is your own implementation, can you please post the code?

init-param
namePortletResourceURLFactory/name
   
valuewicket.tetst.common.JbossPortletResourceURLFactory/value
/init-param


-- 
View this message in context: 
http://www.nabble.com/Jboss-Portal-%2B-Wicket-%28Portlet%29-tp14953943p14998263.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Jboss Portal + Wicket (Portlet)

2008-01-21 Thread Süli Zsolt
JbossPortletResourceURLFactory is my custom class. As far as I know 
Jboss Portal team hasn't implemented it yet, so I did the job (it's not 
a big thing though as u can see in my previous letter). So check my last 
letter for the code ... especially the part And my implementation of 
PortletResourceURLFactory ;).


Good luck!

PS: my surname is Zsolt ;)

Markqt wrote:

Hi Suli,

Thanks much for the details. Where did you get calss
JbossPortletResourceURLFactory? This is exactly what I am missing. I can't
find it in jboss portal, wicket1.3 download, or apache portal bridge1.04. If
this is your own implementation, can you please post the code?

init-param
namePortletResourceURLFactory/name
   
valuewicket.tetst.common.JbossPortletResourceURLFactory/value

/init-param


  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: RadioChoice : default choice ?

2008-01-21 Thread scottomni

Thanks for the suggestion (to hit the Java Books, further), Per.  I'm sure
that is sage advice.

However, just to clarify...
-  I am aware that RadioChoice *is* a different Type than String
   -  my question: how is a RadioChoice value converted back and forth with
a String?
-  It appears (to me) that RadioChoice is a Wicket Class (hence my question
to Wicket Forum)

Regarding Learning Path...
I am accustomed to jumping around when learning and when I came across
Wicket, it appeared to be a superior way to incorporate Java in a web
environment.  Thus, I have not studied any of the Swing stuff that most of
the books contain.  IMHO, I think Wicket would be an outstanding paradigm
from which to *teach* Java.  After all, the web is a very probable
deployment platform for new Java projects.  If Wicket *is* the *way*, I
think there is a huge opportunity to train and indoctrinate new Java
programmers, using Wicket from the get-go.  For me, what has been confusing
has been distinguishing where Wicket is deviating from standard Java.  I
sense that it could all come together quite nicely (for a java newbie), if
beginner 'Java, the Wicket Way' resources were available.

Thanks - Scott



Newgro wrote:
 
 Am Freitag, 18. Januar 2008 23:43:18 schrieb scottomni:

 private RadioChoice genderChoice;

 public RadioChoice getGender(){
   return genderChoice.getModelObjectAsString();
 }

 public void setGender(){
 this.genderChoice = Male;
 }

 Both of my Methods fail, due to incompatible Types.
 The cause of this is that Male is of type String and genderChoice is of
 type 
 RadioChoice. But you can't say that an apple (RadioChoice) is an (=)
 orange 
 (String).
 
 I would suggest, that you start with a good java book. Wicket is not the
 right 
 place to start learning java. It's more a good start learning 
 web-development.
  
 Hence, I don't get 
 what I need to do to display a RadioChoice (on a Form) and Get/Set the
 values (which I will be storing in a database).  Additional note: I am
 picked up 'getModelObjectAsString' from a Login Example.
 The example you should understand is here 
 http://www.wicketstuff.org/wicket13/forminput/
 There is a link in the upper right corner with source code. The classes 
 FormInput.java and FormInputModel.java should help you out.
 
 Otherwise i really appriciate that you know the java basics before you
 start 
 with wicket development. It makes it easier for everyone :-)
 
 Cheers
 Per
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

-- 
View this message in context: 
http://www.nabble.com/RadioChoice-%3A-default-choice---tp14876844p14998986.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Override tag name in html fragment?

2008-01-21 Thread Sam Hough

@Override
protected final void onComponentTag(final ComponentTag tag) {
tag.setName(input);
tag.put(type, text);

super.onComponentTag(tag);
}

Seems to do what I want but is this a valid extension point? In
PasswordTextBox and ListChoice it is marked final...? I don't want to stitch
my client up with something that is going to break with the next version of
Wicket.  So although means extra dom elements on the browser and more
component instances on the server am I better off wrapping the raw
components?

Cheers

Sam



Sam Hough wrote:
 
 We want to switch an input field between input type=text and textarea
 depending on how large the existing data is. Is there any way to do this
 without needing a spurious placeholder element? ie We would rather not
 have a  span wicket:id=textInput but rather just get the text or
 textarea element in the final HTML .
 
 So anything I can do in onComponentTag etc to change the tag name in the
 HTML file?
 
 Cheers
 
 Sam
 

-- 
View this message in context: 
http://www.nabble.com/Override-tag-name-in-html-fragment--tp14995403p14999180.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



parsevelocity template

2008-01-21 Thread fattymelt


-- 
View this message in context: 
http://www.nabble.com/%22parsevelocity-template-tp14999729p14999729.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



parse directive in velocity template failing

2008-01-21 Thread fattymelt

I am using a velocity template, and within it would like to use velocity's
parse directive (to include another template within the current template)
but it complains that it can not find the template in velocity's
TEMPLATE_ROOT.  I have triple-checked that the template is in the same
directory as all of my other working templates. Anyone know why velocity
can't find a template when using parse ?

Does Wicket specify its own template location? If so, does anyone know where
the default Velocity TEMPLATE_ROOT would be?

http://velocity.apache.org/engine/devel/user-guide.html#parse Velocity's
Parse Directive 

TIA
-- 
View this message in context: 
http://www.nabble.com/%22parse%22-directive-in-velocity-template-failing-tp14999823p14999823.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: How to change the style of navigator in PageableViewList

2008-01-21 Thread trames

Extend PagingNavigator.  I made a custom one so I can use everywhere:

It looks something like this

First Prev 1 2 3 4 Next Last


The active page will be in Red and italics.
You can make it anything you want by changing the HTML and/or CSS. Hope it
works for you.

Java - CustomPagingNavigator.java

import org.apache.wicket.markup.html.navigation.paging.PagingNavigator;
import org.apache.wicket.markup.html.navigation.paging.IPageable;
import org.apache.wicket.markup.html.navigation.paging.IPagingLabelProvider;



public class CustomPagingNavigator extends PagingNavigator{

private static final long serialVersionUID = 1L; 


// First PagingNavigator constructor
public CustomPagingNavigator (String id, IPageable pageable) {
super(id, pageable);
}



// Second PagingNavigator constructor
public CustomPagingNavigator (String id, IPageable pageable,
IPagingLabelProvider labelProvider) {
super(id, pageable, labelProvider);
}

}

HTML - CustomPagingNavigator.html

!-- This is a customization of the wicket component PagingNavigator.html 
It changes the following defaults
 is now First
 is now Last
 is now Prev
 is now Next

You will also need to copy CustomPagingNavigator.css to the root of your
web app
and @include it in your main style sheet.  See .css file

--

html xmlns:wicket
body
wicket:panel
 First   Prev 
 # 1  
 Next   Last 
/wicket:panel
/body
/html

CSS - CustomPagingNavigator.css

/* Copy this file to the root of the web app
/* Use the following in the main style sheet to import these specs*/
/* @import url(CustomPagingNavigator.css);*/

/* Data Navigator*/
.navigator {color:red}
.navigator a:link, a:visited, a:active {color:blue;text-decoration:none;}
-- 
View this message in context: 
http://www.nabble.com/How-to-change-the-style-of-navigator-in-PageableViewList-tp14978321p1501.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Tip:ServletContext from WicketFilter

2008-01-21 Thread Ayodeji Aladejebi
Well, I have started migrating some code to 1.3, however i had some
STOP-AND-CONFIRM situation

In 1.2.x

ServletContext context = Application.getWicketServlet().getServletContext()
?

doSomethingWithContext(context);

Migrating to 1.3.x

ServletContext context =
Application.getWicketFilter().getFilterConfig().getServletContext()
?

doSomethingWithContext(context);


I guess by doing this, my previous code wont break, even though there is no
WicketServlet configured in my web.xml?

Or must I configure a WicketServlet to be able to do this

thanks


Re: Tip:ServletContext from WicketFilter

2008-01-21 Thread Johan Compagner
that should still work.



On Jan 21, 2008 4:42 PM, Ayodeji Aladejebi [EMAIL PROTECTED] wrote:

 Well, I have started migrating some code to 1.3, however i had some
 STOP-AND-CONFIRM situation

 In 1.2.x

 ServletContext context = Application.getWicketServlet
 ().getServletContext()
 ?

 doSomethingWithContext(context);

 Migrating to 1.3.x

 ServletContext context =
 Application.getWicketFilter().getFilterConfig().getServletContext()
 ?

 doSomethingWithContext(context);


 I guess by doing this, my previous code wont break, even though there is
 no
 WicketServlet configured in my web.xml?

 Or must I configure a WicketServlet to be able to do this

 thanks


t


Re: Different views in wicket

2008-01-21 Thread Nino Saturnino Martinez Vazquez Wael

try get variation...

Mathias P.W Nilsson wrote:

Hi!

I'm developing a site that has different views and languages. How does this
fit in the wicket framework?

When adding a WebPage you get a default .html view. Is there anyway on
having multiple views for a wicket page? How do you develop a site with same
model but different views?

// Mathias
  


--
Nino Martinez Wael
Java Specialist @ Jayway DK
http://www.jayway.dk
+45 2936 7684


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: RadioChoice : default choice ?

2008-01-21 Thread cblehman

Scott,

To answer your last question, to set a selected value on the RadioChoice,
you must set the PropertyModel's value to what you want selected.  One thing
that took me a while to figure out personally (and I have been programming
in java for several years) is that the Object you set in the PropertyModel
must be of the same type (class) as the objects in your list of choices.  

This is what Per was referring to.  So if you have a list of Integers as
choices, set the propertymodel to an integer.  If you instead have a more
complex Object (say MyChoiceObject) for your choices you use that.  To
render the choices, Wicket by default will just do ToString on the Object
inthe choices list, unless you create an IChoiceRenderer.  In any event, you
need to set the PropertyModel's object to an object that is int he List of
choices to preselect one of the objects.  The example below is a good on,
you should look at the RadioChoice and DropDownChoice, since they both use
the same idea with their propertymodels.

The point is that at some time, Wicket will try to cast one of the objects
in the list into the variable in the propertymodel, so they have to  have
the same type.

Hope this helps...
-Clay


Newgro wrote:
 
 
 The example you should understand is here 
 http://www.wicketstuff.org/wicket13/forminput/
 There is a link in the upper right corner with source code. The classes 
 FormInput.java and FormInputModel.java should help you out.
 
 
 
 

-- 
View this message in context: 
http://www.nabble.com/RadioChoice-%3A-default-choice---tp14876844p15001375.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: create new model object of a Form from one of its FormComp values??

2008-01-21 Thread Sergey Podatelev
On Jan 20, 2008 8:14 PM, Igor Vaynberg [EMAIL PROTECTED] wrote:

personally i would map the form to a bean, and then in onsubmit()
 transfer those properties to an instance of your domain object.


Igor, could you please tell in short how is this better than just get data
form the models of each component in onsubmit()?
I'm doing same thing within my app and was wondering if I should create a
bean just for form data extraction purposes.

-- 
sp


Re: create new model object of a Form from one of its FormComp values??

2008-01-21 Thread Martijn Dashorst
Having a bean makes things explicit. Getting stuff from a text component
directly is very read unfriendly. See it as a small investment in
maintenance. You will thank yourself later for taking the 1 minute to
generate the bean :-)
But it is all a matter of taste and one can argue about that for ages.
Whatever gets the job done and is maintainable in 2 years from now is the
winner imo. What that means for you, that is for you to decide :)

Martijn

On 1/21/08, Sergey Podatelev [EMAIL PROTECTED] wrote:

 On Jan 20, 2008 8:14 PM, Igor Vaynberg [EMAIL PROTECTED] wrote:

 personally i would map the form to a bean, and then in onsubmit()
  transfer those properties to an instance of your domain object.
 
 
 Igor, could you please tell in short how is this better than just get data
 form the models of each component in onsubmit()?
 I'm doing same thing within my app and was wondering if I should create a
 bean just for form data extraction purposes.

 --
 sp




-- 
Buy Wicket in Action: http://manning.com/dashorst
Apache Wicket 1.3.0 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0


Re: Different views in wicket

2008-01-21 Thread Mathias P.W Nilsson

I don't understand your reply. Can you please explain?
-- 
View this message in context: 
http://www.nabble.com/Different-views-in-wicket-tp14997475p15002034.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Different views in wicket

2008-01-21 Thread Erik van Oosten

Mathias P.W Nilsson schreef:

I don't understand your reply. Can you please explain?
  


Each template (html) file can come in variations. E.g 
HomePage_green.html. In HomePage.java you can call setVariation(green).


Does that help?

Regards,
   Erik.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Different views in wicket

2008-01-21 Thread Igor Vaynberg
wicket tries to load localized files first.

so if you have MyPage.class and you are in german locale the loading
order would be
MyPage_DE_de.html
MyPage_DE.html
MyPage.html

then there are also variations, if your page.getvariation() returns
foo then the loading order is

MyPage_foo_DE_de.html
MyPage_foo_DE.html
MyPage_foo.html
MyPage_DE_de.html
MyPage_DE.html
MyPage.html

there is also session.set/getstyle() which is just like variation but
will set the style on session-level instead of page-level.

-igor


On Jan 21, 2008 5:32 AM, Mathias P.W Nilsson [EMAIL PROTECTED] wrote:

 Hi!

 I'm developing a site that has different views and languages. How does this
 fit in the wicket framework?

 When adding a WebPage you get a default .html view. Is there anyway on
 having multiple views for a wicket page? How do you develop a site with same
 model but different views?

 // Mathias
 --
 View this message in context: 
 http://www.nabble.com/Different-views-in-wicket-tp14997475p14997475.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Different views in wicket

2008-01-21 Thread Eelco Hillenius
On Jan 21, 2008 9:29 AM, Erik van Oosten [EMAIL PROTECTED] wrote:
 Mathias P.W Nilsson schreef:
  I don't understand your reply. Can you please explain?
 

 Each template (html) file can come in variations. E.g
 HomePage_green.html. In HomePage.java you can call setVariation(green).

Yes. And localized files are served automatically. See the form input
example of wicket-examples for an example of that.

And finally, stop by here:
http://cwiki.apache.org/WICKET/localization-and-skinning-of-applications.html

Eelco

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: create new model object of a Form from one of its FormComp values??

2008-01-21 Thread Igor Vaynberg
it gives you the advantage of being able to construct your domain
objects easily: new Person(personBean);

you also dont have to access the form components directly to poll
their models, to me this is a plus.

-igor


On Jan 21, 2008 9:00 AM, Sergey Podatelev [EMAIL PROTECTED] wrote:
 On Jan 20, 2008 8:14 PM, Igor Vaynberg [EMAIL PROTECTED] wrote:

 personally i would map the form to a bean, and then in onsubmit()
  transfer those properties to an instance of your domain object.
 
 
 Igor, could you please tell in short how is this better than just get data
 form the models of each component in onsubmit()?
 I'm doing same thing within my app and was wondering if I should create a
 bean just for form data extraction purposes.

 --
 sp


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tip:ServletContext from WicketFilter

2008-01-21 Thread Igor Vaynberg
there is a webapplication.getservletcontext().

-igor


On Jan 21, 2008 7:42 AM, Ayodeji Aladejebi [EMAIL PROTECTED] wrote:
 Well, I have started migrating some code to 1.3, however i had some
 STOP-AND-CONFIRM situation

 In 1.2.x

 ServletContext context = Application.getWicketServlet().getServletContext()
 ?

 doSomethingWithContext(context);

 Migrating to 1.3.x

 ServletContext context =
 Application.getWicketFilter().getFilterConfig().getServletContext()
 ?

 doSomethingWithContext(context);


 I guess by doing this, my previous code wont break, even though there is no
 WicketServlet configured in my web.xml?

 Or must I configure a WicketServlet to be able to do this

 thanks


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Override tag name in html fragment?

2008-01-21 Thread Igor Vaynberg
its not that simple

input tag has no body input/ why textarea does textarea/textarea
also input stores its value in the value attr, textarea does it in its
body

that is why we have two separate components for this. you can of
course write your own that handles both cases properly...

-igor


On Jan 21, 2008 7:03 AM, Sam Hough [EMAIL PROTECTED] wrote:

 @Override
 protected final void onComponentTag(final ComponentTag tag) {
 tag.setName(input);
 tag.put(type, text);

 super.onComponentTag(tag);
 }

 Seems to do what I want but is this a valid extension point? In
 PasswordTextBox and ListChoice it is marked final...? I don't want to stitch
 my client up with something that is going to break with the next version of
 Wicket.  So although means extra dom elements on the browser and more
 component instances on the server am I better off wrapping the raw
 components?

 Cheers

 Sam



 Sam Hough wrote:
 
  We want to switch an input field between input type=text and textarea
  depending on how large the existing data is. Is there any way to do this
  without needing a spurious placeholder element? ie We would rather not
  have a  span wicket:id=textInput but rather just get the text or
  textarea element in the final HTML .
 
  So anything I can do in onComponentTag etc to change the tag name in the
  HTML file?
 
  Cheers
 
  Sam
 

 --
 View this message in context: 
 http://www.nabble.com/Override-tag-name-in-html-fragment--tp14995403p14999180.html

 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: create new model object of a Form from one of its FormComp values??

2008-01-21 Thread Eelco Hillenius
 personally i would map the form to a bean, and then in onsubmit()
  transfer those properties to an instance of your domain object.
 
 
 Igor, could you please tell in short how is this better than just get data
 form the models of each component in onsubmit()?
 I'm doing same thing within my app and was wondering if I should create a
 bean just for form data extraction purposes.

The good thing about using beans is that you can eliminate plumbing
code. Instead of a massive copy action e.g. in your onSubmit, you can
use a bean that is already populated with the values. I often use my
domain objects directly - and I already have those objects anyway - so
I save quite a bit of dumb copying code. Not everyone agrees with
using domain objects directly though; ymmv.

Eelco

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Ext JS, form submit

2008-01-21 Thread Murat Yücel
Hi Flemming

Just found this project: http://code.google.com/p/exttld/downloads/list
It seems like they have made a ext tld project for java based frameworks.

/Murat

2008/1/21, Murat Yücel [EMAIL PROTECTED]:

 Hi Flemming

 I have also tried to integrate ExtJS and wicket, but i dont think it is
 possible if you need to post
 or edit content on a page. The best way to post a form is to use xml
 between ext and wicket
 but then it doesnt makes sense to use wicket.

 Wicket needs markup, ext doesnt have any markup, thats why you can only
 use readonly ext
 widgets.

 Maybe the wicket team should do the same as google. Talk with the ext devs
 and make
 and integration.

 /Murat

 2008/1/18, Flemming Boller [EMAIL PROTECTED]:
 
  Hi
 
 
  Having glazed at the ExtJS components you can not help, but feel I must
  try
  and integrate this into wicket.
 
  However  when I started at  trying to submit data to  wicket from the
  Ext.form.FormPanel , lots of trouble appeared.
 
  I can not make Ext.FormPanel apply to  a form tag , only a div tag.
  With
  div tag I can not in wicket use the Form Component.
 
  Also the id´s of elements change after Ext.onReady() has been performed,
  which I think is not good for wicket :-)
 
 
  Anyway the million dollar question is: Has anyone made a successfully
  'form' submit from Ext to a wicket component ?
 
 
  Regards
  Flemming
 




Re: Is this safe?

2008-01-21 Thread Eelco Hillenius
On Jan 21, 2008 1:51 AM, Martijn Lindhout [EMAIL PROTECTED] wrote:
 ok, and if the session isn't thread safe, where do I store my temporal data?

I think the session is a fine storage option for a shopping cart. Just
synchronize the cart itself and you're fine. Or don't; it's rather
unlikely you actually run into trouble if you ask me.

Btw, add(new CartPanel(cart, new PropertyModel(this,
session.cart))); also works, since components have a getSession
method.

Eelco

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: We are adopting Wicket in our Organization

2008-01-21 Thread Eelco Hillenius
On Jan 21, 2008 1:54 AM, Joshua Jackson [EMAIL PROTECTED] wrote:
 SEAM is not that bad actually. Though it still has some quirks.

Though most people will use it together with JSF, SEAM does have a
different scope. You can use it by itself as a business component
framework. There are two (kind of competing) wicket-stuff projects for
this, and someone from JBoss is working on more official integration
with Wicket.

Eelco

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Required tag types?

2008-01-21 Thread Johan Maasing
As an exercise I tried to write a CMS-like framework. It became
remarkably similiar and I had the same question. My factories produced
an editor and a display, apart from that they have almost the same
names as yours. I guess this almost qualifies as a FAQ :-)

2008/1/20, James Carman [EMAIL PROTECTED]:
 The way my framework is set up, I've got a PropertyEditorFactory interface:

 public interface PropertyEditorFactory
 {
   public Component createPropertyEditor(String componentName, Object
 target, PropertyMetadata meta);
 }

 If I required my factory to return Panel objects instead, where would
 the markup for those Panels come from?  Would I have to write my own
 Panel extension classes that have the different editor types in them
 (TextEditorPanel, BooleanEditorPanel, etc.)?



 On 1/20/08, Igor Vaynberg [EMAIL PROTECTED] wrote:
  instead of using fragments you can use panels, which would make the
  editors reusable across projects/pages.
 
  as far as why the checks are there...
 
  add(new TextField(foo));
  div wicket:id=foo/
 
  will end up with
 
  div wicket:id=foo value=bar/ == not a very useful textbox
 
  wicket does not mutate markup by default, so it will not mutate div
  tag to input tag.
 
  it also adds a level of error checking, making sure you add the right
  components to the right places.
 
  -igor
 
 
  On Jan 20, 2008 1:50 PM, James Carman [EMAIL PROTECTED] wrote:
   So, the key is to use Fragments?  This is very similar to how we did
   it in Trails.  I would like to make this somewhat reusable in other
   projects so that they can define their own editors without having to
   change this framework code.  I'm somewhat new to Wicket, so maybe I
   just don't understand this all yet, but it seems to me like this
   framework will only be able to use Fragments defined within the
   current markup (the BeanEditPanel.html file).  Is that true?  In
   Trails, we had the concept of a component address that  you would
   use to locate the editor component you want to use.  So, it could be
   defined in another page supplied by the user.  Trails comes with a
   default page containing all of its editors as Blocks (similar to a
   Fragment).  The default behavior returns components from this page as
   the editors for properties.  However, any client application could
   define their own editor component blocks on some page and use those
   also.
  
  
   On 1/20/08, Gerolf Seitz [EMAIL PROTECTED] wrote:
have you seen Al's Bean Editor [0]?
this might give you a hint in the right direction.
   
regards,
  gerolf
   
[0] http://herebebeasties.com/2007-08-17/wicket-bean-editor/
   
On Jan 20, 2008 10:17 PM, James Carman [EMAIL PROTECTED] wrote:
   
 Is there any reason that components require that they be applied to
 specific tag types in the markup files?  I'm writing a little utility
 which calculates at runtime what editor to use based on the property
 type (a la Trails).  So, I have no idea what type of tag to use.  I
 thought I'd just do this (the actual component is a TextField in this
 case):

 div wicket:id=editor /

 But, I get the following error message:

 org.apache.wicket.markup.MarkupException: Component editor must be
 applied to a tag of type 'input', not 'div wicket:id=editor' (line
 0, column 0)

 If I change my markup to:

 input type=text wicket:id=editor /

 then it works.  But, suppose a certain property requires a more
 complicated editor component (maybe rich text, so I'd use something
 like FCKEditor).  Would that component be complaining that it's being
 applied to an input tag?  Is there any generic way to do this so
 that all components will be happy at runtime with the markup?  Is
 there any way to relax that restriction?

 James

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


   
  
   -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
  
  
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: bookmarkable link keep recreate the objects.

2008-01-21 Thread Eelco Hillenius
  This is obviouly a huge performance issue.

I wonder if it is. Java is optimized for creating objects, and
creating new ones is often cheaper than reusing old ones if you take
synchronization and lookups into account.

Are you sure it is a bottleneck? If you haven't seen any actual
performance problems (and determined that it is the web tier causing
it, which is often unlikely given that accessing the back-end such as
databases often take the majority of the processing of a request)
you'd be wasting your time. Premature optimization is evil :-)

If you're still unconvinced, take a look at
org.apache.wicket.examples.staticpages in wicket-examples; it might do
what you want.

Eelco

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: create new model object of a Form from one of its FormComp values??

2008-01-21 Thread infodoc

Thanks to everyone for their comments 

Igor,

Assuming I use a bean, could you please give me a bit more detail on your
suggestion?
I want the model object of the editor Form to be the newly-created Account,
so that other objects can simply call getModelObject() on the editor like
normal and get the correct (new) value.  Do I simply set the new Account as
the model object of the editor Form?

In onSubmit(), would I code something like the following?

Account accountBean = (Account)getModelObject();  //bean updated with values
from FormComponents

Account newAccount = Account(accountBean );  //copy constructor using bean

setModelObject(newAccount);


RDC



personally i would map the form to a bean, and then in onsubmit()
transfer those properties to an instance of your domain object.

-- 
View this message in context: 
http://www.nabble.com/create-new-model-object-of-a-Form-from-one-of-its-FormComp-values---tp14983110p15004311.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: create new model object of a Form from one of its FormComp values??

2008-01-21 Thread Igor Vaynberg
yep, that will work.

-igor


On Jan 21, 2008 11:17 AM, infodoc [EMAIL PROTECTED] wrote:

 Thanks to everyone for their comments 

 Igor,

 Assuming I use a bean, could you please give me a bit more detail on your
 suggestion?
 I want the model object of the editor Form to be the newly-created Account,
 so that other objects can simply call getModelObject() on the editor like
 normal and get the correct (new) value.  Do I simply set the new Account as
 the model object of the editor Form?

 In onSubmit(), would I code something like the following?

 Account accountBean = (Account)getModelObject();  //bean updated with values
 from FormComponents

 Account newAccount = Account(accountBean );  //copy constructor using bean

 setModelObject(newAccount);


 RDC



 personally i would map the form to a bean, and then in onsubmit()
 transfer those properties to an instance of your domain object.

 --
 View this message in context: 
 http://www.nabble.com/create-new-model-object-of-a-Form-from-one-of-its-FormComp-values---tp14983110p15004311.html

 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: RadioChoice : default choice ?

2008-01-21 Thread scottomni

Thanks Clay.  I think I have reached a point in Wicket that is providing (me)
the motivation to go 'back' to the Java Book and push forward (through the
java learning curve).  I'm getting there, slowly but surely. ;-)

In the process, it looks like I will be familiarizing myself with the Swing
library -- which, will probably enhance my appreciation (and understanding)
of Wicket.

Scott

cblehman wrote:
 
 Scott,
 
 To answer your last question, to set a selected value on the RadioChoice,
 you must set the PropertyModel's value to what you want selected.  One
 thing that took me a while to figure out personally (and I have been
 programming in java for several years) is that the Object you set in the
 PropertyModel must be of the same type (class) as the objects in your list
 of choices.  
 
 This is what Per was referring to.  So if you have a list of Integers as
 choices, set the propertymodel to an integer.  If you instead have a more
 complex Object (say MyChoiceObject) for your choices you use that.  To
 render the choices, Wicket by default will just do ToString on the Object
 inthe choices list, unless you create an IChoiceRenderer.  In any event,
 you need to set the PropertyModel's object to an object that is int he
 List of choices to preselect one of the objects.  The example below is a
 good on, you should look at the RadioChoice and DropDownChoice, since they
 both use the same idea with their propertymodels.
 
 The point is that at some time, Wicket will try to cast one of the objects
 in the list into the variable in the propertymodel, so they have to  have
 the same type.
 
 Hope this helps...
 -Clay
 
 
 Newgro wrote:
 
 
 The example you should understand is here 
 http://www.wicketstuff.org/wicket13/forminput/
 There is a link in the upper right corner with source code. The classes 
 FormInput.java and FormInputModel.java should help you out.
 
 
 
 
 
 

-- 
View this message in context: 
http://www.nabble.com/RadioChoice-%3A-default-choice---tp14876844p15004489.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: create new model object of a Form from one of its FormComp values??

2008-01-21 Thread Igor Vaynberg
its simply easier to say:

bean.getdate() if you are using a bean, or just date if you are
binding to a property on the form subclass vs
(Date)textbox.getModelObject(); which requires you to keep a reference
to the textbox component anyways.

-igor



On Jan 21, 2008 11:42 AM, Sergey Podatelev [EMAIL PROTECTED] wrote:
 On Jan 21, 2008 9:25 PM, Eelco Hillenius [EMAIL PROTECTED] wrote:

 Instead of a massive copy action e.g. in your onSubmit, you can
  use a bean that is already populated with the values.


 I do understand advantages of using bean with CompoundPropertyModel, my
 question was related to the situation when you are forced to create your
 target object after the form is submitted. For instance, when you create
 different kinds of objects based on what exactly was submitted, or when
 constructor of the target object takes certain values and there're no
 setters for those values. Or, like in my situation, when both of those
 restrictions apply.

 Of course, maybe I'm missing something, and there's also a way to use this
 approach even in cases described above.

 --
 sp


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: RadioChoice : default choice ?

2008-01-21 Thread Eelco Hillenius
 In the process, it looks like I will be familiarizing myself with the Swing
 library -- which, will probably enhance my appreciation (and understanding)
 of Wicket.

Getting familiar with Swing will almost certainly help you get Wicket.
Just keep in mind that with Swing, you would update values by
'pushing' them (for which you'd typically make heave use of the
observer pattern, e.g. using PropertyChangeListeners etc), whereas
with Wicket you would rely on the request cycle doing it for you (we
often call that 'pull' and it is in fact an example of Inversion of
Control, since you let your model objects being updated by the
framework rather than pushing out changes to the framework yourself).

Eelco

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Override HTML in html fragment

2008-01-21 Thread Eelco Hillenius
 We want to switch an input field between input type=text and textarea
 depending on how large the existing data is. Is there any way to do this
 without needing a spurious placeholder element? ie We would rather not have
 a  but rather just get the text or textarea in the final HTML .

You could create a custom form component that can both be a text area
or a text field.

 So anything I can do in onComponentTag etc to change the tag name in the
 HTML file?

Yep. From the top of my head, you can do this with tag#setName

Eelco

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: RadioChoice : default choice ?

2008-01-21 Thread Per Newgro
 Getting familiar with Swing will almost certainly help you get Wicket.
 Just keep in mind that with Swing, you would update values by
 'pushing' them (for which you'd typically make heave use of the
 observer pattern, e.g. using PropertyChangeListeners etc), whereas
 with Wicket you would rely on the request cycle doing it for you (we
 often call that 'pull' and it is in fact an example of Inversion of
 Control, since you let your model objects being updated by the
 framework rather than pushing out changes to the framework yourself).
Btw. on that issue you can checkout for the jgoodies binding framework. It has 
similiar concepts like wicket - but is for swing components. But i don't want 
to hijack this thread :-)

Cheers
Per


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Required tag types?

2008-01-21 Thread James Carman
Or, maybe we should start a new project (or a Wicket subproject) to take
care of this common need.

On 1/21/08, Johan Maasing [EMAIL PROTECTED] wrote:

 As an exercise I tried to write a CMS-like framework. It became
 remarkably similiar and I had the same question. My factories produced
 an editor and a display, apart from that they have almost the same
 names as yours. I guess this almost qualifies as a FAQ :-)

 2008/1/20, James Carman [EMAIL PROTECTED]:
  The way my framework is set up, I've got a PropertyEditorFactory
 interface:
 
  public interface PropertyEditorFactory
  {
public Component createPropertyEditor(String componentName, Object
  target, PropertyMetadata meta);
  }
 
  If I required my factory to return Panel objects instead, where would
  the markup for those Panels come from?  Would I have to write my own
  Panel extension classes that have the different editor types in them
  (TextEditorPanel, BooleanEditorPanel, etc.)?
 
 
 
  On 1/20/08, Igor Vaynberg [EMAIL PROTECTED] wrote:
   instead of using fragments you can use panels, which would make the
   editors reusable across projects/pages.
  
   as far as why the checks are there...
  
   add(new TextField(foo));
   div wicket:id=foo/
  
   will end up with
  
   div wicket:id=foo value=bar/ == not a very useful textbox
  
   wicket does not mutate markup by default, so it will not mutate div
   tag to input tag.
  
   it also adds a level of error checking, making sure you add the right
   components to the right places.
  
   -igor
  
  
   On Jan 20, 2008 1:50 PM, James Carman [EMAIL PROTECTED]
 wrote:
So, the key is to use Fragments?  This is very similar to how we did
it in Trails.  I would like to make this somewhat reusable in other
projects so that they can define their own editors without having
 to
change this framework code.  I'm somewhat new to Wicket, so maybe I
just don't understand this all yet, but it seems to me like this
framework will only be able to use Fragments defined within the
current markup (the BeanEditPanel.html file).  Is that true?  In
Trails, we had the concept of a component address that  you would
use to locate the editor component you want to use.  So, it could be
defined in another page supplied by the user.  Trails comes with a
default page containing all of its editors as Blocks (similar to a
Fragment).  The default behavior returns components from this page
 as
the editors for properties.  However, any client application could
define their own editor component blocks on some page and use those
also.
   
   
On 1/20/08, Gerolf Seitz [EMAIL PROTECTED] wrote:
 have you seen Al's Bean Editor [0]?
 this might give you a hint in the right direction.

 regards,
   gerolf

 [0] http://herebebeasties.com/2007-08-17/wicket-bean-editor/

 On Jan 20, 2008 10:17 PM, James Carman [EMAIL PROTECTED]
 wrote:

  Is there any reason that components require that they be applied
 to
  specific tag types in the markup files?  I'm writing a little
 utility
  which calculates at runtime what editor to use based on the
 property
  type (a la Trails).  So, I have no idea what type of tag to
 use.  I
  thought I'd just do this (the actual component is a TextField in
 this
  case):
 
  div wicket:id=editor /
 
  But, I get the following error message:
 
  org.apache.wicket.markup.MarkupException: Component editor must
 be
  applied to a tag of type 'input', not 'div wicket:id=editor'
 (line
  0, column 0)
 
  If I change my markup to:
 
  input type=text wicket:id=editor /
 
  then it works.  But, suppose a certain property requires a more
  complicated editor component (maybe rich text, so I'd use
 something
  like FCKEditor).  Would that component be complaining that it's
 being
  applied to an input tag?  Is there any generic way to do this
 so
  that all components will be happy at runtime with the
 markup?  Is
  there any way to relax that restriction?
 
  James
 
 
 -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 

   
   
 -
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
   
   
  
   -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
  
  
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 

 -
 To unsubscribe, e-mail: [EMAIL 

Re: RadioChoice : default choice ?

2008-01-21 Thread Eelco Hillenius
On Jan 21, 2008 1:08 PM, Per Newgro [EMAIL PROTECTED] wrote:
  Getting familiar with Swing will almost certainly help you get Wicket.
  Just keep in mind that with Swing, you would update values by
  'pushing' them (for which you'd typically make heave use of the
  observer pattern, e.g. using PropertyChangeListeners etc), whereas
  with Wicket you would rely on the request cycle doing it for you (we
  often call that 'pull' and it is in fact an example of Inversion of
  Control, since you let your model objects being updated by the
  framework rather than pushing out changes to the framework yourself).
 Btw. on that issue you can checkout for the jgoodies binding framework. It has
 similiar concepts like wicket - but is for swing components. But i don't want
 to hijack this thread :-)

I've never used it myself, but I have heard good things about it. So
yeah Scott, check it out :-)

Eelco

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Required tag types?

2008-01-21 Thread Johan Maasing
Yes that would be fun and a great way to learn more wicket. Are you
doing a fork of trails (wrails)?
Primarily what I am interested in is web content management and
publishing. I'm looking to replace/enhance a legacy system that bases
its' rendering on velocity or XML-based views.   As a start I would
like to write a simple (but functional) publishing system based on
wicket. What I'm looking for is coding specific editors and display
components based on the content type. The content type is, I guess,
basically a domain object like editorial, flash and so on. Does it
sound like enough overlap with your interests to actually start a
project?

2008/1/21, James Carman [EMAIL PROTECTED]:
 Or, maybe we should start a new project (or a Wicket subproject) to take
 care of this common need.

 On 1/21/08, Johan Maasing [EMAIL PROTECTED] wrote:
 
  As an exercise I tried to write a CMS-like framework. It became
  remarkably similiar and I had the same question. My factories produced
  an editor and a display, apart from that they have almost the same
  names as yours. I guess this almost qualifies as a FAQ :-)
 
  2008/1/20, James Carman [EMAIL PROTECTED]:
   The way my framework is set up, I've got a PropertyEditorFactory
  interface:
  
   public interface PropertyEditorFactory
   {
 public Component createPropertyEditor(String componentName, Object
   target, PropertyMetadata meta);
   }
  
   If I required my factory to return Panel objects instead, where would
   the markup for those Panels come from?  Would I have to write my own
   Panel extension classes that have the different editor types in them
   (TextEditorPanel, BooleanEditorPanel, etc.)?
  
  
  
   On 1/20/08, Igor Vaynberg [EMAIL PROTECTED] wrote:
instead of using fragments you can use panels, which would make the
editors reusable across projects/pages.
   
as far as why the checks are there...
   
add(new TextField(foo));
div wicket:id=foo/
   
will end up with
   
div wicket:id=foo value=bar/ == not a very useful textbox
   
wicket does not mutate markup by default, so it will not mutate div
tag to input tag.
   
it also adds a level of error checking, making sure you add the right
components to the right places.
   
-igor
   
   
On Jan 20, 2008 1:50 PM, James Carman [EMAIL PROTECTED]
  wrote:
 So, the key is to use Fragments?  This is very similar to how we did
 it in Trails.  I would like to make this somewhat reusable in other
 projects so that they can define their own editors without having
  to
 change this framework code.  I'm somewhat new to Wicket, so maybe I
 just don't understand this all yet, but it seems to me like this
 framework will only be able to use Fragments defined within the
 current markup (the BeanEditPanel.html file).  Is that true?  In
 Trails, we had the concept of a component address that  you would
 use to locate the editor component you want to use.  So, it could be
 defined in another page supplied by the user.  Trails comes with a
 default page containing all of its editors as Blocks (similar to a
 Fragment).  The default behavior returns components from this page
  as
 the editors for properties.  However, any client application could
 define their own editor component blocks on some page and use those
 also.


 On 1/20/08, Gerolf Seitz [EMAIL PROTECTED] wrote:
  have you seen Al's Bean Editor [0]?
  this might give you a hint in the right direction.
 
  regards,
gerolf
 
  [0] http://herebebeasties.com/2007-08-17/wicket-bean-editor/
 
  On Jan 20, 2008 10:17 PM, James Carman [EMAIL PROTECTED]
  wrote:
 
   Is there any reason that components require that they be applied
  to
   specific tag types in the markup files?  I'm writing a little
  utility
   which calculates at runtime what editor to use based on the
  property
   type (a la Trails).  So, I have no idea what type of tag to
  use.  I
   thought I'd just do this (the actual component is a TextField in
  this
   case):
  
   div wicket:id=editor /
  
   But, I get the following error message:
  
   org.apache.wicket.markup.MarkupException: Component editor must
  be
   applied to a tag of type 'input', not 'div wicket:id=editor'
  (line
   0, column 0)
  
   If I change my markup to:
  
   input type=text wicket:id=editor /
  
   then it works.  But, suppose a certain property requires a more
   complicated editor component (maybe rich text, so I'd use
  something
   like FCKEditor).  Would that component be complaining that it's
  being
   applied to an input tag?  Is there any generic way to do this
  so
   that all components will be happy at runtime with the
  markup?  Is
   there any way to relax that restriction?
  
   James
  
  
  

Add row to list of items on a page dynamically via ajax without repainting whole list

2008-01-21 Thread atul singh
Hi
I want to add a new row on my page using ajax, without having to repaint the
complete list already being displayed on the page.
This i want to reduce the ajax payload;any help on how i can do this?


Re: Required tag types?

2008-01-21 Thread James Carman
Well, custom editor components based on object type sounds in scope for what
I have in mind.  And, yes, I'm planning on implementing something similar to
Trails using Wicket (and I was planning on calling it wails).

On 1/21/08, Johan Maasing [EMAIL PROTECTED] wrote:

 Yes that would be fun and a great way to learn more wicket. Are you
 doing a fork of trails (wrails)?
 Primarily what I am interested in is web content management and
 publishing. I'm looking to replace/enhance a legacy system that bases
 its' rendering on velocity or XML-based views.   As a start I would
 like to write a simple (but functional) publishing system based on
 wicket. What I'm looking for is coding specific editors and display
 components based on the content type. The content type is, I guess,
 basically a domain object like editorial, flash and so on. Does it
 sound like enough overlap with your interests to actually start a
 project?

 2008/1/21, James Carman [EMAIL PROTECTED]:
  Or, maybe we should start a new project (or a Wicket subproject) to take
  care of this common need.
 
  On 1/21/08, Johan Maasing [EMAIL PROTECTED] wrote:
  
   As an exercise I tried to write a CMS-like framework. It became
   remarkably similiar and I had the same question. My factories produced
   an editor and a display, apart from that they have almost the same
   names as yours. I guess this almost qualifies as a FAQ :-)
  
   2008/1/20, James Carman [EMAIL PROTECTED]:
The way my framework is set up, I've got a PropertyEditorFactory
   interface:
   
public interface PropertyEditorFactory
{
  public Component createPropertyEditor(String componentName, Object
target, PropertyMetadata meta);
}
   
If I required my factory to return Panel objects instead, where
 would
the markup for those Panels come from?  Would I have to write my own
Panel extension classes that have the different editor types in them
(TextEditorPanel, BooleanEditorPanel, etc.)?
   
   
   
On 1/20/08, Igor Vaynberg [EMAIL PROTECTED] wrote:
 instead of using fragments you can use panels, which would make
 the
 editors reusable across projects/pages.

 as far as why the checks are there...

 add(new TextField(foo));
 div wicket:id=foo/

 will end up with

 div wicket:id=foo value=bar/ == not a very useful textbox

 wicket does not mutate markup by default, so it will not mutate
 div
 tag to input tag.

 it also adds a level of error checking, making sure you add the
 right
 components to the right places.

 -igor


 On Jan 20, 2008 1:50 PM, James Carman [EMAIL PROTECTED]
   wrote:
  So, the key is to use Fragments?  This is very similar to how we
 did
  it in Trails.  I would like to make this somewhat reusable in
 other
  projects so that they can define their own editors without
 having
   to
  change this framework code.  I'm somewhat new to Wicket, so
 maybe I
  just don't understand this all yet, but it seems to me like this
  framework will only be able to use Fragments defined within the
  current markup (the BeanEditPanel.html file).  Is that true?  In
  Trails, we had the concept of a component address that  you
 would
  use to locate the editor component you want to use.  So, it
 could be
  defined in another page supplied by the user.  Trails comes with
 a
  default page containing all of its editors as Blocks (similar
 to a
  Fragment).  The default behavior returns components from this
 page
   as
  the editors for properties.  However, any client application
 could
  define their own editor component blocks on some page and use
 those
  also.
 
 
  On 1/20/08, Gerolf Seitz [EMAIL PROTECTED] wrote:
   have you seen Al's Bean Editor [0]?
   this might give you a hint in the right direction.
  
   regards,
 gerolf
  
   [0] http://herebebeasties.com/2007-08-17/wicket-bean-editor/
  
   On Jan 20, 2008 10:17 PM, James Carman 
 [EMAIL PROTECTED]
   wrote:
  
Is there any reason that components require that they be
 applied
   to
specific tag types in the markup files?  I'm writing a
 little
   utility
which calculates at runtime what editor to use based on
 the
   property
type (a la Trails).  So, I have no idea what type of tag to
   use.  I
thought I'd just do this (the actual component is a
 TextField in
   this
case):
   
div wicket:id=editor /
   
But, I get the following error message:
   
org.apache.wicket.markup.MarkupException: Component editor
 must
   be
applied to a tag of type 'input', not 'div
 wicket:id=editor'
   (line
0, column 0)
   
If I change my markup to:
   
input type=text wicket:id=editor /
   
then it works.  But, suppose a certain property requires a
 more

Re: Required tag types?

2008-01-21 Thread Eelco Hillenius
On Jan 21, 2008 2:34 PM, James Carman [EMAIL PROTECTED] wrote:
 Well, custom editor components based on object type sounds in scope for what
 I have in mind.  And, yes, I'm planning on implementing something similar to
 Trails using Wicket (and I was planning on calling it wails).

I'm not sure how well it works, but before anyone jumps into a code
rage, it might be a good idea to check out Grail's Wicket support:
http://grails.codehaus.org/Wicket+Plugin. Even if it is not perfect
yet (it might be, I don't know), it might be a more efficient use of
your time to improve the plugin rather than starting from scratch.
Unless you don't like Grails of course.

Cheers,

Eelco

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: bookmarkable link keep recreate the objects.

2008-01-21 Thread Ned Collyer


Eelco Hillenius wrote:
 
 If you're still unconvinced, take a look at
 org.apache.wicket.examples.staticpages in wicket-examples; it might do
 what you want.
 
 Eelco
 

This sounds like very similar question to
http://www.nabble.com/Link-to-last-version-of-a-page-of-a-given-type-class.-td14994042.html

Its like a page is designed to maintain state only while you operate
components within it.  Clicking on a link to the page instantiates a new
one! (even tho old ones are kicking around in the page store or session)

Sure the FAQ example could be static, but it may well have some state
associated with it.

Anyway, I've got a limited workaround.

It seems like a commonly used concept.
-- 
View this message in context: 
http://www.nabble.com/bookmarkable-link--keep-recreate-the-objects.-tp14997853p15009613.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: parse directive in velocity template failing

2008-01-21 Thread James McLaughlin
fattymelt,
It used to work that you could jar up your templates and put them
under WEB-INF/lib. If that doesn't work, create your own
velocity.properties file and define the init-params
velocityPropertiesFolder and velocity.properties in your web.xml. You
can define there which loaders to use and what root the
FileResourceLoader should use. Best of luck, fattymelt!

On Jan 21, 2008 9:27 AM, fattymelt [EMAIL PROTECTED] wrote:

 I am using a velocity template, and within it would like to use velocity's
 parse directive (to include another template within the current template)
 but it complains that it can not find the template in velocity's
 TEMPLATE_ROOT.  I have triple-checked that the template is in the same
 directory as all of my other working templates. Anyone know why velocity
 can't find a template when using parse ?

 Does Wicket specify its own template location? If so, does anyone know where
 the default Velocity TEMPLATE_ROOT would be?

 http://velocity.apache.org/engine/devel/user-guide.html#parse Velocity's
 Parse Directive

 TIA
 --
 View this message in context: 
 http://www.nabble.com/%22parse%22-directive-in-velocity-template-failing-tp14999823p14999823.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: bookmarkable link keep recreate the objects.

2008-01-21 Thread dvd
Thanks. I looked that source of the staticpages examples and even more troubled 
with it. It generates each static links via a costly 
markup object creation and attribute modification.
In a base template page that may contain,say 50 such links, 
that would be displayed for all site (bookmarkable) pages, 
it would mean  a lot of object creation/destruction just for a static markup. I 
saw a post about running out of wicket memory during stress test. I had quite a 
few times noticing the turnaround is quite slow in my app even though it is 
just a page with many constructed links, even though I do not have test suite 
to back it up. 

Would it be possible to turn a bookmarkale/stateless page object
into a stateful page during a session once user first access it.
After all, bookmarkable page link is for accessing the page when you
return to it after ,say  a few days. Once you access/create it,
during the session, it should be considered a stateful.



  This is obviouly a huge performance issue.

I wonder if it is. Java is optimized for creating objects, and
creating new ones is often cheaper than reusing old ones if you take
synchronization and lookups into account.

Are you sure it is a bottleneck? If you haven't seen any actual
performance problems (and determined that it is the web tier causing
it, which is often unlikely given that accessing the back-end such as
databases often take the majority of the processing of a request)
you'd be wasting your time. Premature optimization is evil :-)

If you're still unconvinced, take a look at
org.apache.wicket.examples.staticpages in wicket-examples; it might do
what you want.

Eelco

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Required tag types?

2008-01-21 Thread James Carman
Eelco,

I will take a look at it, but I'm not big on Groovy or Grails.   I decided
to write the Wails framework as an exercise in learning Wicket and if it
turned out to be something folks might like, then they could feel free to do
so.  I was somewhat active in the Tapestry (4.x versions) community for a
while and Wicket has interested me for quite some time.

James

On 1/21/08, Eelco Hillenius [EMAIL PROTECTED] wrote:

 On Jan 21, 2008 2:34 PM, James Carman [EMAIL PROTECTED] wrote:
  Well, custom editor components based on object type sounds in scope for
 what
  I have in mind.  And, yes, I'm planning on implementing something
 similar to
  Trails using Wicket (and I was planning on calling it wails).

 I'm not sure how well it works, but before anyone jumps into a code
 rage, it might be a good idea to check out Grail's Wicket support:
 http://grails.codehaus.org/Wicket+Plugin. Even if it is not perfect
 yet (it might be, I don't know), it might be a more efficient use of
 your time to improve the plugin rather than starting from scratch.
 Unless you don't like Grails of course.

 Cheers,

 Eelco

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




Re: Required tag types?

2008-01-21 Thread Eelco Hillenius
On Jan 21, 2008 4:48 PM, James Carman [EMAIL PROTECTED] wrote:
 Eelco,

 I will take a look at it, but I'm not big on Groovy or Grails.   I decided
 to write the Wails framework as an exercise in learning Wicket and if it
 turned out to be something folks might like, then they could feel free to do
 so.  I was somewhat active in the Tapestry (4.x versions) community for a
 while and Wicket has interested me for quite some time.

Well, that's an excellent reason. I'm not crazy about Groovy myself
tbh, though my opinion is heavily colored by my experiences years ago
when it was still in alpha. Since then it got much better I hear. And
there are plenty of people who seem to like Grails.

Anyway, I don't want to hold you back on creating something fun for
Wicket :-) We can give you write access to wicket-stuff if you want
your project to live there.

Cheers,

Eelco

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: bookmarkable link keep recreate the objects.

2008-01-21 Thread Igor Vaynberg
On Jan 21, 2008 4:31 PM,  [EMAIL PROTECTED] wrote:
 Thanks. I looked that source of the staticpages examples and even more 
 troubled with it. It generates each static links via a costly
 markup object creation and attribute modification.
 In a base template page that may contain,say 50 such links,
 that would be displayed for all site (bookmarkable) pages,
 it would mean  a lot of object creation/destruction just for a static markup.

have you profiled how expensive creating these objects really is? i
would be curious about the numbers you get.

I saw a post about running out of wicket memory during stress test.

was that because there was a memory leak in wicket code or in the user's code?

I had quite a few times  noticing the turnaround is quite slow in my
app even though it is just a page with many constructed links, even
though I do not have test suite to back it up.

have you tried starting your app in deployment mode? development mode
has quiet a lot of overhead which gets you better error reporting.

 Would it be possible to turn a bookmarkale/stateless page object
 into a stateful page during a session once user first access it.

these pages are not created until accessed...so not sure what you mean

 After all, bookmarkable page link is for accessing the page when you
 return to it after ,say  a few days. Once you access/create it,
 during the session, it should be considered a stateful.

yes and it is, however, it is up to you to determine the scope that
defines its statefulnes. you do  this like you do with most other java
objects - by holding onto its reference.

for conversation scopes you pass the reference around into pages that
define the conversation

for session scope you should store that reference within session.

   This is obviouly a huge performance issue.

really? maybe to make it obvious you should show some numbers so we
can compare. maybe a graph...personally i love pie charts :)

-igor

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Jboss Portal + Wicket (Portlet)

2008-01-21 Thread Markqt

Finally, I got Wicket1.3 portlet working in JBoss portal 2.6.3 - after fixing
a few bugs in  JBoss's PortletWindowUtils class. When I tried the
EditableLable AJAX component, I got following error using Firefox:

Error: wicketAjaxGet is not defined
Source File:
http://localhost:8080/portal/auth/portal/default/default/Wicket13PortletWindow?mode=edit
Line: 1

The error is different in I.E. - complaining about Wicket undefined. 

script type=text/javascript
id=wicket-ajax-portlet-flag!--/*--![CDATA[/*!--*/
Wicket.portlet=true
/*--]]*//script



Süli Zsolt wrote:
 
 JbossPortletResourceURLFactory is my custom class. As far as I know 
 Jboss Portal team hasn't implemented it yet, so I did the job (it's not 
 a big thing though as u can see in my previous letter). So check my last 
 letter for the code ... especially the part And my implementation of 
 PortletResourceURLFactory ;).
 
 Good luck!
 
 PS: my surname is Zsolt ;)
 
 Markqt wrote:
 Hi Suli,

 Thanks much for the details. Where did you get calss
 JbossPortletResourceURLFactory? This is exactly what I am missing. I
 can't
 find it in jboss portal, wicket1.3 download, or apache portal bridge1.04.
 If
 this is your own implementation, can you please post the code?

 init-param
 namePortletResourceURLFactory/name

 valuewicket.tetst.common.JbossPortletResourceURLFactory/value
 /init-param


   
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Jboss-Portal-%2B-Wicket-%28Portlet%29-tp14953943p15011074.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: bookmarkable link keep recreate the objects.

2008-01-21 Thread dvd
 Would it be possible to turn a bookmarkale/stateless page object 
 into a stateful page during a session once user first access it. 

these pages are not created until accessed...so not sure what you mean 

 I meant once they are created, accessing it again (say hit refresh button on 
 browser) should
not result in a new page object recreation, instead using a way to
locate the previous created object and rerender it as in a stateful
page.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: bookmarkable link keep recreate the objects.

2008-01-21 Thread Igor Vaynberg
you are free to write your own coding strategy that checks for
existence of these pages in session before creating a new instance.

-igor


On Jan 21, 2008 6:01 PM,  [EMAIL PROTECTED] wrote:
  Would it be possible to turn a bookmarkale/stateless page object
  into a stateful page during a session once user first access it.

 these pages are not created until accessed...so not sure what you mean

  I meant once they are created, accessing it again (say hit refresh button 
  on browser) should
 not result in a new page object recreation, instead using a way to
 locate the previous created object and rerender it as in a stateful
 page.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: bookmarkable link keep recreate the objects.

2008-01-21 Thread dvd
I see. I guess I need to dig through more info on usage of api.
But I just noticed the following perhaps you can point out 
surprising (to me) issue right away. 
It is a simple list view display with 

class Test{
PageableListView listView = new PageableListView(records, new 
PropertyModel(this, records),
rowsPerPage) {
public void populateItem(final ListItem listItem) {
final Object record = listItem.getModelObject();
 
   public List getRecords(){
   return a record list from db query
}

}   

what I noticed that for each populateItem call, it would invokes
getRecords() (perhaps with further indexing). So it I have 1000 records
in db, it would issue 1000 query for the same result list.
What I am doing wrong here? I basically took an example class from wicket 
website and replace the fixed record list with a db query and
could not explain the extreem slowness until I found out this problem.


you are free to write your own coding strategy that checks for
existence of these pages in session before creating a new instance.

-igor


On Jan 21, 2008 6:01 PM,  [EMAIL PROTECTED] wrote:
  Would it be possible to turn a bookmarkale/stateless page object
  into a stateful page during a session once user first access it.

 these pages are not created until accessed...so not sure what you mean

  I meant once they are created, accessing it again (say hit refresh button 
on browser) should
 not result in a new page object recreation, instead using a way to
 locate the previous created object and rerender it as in a stateful
 page.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: bookmarkable link keep recreate the objects.

2008-01-21 Thread Igor Vaynberg
wicket is doing exactly what you told it to do

you call final Object record = listItem.getModelObject(); 1000 times

which in turns calls listviewmodel.getobject().get(index); where index
varies from 1 to 1000

listviewmodel is PropertyModel(this, records) so when its
getobject() is called (1000 times) it calls getrecords() method

thus your getrecords is called 1000 times - just like you have it setup.

you should read up on detachable models and loadable models - models
that cache a value for the duration of a request.

for example, if you replace new PropertyModel(this, records) with
new LoadableDetachableModel() { Object load() { return getRecords();
}}

getRecords() would only be called once per request.

also if you have read the javadoc of ListView you would have noticed
that it does not recommend using ListView with database driven data.
ListView is made to work with lists. in a list an item is identified
by its index, in a database rowset an item is identified by its
primary key.

you took an example that uses static data where getrecords() is a
cheap call and expect it to work with database data without
modifications - where getrecords() is an expensive call, dont you
think that is silly?

if you want to display database data i would look into DataView and
DataTable. there are plenty examples in
http://wicketstuff.org/wicket13/repeater/

-igor


On Jan 21, 2008 6:32 PM,  [EMAIL PROTECTED] wrote:
 I see. I guess I need to dig through more info on usage of api.
 But I just noticed the following perhaps you can point out
 surprising (to me) issue right away.
 It is a simple list view display with

 class Test{
 PageableListView listView = new PageableListView(records, new 
 PropertyModel(this, records),
 rowsPerPage) {
 public void populateItem(final ListItem listItem) {
 final Object record = listItem.getModelObject();

public List getRecords(){
return a record list from db query
 }

 }

 what I noticed that for each populateItem call, it would invokes
 getRecords() (perhaps with further indexing). So it I have 1000 records
 in db, it would issue 1000 query for the same result list.
 What I am doing wrong here? I basically took an example class from wicket 
 website and replace the fixed record list with a db query and
 could not explain the extreem slowness until I found out this problem.



 you are free to write your own coding strategy that checks for
 existence of these pages in session before creating a new instance.
 
 -igor
 
 
 On Jan 21, 2008 6:01 PM,  [EMAIL PROTECTED] wrote:
   Would it be possible to turn a bookmarkale/stateless page object
   into a stateful page during a session once user first access it.
 
  these pages are not created until accessed...so not sure what you mean
 
   I meant once they are created, accessing it again (say hit refresh 
   button
 on browser) should
  not result in a new page object recreation, instead using a way to
  locate the previous created object and rerender it as in a stateful
  page.
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: bookmarkable link keep recreate the objects.

2008-01-21 Thread Eelco Hillenius
On Jan 21, 2008 6:32 PM,  [EMAIL PROTECTED] wrote:
 I see. I guess I need to dig through more info on usage of api.
 But I just noticed the following perhaps you can point out
 surprising (to me) issue right away.
 It is a simple list view display with

 class Test{
 PageableListView listView = new PageableListView(records, new 
 PropertyModel(this, records),
 rowsPerPage) {
 public void populateItem(final ListItem listItem) {
 final Object record = listItem.getModelObject();

public List getRecords(){
return a record list from db query
 }

 }

The idea behind PageableListView is that it is backed by a list that
understands how to page. See for instance
http://wicket-stuff.svn.sourceforge.net/viewvc/wicket-stuff/branches/WICKET_1_2/wicket-contrib-data/src/java/wicket/contrib/data/model/PageableList.java?view=markup

However, nowadays IDataProvider and the repeaters that use it are a
better alternative to PageableListViews, amongst other reasons because
the paging is more explicit.

Eelco

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: bookmarkable link keep recreate the objects.

2008-01-21 Thread dvd
Got it.

On Jan 21, 2008 6:32 PM,  [EMAIL PROTECTED] wrote:
 I see. I guess I need to dig through more info on usage of api.
 But I just noticed the following perhaps you can point out
 surprising (to me) issue right away.
 It is a simple list view display with

 class Test{
 PageableListView listView = new PageableListView(records, new 
PropertyModel(this, records),
 rowsPerPage) {
 public void populateItem(final ListItem listItem) {
 final Object record = listItem.getModelObject();

public List getRecords(){
return a record list from db query
 }

 }

The idea behind PageableListView is that it is backed by a list that
understands how to page. See for instance
http://wicket-stuff.svn.sourceforge.net/viewvc/wicket-stuff/branches/WICKET_1_2
/wicket-contrib-data/src/java/wicket/contrib/data/model/PageableList.java?view=
markup

However, nowadays IDataProvider and the repeaters that use it are a
better alternative to PageableListViews, amongst other reasons because
the paging is more explicit.

Eelco

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: bookmarkable link keep recreate the objects.

2008-01-21 Thread dvd
Thanks for the tip. It worked perfectly.
I do feel this could be a minor bug even for a fixed list
(might not be noticeable visually). At the time ListView is
created, it is provided with a predefined model object =this.getRecords()
which should be the state of the listview and this.getModel
should directly return this state. This is probably due to the program idiom 
used.


wicket is doing exactly what you told it to do

you call final Object record = listItem.getModelObject(); 1000 times

which in turns calls listviewmodel.getobject().get(index); where index
varies from 1 to 1000

listviewmodel is PropertyModel(this, records) so when its
getobject() is called (1000 times) it calls getrecords() method

thus your getrecords is called 1000 times - just like you have it setup.

you should read up on detachable models and loadable models - models
that cache a value for the duration of a request.

for example, if you replace new PropertyModel(this, records) with
new LoadableDetachableModel() { Object load() { return getRecords();
}}

getRecords() would only be called once per request.

also if you have read the javadoc of ListView you would have noticed
that it does not recommend using ListView with database driven data.
ListView is made to work with lists. in a list an item is identified
by its index, in a database rowset an item is identified by its
primary key.

you took an example that uses static data where getrecords() is a
cheap call and expect it to work with database data without
modifications - where getrecords() is an expensive call, dont you
think that is silly?

if you want to display database data i would look into DataView and
DataTable. there are plenty examples in
http://wicketstuff.org/wicket13/repeater/

-igor


On Jan 21, 2008 6:32 PM,  [EMAIL PROTECTED] wrote:
 I see. I guess I need to dig through more info on usage of api.
 But I just noticed the following perhaps you can point out
 surprising (to me) issue right away.
 It is a simple list view display with

 class Test{
 PageableListView listView = new PageableListView(records, new 
PropertyModel(this, records),
 rowsPerPage) {
 public void populateItem(final ListItem listItem) {
 final Object record = listItem.getModelObject();

public List getRecords(){
return a record list from db query
 }

 }

 what I noticed that for each populateItem call, it would invokes
 getRecords() (perhaps with further indexing). So it I have 1000 records
 in db, it would issue 1000 query for the same result list.
 What I am doing wrong here? I basically took an example class from wicket 
website and replace the fixed record list with a db query and
 could not explain the extreem slowness until I found out this problem.



 you are free to write your own coding strategy that checks for
 existence of these pages in session before creating a new instance.
 
 -igor
 
 
 On Jan 21, 2008 6:01 PM,  [EMAIL PROTECTED] wrote:
   Would it be possible to turn a bookmarkale/stateless page object
   into a stateful page during a session once user first access it.
 
  these pages are not created until accessed...so not sure what you mean
 
   I meant once they are created, accessing it again (say hit refresh 
button
 on browser) should
  not result in a new page object recreation, instead using a way to
  locate the previous created object and rerender it as in a stateful
  page.
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: parse directive in velocity template failing

2008-01-21 Thread fattymelt

Just to be sure...

In the Wicket section of web.xml I am going to add the two init-params. One
of which defines the folder in which to find my properties file, and the
other is the actual filename. Then I can use that properties file to specify
what my TEMPLATE_ROOT is.

The only I don't get, is that I have working templates now that are in
WEB-IN/templates. So, it isn't like velocity-contrib isn't finding them. So
I'm not sure why the parse directive isn't looking there, too?


James McLaughlin-3 wrote:
 
 fattymelt,
 It used to work that you could jar up your templates and put them
 under WEB-INF/lib. If that doesn't work, create your own
 velocity.properties file and define the init-params
 velocityPropertiesFolder and velocity.properties in your web.xml. You
 can define there which loaders to use and what root the
 FileResourceLoader should use. Best of luck, fattymelt!
 

-- 
View this message in context: 
http://www.nabble.com/%22parse%22-directive-in-velocity-template-failing-tp14999823p15013060.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Add row to list of items on a page dynamically via ajax without repainting whole list

2008-01-21 Thread Peter Thomas
On 1/22/08, atul singh [EMAIL PROTECTED] wrote:

 Hi
 I want to add a new row on my page using ajax, without having to repaint
 the
 complete list already being displayed on the page.
 This i want to reduce the ajax payload;any help on how i can do this?


Try this thread:

http://www.nabble.com/Adding-item-to-ListView-over-Ajax---refresh-only-newest-row-td11272937.html


Re: Required tag types?

2008-01-21 Thread Johan Maasing
2008/1/22, Eelco Hillenius [EMAIL PROTECTED]:
 On Jan 21, 2008 4:48 PM, James Carman [EMAIL PROTECTED] wrote:
  Eelco,
 
  I will take a look at it, but I'm not big on Groovy or Grails.   I decided
  to write the Wails framework as an exercise in learning Wicket and if it
  turned out to be something folks might like, then they could feel free to do
  so.  I was somewhat active in the Tapestry (4.x versions) community for a
  while and Wicket has interested me for quite some time.

I'm in the same spot, looking to learn more wicket (groovy - not so
much). It would be fun to try to collect some editors (and in my case
read-only displays) for specific classes. I guess that it would be a
good idea to try to narrow that scope a bit. What I am after is in the
end two applications, one delivery-side which is the site with
published content. The other is the administrative site where you
publish content. So far nothing special apart from that the look and
feel should be consistent for display and editor components.

I would like to have a registry of editors and display-components. The
framework selects which editor or display to use based on the type of
content. I guess this is where you actually get some benefit from such
a framework. The dynamic selection of components based on type
information. For my case it is enough to register editors with a key
based on a java class at application start up. I guess that James
might have another tack on how this should work (I haven't looked at
Trails that much). Also, I would be perfectly happy to have a
specific java class hierarchy representing the domain (perhaps rooted
in some interface like 'Content' and ' PersistentContent'. I guess
this is a bit different scope from Wails and stuff like Wicket Web
Beans (http://wicketwebbeans.sourceforge.net/)

So, to narrow the scope, I'm interested in creating a Component that
looks at some (request) parameter to decide which content to look up
in a backing store. It would select an appropriate editor or display
based on the type of content. The editors should have a (somewhat)
consistent Look and Feel.

Judging from this mailing list there seems to be other people working
on CMS-like frameworks. Perhaps others (apart from me and Mr. Carman)
might be interested in something like this also?

Cheers,
Johan

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]