Re: Windows and .url files and nsILocalFileWin

Darin Fisher <[email protected]> Thu, 20 Nov 2003 22:38:48 -0800
Newsgroups gmane.comp.mozilla.devel.netlib,gmane.comp.mozilla.devel.xpcom
Message-ID <[email protected]>
Christian Biesinger wrote:

> Christian Biesinger wrote:
>
>> So this really should not be in a win32-specific file.
>
>
> OK. New proposal.
>
> On nsIFileProtocolHandler:
>
>     nsIURI readURLFile(in nsILocalFile file);
>
> nsIURI is not really what the two current callers want... (my new 
> caller does want it though) however it seems like a better idea to me 
> - darin keeps saying that string representations of an uri are lossy :)
>
> and it's easy to get a string from an nsIURI.
>
> This method would throw NS_ERROR_NOT_AVAILABLE on platforms not 
> supporting url files, I guess. I prefer not to use NOT_IMPLEMENTED 
> because that sounds to me like it would ever be implemented. I can use 
> it though if people want me to.
>

I like this plan.  I'm not picky about the error codes.

Darin