marschall / memoryfilesystem

An in memory implementation of a JSR-203 file system
282 stars 36 forks source link

Switch MemoryEntryFileAttributes from FileTime to Instant #119

Closed marschall closed 5 years ago

marschall commented 5 years ago

We can safe a bit of memory if we use Instant instead of FileTime in MemoryEntryFileAttributes.

This results in fewer allocations when not all file times are read, for example when only the #size() and #isRegularFile() methods are used.

This results in slightly higher allocations when the same file time is read multiple times from the same BasicFileAttributes object.