/** * Creates a file object. This method is called only if the requested file is not cached. */ @Override protected FileObject createFile(final AbstractFileName name) throws Exception { // Find the file that the name points to final FileName junctionPoint = getJunctionForFile(name); final FileObject file; if (junctionPoint != null) { // Resolve the real file final FileObject junctionFile = junctions.get(junctionPoint); final String relName = junctionPoint.getRelativeName(name); file = junctionFile.resolveFile(relName, NameScope.DESCENDENT_OR_SELF); } else { file = null; } // Return a wrapper around the file return new DelegateFileObject(name, this, file); }
/** * Creates a file object. This method is called only if the requested file is not cached. */ @Override protected FileObject createFile(final AbstractFileName name) throws Exception { // Find the file that the name points to final FileName junctionPoint = getJunctionForFile(name); final FileObject file; if (junctionPoint != null) { // Resolve the real file final FileObject junctionFile = junctions.get(junctionPoint); final String relName = junctionPoint.getRelativeName(name); file = junctionFile.resolveFile(relName, NameScope.DESCENDENT_OR_SELF); } else { file = null; } // Return a wrapper around the file return new DelegateFileObject(name, this, file); }
/** * Creates a file object. This method is called only if the requested file is not cached. */ @Override protected FileObject createFile(final AbstractFileName name) throws Exception { // Find the file that the name points to final FileName junctionPoint = getJunctionForFile(name); final FileObject file; if (junctionPoint != null) { // Resolve the real file final FileObject junctionFile = junctions.get(junctionPoint); final String relName = junctionPoint.getRelativeName(name); file = junctionFile.resolveFile(relName, NameScope.DESCENDENT_OR_SELF); } else { file = null; } // Return a wrapper around the file return new DelegateFileObject(name, this, file); }
/** * Creates a file object. This method is called only if the requested * file is not cached. */ @Override protected FileObject createFile(final AbstractFileName name) throws Exception { // Find the file that the name points to final FileName junctionPoint = getJunctionForFile(name); final FileObject file; if (junctionPoint != null) { // Resolve the real file final FileObject junctionFile = junctions.get(junctionPoint); final String relName = junctionPoint.getRelativeName(name); file = junctionFile.resolveFile(relName, NameScope.DESCENDENT_OR_SELF); } else { file = null; } // Return a wrapper around the file return new DelegateFileObject(name, this, file); }
return new DelegateFileObject<AbstractFileSystem>(fileName, fileSystem, ramFile);
DelegateFileObject file = (DelegateFileObject) getFileFromCache(parentName); if (file == null) { file = new DelegateFileObject(parentName, this, null); putFileToCache(file); } else {
DelegateFileObject file = (DelegateFileObject) getFileFromCache(parentName); if (file == null) { file = new DelegateFileObject(parentName, this, null); putFileToCache(file); } else {
DelegateFileObject file = (DelegateFileObject) getFileFromCache(parentName); if (file == null) { file = new DelegateFileObject(parentName, this, null); putFileToCache(file); } else {
if (file == null) file = new DelegateFileObject(parentName, this, null); putFileToCache(file);