Package org.apache.commons.vfs

Examples of org.apache.commons.vfs.FileName


                } else {
                    continue;
                }
            }

            final FileName filename = getFileSystemManager().
                    resolveName(getRootName(), UriParser.encode(name));

            // Create the file
            IsoFileObject fileObj;

            if (entry.isDirectory() && getFileFromCache(filename) != null) {
                fileObj = (IsoFileObject) getFileFromCache(filename);
                fileObj.setIsoEntry(entry);
                continue;
            }

            fileObj = new IsoFileObject(filename, entry, this);
            putFileToCache(fileObj);
            strongRef.add(fileObj);
            fileObj.holdObject(strongRef);

            // Make sure all ancestors exist
            IsoFileObject parent;

            for (FileName parentName = filename.getParent(); parentName != null;
                 fileObj = parent, parentName = parentName.getParent()) {

                // Locate the parent
                parent = (IsoFileObject) getFileFromCache(parentName);
View Full Code Here


    }

    protected FileSystem doCreateFileSystem(final String scheme, final FileObject file,
                                            final FileSystemOptions fileSystemOptions)
            throws FileSystemException {
        final FileName rootName = new LayeredFileName(
                scheme, file.getName(), FileName.ROOT_PATH, FileType.FOLDER);
        return new IsoFileSystem(rootName, file, fileSystemOptions);
    }
View Full Code Here

TOP

Related Classes of org.apache.commons.vfs.FileName

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.