You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Martin Grigorov (JIRA)" <ji...@apache.org> on 2016/03/09 18:34:40 UTC
[jira] [Assigned] (WICKET-6113) Improve ResourceStreamResource api
[ https://issues.apache.org/jira/browse/WICKET-6113?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Martin Grigorov reassigned WICKET-6113:
---------------------------------------
Assignee: Martin Grigorov
> Improve ResourceStreamResource api
> ----------------------------------
>
> Key: WICKET-6113
> URL: https://issues.apache.org/jira/browse/WICKET-6113
> Project: Wicket
> Issue Type: Improvement
> Components: wicket
> Reporter: Jonas
> Assignee: Martin Grigorov
> Priority: Minor
>
> I'd like to propose an improvement of org.apache.wicket.request.resource.ResourceStreamResource: it is currently quite hard to determine the IResourceStream inside the #getResourceStream method, as the relevant context (i.e. the Attributes object) isn't available. Of course it is possible to override #newResourceResponse to get access to Attributes, but the resulting code feels quite clumsy. I propose to pass the Attributes from #newResourceResponse into #internalGetResourceStream and finally into #getResourceStream.
> This of course breaks the current API, so I guess this would be something
> for Wicket 8.
> To put this in context, what we're doing is basically described in
> http://wicketinaction.com/2011/07/wicket-1-5-mounting-resources/ , except
> we don't extend DynamicImageResource, where you would have to handle mime
> type etc. in your subclass. By extending ResourceStreamResource, mime type
> etc. is handled by automatically.
> (Corresponding mailing list thread:
> http://apache-wicket.1842946.n4.nabble.com/Improve-ResourceStreamResource-api-td4673761.html )
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)