Re: status of the PageMap

2009-06-17 Thread Johan Compagner
PageMaps cant currently be extended easily because the are created by the
different ISessionStore implementations
Because pagemap behavior is really bound to how a specific store works.

On Wed, Jun 17, 2009 at 05:11, Joe Fawzy joewic...@gmail.com wrote:

 Hi So this is the current status, what about future plans?,
 How can i provide my own custom implementation?
 thanks
 Joe

 On Tue, Jun 16, 2009 at 9:19 PM, Johan Compagner jcompag...@gmail.com
 wrote:

  in 1.4 it is still an part of wicket.
 
  But it is not that needed anymore as before but that is sinse 1.3 when we
  started saving to disk.
 
  johan
 
 
 
  On Tue, Jun 16, 2009 at 20:03, Joe Fawzy joewic...@gmail.com wrote:
 
   Hi alli was wondering , what is the status of the pageMap?
   i saw in the wiki some articles talking about it will be deprecated, so
  is
   that true? i can see it in the 1.4 docs, is that for backward
  compatability
   or it still a essential part of the platform?
   How can i plug my own custom subclass of PageMap and make the framework
  use
   it instead of the stock ones
   thanks
   Joe
  
 



wicketstuff mini veil

2009-06-17 Thread Jing Ge (Besitec IT DEHAM)
Hallo,

 

I have checked out the source code and taken a look at the class Veil. I
found the following code:

 

   public void bind(Component component)

   {

  super.bind(component);

  if (component != null)

  {

 throw new IllegalStateException(

  This behavior is
already bound to component. An instance of this behavior cannot be
reused between components. Bound component: 

 
+ this.component.toString());

  }

  this.component = component;

   }

 

From the code we can see, the component will be checked after binding.
If it is null, an exception will be thrown. 

 

Well, actually, I don't get it. Since the component can not be null
after binding, the exception will be always thrown. Show me if I am
wrong.

 

Has anyone ever used the mini veil? Could anyone give me hand? Thanks.

 

Best regards!

Jing Ge

 

 

 



RE: wicketstuff mini veil

2009-06-17 Thread Jing Ge (Besitec IT DEHAM)
Hello,

 

Should it be:

 

   super.bind(component);

   if (this.component != null) {

  .

   }

 

regards!

Jing Ge

 

-Original Message-
From: Jing Ge (Besitec IT DEHAM) [mailto:j...@besitec.com] 
Sent: Mittwoch, 17. Juni 2009 10:15
To: users@wicket.apache.org
Subject: wicketstuff mini veil

 

Hallo,

 

 

 

I have checked out the source code and taken a look at the class Veil. I

found the following code:

 

 

 

   public void bind(Component component)

 

   {

 

  super.bind(component);

 

  if (component != null)

 

  {

 

 throw new IllegalStateException(

 

  This behavior is

already bound to component. An instance of this behavior cannot be

reused between components. Bound component: 

 

 

+ this.component.toString());

 

  }

 

  this.component = component;

 

   }

 

 

 

From the code we can see, the component will be checked after binding.

If it is null, an exception will be thrown. 

 

 

 

Well, actually, I don't get it. Since the component can not be null

after binding, the exception will be always thrown. Show me if I am

wrong.

 

 

 

Has anyone ever used the mini veil? Could anyone give me hand? Thanks.

 

 

 

Best regards!

 

Jing Ge

 

 

 

 

 

 

 



ALT tags within an ImageMap

2009-06-17 Thread Frank Prins
Hi There All!

 

Working with Wicket for a while now, and really starting to get hooked,
great stuff!

I am working on a user interface for an application, and ran into a
(minor) thing, I hope someone can shine a light on this.

 

In a shortcut menu, I am using an imagemap with a couple of links in it,
and I am wondering if it is possible to create some ALT tags for mouse
over actions, one for each link The links in the Imagemap look this this
(simplified for readability):

 

imageMap.addPolygonLink(new int[] {123,123), new
BookmarkablePageLink(Support, SupportHomePage.class);

 

So I tried to create a SimpleAttributeModifier on both the PolygonLink
and BookmarkablePageLink, but unfortunately none of them worked.

Did I miss something here, or is there just no possibility?

 

thanks in advance!

 

Frank Prins



RE: wicketstuff mini veil

2009-06-17 Thread Jing Ge (Besitec IT DEHAM)
Hello, 

After doing this change, the project can be compiled and run. But I get
another problem.

Here is my test code:

final Label label = new Label(testLabel, new
ModelString());
  add(label);
  Form form = new Form(testForm);
AjaxButton button = new AjaxButton(testVeil) {

@Override
protected void onSubmit(AjaxRequestTarget arg0, Form?
arg1) {
try {
Thread.sleep(5000);
label.setDefaultModelObject( + new
Random().nextLong());
arg0.addComponent(label);
} catch (InterruptedException ex) {
 
Logger.getLogger(HomePage.class.getName()).log(Level.SEVERE, null, ex);
}
}
};
button.add(new Veil());
form.add(button);
add(form);

After the application is deployed and running, the ajax button is
disabled. Did I do something wrong? 

Best regards!
Jing Ge

-Original Message-
From: Jing Ge (Besitec IT DEHAM) [mailto:j...@besitec.com] 
Sent: Mittwoch, 17. Juni 2009 10:18
To: users@wicket.apache.org
Subject: RE: wicketstuff mini veil

Hello,

 

Should it be:

 

   super.bind(component);

   if (this.component != null) {

  .

   }

 

regards!

Jing Ge

 

-Original Message-
From: Jing Ge (Besitec IT DEHAM) [mailto:j...@besitec.com] 
Sent: Mittwoch, 17. Juni 2009 10:15
To: users@wicket.apache.org
Subject: wicketstuff mini veil

 

Hallo,

 

 

 

I have checked out the source code and taken a look at the class Veil. I

found the following code:

 

 

 

   public void bind(Component component)

 

   {

 

  super.bind(component);

 

  if (component != null)

 

  {

 

 throw new IllegalStateException(

 

  This behavior is

already bound to component. An instance of this behavior cannot be

reused between components. Bound component: 

 

 

+ this.component.toString());

 

  }

 

  this.component = component;

 

   }

 

 

 

From the code we can see, the component will be checked after binding.

If it is null, an exception will be thrown. 

 

 

 

Well, actually, I don't get it. Since the component can not be null

after binding, the exception will be always thrown. Show me if I am

wrong.

 

 

 

Has anyone ever used the mini veil? Could anyone give me hand? Thanks.

 

 

 

Best regards!

 

Jing Ge

 

 

 

 

 

 

 



-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Re: Re: Re: DAO not getting injected, using springbean

2009-06-17 Thread James Carman
Did you mark UserDAOHibernate with the @Repository annotation?

2009/6/16 Bruce McGuire br...@coastware.com:
 Hi Vasu.

 Thanks for the info. Now I get it, and have successfully wired my demo app
 so that it does the job.

 Although I did notice that along with the context:component-scan I did need
 to define the beans that I was going to autowire. How did you get around
 this?

   context:component-scan base-package=com.coastware /
   bean id=userDAO
 class=com.coastware.vProbe.model.dao.hibernate.UserDAOHibernate /

 Other than that, this is a very much reduced context file.

 Now I need to duplicate this in my real application.

 Thanks for everyone's help.

 Bruce McGuire.

 Vasu Srinivasan wrote:

 Using annotations, I have only one line in the spring's
 applicationContext.xml --

 context:component-scan base-package=packagename /

 Services are tagged with @Service, Daos are tagged with
 @Component(xxxDaoImpl), Wicket web pages have @SpringBean
 (name=serviceName)

 Within the ServiceImpl, the Daos are tagged with @Autowired.

 No other xml config, setter, getter for daos etc.

 Works like a charm.

 2009/6/16 James Carman jcar...@carmanconsulting.com



 You are correct.  You should only use @SpringBean in your wicket-related
 code (components/pages).  Let Spring wire the rest together, however you
 want to configure it to do that (with annotations or xml).  You can use
 @Autowired to inject your DAOs into your Services.  You just have to make
 sure you set up your Spring context so that it takes care of that.

 On Tue, Jun 16, 2009 at 4:36 PM, Bruce McGuire br...@coastware.com
 wrote:



 Hello James.

 So I have completely missed the point of the Repository, Service and
 SpringBean annotations?  I was under the impression that the idea was to
 avoid using a lot of xml in my context files.

 If I am understanding correctly, what you and Martijn are saying is the
 following:
 Tag the dao and service classes with Repository and Service, and in


 wicket


 code, tag any use of them with SpringBean. However, in the service


 classes,


 use the normal xml injection method and get/set to get the dao into the
 service class.

 Is this a correct interpretation?

 Thanks,

 Bruce.

 James Carman wrote:



 You shouldn't use @SpringBean in your spring-managed beans, only in
 your Wicket code.  You don't want view-specific code in your domain
 code.

 On Tue, Jun 16, 2009 at 4:17 PM, Bruce McGuire br...@coastware.com
 wrote:




 Hi Martijn.

 Thanks for the quick response.

 Are you saying that the dao and the service should have the
 InjectorHolder code, rather than the @Repository and @Service tags?

 Bruce.

 Martijn Dashorst wrote:




 @SpringBean only works with Components. For all other uses you should
 either call InjectorHolder.getInjector().inject(this) in your
 constructor or use Salve.

 Martijn

 On Tue, Jun 16, 2009 at 9:26 PM, Bruce McGuirebr...@coastware.com
 wrote:





 Hello.

 I have created a new small project to try to figure out how to use


 the


 SpringBean, Service, and Repository annotations with Wicket, Spring,
 Hibernate, Maven and Eclipse.

 However, I am getting an error with a user DAO that I have created.

 I have a service that is using the dao tagged as @Service, I have
 the
 DAO in
 the service tagged with @SpringBean, and the DAO code itself is


 tagged


 with
 @Repository.  The service that is using the DAO is getting found
 correctly.

 When I have the InjectorHolder code in the dao constructor, I get an
 error
 that says 'InjectorHolder has not been assigned an injector'

 When I comment out the InjectorHolder line in the dao constructor,


 the


 DAO
 is null, and getUserDAO throws an exception.

 Since I am not certain that I can attach files, I will insert the
 relevant
 code and exceptions into this email.

 Any pointers you can give would be greatly appreciated.

 Thanks very very much,

 Bruce.

 UserServiceImpl
  @Service(UserService)
 public class UserServiceImpl implements UserService
 {
 �...@springbean
  UserDAO userDAO ;

  private UserDAO getUserDAO()
  {
    if (null =erDAO)
    {
        throw new RuntimeException(userDAO is null) ;
    }

    return(userDAO) ;
  }

 �...@override
  public ListUser getUsers()
  {
    return (getUserDAO().findAll());
  }
 
 UserDAOHibernate
  @Repository(UserDAO)
 public class UserDAOHibernate extends GenericDAOHibernateUser,


 String


 implements UserDAO
 {
  private static Log log =Factory.getLog(UserDAOHibernate);

  public UserDAOHibernate()
  {
    InjectorHolder.getInjector().inject(this);
  }

 ...
 
 HomePage
  public class HomePage extends WebPage
 {
 �...@springbean
  private UserService userService ;

  public HomePage(final PageParameters parameters)
  {
    super (parameters) ;

    ListUser userList =rService.getUsers() ;

    RepeatingView rv = RepeatingView(Users) ;
    for(User user: userList)
    

Re: ALT tags within an ImageMap

2009-06-17 Thread James Carman
You might want to try my ClientSideImageMap class:
https://issues.apache.org/jira/browse/WICKET-1936

https://issues.apache.org/jira/browse/WICKET-1936It's a bit more flexible
than the existing implementation (and it'll support what you're wanting to
do).  The existing client side image map just grabs the URL off the link.
 It doesn't attach the link to the area of the map.  ClientSideImageMap
takes advantage of the fact that you can attach a Link object to any markup
element.

On Wed, Jun 17, 2009 at 4:59 AM, Frank Prins frank.pr...@copernicus.nlwrote:

 Hi There All!



 Working with Wicket for a while now, and really starting to get hooked,
 great stuff!

 I am working on a user interface for an application, and ran into a
 (minor) thing, I hope someone can shine a light on this.



 In a shortcut menu, I am using an imagemap with a couple of links in it,
 and I am wondering if it is possible to create some ALT tags for mouse
 over actions, one for each link The links in the Imagemap look this this
 (simplified for readability):



 imageMap.addPolygonLink(new int[] {123,123), new
 BookmarkablePageLink(Support, SupportHomePage.class);



 So I tried to create a SimpleAttributeModifier on both the PolygonLink
 and BookmarkablePageLink, but unfortunately none of them worked.

 Did I miss something here, or is there just no possibility?



 thanks in advance!



 Frank Prins




Creating a page hierarchy

2009-06-17 Thread Frank Tegtmeyer
Hi,

is there one established way to generate a page hierarchy?
Or some best practices?

I like to have a website (also a dynamic one) organized in a
hierarchical way like traditional static websites. This way
users can go to their desired functionality quickly and may
be able to even remember the associated URL.

I assume I have to use bookmarkable pages somehow.

Some questions remain for me:

1. Do I have to mount each single page or is there some
   wildcard/regexp/inheritance mechanism like in Django?
2. How do I organize my source files? Does it make sense to
   reflect the site hierarchy in a package hierarchy?
3. The site I develop has to use authorization. Is it
   possible to get a user back to the bookmarked page that
   he accessed after asking for authentication?
   I think yes, but am not sure.

Regards, Frank


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Creating a page hierarchy

2009-06-17 Thread Nicolas Melendez
I think reflect site hierarchy to package hierarchy,  is good idea because
when the application is big, it is easy to find the panels.
i always use like this.

Application  Module  view

NM

On Wed, Jun 17, 2009 at 2:07 PM, Frank Tegtmeyer f...@fte.to wrote:

 Hi,

 is there one established way to generate a page hierarchy?
 Or some best practices?

 I like to have a website (also a dynamic one) organized in a
 hierarchical way like traditional static websites. This way
 users can go to their desired functionality quickly and may
 be able to even remember the associated URL.

 I assume I have to use bookmarkable pages somehow.

 Some questions remain for me:

 1. Do I have to mount each single page or is there some
   wildcard/regexp/inheritance mechanism like in Django?
 2. How do I organize my source files? Does it make sense to
   reflect the site hierarchy in a package hierarchy?
 3. The site I develop has to use authorization. Is it
   possible to get a user back to the bookmarked page that
   he accessed after asking for authentication?
   I think yes, but am not sure.

 Regards, Frank


 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org




Help with Fragments

2009-06-17 Thread Chris

I'm Having trouble getting Fragments to work.  Here is my markup

span wicket:id=border class=mark
span wicket:id=showAllergies /
/span

wicket:fragment wicket:id=noAllergies 
   DUDE you are lucky!
/wicket:fragment

If I add a fragment like this
getBorder().add(new Fragment(showAllergies, noAllergies, this));

I get this Error..
Unable to find component with id 'showAllergies' in [MarkupContainer 
[Component id = _body]]. This means that you declared 
wicket:id=showAllergies in your markup, but that you either did not add 
the component to your page at all, or that the hierarchy does not match.


But if I do something like this, it finds the component.

getBorder().add(new AllergiesFragment(showAllergies, noAllergies));

private class AllergiesFragment extends Fragment {
  public AllergiesFragment(String id, String markupId) {
  super(id, markupId);
   }
}

Can someone tell me what what I'm missing?

Thanks





-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



AjaxEventBehavior onclick for WebMarkupContainer Precondition Check

2009-06-17 Thread Justin Boyd
All,

I have a simple application where I can change the size, position, and color
of a div within a page.  When I click on the div I want some functionality
to be performed, however the onclick event is never being returned to the
server, and is instead intercepted and rejected by the javascript, I get the
error
Ajax GET stopped because of precondition check,
url:;jsessionid=e80700c56cdf00f163ab8b7adb38?wicket:interface=:0:superDiv::IBehaviorListener:0:

HomePage.java -
public class HomePage extends BasePage
{

CompoundPropertyModelRectInfo rectInfoModel = new
CompoundPropertyModelRectInfo(new RectInfo(100, 100, 400, 400, blue));
WebMarkupContainer superDiv = new SuperDiv(superDiv, rectInfoModel);

public HomePage(){
... form setup ...
superDiv.add(new AjaxEventBehavior(onmousedown)
{

@Override
protected void onEvent(AjaxRequestTarget target)
{
System.out.println(dicks);
}
});
add(superDiv.setOutputMarkupId(true));

}

private class SuperDiv extends WebMarkupContainer
{

IModelRectInfo rectInfoModel;

public SuperDiv(String id, IModelRectInfo rectInfoModel)
{
super(id);
this.rectInfoModel = rectInfoModel;
}

@Override
protected void onComponentTag(ComponentTag tag)
{
tag.put(style,
position: static; +
top:  + getModelObject().getTop() + ; +
left:  + getModelObject().getLeft() + ; +
height:  + getModelObject().getHeight() + ; +
width:  + getModelObject().getWidth() + ; +
background-color:  + getModelObject().getColor() +
;);
}

public RectInfo getModelObject()
{
return rectInfoModel.getObject();
}

public void setModelObject(RectInfo rectInfo)
{
rectInfoModel.setObject(rectInfo);
}
}

The markup is simple, I can post that if requested, but it's just a div with
a wicket:id tag.

Thanks in advance!


RE: ALT tags within an ImageMap

2009-06-17 Thread Frank Prins
Hey James,

Thanks for the quick reply, will try this out later. I had hoped I
didn't see some obvious setting and have it makde out of the box.
But either way, your solution sounds good, and I will implement this
later on.

Frank

 -Original Message-
 From: James Carman [mailto:jcar...@carmanconsulting.com]
 Sent: woensdag 17 juni 2009 13:43
 To: users@wicket.apache.org
 Subject: Re: ALT tags within an ImageMap
 
 You might want to try my ClientSideImageMap class:
 https://issues.apache.org/jira/browse/WICKET-1936
 
 https://issues.apache.org/jira/browse/WICKET-1936It's a bit more
 flexible
 than the existing implementation (and it'll support what you're
wanting
 to
 do).  The existing client side image map just grabs the URL off the
 link.
  It doesn't attach the link to the area of the map.
 ClientSideImageMap
 takes advantage of the fact that you can attach a Link object to any
 markup
 element.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: AjaxEventBehavior onclick for WebMarkupContainer Precondition Check

2009-06-17 Thread Martin Funk
since the error is thrown on the browser side a dump of the generated  
html source might be more helpful.


try http://papernapkin.org/pastebin/home for posting that dump

mf

Am 17.06.2009 um 15:58 schrieb Justin Boyd:


All,

I have a simple application where I can change the size, position,  
and color
of a div within a page.  When I click on the div I want some  
functionality
to be performed, however the onclick event is never being returned  
to the
server, and is instead intercepted and rejected by the javascript, I  
get the

error
Ajax GET stopped because of precondition check,
url:;jsessionid=e80700c56cdf00f163ab8b7adb38?wicket:interface=: 
0:superDiv::IBehaviorListener:0:


HomePage.java -
public class HomePage extends BasePage
{

   CompoundPropertyModelRectInfo rectInfoModel = new
CompoundPropertyModelRectInfo(new RectInfo(100, 100, 400, 400,  
blue));
   WebMarkupContainer superDiv = new SuperDiv(superDiv,  
rectInfoModel);


   public HomePage(){
   ... form setup ...
   superDiv.add(new AjaxEventBehavior(onmousedown)
   {

   @Override
   protected void onEvent(AjaxRequestTarget target)
   {
   System.out.println(dicks);
   }
   });
   add(superDiv.setOutputMarkupId(true));

   }

   private class SuperDiv extends WebMarkupContainer
   {

   IModelRectInfo rectInfoModel;

   public SuperDiv(String id, IModelRectInfo rectInfoModel)
   {
   super(id);
   this.rectInfoModel = rectInfoModel;
   }

   @Override
   protected void onComponentTag(ComponentTag tag)
   {
   tag.put(style,
   position: static; +
   top:  + getModelObject().getTop() + ; +
   left:  + getModelObject().getLeft() + ; +
   height:  + getModelObject().getHeight() + ; +
   width:  + getModelObject().getWidth() + ; +
   background-color:  +  
getModelObject().getColor() +

;);
   }

   public RectInfo getModelObject()
   {
   return rectInfoModel.getObject();
   }

   public void setModelObject(RectInfo rectInfo)
   {
   rectInfoModel.setObject(rectInfo);
   }
   }

The markup is simple, I can post that if requested, but it's just a  
div with

a wicket:id tag.

Thanks in advance!



-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



ResourceReference not locale aware?

2009-06-17 Thread Roman Uhlig Maxity.de

I'm trying to load localized versions of an image with a
ResourceReference. The javadoc says:

The locale and/or style do not need to be set on a resource reference
because those values will automatically be determined based on the
context in which the resource is being used.

Actually, it does not. No matter what locale is set in the session,
ResourceReference is returning the same base version of the image when
used like that:

new Image(image, new ResourceReference(this.getClass(),
res/imagepack1/localized_testimage.gif));

res/imagepack1 contains the localized images as well, e.g.
localized_testimage_de.gif.

I'm using 1.4-rc4 right now. Am I doing something wrong or does it just
not work? 

Thanks for any hints on that,
Roman

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



AjaxFormSubmitBehavior throws an NullPointerException when the getForm() is overridden

2009-06-17 Thread zoltan luspai

Hi,


I have an AjaxFormSubmitBehavior where I don't pass the form parameter 
in the constructor, but have overridden the getForm() method to find the 
related form. (The form is not parent of the button this behavior is 
attached to, so can not be found by the behavior itself).



When I click on the button attached, the form is submitted nicely, but 
after the onSubmit call I get this exception:



java.lang.NullPointerException

   at 
org.apache.wicket.ajax.form.AjaxFormSubmitBehavior.onEvent(AjaxFormSubmitBehavior.java:142)
   at 
org.apache.wicket.ajax.AjaxEventBehavior.respond(AjaxEventBehavior.java:166)
   at 
org.apache.wicket.ajax.AbstractDefaultAjaxBehavior.onRequest(AbstractDefaultAjaxBehavior.java:299)
   at 
org.apache.wicket.request.target.component.listener.BehaviorRequestTarget.processEvents(BehaviorRequestTarget.java:113)
   at 
org.apache.wicket.request.AbstractRequestCycleProcessor.processEvents(AbstractRequestCycleProcessor.java:92)
   at 
org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:1240)

   at org.apache.wicket.RequestCycle.step(RequestCycle.java:1319)


Having a look at the source it seems there is a but at this line in 
AjaxFormSubmitBehavior:



   @Override
   protected void onEvent(AjaxRequestTarget target)
   {
   ...
   if (form.findParent(Page.class) != null)
   ...
   }

I think that should be :
   ... getForm().findParent(Page.class)


unless, there is a good reason not to be so?

Btw; I am using wicket version 1.4rc4.


Cheers

Zoltan



Re: AjaxEventBehavior onclick for WebMarkupContainer Precondition Check

2009-06-17 Thread walnutmon

Martin, 

I actually don't know how to get that dump, i'm using firefox, the error I
posted was from the AjaxDebugBox, any tips on getting the client side dump? 
I have firebug, but don't seem to see any JavaScript errors, although
admittedly I don't know anything about using it for JavaScript debugging.


Martin Funk-3 wrote:
 
 since the error is thrown on the browser side a dump of the generated  
 html source might be more helpful.
 
 try http://papernapkin.org/pastebin/home for posting that dump
 
 mf
 
 Am 17.06.2009 um 15:58 schrieb Justin Boyd:
 
 All,

 I have a simple application where I can change the size, position,  
 and color
 of a div within a page.  When I click on the div I want some  
 functionality
 to be performed, however the onclick event is never being returned  
 to the
 server, and is instead intercepted and rejected by the javascript, I  
 get the
 error
 Ajax GET stopped because of precondition check,
 url:;jsessionid=e80700c56cdf00f163ab8b7adb38?wicket:interface=: 
 0:superDiv::IBehaviorListener:0:

 HomePage.java -
 public class HomePage extends BasePage
 {

CompoundPropertyModelRectInfo rectInfoModel = new
 CompoundPropertyModelRectInfo(new RectInfo(100, 100, 400, 400,  
 blue));
WebMarkupContainer superDiv = new SuperDiv(superDiv,  
 rectInfoModel);

public HomePage(){
... form setup ...
superDiv.add(new AjaxEventBehavior(onmousedown)
{

@Override
protected void onEvent(AjaxRequestTarget target)
{
System.out.println(dicks);
}
});
add(superDiv.setOutputMarkupId(true));

}

private class SuperDiv extends WebMarkupContainer
{

IModelRectInfo rectInfoModel;

public SuperDiv(String id, IModelRectInfo rectInfoModel)
{
super(id);
this.rectInfoModel = rectInfoModel;
}

@Override
protected void onComponentTag(ComponentTag tag)
{
tag.put(style,
position: static; +
top:  + getModelObject().getTop() + ; +
left:  + getModelObject().getLeft() + ; +
height:  + getModelObject().getHeight() + ; +
width:  + getModelObject().getWidth() + ; +
background-color:  +  
 getModelObject().getColor() +
 ;);
}

public RectInfo getModelObject()
{
return rectInfoModel.getObject();
}

public void setModelObject(RectInfo rectInfo)
{
rectInfoModel.setObject(rectInfo);
}
}

 The markup is simple, I can post that if requested, but it's just a  
 div with
 a wicket:id tag.

 Thanks in advance!
 
 
 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 

-- 
View this message in context: 
http://www.nabble.com/AjaxEventBehavior-onclick-for-WebMarkupContainer-Precondition-Check-tp24074285p24075168.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: AjaxEventBehavior onclick for WebMarkupContainer Precondition Check

2009-06-17 Thread Martin Funk

ok, wrong wording on my side.

i meant the html source of the page in the browser.

mf

Am 17.06.2009 um 16:41 schrieb walnutmon:



Martin,

I actually don't know how to get that dump, i'm using firefox, the  
error I
posted was from the AjaxDebugBox, any tips on getting the client  
side dump?

I have firebug, but don't seem to see any JavaScript errors, although
admittedly I don't know anything about using it for JavaScript  
debugging.



Martin Funk-3 wrote:


since the error is thrown on the browser side a dump of the generated
html source might be more helpful.

try http://papernapkin.org/pastebin/home for posting that dump

mf

Am 17.06.2009 um 15:58 schrieb Justin Boyd:


All,

I have a simple application where I can change the size, position,
and color
of a div within a page.  When I click on the div I want some
functionality
to be performed, however the onclick event is never being returned
to the
server, and is instead intercepted and rejected by the javascript, I
get the
error
Ajax GET stopped because of precondition check,
url:;jsessionid=e80700c56cdf00f163ab8b7adb38?wicket:interface=:
0:superDiv::IBehaviorListener:0:

HomePage.java -
public class HomePage extends BasePage
{

  CompoundPropertyModelRectInfo rectInfoModel = new
CompoundPropertyModelRectInfo(new RectInfo(100, 100, 400, 400,
blue));
  WebMarkupContainer superDiv = new SuperDiv(superDiv,
rectInfoModel);

  public HomePage(){
  ... form setup ...
  superDiv.add(new AjaxEventBehavior(onmousedown)
  {

  @Override
  protected void onEvent(AjaxRequestTarget target)
  {
  System.out.println(dicks);
  }
  });
  add(superDiv.setOutputMarkupId(true));

  }

  private class SuperDiv extends WebMarkupContainer
  {

  IModelRectInfo rectInfoModel;

  public SuperDiv(String id, IModelRectInfo rectInfoModel)
  {
  super(id);
  this.rectInfoModel = rectInfoModel;
  }

  @Override
  protected void onComponentTag(ComponentTag tag)
  {
  tag.put(style,
  position: static; +
  top:  + getModelObject().getTop() + ; +
  left:  + getModelObject().getLeft() + ; +
  height:  + getModelObject().getHeight() + ; +
  width:  + getModelObject().getWidth() + ; +
  background-color:  +
getModelObject().getColor() +
;);
  }

  public RectInfo getModelObject()
  {
  return rectInfoModel.getObject();
  }

  public void setModelObject(RectInfo rectInfo)
  {
  rectInfoModel.setObject(rectInfo);
  }
  }

The markup is simple, I can post that if requested, but it's just a
div with
a wicket:id tag.

Thanks in advance!



-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org





--
View this message in context: 
http://www.nabble.com/AjaxEventBehavior-onclick-for-WebMarkupContainer-Precondition-Check-tp24074285p24075168.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org




-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: AjaxFormSubmitBehavior throws an NullPointerException when the getForm() is overridden

2009-06-17 Thread Erik van Oosten
Please file an issue in Jira, preferably with a quickstart to 
demonstrate the problem. A patch would be even better of course.


Regards,
   Erik.

zoltan luspai wrote:

Hi,


I have an AjaxFormSubmitBehavior where I don't pass the form parameter 
in the constructor, but have overridden the getForm() method to find 
the related form. (The form is not parent of the button this behavior 
is attached to, so can not be found by the behavior itself).



When I click on the button attached, the form is submitted nicely, 
but after the onSubmit call I get this exception:



java.lang.NullPointerException

   at 
org.apache.wicket.ajax.form.AjaxFormSubmitBehavior.onEvent(AjaxFormSubmitBehavior.java:142) 

   at 
org.apache.wicket.ajax.AjaxEventBehavior.respond(AjaxEventBehavior.java:166) 

   at 
org.apache.wicket.ajax.AbstractDefaultAjaxBehavior.onRequest(AbstractDefaultAjaxBehavior.java:299) 

   at 
org.apache.wicket.request.target.component.listener.BehaviorRequestTarget.processEvents(BehaviorRequestTarget.java:113) 

   at 
org.apache.wicket.request.AbstractRequestCycleProcessor.processEvents(AbstractRequestCycleProcessor.java:92) 

   at 
org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:1240) 


   at org.apache.wicket.RequestCycle.step(RequestCycle.java:1319)


Having a look at the source it seems there is a but at this line in 
AjaxFormSubmitBehavior:



   @Override
   protected void onEvent(AjaxRequestTarget target)
   {
   ...
   if (form.findParent(Page.class) != null)
   ...
   }

I think that should be :
   ... getForm().findParent(Page.class)


unless, there is a good reason not to be so?

Btw; I am using wicket version 1.4rc4.


Cheers

Zoltan





-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: AjaxEventBehavior onclick for WebMarkupContainer Precondition Check

2009-06-17 Thread walnutmon

!DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN
html
head
title/title
/head
body
form wicket:id=form
top: input type=text wicket:id=top/br/
left: input type=text wicket:id=left/br/
length: input type=text wicket:id=height/br/
width: input type=text wicket:id=width/br/
color: input type=text wicket:id=color/br/
input type=submit/
/form
div wicket:id=superDiv/div
/body
/html


Martin Funk-3 wrote:
 
 ok, wrong wording on my side.
 
 i meant the html source of the page in the browser.
 
 mf
 
 

-- 
View this message in context: 
http://www.nabble.com/AjaxEventBehavior-onclick-for-WebMarkupContainer-Precondition-Check-tp24074285p24076448.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: wicketstuff mini veil

2009-06-17 Thread Warren Bell

I don't know about the mini veil, but shouldn't your label and button be set up 
something like this:

In the class add a member that is your model string and then modify it in in 
the AjaxButton#onSubmit(...)

String modelString = 

...

final Label label = new Label(testLabel, new ModelString()
{

@Override
protected String getObject()
{
return modelString;
}

});

...

AjaxButton button = new AjaxButton(testVeil)

{
@Override
protected void onSubmit(AjaxRequestTarget arg0, Form? arg1)
{

modelString =  + new Random().nextLong();
arg0.addComponent(label);

}
}

I have not used setDefaultModelObject(...) before. I read that you shouldn't 
set a model object this way. Maybe that is causing a problem?


Warren


Jing Ge (Besitec IT DEHAM) wrote:
Hello, 


After doing this change, the project can be compiled and run. But I get
another problem.

Here is my test code:

final Label label = new Label(testLabel, new
ModelString());
  add(label);
  Form form = new Form(testForm);
AjaxButton button = new AjaxButton(testVeil) {

@Override
protected void onSubmit(AjaxRequestTarget arg0, Form?
arg1) {
try {
Thread.sleep(5000);
label.setDefaultModelObject( + new
Random().nextLong());
arg0.addComponent(label);
} catch (InterruptedException ex) {
 
Logger.getLogger(HomePage.class.getName()).log(Level.SEVERE, null, ex);

}
}
};
button.add(new Veil());
form.add(button);
add(form);

After the application is deployed and running, the ajax button is
disabled. Did I do something wrong? 


Best regards!
Jing Ge

-Original Message-
From: Jing Ge (Besitec IT DEHAM) [mailto:j...@besitec.com] 
Sent: Mittwoch, 17. Juni 2009 10:18

To: users@wicket.apache.org
Subject: RE: wicketstuff mini veil

Hello,

 


Should it be:

 


   super.bind(component);

   if (this.component != null) {

  .

   }

 


regards!

Jing Ge

 


-Original Message-
From: Jing Ge (Besitec IT DEHAM) [mailto:j...@besitec.com] 
Sent: Mittwoch, 17. Juni 2009 10:15

To: users@wicket.apache.org
Subject: wicketstuff mini veil

 


Hallo,

 

 

 


I have checked out the source code and taken a look at the class Veil. I

found the following code:

 

 

 


   public void bind(Component component)

 


   {

 


  super.bind(component);

 


  if (component != null)

 


  {

 


 throw new IllegalStateException(

 


  This behavior is

already bound to component. An instance of this behavior cannot be

reused between components. Bound component: 

 

 


+ this.component.toString());

 


  }

 


  this.component = component;

 


   }

 

 

 


From the code we can see, the component will be checked after binding.

If it is null, an exception will be thrown. 

 

 

 


Well, actually, I don't get it. Since the component can not be null

after binding, the exception will be always thrown. Show me if I am

wrong.

 

 

 


Has anyone ever used the mini veil? Could anyone give me hand? Thanks.

 

 

 


Best regards!

 


Jing Ge

 

 

 

 

 

 

 




-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org

  



--
Thanks,

Warren Bell
909-645-8864
warrenbe...@gmail.com


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Re: Re: Re: Re: DAO not getting injected, using springbean

2009-06-17 Thread Bruce McGuire

Hi James.

It turns out that I had 'userDAO' in one spot, and 'UserDAO' in another. 
Problem solved.


Thanks,

Bruce.

James Carman wrote:

Did you mark UserDAOHibernate with the @Repository annotation?

2009/6/16 Bruce McGuire br...@coastware.com:
  

Hi Vasu.

Thanks for the info. Now I get it, and have successfully wired my demo app
so that it does the job.

Although I did notice that along with the context:component-scan I did need
to define the beans that I was going to autowire. How did you get around
this?

  context:component-scan base-package=om.coastware /
  bean id=serDAO
class=om.coastware.vProbe.model.dao.hibernate.UserDAOHibernate /

Other than that, this is a very much reduced context file.

Now I need to duplicate this in my real application.

Thanks for everyone's help.

Bruce McGuire.

Vasu Srinivasan wrote:


Using annotations, I have only one line in the spring's
applicationContext.xml --

context:component-scan base-package=ackagename /

Services are tagged with @Service, Daos are tagged with
@Component(xxxDaoImpl), Wicket web pages have @SpringBean
(name=serviceName)

Within the ServiceImpl, the Daos are tagged with @Autowired.

No other xml config, setter, getter for daos etc.

Works like a charm.

2009/6/16 James Carman jcar...@carmanconsulting.com


  

You are correct.  You should only use @SpringBean in your wicket-related
code (components/pages).  Let Spring wire the rest together, however you
want to configure it to do that (with annotations or xml).  You can use
@Autowired to inject your DAOs into your Services.  You just have to make
sure you set up your Spring context so that it takes care of that.

On Tue, Jun 16, 2009 at 4:36 PM, Bruce McGuire br...@coastware.com
wrote:




Hello James.

So I have completely missed the point of the Repository, Service and
SpringBean annotations?  I was under the impression that the idea was to
avoid using a lot of xml in my context files.

If I am understanding correctly, what you and Martijn are saying is the
following:
Tag the dao and service classes with Repository and Service, and in

  

wicket



code, tag any use of them with SpringBean. However, in the service

  

classes,



use the normal xml injection method and get/set to get the dao into the
service class.

Is this a correct interpretation?

Thanks,

Bruce.

James Carman wrote:


  

You shouldn't use @SpringBean in your spring-managed beans, only in
your Wicket code.  You don't want view-specific code in your domain
code.

On Tue, Jun 16, 2009 at 4:17 PM, Bruce McGuire br...@coastware.com
wrote:





Hi Martijn.

Thanks for the quick response.

Are you saying that the dao and the service should have the
InjectorHolder code, rather than the @Repository and @Service tags?

Bruce.

Martijn Dashorst wrote:



  

@SpringBean only works with Components. For all other uses you should
either call InjectorHolder.getInjector().inject(this) in your
constructor or use Salve.

Martijn

On Tue, Jun 16, 2009 at 9:26 PM, Bruce McGuirebr...@coastware.com
wrote:






Hello.

I have created a new small project to try to figure out how to use

  

the



SpringBean, Service, and Repository annotations with Wicket, Spring,
Hibernate, Maven and Eclipse.

However, I am getting an error with a user DAO that I have created.

I have a service that is using the dao tagged as @Service, I have
the
DAO in
the service tagged with @SpringBean, and the DAO code itself is

  

tagged



with
@Repository.  The service that is using the DAO is getting found
correctly.

When I have the InjectorHolder code in the dao constructor, I get an
error
that says 'InjectorHolder has not been assigned an injector'

When I comment out the InjectorHolder line in the dao constructor,

  

the



DAO
is null, and getUserDAO throws an exception.

Since I am not certain that I can attach files, I will insert the
relevant
code and exceptions into this email.

Any pointers you can give would be greatly appreciated.

Thanks very very much,

Bruce.

UserServiceImpl
== @Service(UserService)
public class UserServiceImpl implements UserService
{
 @SpringBean
 UserDAO userDAO ;

 private UserDAO getUserDAO()
 {
   if (null =DAO)
   {
   throw new RuntimeException(userDAO is null) ;
   }

   return(userDAO) ;
 }

 @Override
 public ListUser getUsers()
 {
   return (getUserDAO().findAll());
 }
==
UserDAOHibernate
== @Repository(UserDAO)
public class UserDAOHibernate extends GenericDAOHibernateUser,

  

String



implements UserDAO
{
 private static Log log úctory.getLog(UserDAOHibernate);

 public UserDAOHibernate()
 {
   InjectorHolder.getInjector().inject(this);
 }

...
==
HomePage
== public class HomePage extends WebPage
{
 @SpringBean
 private UserService 

Re: AjaxEventBehavior onclick for WebMarkupContainer Precondition Check

2009-06-17 Thread Martin Funk

close, but no cigar
http://www.phrases.org.uk/meanings/close-but-no-cigar.html

not the html of the component or page that you created in the ide.
i think it might be helpful to see the html that the browser received.
in firefox there ought to be a menu item like: View - show  
Sourcecode (i'm using firefox with a german locale, so the naming  
might be slightly different)


mf


Am 17.06.2009 um 17:44 schrieb walnutmon:



!DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN
html
   head
   title/title
   /head
   body
   form wicket:id=form
   top: input type=text wicket:id=top/br/
   left: input type=text wicket:id=left/br/
   length: input type=text wicket:id=height/br/
   width: input type=text wicket:id=width/br/
   color: input type=text wicket:id=color/br/
   input type=submit/
   /form
   div wicket:id=superDiv/div
   /body
/html


Martin Funk-3 wrote:


ok, wrong wording on my side.

i meant the html source of the page in the browser.

mf




--
View this message in context: 
http://www.nabble.com/AjaxEventBehavior-onclick-for-WebMarkupContainer-Precondition-Check-tp24074285p24076448.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org




-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: AjaxEventBehavior onclick for WebMarkupContainer Precondition Check

2009-06-17 Thread walnutmon

Close but no donut, copper.  That occurred to me, but it was too late.  The
source doesn't seem to give much away, I do see the JavaScript on the Div
though.


!DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN
html
head
title/title
script type=text/javascript
src=resources/org.apache.wicket.markup.html.WicketEventReference/wicket-event.js/script
script type=text/javascript
src=resources/org.apache.wicket.ajax.WicketAjaxReference/wicket-ajax.js/script
script type=text/javascript
src=resources/org.apache.wicket.ajax.AbstractDefaultAjaxBehavior/wicket-ajax-debug.js/script
script type=text/javascript
id=wicket-ajax-debug-enable!--/*--![CDATA[/*!--*/
wicketAjaxDebugEnable=true;
/*--]]*//script

/head
body
form wicket:id=form id=form1 method=post
action=?wicket:interface=:0:form::IFormSubmitListener::div
style=display:noneinput type=hidden name=form1_hf_0 id=form1_hf_0
//div
top: input type=text wicket:id=top value=400
name=top/br/
left: input type=text wicket:id=left value=400
name=left/br/
length: input type=text wicket:id=height value=100
name=height/br/
width: input type=text wicket:id=width value=100
name=width/br/

color: input type=text wicket:id=color value=blue
name=color/br/
input type=submit/
/form
div wicket:id=superDiv style=position: static;top: 400;left:
400;height: 100;width: 100;background-color: blue; onmousedown=var
wcall=wicketAjaxGet('?wicket:interface=:0:superDiv::IBehaviorListener:0:',null,null,
function() {return Wicket.$('superDiv2') != null;}.bind(this));/div
/body
/html

Thanks again
-- 
View this message in context: 
http://www.nabble.com/AjaxEventBehavior-onclick-for-WebMarkupContainer-Precondition-Check-tp24074285p24078270.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Conversation scope in wicket

2009-06-17 Thread Joe Fawzy
Hi alli need to implement something like a conversation scope in wicket
i know that wicket is stateful by default and i can pass object o from page
A - page B
But if Object o in page A which - page B - page C - page D - page E
and i need Object o in page E ,that will be very tedious to pass o all
throught the way from A  ..E
also if i need to pass a large number of objects between a set of pages
,this will be a nightmare

so How can i implement a Conversation object ala Session and store these
objects there

i thought of using the IPageMap as a key in this situation as it represent
an open browser window or tab ie. conversation, but in a previous mail ,i
've been tald that it cannot be extended easily, and i cannot provide my own
factory for one

so, any ideas about the conversation scope?
what do u think about the pageMap ? will it work? is it reliable?
can the core team provide some hooks to implement something like
IPageMapFactory?

thanks
Joe


Re: AjaxEventBehavior onclick for WebMarkupContainer Precondition Check

2009-06-17 Thread Martin Funk

hm... lets see,

the JavaScript in the Browser complains since: function() {return  
Wicket.$('superDiv2') != null;}.bind(this))

returns false. (its the precondition)
It returns false since there is no dom element with the id 'superDiv2'  
in the page.

I assume its the id of the div elements, but the id is not rendered.
Which is strange since   add(superDiv.setOutputMarkupId(true)); got  
called.

Next shoot would be the overridden onComponentTag() method.
I'd say a call to super.onComponentTag() is needed.

Maybe that should be described more explicit in the JavaDoc.

mf

Am 17.06.2009 um 19:25 schrieb walnutmon:



Close but no donut, copper.  That occurred to me, but it was too  
late.  The
source doesn't seem to give much away, I do see the JavaScript on  
the Div

though.


!DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN
html
   head
   title/title
   script type=text/javascript
src=resources/org.apache.wicket.markup.html.WicketEventReference/ 
wicket-event.js/script

script type=text/javascript
src=resources/org.apache.wicket.ajax.WicketAjaxReference/wicket- 
ajax.js/script

script type=text/javascript
src=resources/org.apache.wicket.ajax.AbstractDefaultAjaxBehavior/ 
wicket-ajax-debug.js/script

script type=text/javascript
id=wicket-ajax-debug-enable!--/*--![CDATA[/*!--*/
wicketAjaxDebugEnable=true;
/*--]]*//script

/head
   body
   form wicket:id=form id=form1 method=post
action=?wicket:interface=:0:form::IFormSubmitListener::div
style=display:noneinput type=hidden name=form1_hf_0  
id=form1_hf_0

//div
   top: input type=text wicket:id=top value=400
name=top/br/
   left: input type=text wicket:id=left value=400
name=left/br/
   length: input type=text wicket:id=height value=100
name=height/br/
   width: input type=text wicket:id=width value=100
name=width/br/

   color: input type=text wicket:id=color value=blue
name=color/br/
   input type=submit/
   /form
   div wicket:id=superDiv style=position: static;top:  
400;left:

400;height: 100;width: 100;background-color: blue; onmousedown=var
wcall=wicketAjaxGet('?wicket:interface=: 
0:superDiv::IBehaviorListener:0:',null,null,
function() {return Wicket.$('superDiv2') != null;}.bind(this));/ 
div

   /body
/html

Thanks again
--
View this message in context: 
http://www.nabble.com/AjaxEventBehavior-onclick-for-WebMarkupContainer-Precondition-Check-tp24074285p24078270.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org




-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Conversation scope in wicket

2009-06-17 Thread Igor Vaynberg
class mysession extends websesison {
  private mapstring, mapobject,object coversations;

  public mapobject,object getconversation(ipagemap pmap) {
return conversations.get(pmap.getid());
  }
}

-igor

On Wed, Jun 17, 2009 at 10:29 AM, Joe Fawzyjoewic...@gmail.com wrote:
 Hi alli need to implement something like a conversation scope in wicket
 i know that wicket is stateful by default and i can pass object o from page
 A - page B
 But if Object o in page A which - page B - page C - page D - page E
 and i need Object o in page E ,that will be very tedious to pass o all
 throught the way from A  ..E
 also if i need to pass a large number of objects between a set of pages
 ,this will be a nightmare

 so How can i implement a Conversation object ala Session and store these
 objects there

 i thought of using the IPageMap as a key in this situation as it represent
 an open browser window or tab ie. conversation, but in a previous mail ,i
 've been tald that it cannot be extended easily, and i cannot provide my own
 factory for one

 so, any ideas about the conversation scope?
 what do u think about the pageMap ? will it work? is it reliable?
 can the core team provide some hooks to implement something like
 IPageMapFactory?

 thanks
 Joe


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: AjaxEventBehavior onclick for WebMarkupContainer Precondition Check

2009-06-17 Thread walnutmon

For the record, the call to super.onComponentTag(tag) fixed the issue.

Awesome catch Martin!



Martin Funk-3 wrote:
 
 hm... lets see,
 
 the JavaScript in the Browser complains since: function() {return  
 Wicket.$('superDiv2') != null;}.bind(this))
 returns false. (its the precondition)
 It returns false since there is no dom element with the id 'superDiv2'  
 in the page.
 I assume its the id of the div elements, but the id is not rendered.
 Which is strange since   add(superDiv.setOutputMarkupId(true)); got  
 called.
 Next shoot would be the overridden onComponentTag() method.
 I'd say a call to super.onComponentTag() is needed.
 
 Maybe that should be described more explicit in the JavaDoc.
 
 mf
 
 Am 17.06.2009 um 19:25 schrieb walnutmon:
 

 Close but no donut, copper.  That occurred to me, but it was too  
 late.  The
 source doesn't seem to give much away, I do see the JavaScript on  
 the Div
 though.


 !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN
 html
head
title/title
script type=text/javascript
 src=resources/org.apache.wicket.markup.html.WicketEventReference/ 
 wicket-event.js/script
 script type=text/javascript
 src=resources/org.apache.wicket.ajax.WicketAjaxReference/wicket- 
 ajax.js/script
 script type=text/javascript
 src=resources/org.apache.wicket.ajax.AbstractDefaultAjaxBehavior/ 
 wicket-ajax-debug.js/script
 script type=text/javascript
 id=wicket-ajax-debug-enable!--/*--![CDATA[/*!--*/
 wicketAjaxDebugEnable=true;
 /*--]]*//script

 /head
body
form wicket:id=form id=form1 method=post
 action=?wicket:interface=:0:form::IFormSubmitListener::div
 style=display:noneinput type=hidden name=form1_hf_0  
 id=form1_hf_0
 //div
top: input type=text wicket:id=top value=400
 name=top/br/
left: input type=text wicket:id=left value=400
 name=left/br/
length: input type=text wicket:id=height value=100
 name=height/br/
width: input type=text wicket:id=width value=100
 name=width/br/

color: input type=text wicket:id=color value=blue
 name=color/br/
input type=submit/
/form
div wicket:id=superDiv style=position: static;top:  
 400;left:
 400;height: 100;width: 100;background-color: blue; onmousedown=var
 wcall=wicketAjaxGet('?wicket:interface=: 
 0:superDiv::IBehaviorListener:0:',null,null,
 function() {return Wicket.$('superDiv2') != null;}.bind(this));/ 
 div
/body
 /html

 Thanks again
 -- 
 View this message in context:
 http://www.nabble.com/AjaxEventBehavior-onclick-for-WebMarkupContainer-Precondition-Check-tp24074285p24078270.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org

 
 
 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 

-- 
View this message in context: 
http://www.nabble.com/AjaxEventBehavior-onclick-for-WebMarkupContainer-Precondition-Check-tp24074285p24079175.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket-like JavaScript Components

2009-06-17 Thread Paolo Di Tommaso
Say your boss to engage more java developers ;)

-- p

On Tue, Jun 16, 2009 at 9:23 PM, Dane Laverty danelave...@gmail.com wrote:

 I'm currently the only Java programmer on staff, and I'm already
 maintaining
 two Wicket applications, so my boss is concerned that if I start a third
 project in Java that no one else will be able to maintain it. It's a
 reasonable concern, but kind of too bad nonetheless. I'm using JQuery as my
 main JS resource for the application. All of the business logic is managed
 through Ajax calls.

 On Tue, Jun 16, 2009 at 12:05 PM, Jeremy Thomerson 
 jer...@wickettraining.com wrote:

  Yeah - but I would guess that it wouldn't fit where I'm limited to
  using only JavaScript
 
  Out of curiosity - what do you mean where I'm limited to using only
  JavaScript?  I mean, can you use HTML?  What does this app do -
  obviously not much if it's only JS.  What does it tie in with to do
  business logic, etc?  Were these requirements written by a PHB?
 
  --
  Jeremy Thomerson
  http://www.wickettraining.com
 
 
 
 
  On Tue, Jun 16, 2009 at 11:56 AM, Nicolas
  Melendeznmelen...@getsense.com.ar wrote:
   GWT is a good framework.You can code in java and then it is translated
 to
   javascript.
   NM
  
   On Tue, Jun 16, 2009 at 4:05 PM, nino martinez wael 
   nino.martinez.w...@gmail.com wrote:
  
   You can also have a look at wicketstuff and see what integrations
   already exists :)
  
   2009/6/15 Dane Laverty danelave...@gmail.com:
I'm working on a small project where I'm limited to using only
   JavaScript. I
love the Wicket programming model, especially reusable components.
 Is
   anyone
aware of a JavaScript framework or JavaScript techniques that would
  allow
   me
to approximate Wicket components?
   
  
   -
   To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
   For additional commands, e-mail: users-h...@wicket.apache.org
  
  
  
 
  -
  To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
  For additional commands, e-mail: users-h...@wicket.apache.org
 
 



Usage DiskPageStore causes Session Swapping

2009-06-17 Thread rajendar medishetty
Hi,

In one of our application, we are facing session swapping problem when we
use DiskPageStore and this problem doesn't occur if we use HttpSessionStore.

Let me explain you in more detail.

This is policy Enrollment Application, we use Spring, Hibernate and Wicket
Frameworks.
We are using JDK serialization and the std SecondLevelCache/*DiskPageStore*
*session* store.

*Scenario:*
Application works fine, when we are using only one in one Browser window.
 It seems that when two users are using the system, second user is able to
see the first users data when he clicks back button.

*Analysis*:
Session id is different for both users, but while reading the page from the
disk it somehow reads the wrong page.

If I change the PageStore to HttpSessionStore, the same scenario works fine.


Any inputs on this issue will be helpful.

-- 
Thanks,
Rajendar


Re: Usage DiskPageStore causes Session Swapping

2009-06-17 Thread Matej Knopp
What wicket version are you using? DiskPageStore has separate folder
for each session so I don't really see why this would happen.

-Matej

On Wed, Jun 17, 2009 at 8:28 PM, rajendar
medishettyrajendar.medishe...@gmail.com wrote:
 Hi,

 In one of our application, we are facing session swapping problem when we
 use DiskPageStore and this problem doesn't occur if we use HttpSessionStore.

 Let me explain you in more detail.

 This is policy Enrollment Application, we use Spring, Hibernate and Wicket
 Frameworks.
 We are using JDK serialization and the std SecondLevelCache/*DiskPageStore*
 *session* store.

 *Scenario:*
 Application works fine, when we are using only one in one Browser window.
  It seems that when two users are using the system, second user is able to
 see the first users data when he clicks back button.

 *Analysis*:
 Session id is different for both users, but while reading the page from the
 disk it somehow reads the wrong page.

 If I change the PageStore to HttpSessionStore, the same scenario works fine.


 Any inputs on this issue will be helpful.

 --
 Thanks,
 Rajendar


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Conversation scope in wicket

2009-06-17 Thread Joe Fawzy
Hi dearthanks for the reply and for the code snippet
But, do u think that using pageMap is reliable or what
i mean , is using pageMap is a good solution or just a hack, work around
thanks
Joe

On Wed, Jun 17, 2009 at 8:58 PM, Igor Vaynberg igor.vaynb...@gmail.comwrote:

 class mysession extends websesison {
  private mapstring, mapobject,object coversations;

  public mapobject,object getconversation(ipagemap pmap) {
return conversations.get(pmap.getid());
  }
 }

 -igor

 On Wed, Jun 17, 2009 at 10:29 AM, Joe Fawzyjoewic...@gmail.com wrote:
  Hi alli need to implement something like a conversation scope in wicket
  i know that wicket is stateful by default and i can pass object o from
 page
  A - page B
  But if Object o in page A which - page B - page C - page D - page E
  and i need Object o in page E ,that will be very tedious to pass o all
  throught the way from A  ..E
  also if i need to pass a large number of objects between a set of pages
  ,this will be a nightmare
 
  so How can i implement a Conversation object ala Session and store these
  objects there
 
  i thought of using the IPageMap as a key in this situation as it
 represent
  an open browser window or tab ie. conversation, but in a previous mail ,i
  've been tald that it cannot be extended easily, and i cannot provide my
 own
  factory for one
 
  so, any ideas about the conversation scope?
  what do u think about the pageMap ? will it work? is it reliable?
  can the core team provide some hooks to implement something like
  IPageMapFactory?
 
  thanks
  Joe
 

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org




Re: Usage DiskPageStore causes Session Swapping

2009-06-17 Thread rajendar.medishetty


Initially we were using Wicket 1.3.3 and sometime back I upgraded to Wicket
1.3.5. I'm able to produce the scenario with both wicket versions.



Matej Knopp-2 wrote:
 
 What wicket version are you using? DiskPageStore has separate folder
 for each session so I don't really see why this would happen.
 
 -Matej
 
 On Wed, Jun 17, 2009 at 8:28 PM, rajendar
 medishettyrajendar.medishe...@gmail.com wrote:
 Hi,

 In one of our application, we are facing session swapping problem when we
 use DiskPageStore and this problem doesn't occur if we use
 HttpSessionStore.

 Let me explain you in more detail.

 This is policy Enrollment Application, we use Spring, Hibernate and
 Wicket
 Frameworks.
 We are using JDK serialization and the std
 SecondLevelCache/*DiskPageStore*
 *session* store.

 *Scenario:*
 Application works fine, when we are using only one in one Browser window.
  It seems that when two users are using the system, second user is able
 to
 see the first users data when he clicks back button.

 *Analysis*:
 Session id is different for both users, but while reading the page from
 the
 disk it somehow reads the wrong page.

 If I change the PageStore to HttpSessionStore, the same scenario works
 fine.


 Any inputs on this issue will be helpful.

 --
 Thanks,
 Rajendar

 
 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Usage-DiskPageStore-causes-Session-Swapping-tp24079378p24079732.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Conversation scope in wicket

2009-06-17 Thread Igor Vaynberg
if the scope of your conversation is a browser window then its the best choice.

-igor

On Wed, Jun 17, 2009 at 11:45 AM, Joe Fawzyjoewic...@gmail.com wrote:
 Hi dearthanks for the reply and for the code snippet
 But, do u think that using pageMap is reliable or what
 i mean , is using pageMap is a good solution or just a hack, work around
 thanks
 Joe

 On Wed, Jun 17, 2009 at 8:58 PM, Igor Vaynberg igor.vaynb...@gmail.comwrote:

 class mysession extends websesison {
  private mapstring, mapobject,object coversations;

  public mapobject,object getconversation(ipagemap pmap) {
        return conversations.get(pmap.getid());
  }
 }

 -igor

 On Wed, Jun 17, 2009 at 10:29 AM, Joe Fawzyjoewic...@gmail.com wrote:
  Hi alli need to implement something like a conversation scope in wicket
  i know that wicket is stateful by default and i can pass object o from
 page
  A - page B
  But if Object o in page A which - page B - page C - page D - page E
  and i need Object o in page E ,that will be very tedious to pass o all
  throught the way from A  ..E
  also if i need to pass a large number of objects between a set of pages
  ,this will be a nightmare
 
  so How can i implement a Conversation object ala Session and store these
  objects there
 
  i thought of using the IPageMap as a key in this situation as it
 represent
  an open browser window or tab ie. conversation, but in a previous mail ,i
  've been tald that it cannot be extended easily, and i cannot provide my
 own
  factory for one
 
  so, any ideas about the conversation scope?
  what do u think about the pageMap ? will it work? is it reliable?
  can the core team provide some hooks to implement something like
  IPageMapFactory?
 
  thanks
  Joe
 

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org




-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Usage DiskPageStore causes Session Swapping

2009-06-17 Thread Martijn Dashorst
I think we squashed a lingering thread local in 1.3.6 during request
detaching, which could cause this to happen.

Martijn

On Wed, Jun 17, 2009 at 8:52 PM, Matej Knoppmatej.kn...@gmail.com wrote:
 Latest  release in 1.3 branch is 1.3.6.

 -Matej

 On Wed, Jun 17, 2009 at 8:48 PM,
 rajendar.medishettyrajendar.medishe...@gmail.com wrote:


 Initially we were using Wicket 1.3.3 and sometime back I upgraded to Wicket
 1.3.5. I'm able to produce the scenario with both wicket versions.



 Matej Knopp-2 wrote:

 What wicket version are you using? DiskPageStore has separate folder
 for each session so I don't really see why this would happen.

 -Matej

 On Wed, Jun 17, 2009 at 8:28 PM, rajendar
 medishettyrajendar.medishe...@gmail.com wrote:
 Hi,

 In one of our application, we are facing session swapping problem when we
 use DiskPageStore and this problem doesn't occur if we use
 HttpSessionStore.

 Let me explain you in more detail.

 This is policy Enrollment Application, we use Spring, Hibernate and
 Wicket
 Frameworks.
 We are using JDK serialization and the std
 SecondLevelCache/*DiskPageStore*
 *session* store.

 *Scenario:*
 Application works fine, when we are using only one in one Browser window.
  It seems that when two users are using the system, second user is able
 to
 see the first users data when he clicks back button.

 *Analysis*:
 Session id is different for both users, but while reading the page from
 the
 disk it somehow reads the wrong page.

 If I change the PageStore to HttpSessionStore, the same scenario works
 fine.


 Any inputs on this issue will be helpful.

 --
 Thanks,
 Rajendar


 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org




 --
 View this message in context: 
 http://www.nabble.com/Usage-DiskPageStore-causes-Session-Swapping-tp24079378p24079732.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org



 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org





-- 
Become a Wicket expert, learn from the best: http://wicketinaction.com
Apache Wicket 1.3.5 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: AjaxEventBehavior onclick for WebMarkupContainer Precondition Check

2009-06-17 Thread Martin Funk


Am 17.06.2009 um 20:15 schrieb walnutmon:



For the record, the call to super.onComponentTag(tag) fixed the issue.

Awesome catch Martin!

Thank you,

your welcome. (and not to forget, I had my fun too)

mf





Martin Funk-3 wrote:


hm... lets see,

the JavaScript in the Browser complains since: function() {return
Wicket.$('superDiv2') != null;}.bind(this))
returns false. (its the precondition)
It returns false since there is no dom element with the id  
'superDiv2'

in the page.
I assume its the id of the div elements, but the id is not  
rendered.

Which is strange since   add(superDiv.setOutputMarkupId(true)); got
called.
Next shoot would be the overridden onComponentTag() method.
I'd say a call to super.onComponentTag() is needed.

Maybe that should be described more explicit in the JavaDoc.

mf

Am 17.06.2009 um 19:25 schrieb walnutmon:



Close but no donut, copper.  That occurred to me, but it was too
late.  The
source doesn't seem to give much away, I do see the JavaScript on
the Div
though.


!DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN
html
  head
  title/title
  script type=text/javascript
src=resources/org.apache.wicket.markup.html.WicketEventReference/
wicket-event.js/script
script type=text/javascript
src=resources/org.apache.wicket.ajax.WicketAjaxReference/wicket-
ajax.js/script
script type=text/javascript
src=resources/org.apache.wicket.ajax.AbstractDefaultAjaxBehavior/
wicket-ajax-debug.js/script
script type=text/javascript
id=wicket-ajax-debug-enable!--/*--![CDATA[/*!--*/
wicketAjaxDebugEnable=true;
/*--]]*//script

/head
  body
  form wicket:id=form id=form1 method=post
action=?wicket:interface=:0:form::IFormSubmitListener::div
style=display:noneinput type=hidden name=form1_hf_0
id=form1_hf_0
//div
  top: input type=text wicket:id=top value=400
name=top/br/
  left: input type=text wicket:id=left value=400
name=left/br/
  length: input type=text wicket:id=height value=100
name=height/br/
  width: input type=text wicket:id=width value=100
name=width/br/

  color: input type=text wicket:id=color value=blue
name=color/br/
  input type=submit/
  /form
  div wicket:id=superDiv style=position: static;top:
400;left:
400;height: 100;width: 100;background-color: blue; onmousedown=var
wcall=wicketAjaxGet('?wicket:interface=:
0:superDiv::IBehaviorListener:0:',null,null,
function() {return Wicket.$('superDiv2') != null;}.bind(this));/
div
  /body
/html

Thanks again
--
View this message in context:
http://www.nabble.com/AjaxEventBehavior-onclick-for-WebMarkupContainer-Precondition-Check-tp24074285p24078270.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org




-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org





--
View this message in context: 
http://www.nabble.com/AjaxEventBehavior-onclick-for-WebMarkupContainer-Precondition-Check-tp24074285p24079175.html
Sent from the Wicket - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org




-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Conversation scope in wicket

2009-06-17 Thread Joe Fawzy
thanks dearwill wicket continue to support pageMap beyond 1.4 or it is now a
deprecated feature?
thanks
Joe

On Wed, Jun 17, 2009 at 9:56 PM, Igor Vaynberg igor.vaynb...@gmail.comwrote:

 if the scope of your conversation is a browser window then its the best
 choice.

 -igor

 On Wed, Jun 17, 2009 at 11:45 AM, Joe Fawzyjoewic...@gmail.com wrote:
  Hi dearthanks for the reply and for the code snippet
  But, do u think that using pageMap is reliable or what
  i mean , is using pageMap is a good solution or just a hack, work around
  thanks
  Joe
 
  On Wed, Jun 17, 2009 at 8:58 PM, Igor Vaynberg igor.vaynb...@gmail.com
 wrote:
 
  class mysession extends websesison {
   private mapstring, mapobject,object coversations;
 
   public mapobject,object getconversation(ipagemap pmap) {
 return conversations.get(pmap.getid());
   }
  }
 
  -igor
 
  On Wed, Jun 17, 2009 at 10:29 AM, Joe Fawzyjoewic...@gmail.com wrote:
   Hi alli need to implement something like a conversation scope in
 wicket
   i know that wicket is stateful by default and i can pass object o from
  page
   A - page B
   But if Object o in page A which - page B - page C - page D - page
 E
   and i need Object o in page E ,that will be very tedious to pass o all
   throught the way from A  ..E
   also if i need to pass a large number of objects between a set of
 pages
   ,this will be a nightmare
  
   so How can i implement a Conversation object ala Session and store
 these
   objects there
  
   i thought of using the IPageMap as a key in this situation as it
  represent
   an open browser window or tab ie. conversation, but in a previous mail
 ,i
   've been tald that it cannot be extended easily, and i cannot provide
 my
  own
   factory for one
  
   so, any ideas about the conversation scope?
   what do u think about the pageMap ? will it work? is it reliable?
   can the core team provide some hooks to implement something like
   IPageMapFactory?
  
   thanks
   Joe
  
 
  -
  To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
  For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org




RE: 1.4 trunk broken?

2009-06-17 Thread Stefan Lindner
The problem occurs when I klicked around on a page an then deploy a new version 
of the app.
When I klick on a page link now then the error occurs. In former trunk versions 
and all former wicket version I was redirected to the application's homepage.

Stefan

-Ursprüngliche Nachricht-
Von: Johan Compagner [mailto:jcompag...@gmail.com] 
Gesendet: Dienstag, 16. Juni 2009 20:19
An: users@wicket.apache.org
Betreff: Re: 1.4 trunk broken?

i do remember one change for that invalidurlexception
(that we should throw that as an exception instead of just a page expired or
something)

On Tue, Jun 16, 2009 at 18:09, Stefan Lindner lind...@visionet.de wrote:

 Using current 1.4 trunk gives me the error

 [RequestCycle] org.apache.wicket.protocol.http.PageExpiredException:
 Cannot find the rendered page in session [pagemap=nu
 ll,componentPath=1,versionNumber=0]
 org.apache.wicket.protocol.http.request.InvalidUrlException:
 org.apache.wicket.protocol.http.PageExpiredException: Cannot find the
 rendered
 page in session [pagemap=null,componentPath=1,versionNumber=0]
at
 org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequ
 estCycleProcessor.java:250)
at org.apache.wicket.RequestCycle.step(RequestCycle.java:1301)
at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1419)
at org.apache.wicket.RequestCycle.request(RequestCycle.java:545)
at
 org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:456
 )
at
 org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:
 289)
at
 org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
 tionFilterChain.java:235)
at
 org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
 erChain.java:206)
at
 org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilte
 r.java:96)
at
 org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
 tionFilterChain.java:235)
at
 org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
 erChain.java:206)
at
 org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
 e.java:235)
at
 org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv
 e.java:191)
at
 org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAs
 sociationValve.java:190)
at
 org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.j
 ava:92)
at
 org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(
 SecurityContextEstablishmentValve.java:126)
at
 org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(S
 ecurityContextEstablishmentValve.java:70)
at
 org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java
 :127)
at
 org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java
 :102)
at
 org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConn
 ectionValve.java:158)
at
 org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.
 java:109)
at
 org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:3
 30)
at
 org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:82
 9)
at
 org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(
 Http11Protocol.java:598)
at
 org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:619)
 Caused by: org.apache.wicket.protocol.http.PageExpiredException: Cannot
 find the rendered page in session [pagemap=null,componentPath=1,vers
 ionNumber=0]
at
 org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequ
 estCycleProcessor.java:197)
... 25 more


 On loading a page. Did I miss some big change?

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org



-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Usage DiskPageStore causes Session Swapping

2009-06-17 Thread Matej Knopp
Latest  release in 1.3 branch is 1.3.6.

-Matej

On Wed, Jun 17, 2009 at 8:48 PM,
rajendar.medishettyrajendar.medishe...@gmail.com wrote:


 Initially we were using Wicket 1.3.3 and sometime back I upgraded to Wicket
 1.3.5. I'm able to produce the scenario with both wicket versions.



 Matej Knopp-2 wrote:

 What wicket version are you using? DiskPageStore has separate folder
 for each session so I don't really see why this would happen.

 -Matej

 On Wed, Jun 17, 2009 at 8:28 PM, rajendar
 medishettyrajendar.medishe...@gmail.com wrote:
 Hi,

 In one of our application, we are facing session swapping problem when we
 use DiskPageStore and this problem doesn't occur if we use
 HttpSessionStore.

 Let me explain you in more detail.

 This is policy Enrollment Application, we use Spring, Hibernate and
 Wicket
 Frameworks.
 We are using JDK serialization and the std
 SecondLevelCache/*DiskPageStore*
 *session* store.

 *Scenario:*
 Application works fine, when we are using only one in one Browser window.
  It seems that when two users are using the system, second user is able
 to
 see the first users data when he clicks back button.

 *Analysis*:
 Session id is different for both users, but while reading the page from
 the
 disk it somehow reads the wrong page.

 If I change the PageStore to HttpSessionStore, the same scenario works
 fine.


 Any inputs on this issue will be helpful.

 --
 Thanks,
 Rajendar


 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org




 --
 View this message in context: 
 http://www.nabble.com/Usage-DiskPageStore-causes-Session-Swapping-tp24079378p24079732.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org



-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Conversation scope in wicket

2009-06-17 Thread Igor Vaynberg
only time will tell

-igor

On Wed, Jun 17, 2009 at 11:59 AM, Joe Fawzyjoewic...@gmail.com wrote:
 thanks dearwill wicket continue to support pageMap beyond 1.4 or it is now a
 deprecated feature?
 thanks
 Joe

 On Wed, Jun 17, 2009 at 9:56 PM, Igor Vaynberg igor.vaynb...@gmail.comwrote:

 if the scope of your conversation is a browser window then its the best
 choice.

 -igor

 On Wed, Jun 17, 2009 at 11:45 AM, Joe Fawzyjoewic...@gmail.com wrote:
  Hi dearthanks for the reply and for the code snippet
  But, do u think that using pageMap is reliable or what
  i mean , is using pageMap is a good solution or just a hack, work around
  thanks
  Joe
 
  On Wed, Jun 17, 2009 at 8:58 PM, Igor Vaynberg igor.vaynb...@gmail.com
 wrote:
 
  class mysession extends websesison {
   private mapstring, mapobject,object coversations;
 
   public mapobject,object getconversation(ipagemap pmap) {
         return conversations.get(pmap.getid());
   }
  }
 
  -igor
 
  On Wed, Jun 17, 2009 at 10:29 AM, Joe Fawzyjoewic...@gmail.com wrote:
   Hi alli need to implement something like a conversation scope in
 wicket
   i know that wicket is stateful by default and i can pass object o from
  page
   A - page B
   But if Object o in page A which - page B - page C - page D - page
 E
   and i need Object o in page E ,that will be very tedious to pass o all
   throught the way from A  ..E
   also if i need to pass a large number of objects between a set of
 pages
   ,this will be a nightmare
  
   so How can i implement a Conversation object ala Session and store
 these
   objects there
  
   i thought of using the IPageMap as a key in this situation as it
  represent
   an open browser window or tab ie. conversation, but in a previous mail
 ,i
   've been tald that it cannot be extended easily, and i cannot provide
 my
  own
   factory for one
  
   so, any ideas about the conversation scope?
   what do u think about the pageMap ? will it work? is it reliable?
   can the core team provide some hooks to implement something like
   IPageMapFactory?
  
   thanks
   Joe
  
 
  -
  To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
  For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org




-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Apache Logs, Session IDs, and PageExpiredException

2009-06-17 Thread Jeremy Levy
We see a very similar issue: Between one request to another that happen
within a matter of seconds / minutes the sessionid disappears.  A lot of our
traffic is mobile so I assume some of it is crappy browser implementation.
  We have not been able to reproduce it any meaningful way.
We have been able to mitigate the effect on our
users by making as many pages as possible bookmarkable as well as
including cookie based auto-login.

I have seen other things cause this however, if you are using jvmRoute
with a node that is down and your don't properly fail over you will
consistently get this error.

For what it's worth we are using Wicket 1.3.6 (but been anecdotally having
the issue since 1.3.0 or earlier) in Tomcat/JBoss 4.2.2.

Jeremy





On Thu, Jun 11, 2009 at 4:31 PM, Dane Laverty danelave...@gmail.com wrote:

 Thanks for pointing that out. I've tried some other changes, so I'll wait
 and see how they work out. However, if the problem persists I'll look into
 the possibility of it being an HTTPS-related issue. That line of reasoning
 hadn't ever occurred to me.

 Dane

 On Thu, Jun 11, 2009 at 1:09 PM, Igor Vaynberg igor.vaynb...@gmail.com
 wrote:
 
  good catch Jason.
 
  We have also ran into this when implementing wicket's @RequireHttps
  annotation, there is a javadoc section in HttpsRequestCycleProtocol
  that talks about this cookie pain.
 
  -igor
 
  On Thu, Jun 11, 2009 at 1:03 PM, Jason Leaja...@kumachan.net.nz wrote:
   I notice there are some secure requests there (https)... so I will now
   blindly assume you are having the same problem I had in the past...
  
   I had a problem with session ids changing when trying to swtich between
   secure/insecure pages.
   If your first request to a tomcat server is secure, and a session is
   created, tomcat will create a secure session id cookie that will only
 be
   sent in https requests.  If you request a non-secure (http) page
 request
 it
   will not send the cookie, and a new insecure session cookie is created.
  
   One way to fix* this is to use a http request filter that checks for
 new
   session id cookie creation, and writing a new insecure cookie if a
 secure
   one has been created.  Something like this:
http://forum.springsource.org/archive/index.php/t-65651.html
  
   *when I say fix, I mean make the system less secure :)
  
   Igor Vaynberg wrote:
  
   yes, a changing sessionid will cause a page expired error because the
   client all of a sudden gets a new blank session.
  
   changing session ids can be caused by either session expiration or a
   manual session invalidation - like during a logout procedure.
  
   you have to figure out what causes the session to get dumped and a new
   one to be created in your application/servlet container.
  
   -igor
  
   On Thu, Jun 11, 2009 at 9:56 AM, Dane Lavertydanelave...@gmail.com
   wrote:
  
  
   I'm trying to track down the source of frequent PageExpiredExceptions
   that
   we're getting on our deployment server. One of the errors occured at
   01:28:06 this morning. In the Apache logs, I discovered that the
 user's
   session ID spontaneously changed at that time, (see the change
 between
   lines
   4  5 below, and then again between lines 11  12). Is that just a
   coincidence, or would a changing session ID cause the
   PageExpiredException?
   And if so, what causes the session ID to change? (I'm using Wicket
 1.3.6.
   I
   can't replicate the errors in development, which sounds common
 according
   to
   the several PageExpiredException threads. I'm not seeing any sort of
   serialization errors either.) Thanks for your help!
  
   XXX.XXX.29.22 - - [11/Jun/2009:01:28:03 -0700] GET
   /resources/comp.Comp/Oregon2.jpg HTTP/1.1 200 22145 
  
  

 https://www.foodhandler.org/login%3bjsessionid=E0381EA98B6C107CD1D4DF8FDE5D88C3
   ...
   XXX.XXX.29.22 - - [11/Jun/2009:01:28:03 -0700] GET
   /resources/comp.Comp/newVGrad.png HTTP/1.1 200 48736 
  
  

 https://www.foodhandler.org/login%3bjsessionid=E0381EA98B6C107CD1D4DF8FDE5D88C3
   ...
   XXX.XXX.29.22 - - [11/Jun/2009:01:28:03 -0700] GET
   /resources/comp.Comp/navBoxBottom.jpg HTTP/1.1 200 14140 
  
  

 https://www.foodhandler.org/login%3bjsessionid=E0381EA98B6C107CD1D4DF8FDE5D88C3
   ...
   XXX.XXX.29.22 - - [11/Jun/2009:01:28:05 -0700] GET
   /pay%3bjsessionid=E0381EA98B6C107CD1D4DF8FDE5D88C3 HTTP/1.1 302 -
 -...
   XXX.XXX.29.22 - - [11/Jun/2009:01:28:05 -0700] GET
   /foodhandler/login;jsessionid=271042707F280E26F7A08E6FFF108C22
 HTTP/1.1
   302
   263 -...
   XXX.XXX.29.22 - - [11/Jun/2009:01:28:05 -0700] GET
   /login%3bjsessionid=271042707F280E26F7A08E6FFF108C22 HTTP/1.1 200
 8056
   -...
   XXX.XXX.29.22 - - [11/Jun/2009:01:28:06 -0700] GET
   /resources/comp.Comp/main.css HTTP/1.1 200 9904 
  
  

 https://www.foodhandler.org/login%3bjsessionid=271042707F280E26F7A08E6FFF108C22
   ...
   XXX.XXX.29.22 - - [11/Jun/2009:01:28:06 -0700] GET
   /resources/comp.Comp/print.css HTTP/1.1 200 459 
  
  

 

inmethod trunk for a wicket app 1.3.6

2009-06-17 Thread Fernando Wermus
Hi all,
I put the following dependence in my pom:

dependency
groupIdorg.wicketstuff/groupId
artifactIdinmethod-grid/artifactId
version1.4-SNAPSHOT/version
/dependency

But my project is a wicket app 1.3.6. The wicketstuff page says that it
could work depending on the proyect. I would like to know if in the case of
inmethod I could use the trunk or I have to use an older version.

Thanks in advance!

-- 
Fernando Wermus.

www.linkedin.com/in/fernandowermus


Re: Apache Logs, Session IDs, and PageExpiredException

2009-06-17 Thread Igor Vaynberg
if your servlet container loses the session there isnt much we can do

-igor

On Wed, Jun 17, 2009 at 2:55 PM, Jeremy Levyjel...@gmail.com wrote:
 We see a very similar issue: Between one request to another that happen
 within a matter of seconds / minutes the sessionid disappears.  A lot of our
 traffic is mobile so I assume some of it is crappy browser implementation.
  We have not been able to reproduce it any meaningful way.
 We have been able to mitigate the effect on our
 users by making as many pages as possible bookmarkable as well as
 including cookie based auto-login.

 I have seen other things cause this however, if you are using jvmRoute
 with a node that is down and your don't properly fail over you will
 consistently get this error.

 For what it's worth we are using Wicket 1.3.6 (but been anecdotally having
 the issue since 1.3.0 or earlier) in Tomcat/JBoss 4.2.2.

 Jeremy





 On Thu, Jun 11, 2009 at 4:31 PM, Dane Laverty danelave...@gmail.com wrote:

 Thanks for pointing that out. I've tried some other changes, so I'll wait
 and see how they work out. However, if the problem persists I'll look into
 the possibility of it being an HTTPS-related issue. That line of reasoning
 hadn't ever occurred to me.

 Dane

 On Thu, Jun 11, 2009 at 1:09 PM, Igor Vaynberg igor.vaynb...@gmail.com
 wrote:
 
  good catch Jason.
 
  We have also ran into this when implementing wicket's @RequireHttps
  annotation, there is a javadoc section in HttpsRequestCycleProtocol
  that talks about this cookie pain.
 
  -igor
 
  On Thu, Jun 11, 2009 at 1:03 PM, Jason Leaja...@kumachan.net.nz wrote:
   I notice there are some secure requests there (https)... so I will now
   blindly assume you are having the same problem I had in the past...
  
   I had a problem with session ids changing when trying to swtich between
   secure/insecure pages.
   If your first request to a tomcat server is secure, and a session is
   created, tomcat will create a secure session id cookie that will only
 be
   sent in https requests.  If you request a non-secure (http) page
 request
 it
   will not send the cookie, and a new insecure session cookie is created.
  
   One way to fix* this is to use a http request filter that checks for
 new
   session id cookie creation, and writing a new insecure cookie if a
 secure
   one has been created.  Something like this:
    http://forum.springsource.org/archive/index.php/t-65651.html
  
   *when I say fix, I mean make the system less secure :)
  
   Igor Vaynberg wrote:
  
   yes, a changing sessionid will cause a page expired error because the
   client all of a sudden gets a new blank session.
  
   changing session ids can be caused by either session expiration or a
   manual session invalidation - like during a logout procedure.
  
   you have to figure out what causes the session to get dumped and a new
   one to be created in your application/servlet container.
  
   -igor
  
   On Thu, Jun 11, 2009 at 9:56 AM, Dane Lavertydanelave...@gmail.com
   wrote:
  
  
   I'm trying to track down the source of frequent PageExpiredExceptions
   that
   we're getting on our deployment server. One of the errors occured at
   01:28:06 this morning. In the Apache logs, I discovered that the
 user's
   session ID spontaneously changed at that time, (see the change
 between
   lines
   4  5 below, and then again between lines 11  12). Is that just a
   coincidence, or would a changing session ID cause the
   PageExpiredException?
   And if so, what causes the session ID to change? (I'm using Wicket
 1.3.6.
   I
   can't replicate the errors in development, which sounds common
 according
   to
   the several PageExpiredException threads. I'm not seeing any sort of
   serialization errors either.) Thanks for your help!
  
   XXX.XXX.29.22 - - [11/Jun/2009:01:28:03 -0700] GET
   /resources/comp.Comp/Oregon2.jpg HTTP/1.1 200 22145 
  
  

 https://www.foodhandler.org/login%3bjsessionid=E0381EA98B6C107CD1D4DF8FDE5D88C3
   ...
   XXX.XXX.29.22 - - [11/Jun/2009:01:28:03 -0700] GET
   /resources/comp.Comp/newVGrad.png HTTP/1.1 200 48736 
  
  

 https://www.foodhandler.org/login%3bjsessionid=E0381EA98B6C107CD1D4DF8FDE5D88C3
   ...
   XXX.XXX.29.22 - - [11/Jun/2009:01:28:03 -0700] GET
   /resources/comp.Comp/navBoxBottom.jpg HTTP/1.1 200 14140 
  
  

 https://www.foodhandler.org/login%3bjsessionid=E0381EA98B6C107CD1D4DF8FDE5D88C3
   ...
   XXX.XXX.29.22 - - [11/Jun/2009:01:28:05 -0700] GET
   /pay%3bjsessionid=E0381EA98B6C107CD1D4DF8FDE5D88C3 HTTP/1.1 302 -
 -...
   XXX.XXX.29.22 - - [11/Jun/2009:01:28:05 -0700] GET
   /foodhandler/login;jsessionid=271042707F280E26F7A08E6FFF108C22
 HTTP/1.1
   302
   263 -...
   XXX.XXX.29.22 - - [11/Jun/2009:01:28:05 -0700] GET
   /login%3bjsessionid=271042707F280E26F7A08E6FFF108C22 HTTP/1.1 200
 8056
   -...
   XXX.XXX.29.22 - - [11/Jun/2009:01:28:06 -0700] GET
   /resources/comp.Comp/main.css HTTP/1.1 200 9904 
  
  

 

Wicket Date Field Validation

2009-06-17 Thread Rao Archana (HCTM/ETA)
Hi,

I am working on date fields and have problems with the validation. I
have referred to the link below which helped me.

http://www.nabble.com/Strict-4-digit-year-for-DateTextField--td18656889.
html


So I have subclassed the PatternDateConverter and have set the pattern
as,
dateFormat = ^(\\d{1,2})/(\\d{1,2})/(\\d{4})$;

I have 2 date fields, start_date and end_date. The start_date is a
required field and the end_date is not.

 some code

pdc = new
StrictPatternDateConverter(DateUtil.getDateFormatOnLocale(getLocale()),
false);

 more code

startDateField = DateTextField.withConverter(startDate, new
PropertyModel(this, startDate), pdc);
startDateField.add(new TMPDatePicker());
form.add(startDateField);
endDateField = DateTextField.withConverter(endDate, new
PropertyModel(this, endDate), pdc);
endDateField.add(new TMPDatePicker());
form.add(endDateField);

 more code

This works fine ie it does not allow entry of 03/03/09 or
03/03/-2009

BUT, the end_date becomes a required field. I have to enter the end_date
to click 'Save'. Else it complains that an invalid date has been
entered.
But my end_date is not a required field.

So if I replace it with,

endDateField = DateTextField.forDatePattern(endDate,
DateUtil.getDateFormatOnLocale(getLocale()));
endDateField.withConverter(endDate, pdc);
endDateField.add(new TMPDatePicker());

It allows, 03/03/-2009 and 03/03/09. Why does it allow the '-' sign.
It computes it to a value and displays a year.

My application has several date fields and I need to validate them.

I am a newbie to Wicket and have looked up the archive quite a bit to
find a solution.
Can someone please tell me a solution to my date validation problem?

Thanks very much



Re: Conversation scope in wicket

2009-06-17 Thread Joe Fawzy
Hican this functionality added to the standard wicket?
actually much of seam popularity came from supporting conversation scope...,
so i think that adding explicit wicket support will have momentum
i think that having just a store for conversation objects will be a good
begin
then we may add apis like beginConversation, endConversation
,joinConversation,mergeConversation ,suspendConversation,resumeConversation
and other concepts like workspace
what do u think?
Joe


On Thu, Jun 18, 2009 at 12:32 AM, Igor Vaynberg igor.vaynb...@gmail.comwrote:

 only time will tell

 -igor

 On Wed, Jun 17, 2009 at 11:59 AM, Joe Fawzyjoewic...@gmail.com wrote:
  thanks dearwill wicket continue to support pageMap beyond 1.4 or it is
 now a
  deprecated feature?
  thanks
  Joe
 
  On Wed, Jun 17, 2009 at 9:56 PM, Igor Vaynberg igor.vaynb...@gmail.com
 wrote:
 
  if the scope of your conversation is a browser window then its the best
  choice.
 
  -igor
 
  On Wed, Jun 17, 2009 at 11:45 AM, Joe Fawzyjoewic...@gmail.com wrote:
   Hi dearthanks for the reply and for the code snippet
   But, do u think that using pageMap is reliable or what
   i mean , is using pageMap is a good solution or just a hack, work
 around
   thanks
   Joe
  
   On Wed, Jun 17, 2009 at 8:58 PM, Igor Vaynberg 
 igor.vaynb...@gmail.com
  wrote:
  
   class mysession extends websesison {
private mapstring, mapobject,object coversations;
  
public mapobject,object getconversation(ipagemap pmap) {
  return conversations.get(pmap.getid());
}
   }
  
   -igor
  
   On Wed, Jun 17, 2009 at 10:29 AM, Joe Fawzyjoewic...@gmail.com
 wrote:
Hi alli need to implement something like a conversation scope in
  wicket
i know that wicket is stateful by default and i can pass object o
 from
   page
A - page B
But if Object o in page A which - page B - page C - page D -
 page
  E
and i need Object o in page E ,that will be very tedious to pass o
 all
throught the way from A  ..E
also if i need to pass a large number of objects between a set of
  pages
,this will be a nightmare
   
so How can i implement a Conversation object ala Session and store
  these
objects there
   
i thought of using the IPageMap as a key in this situation as it
   represent
an open browser window or tab ie. conversation, but in a previous
 mail
  ,i
've been tald that it cannot be extended easily, and i cannot
 provide
  my
   own
factory for one
   
so, any ideas about the conversation scope?
what do u think about the pageMap ? will it work? is it reliable?
can the core team provide some hooks to implement something like
IPageMapFactory?
   
thanks
Joe
   
  
   -
   To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
   For additional commands, e-mail: users-h...@wicket.apache.org
  
  
  
 
  -
  To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
  For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org




Re: Conversation scope in wicket

2009-06-17 Thread James Carman
There are a few folks working on implementing JSR-299 support for Wicket,
which would provide support for conversation-scoped beans.  I'm working on
one currently and I believe that the jboss folks have one working too.

On Thu, Jun 18, 2009 at 12:08 AM, Joe Fawzy joewic...@gmail.com wrote:

 Hican this functionality added to the standard wicket?
 actually much of seam popularity came from supporting conversation
 scope...,
 so i think that adding explicit wicket support will have momentum
 i think that having just a store for conversation objects will be a good
 begin
 then we may add apis like beginConversation, endConversation
 ,joinConversation,mergeConversation ,suspendConversation,resumeConversation
 and other concepts like workspace
 what do u think?
 Joe


 On Thu, Jun 18, 2009 at 12:32 AM, Igor Vaynberg igor.vaynb...@gmail.com
 wrote:

  only time will tell
 
  -igor
 
  On Wed, Jun 17, 2009 at 11:59 AM, Joe Fawzyjoewic...@gmail.com wrote:
   thanks dearwill wicket continue to support pageMap beyond 1.4 or it is
  now a
   deprecated feature?
   thanks
   Joe
  
   On Wed, Jun 17, 2009 at 9:56 PM, Igor Vaynberg 
 igor.vaynb...@gmail.com
  wrote:
  
   if the scope of your conversation is a browser window then its the
 best
   choice.
  
   -igor
  
   On Wed, Jun 17, 2009 at 11:45 AM, Joe Fawzyjoewic...@gmail.com
 wrote:
Hi dearthanks for the reply and for the code snippet
But, do u think that using pageMap is reliable or what
i mean , is using pageMap is a good solution or just a hack, work
  around
thanks
Joe
   
On Wed, Jun 17, 2009 at 8:58 PM, Igor Vaynberg 
  igor.vaynb...@gmail.com
   wrote:
   
class mysession extends websesison {
 private mapstring, mapobject,object coversations;
   
 public mapobject,object getconversation(ipagemap pmap) {
   return conversations.get(pmap.getid());
 }
}
   
-igor
   
On Wed, Jun 17, 2009 at 10:29 AM, Joe Fawzyjoewic...@gmail.com
  wrote:
 Hi alli need to implement something like a conversation scope in
   wicket
 i know that wicket is stateful by default and i can pass object o
  from
page
 A - page B
 But if Object o in page A which - page B - page C - page D -
  page
   E
 and i need Object o in page E ,that will be very tedious to pass
 o
  all
 throught the way from A  ..E
 also if i need to pass a large number of objects between a set of
   pages
 ,this will be a nightmare

 so How can i implement a Conversation object ala Session and
 store
   these
 objects there

 i thought of using the IPageMap as a key in this situation as it
represent
 an open browser window or tab ie. conversation, but in a previous
  mail
   ,i
 've been tald that it cannot be extended easily, and i cannot
  provide
   my
own
 factory for one

 so, any ideas about the conversation scope?
 what do u think about the pageMap ? will it work? is it reliable?
 can the core team provide some hooks to implement something like
 IPageMapFactory?

 thanks
 Joe

   
   
 -
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org
   
   
   
  
   -
   To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
   For additional commands, e-mail: users-h...@wicket.apache.org
  
  
  
 
  -
  To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
  For additional commands, e-mail: users-h...@wicket.apache.org
 
 



Re: Conversation scope in wicket

2009-06-17 Thread Igor Vaynberg
you are free to implement this as an open source addition to wicket.
there is wicketstuff or googlecode or sf.net where you can host it.

wicket is a ui framework and conversational scope management falls
outside wicket's scope. it is our job to provide the hooks to make
such things possible, not to provide an implementation.

-igor

On Wed, Jun 17, 2009 at 9:36 PM, Joe Fawzyjoewic...@gmail.com wrote:
 Hiyou mean: injecting webbeans conversation component in wicket component at
 construction time
 this is only what we can achieve with webbeans, as wicket component cannot
 be webbeans components (wicket is unmanaged framework)
 my idea is about native conversation support, which enable wicket component
 to be the component and the target for injection in a natural wicket way
 beside, why depending on external project when we have all the functionality
 we need as wicket is stateful and each pagemap is a conversation(long one
 which may be easily break down to smaller pieces)

 Joe


 On Thu, Jun 18, 2009 at 7:22 AM, James Carman
 jcar...@carmanconsulting.comwrote:

 There are a few folks working on implementing JSR-299 support for Wicket,
 which would provide support for conversation-scoped beans.  I'm working on
 one currently and I believe that the jboss folks have one working too.

 On Thu, Jun 18, 2009 at 12:08 AM, Joe Fawzy joewic...@gmail.com wrote:

  Hican this functionality added to the standard wicket?
  actually much of seam popularity came from supporting conversation
  scope...,
  so i think that adding explicit wicket support will have momentum
  i think that having just a store for conversation objects will be a good
  begin
  then we may add apis like beginConversation, endConversation
  ,joinConversation,mergeConversation
 ,suspendConversation,resumeConversation
  and other concepts like workspace
  what do u think?
  Joe
 
 
  On Thu, Jun 18, 2009 at 12:32 AM, Igor Vaynberg igor.vaynb...@gmail.com
  wrote:
 
   only time will tell
  
   -igor
  
   On Wed, Jun 17, 2009 at 11:59 AM, Joe Fawzyjoewic...@gmail.com
 wrote:
thanks dearwill wicket continue to support pageMap beyond 1.4 or it
 is
   now a
deprecated feature?
thanks
Joe
   
On Wed, Jun 17, 2009 at 9:56 PM, Igor Vaynberg 
  igor.vaynb...@gmail.com
   wrote:
   
if the scope of your conversation is a browser window then its the
  best
choice.
   
-igor
   
On Wed, Jun 17, 2009 at 11:45 AM, Joe Fawzyjoewic...@gmail.com
  wrote:
 Hi dearthanks for the reply and for the code snippet
 But, do u think that using pageMap is reliable or what
 i mean , is using pageMap is a good solution or just a hack, work
   around
 thanks
 Joe

 On Wed, Jun 17, 2009 at 8:58 PM, Igor Vaynberg 
   igor.vaynb...@gmail.com
wrote:

 class mysession extends websesison {
  private mapstring, mapobject,object coversations;

  public mapobject,object getconversation(ipagemap pmap) {
        return conversations.get(pmap.getid());
  }
 }

 -igor

 On Wed, Jun 17, 2009 at 10:29 AM, Joe Fawzyjoewic...@gmail.com
   wrote:
  Hi alli need to implement something like a conversation scope
 in
wicket
  i know that wicket is stateful by default and i can pass object
 o
   from
 page
  A - page B
  But if Object o in page A which - page B - page C - page D
 -
   page
E
  and i need Object o in page E ,that will be very tedious to
 pass
  o
   all
  throught the way from A  ..E
  also if i need to pass a large number of objects between a set
 of
pages
  ,this will be a nightmare
 
  so How can i implement a Conversation object ala Session and
  store
these
  objects there
 
  i thought of using the IPageMap as a key in this situation as
 it
 represent
  an open browser window or tab ie. conversation, but in a
 previous
   mail
,i
  've been tald that it cannot be extended easily, and i cannot
   provide
my
 own
  factory for one
 
  so, any ideas about the conversation scope?
  what do u think about the pageMap ? will it work? is it
 reliable?
  can the core team provide some hooks to implement something
 like
  IPageMapFactory?
 
  thanks
  Joe
 


  -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org



   
   
 -
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org
   
   
   
  
   -
   To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
   For additional commands, e-mail: users-h...@wicket.apache.org
  
  
 




Re: Conversation scope in wicket

2009-06-17 Thread James Carman
On Thu, Jun 18, 2009 at 12:38 AM, Igor Vaynberg igor.vaynb...@gmail.com wrote:

 you are free to implement this as an open source addition to wicket.
 there is wicketstuff or googlecode or sf.net where you can host it.

 wicket is a ui framework and conversational scope management falls
 outside wicket's scope. it is our job to provide the hooks to make
 such things possible, not to provide an implementation.

And, those hooks are very nice.  I would only ask for some more
listener registering opportunities (like for listening to request
cycle events like begin/end rather than having to implement your own
request cycle).

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Conversation scope in wicket

2009-06-17 Thread Igor Vaynberg
jira it up.

-igor

On Wed, Jun 17, 2009 at 9:44 PM, James
Carmanjcar...@carmanconsulting.com wrote:
 On Thu, Jun 18, 2009 at 12:38 AM, Igor Vaynberg igor.vaynb...@gmail.com 
 wrote:

 you are free to implement this as an open source addition to wicket.
 there is wicketstuff or googlecode or sf.net where you can host it.

 wicket is a ui framework and conversational scope management falls
 outside wicket's scope. it is our job to provide the hooks to make
 such things possible, not to provide an implementation.

 And, those hooks are very nice.  I would only ask for some more
 listener registering opportunities (like for listening to request
 cycle events like begin/end rather than having to implement your own
 request cycle).

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org



-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org