public class PathMappedFileManager extends Object implements Closeable
| Constructor and Description |
|---|
PathMappedFileManager(org.commonjava.storage.pathmapped.config.PathMappedStorageConfig config,
org.commonjava.storage.pathmapped.spi.PathDB pathDB,
org.commonjava.storage.pathmapped.spi.PhysicalStore physicalStore) |
| Modifier and Type | Method and Description |
|---|---|
void |
cleanupCurrentThread() |
void |
close() |
void |
copy(String fromFileSystem,
String fromPath,
String toFileSystem,
String toPath) |
boolean |
delete(String fileSystem,
String path) |
boolean |
exists(String fileSystem,
String path) |
Map<org.commonjava.storage.pathmapped.spi.FileInfo,Boolean> |
gc() |
long |
getFileLastModified(String fileSystem,
String path) |
long |
getFileLength(String fileSystem,
String path) |
String |
getFileStoragePath(String fileSystem,
String path) |
Set<String> |
getFileSystemContaining(Collection<String> candidates,
String path) |
Set<String> |
getFileSystemContainingDirectory(Collection<String> candidates,
String path) |
String |
getFirstFileSystemContaining(List<String> candidates,
String path) |
boolean |
isDirectory(String fileSystem,
String path) |
boolean |
isFile(String fileSystem,
String path) |
String[] |
list(String fileSystem,
String path) |
String[] |
list(String fileSystem,
String path,
boolean recursive,
int limit) |
String[] |
list(String fileSystem,
String path,
boolean recursive,
int limit,
org.commonjava.storage.pathmapped.spi.PathDB.FileType fileType) |
String[] |
list(String fileSystem,
String path,
org.commonjava.storage.pathmapped.spi.PathDB.FileType fileType) |
void |
makeDirs(String fileSystem,
String path) |
InputStream |
openInputStream(String fileSystem,
String path) |
OutputStream |
openOutputStream(String fileSystem,
String path) |
OutputStream |
openOutputStream(String fileSystem,
String path,
long timeout,
TimeUnit timeoutUnit) |
void |
startReporting() |
void |
stopReporting() |
public PathMappedFileManager(org.commonjava.storage.pathmapped.config.PathMappedStorageConfig config,
org.commonjava.storage.pathmapped.spi.PathDB pathDB,
org.commonjava.storage.pathmapped.spi.PhysicalStore physicalStore)
public Set<String> getFileSystemContainingDirectory(Collection<String> candidates, String path)
public Set<String> getFileSystemContaining(Collection<String> candidates, String path)
public String getFirstFileSystemContaining(List<String> candidates, String path)
public InputStream openInputStream(String fileSystem, String path) throws IOException
IOExceptionpublic OutputStream openOutputStream(String fileSystem, String path) throws IOException
IOExceptionpublic OutputStream openOutputStream(String fileSystem, String path, long timeout, TimeUnit timeoutUnit) throws IOException
IOExceptionpublic void cleanupCurrentThread()
public void startReporting()
public void stopReporting()
public String[] list(String fileSystem, String path, org.commonjava.storage.pathmapped.spi.PathDB.FileType fileType)
public String[] list(String fileSystem, String path, boolean recursive, int limit, org.commonjava.storage.pathmapped.spi.PathDB.FileType fileType)
public void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableIOExceptionCopyright © 2019-2020. All Rights Reserved.