Deduplicating code in BsdUserDefinedFileAttributeView and LinuxUserDefinedFileAttributeView

Alan Bateman Alan.Bateman at oracle.com
Tue Feb 2 12:16:48 UTC 2021



On 02/02/2021 11:25, Sebastian Stenzel wrote:
>
>
> Right. Should I keep SUPPORTS_BIRTHTIME as 2^16? The comments suggest 
> there are two different domains of supported features.
>
> Proposal:
>
> ```
> private static final int SUPPORTS_OPENAT  = 1 << 1;  // syscalls
> private static final int SUPPORTS_FUTIMES       = 1 << 2;
> private static final int SUPPORTS_FUTIMENS      = 1 << 3;
> private static final int SUPPORTS_LUTIMES       = 1 << 4;
> private static final int SUPPORTS_XATTR         = 1 << 5;
> private static final int SUPPORTS_BIRTHTIME = 1 << 16; // other features
> ```
Capabilities was originally just for system calls but it was extended to 
st_birthtim as the only "other feature".  You proposal is good.

-Alan


More information about the nio-dev mailing list