Martin Grigorov commented:
https://gist.github.com/dashorst/6308833/#comment-892138
> > org.apache.wicket.request.resource.IResource#respond
> At the moment one could have:
>
> - a stateless resource - the mounted resource reference create a new
>   IResource for each request
>
> - a stateful resource - the mounted reference reused the same
>   resource
>
> In both cases IResource#respond() receives IResource.Attributes
> with the current Request, Response and PageParameters.
>
> Do you imagine how the new way will be applied here ?

I haven't looked at resources yet, but the idea that resources
recieve *current* request, response and PageParameters is something
I'd like to extend to pages as well: have stateful pages be able to
respond to updated request parameters.

As for shared resources, we have to ensure that we don't inject
parameters into the instance (similar to JAX-RS prohibiting injection
into Singletons).

I like the resources Andrea has created in his
wicketstuff-restannotations project. Will have to take a closer look
to incorporate it into Wicket, quite possibly in this RFC.

Is this what you were looking for-albeit not complete/finished?

Martijn

Reply via email to