On 5 Mar 2013, at 14:46, E R <pc88m...@gmail.com> wrote: > My use case is that I am developing a second view class, but it can't handle > all of the templates yet. So the logic I am putting into the end method is: > > if (View2 can handle template $c->stash->{template}) { > $c->stash->{current_view} = 'View2'; > } > > This way I can incrementally test View2 as I add capabilities to it.
aha! I'd handle this with a 3rd view, which just delegates to the 2nd view, then the 1st if the newer view doesn't like it.. This separates the 'do I call a view at all' logic - which you're happy with Catalyst's handling of, from the 'which of my views do I delegate to from _this request_' handling - which needs to be your own logic.. Cheers t0m _______________________________________________ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/