public class ExtrasFS extends FilterFileSystemProvider
Lucene shouldn't care about these, but sometimes operating systems create special files themselves (.DS_Store, thumbs.db, .nfsXXX, ...), so we add them and see what breaks.
When a directory is created, sometimes an "extra" file or directory
will be included with it (use
isExtra(String) to check if it's one
of those files).
All other filesystem operations are delegated as normal.
|Constructor and Description|
Create a new instance, wrapping
|Modifier and Type||Method and Description|
checkAccess, copy, createLink, createSymbolicLink, delete, deleteIfExists, getFileAttributeView, getFileStore, getFileSystem, getPath, getScheme, isHidden, isSameFile, move, newAsynchronousFileChannel, newByteChannel, newDirectoryStream, newFileChannel, newFileSystem, newFileSystem, newInputStream, newOutputStream, onClose, readAttributes, readAttributes, readSymbolicLink, setAttribute, toDelegate, toString
public ExtrasFS(FileSystem delegate, boolean active, boolean createDirectory)
trueif we should create extra files
trueif we should create directories instead of files. Ignored if
public void createDirectory(Path dir, FileAttribute<?>... attrs) throws IOException
public static boolean isExtra(String fileName)
fileNameis one of the extra files added by this class.
Copyright © 2000-2021 Apache Software Foundation. All Rights Reserved.