Need review for 6873621: (file) FileStore.supportsFileAttributeView(Class<FileAttributeView> type) returns wrong result

Mark Thornton mthornton at
Fri Sep 4 06:49:23 PDT 2009

Andrew John Hughes wrote:
> 2009/9/4 Alan Bateman <Alan.Bateman at>:
>> I need a reviewer for this one - it's very simple.
>> FileStore.supportsFileAttributeView(Class<? extends FileAttributeView>)
>> should return true if the file store supports the given file attribute view.
>> The method needs to be overridden in the Solaris and Linux implementations
>> so that it returns the right answer for the more specialized views. Also,
>> the Windows implementation is missing one case. The webrev is here:
>> Thanks,
>> Alan.
> Looks good to me.  I like the idea of making this safer by checking
> against a type rather than an arbitrary String.  This also makes these
> classes match UnixFileStore which already does this for the
> PosixFileAttributeView.
> As an aside, I noticed that Solaris is the only implementation to use
> AclFileAttributeView.  Don't both Linux and Windows have some form of
> ACL support?  Something to fix long term I guess.
AclFileAttributeView *is* in the Windows implementation:

 158         if (type == AclFileAttributeView.class || type == FileOwnerAttributeView.class)
 159             return ((volInfo.flags() & FILE_PERSISTENT_ACLS) != 0);

Looks good to me too, although I can only really comment on the Windows case.

Mark Thornton

-------------- next part --------------
An HTML attachment was scrubbed...

More information about the nio-dev mailing list