[webkit-dev] How loading a frame ought to work
darin at apple.com
Tue Oct 13 15:00:02 PDT 2009
On Oct 13, 2009, at 2:10 PM, Adam Barth wrote:
> The word "policy" is very overloaded here. For example, the third-
> party cookie blocking logic used to speak about policy URLs.
I may have overused the term “policy” in my mail. I think that
generally speaking, the things that ought to be called “policies” in
the loader are the questions that are asked asynchronously that
correspond to the methods of the WebPolicyDelegate in the Mac OS X
> In general, FrameLoader does a bunch of work to scroll the
> document's view to a fragment, but that work doesn't seem related to
> transitioning between documents. Maybe that's a better part to break
> off first.
Sure, that part at least is clearly separable, but the question in my
mind would be where to put it.
>>> B) LoadObserver. Currently ResourceLoader forwards many of the
>>> network stack callbacks (e.g., ResourceLoader::didReceiveResponse)
>>> to FrameLoader so they can be farmed out to the Web Inspector,
>>> ProgressTracker, FrameLoaderClient, and others. The goal of this
>>> object is to remove that complexity from FrameLoader.
>> There is a distinction between resource load client calls and
>> higher level load client calls. The resource load client calls are
>> the ones that use a request identifier. And these are indeed all
>> about the resource loader.
>> But many other client calls do not involve the resource loader
>> directly. If you don’t plan to make the LoadObserver responsible
>> for these, then I think it should probably be called the
>> ResourceLoadObserver, since it observes the lower level loading of
>> resources but not the higher level loading of web pages.
>> I’m also not entirely sure if “observer” is the right name here,
>> but I have nothing better to suggest at this time.
> The block of methods I was think of are the ones that take a
> ResourceLoader as a parameter:
Good, yes, those are the functions that use a request identifier that
I mentioned above.
> The general workflow seems to be that FrameLoader translates calls
> of the first kind into calls of the second kind and then notifies a
> bunch of folks that the callback happened. Maybe
> ResourceLoadNotifier is a better name because the object is not
> consuming the notifications but instead routing them to the
> interested objects.
I do like that name.
More information about the webkit-dev