@Override protected void injectType(final FileType fileType) { this.data.setType(fileType); super.injectType(fileType); }
@Override protected void injectType(final FileType fileType) { this.data.setType(fileType); super.injectType(fileType); }
@Override protected void injectType(final FileType fileType) { this.data.setType(fileType); super.injectType(fileType); }
@Override protected void injectType(final FileType fileType) { this.data.setType(fileType); super.injectType(fileType); }
/** * @param rootName The root file name. * @param fileSystemOptions The FileSystem options. */ protected RamFileSystem(final FileName rootName, final FileSystemOptions fileSystemOptions) { super(rootName, null, fileSystemOptions); this.cache = Collections.synchronizedMap(new HashMap<FileName, RamFileData>()); // create root final RamFileData rootData = new RamFileData(rootName); rootData.setType(FileType.FOLDER); rootData.setLastModified(System.currentTimeMillis()); this.cache.put(rootName, rootData); }
/** * @param rootName The root file name. * @param fileSystemOptions The FileSystem options. */ protected RamFileSystem(final FileName rootName, final FileSystemOptions fileSystemOptions) { super(rootName, null, fileSystemOptions); this.cache = Collections.synchronizedMap(new HashMap<FileName, RamFileData>()); // create root final RamFileData rootData = new RamFileData(rootName); rootData.setType(FileType.FOLDER); rootData.setLastModified(System.currentTimeMillis()); this.cache.put(rootName, rootData); }
/** * @param rootName The root file name. * @param fileSystemOptions The FileSystem options. */ protected RamFileSystem(final FileName rootName, final FileSystemOptions fileSystemOptions) { super(rootName, null, fileSystemOptions); this.cache = Collections.synchronizedMap(new HashMap<FileName, RamFileData>()); // create root final RamFileData rootData = new RamFileData(rootName); rootData.setType(FileType.FOLDER); rootData.setLastModified(System.currentTimeMillis()); this.cache.put(rootName, rootData); }
/** * @param rootName The root file name. * @param fileSystemOptions The FileSystem options. */ protected RamFileSystem(final FileName rootName, final FileSystemOptions fileSystemOptions) { super(rootName, null, fileSystemOptions); this.cache = Collections.synchronizedMap(new HashMap<FileName, RamFileData>()); // create root final RamFileData rootData = new RamFileData(rootName); rootData.setType(FileType.FOLDER); rootData.setLastModified(System.currentTimeMillis()); this.cache.put(rootName, rootData); }
/** * @param from The original file. * @param to The new file. * @throws FileSystemException if an error occurs. */ void rename(final RamFileObject from, final RamFileObject to) throws FileSystemException { if (!this.cache.containsKey(from.getName())) { throw new FileSystemException("File does not exist: " + from.getName()); } // Copy data to.getData().setContent(from.getData().getContent()); to.getData().setLastModified(from.getData().getLastModified()); to.getData().setType(from.getData().getType()); this.save(to); this.delete(from); }
/** * @param from The original file. * @param to The new file. * @throws FileSystemException if an error occurs. */ void rename(final RamFileObject from, final RamFileObject to) throws FileSystemException { if (!this.cache.containsKey(from.getName())) { throw new FileSystemException("File does not exist: " + from.getName()); } // Copy data to.getData().setContent(from.getData().getContent()); to.getData().setLastModified(from.getData().getLastModified()); to.getData().setType(from.getData().getType()); this.save(to); this.delete(from); }
/** * @param from The original file. * @param to The new file. * @throws FileSystemException if an error occurs. */ void rename(final RamFileObject from, final RamFileObject to) throws FileSystemException { if (!this.cache.containsKey(from.getName())) { throw new FileSystemException("File does not exist: " + from.getName()); } // Copy data to.getData().setContent(from.getData().getContent()); to.getData().setLastModified(from.getData().getLastModified()); to.getData().setType(from.getData().getType()); this.save(to); this.delete(from); }
/** * @param from The original file. * @param to The new file. * @throws FileSystemException if an error occurs. */ void rename(final RamFileObject from, final RamFileObject to) throws FileSystemException { if (!this.cache.containsKey(from.getName())) { throw new FileSystemException("File does not exist: " + from.getName()); } // Copy data to.getData().setContent(from.getData().getContent()); to.getData().setLastModified(from.getData().getLastModified()); to.getData().setType(from.getData().getType()); this.save(to); this.delete(from); }