Community
Participate
Working Groups
//this is not a local file, so try to obtain a local file
try {
final URI locationURI = file.getLocationURI();
if(locationURI == null)
return null;
IFileStore store = EFS.getStore(locationURI);
//first try to obtain a local file directly fo1r this store
java.io.File localFile = store.toLocalFile(EFS.NONE, null);
//if no local file is available, obtain a cached file
if (localFile == null)
localFile = store.toLocalFile(EFS.CACHE, null);
return Path.fromOSString(localFile.getAbsolutePath());
} catch (CoreException e) {
//this can only happen if the file system is not available for this scheme