@Override public void invalidate(final T parent) { proxy.invalidate(parent); }
@Override public void invalidate(final Path folder) { delegate.invalidate(this.toDecrypted(folder)); }
@Override public void cleanup(final List<Path> deleted) { for(Path folder : new PathReloadFinder().find(deleted)) { cache.invalidate(folder); } }
protected Path list(final Session<?> session) throws BackgroundException { Path home; AttributedList<Path> list; try { home = session.getFeature(Home.class).find(); // Remove cached home to force error if repeated attempt to mount fails cache.invalidate(home); // Retrieve directory listing of default path final SessionListWorker worker = new SessionListWorker(cache, home, listener); listener.message(worker.getActivity()); list = worker.run(session); } catch(NotfoundException e) { log.warn(String.format("Mount failed with %s", e.getMessage())); // The default path does not exist or is not readable due to possible permission issues. Fallback // to default working directory home = new Path(String.valueOf(Path.DELIMITER), EnumSet.of(Path.Type.volume, Path.Type.directory)); // Remove cached home to force error if repeated attempt to mount fails cache.invalidate(home); // Retrieve directory listing of working directory final SessionListWorker worker = new SessionListWorker(cache, home, listener); listener.message(worker.getActivity()); list = worker.run(session); } cache.put(home, list); return home; }
if(invalidate) { cache.invalidate(folder);
cache.invalidate(file); if(browserOutlineView.isItemExpanded(item)) { folders.add(file);