7191556: (fs) UnixNativeDispatcher.getextmntent should be moved into platform specific code

Andrew Hughes ahughes at redhat.com
Wed Aug 15 11:29:28 PDT 2012


----- Original Message -----
> On 15/08/2012 15:18, Andrew Hughes wrote:
> > :
> > This looks good to me and built ok here.
> >
> > My only concern is that this now means that Macs now always get a
> > null
> > file type detector, whereas there might have been a working one if
> > glib
> > was installed.  The name "GNOMEFileTypeDetector" is a bit of a
> > misnomer
> > as GIO is part of glib, which is intentionally multi-platform (even
> > Windows,
> > I believe).
> >
> > Maybe worth asking on the BSD and Mac lists?  It might motivate
> > them to provide
> > a solution using the native Mac API (assuming there is one) ;-)
> >
> > Thanks,
> Thanks Andrew.
> 
> There are a few things still missing on Mac, a FileTypeDetector is
> one.
> I don't know common it is to have GIO on the Mac but I would prefer
> that
> there would be separate change-set to add support for file type
> detector
> on the Mac (if that's okay with you). Once there is an implementation
> then it would plug-in by overriding getFileTypeDetector in
> MacOSXFileSystemProvider.

It's ok by me.  I'm not sure how common it is either (fairly rare I would
have thought).  I would guess it's much more common on *BSD (it's certainly
in FreeBSD's ports, as is GNOME), but that platform doesn't seem to be supported
anyway.  FileSystemProvider's create method will throw an AssertionError rather
than returning the provider, which seems to be there just as a base for the MacOS X
one.

> 
> On GnomeFileTypeDetector then it is so named because it started out
> by
> using GNOME VFS, it got GIO support later. It should probably be
> separated out now. Maybe this is something you would like to take on?
> 

Sure.  It's not so much of an issue with NIO, but GIO/Glib will also need to be used
to replace GConf in sun.net.spi.DefaultProxySelector, so perhaps it's worth seeing
the two could be unified in some way, rather than having a search for GIO at two
different places in the codebase.

> -Alan
> 

-- 
Andrew :)

Free Java Software Engineer
Red Hat, Inc. (http://www.redhat.com)

PGP Key: 248BDC07 (https://keys.indymedia.org/)
Fingerprint = EC5A 1F5E C0AD 1D15 8F1F  8F91 3B96 A578 248B DC07



More information about the nio-dev mailing list