Search Results

Search found 2 results on 1 pages for 'mschayna'.

Page 1/1 | 1 

  • Wicket: stateless AJAX behaviors in stateful page without serialization

    - by mschayna
    I have pretty stateful page with plenty of AJAX components. Most of these components have behaviors, which renders JavaScript code for calling AJAX requests to Java code. Because page isn't stateless, each request causes serialization of page. So far so good. But some of these AJAX requests doesn't change page ever, so serialization of page isn't necessary. For example it is forward caching data for (home-brewed) datagrid component. These requests are calling continuously and serialization of page during each request causes delays. There are some projects for stateless wicket components out there, e.g. wicket-stateless, but it solves another situation -- request of stateless components are processed on new instances of stateless pages. I want to process requests on existing stateful page instance but without serialization. I have tried to implement this in my own RequestCycleProcessor.resolve(), but I hung on searching for page from requestParameters because Session.getPage() always touches page and it causes serialization after request processing. Is there any example, idea, whatever for implementing this in Wicket? Hope it's understandable :)

    Read the article

  • Java: Set<E> collection, where items are identified by its class

    - by mschayna
    I need Set collection, where its items will be identified by items class. Something like ReferenceIdentityMap from Appache Collections, but on class scope i.e. two different instances of same class must be identified as same in this collection. You know, it is a violation of equals()/hashCode() identity principle but in occasional use it makes sense. I have done this in simple class backing with Map<Class<? extends E>, E>, but due to simplicity it doesn't implement Set<E>. There may be a more elegant solution, decorator of any Set<E> would be great. Is there any implementation of such collection there (Apache/Google/something/... Collections)?

    Read the article

1