[Grok-dev] Re: BrowserView versus BrowserPage

Jan-Wijbrand Kolman janwijbrand at gmail.com
Wed Jun 27 09:55:31 EDT 2007


On 6/27/07, Martijn Faassen <faassen at startifact.com> wrote:
> Jan-Wijbrand Kolman wrote:
> > I guess this topic has been discussed before, but I suddenly wonder:
> >
> > Why does grok "only" provide for a "BrowserPage" type of view (via
> > grok.View) and not also a BrowserView type of view? I can imagine
> > having had both a grok.View() implementing IBrowserView and a
> > grok.Page() implementing IBrowserPage.
>
> You say 'grok.View()' and 'grok.Page()' with the '()' there, but these
> would be base classes, right?

Yes. My notation is confusing.

> Yes, Philipp brought this up in the past. I see the point. Making the
> change would require quite a lot of changes in documentation and
> people's code, however. Additionally, we use grok.View for things that
> aren't really pages such as page fragments and file downloads - the word
> 'Page' may sit a bit less well.
>
> I'm not against trying to move forward with this, but we'd need a pretty
> good plan on how to accomplish this first. We need an analysis of what
> grok.View is going to be for exactly. I'm a bit worried we'll give up
> such a general name as 'View' for use cases that occur infrequently.
> Suggestions would be very welcome.

I see the implications. I think if we would have started out with
grok.Page for what now is grok.View, it would have sat quite well. But
well, we cannot change that now anymore,  I certainly agree there.

The first thoughts I had just before bringing up this issue, was to
suggest something like grok.SimpleView or grok.BaseView or maybe even
grok.NonBrowserView. The general case will not change then.

Also, it is certainly possible of course to just register a
multiadapter providing IBrowserView for the case you need it.


kind regard,
jw

-- 
Jan-Wijbrand Kolman


More information about the Grok-dev mailing list