/** * Return iterator based on Storage Directory Type * This iterator selects entries in storageDirs of type dirType and returns * them via the Iterator */ public Iterator<StorageDirectory> dirIterator(StorageDirType dirType) { return dirIterator(dirType, true); }
/** * Return default iterator * This iterator returns all entries in storageDirs */ public Iterator<StorageDirectory> dirIterator() { return dirIterator(null); }
@Override public Iterator<StorageDirectory> iterator() { return dirIterator(dirType); } };
/** * Return all entries in storageDirs, potentially excluding shared dirs. * @param includeShared whether or not to include shared dirs. * @return an iterator over the configured storage dirs. */ public Iterator<StorageDirectory> dirIterator(boolean includeShared) { return dirIterator(null, includeShared); }
/** * @return A list of the given File in every available storage directory, * regardless of whether it might exist. */ public List<File> getFiles(StorageDirType dirType, String fileName) { ArrayList<File> list = new ArrayList<File>(); Iterator<StorageDirectory> it = (dirType == null) ? dirIterator() : dirIterator(dirType); for ( ;it.hasNext(); ) { File currentDir = it.next().getCurrentDir(); if (currentDir != null) { list.add(new File(currentDir, fileName)); } } return list; }
@Override public Iterator<StorageDirectory> iterator() { return dirIterator(dirType); } };
/** * Return default iterator * This iterator returns all entries in storageDirs */ public Iterator<StorageDirectory> dirIterator() { return dirIterator(null); }
/** * Return iterator based on Storage Directory Type * This iterator selects entries in storageDirs of type dirType and returns * them via the Iterator */ public Iterator<StorageDirectory> dirIterator(StorageDirType dirType) { return dirIterator(dirType, true); }
/** * Return iterator based on Storage Directory Type * This iterator selects entries in storageDirs of type dirType and returns * them via the Iterator */ public Iterator<StorageDirectory> dirIterator(StorageDirType dirType) { return dirIterator(dirType, true); }
@Override public Iterator<StorageDirectory> iterator() { return dirIterator(dirType); } };
/** * Return default iterator * This iterator returns all entries in storageDirs */ public Iterator<StorageDirectory> dirIterator() { return dirIterator(null); }
/** * Return default iterator * This iterator returns all entires of storageDirs */ public Iterator<StorageDirectory> dirIterator() { return dirIterator(null); }
/** * Return all entries in storageDirs, potentially excluding shared dirs. * @param includeShared whether or not to include shared dirs. * @return an iterator over the configured storage dirs. */ public Iterator<StorageDirectory> dirIterator(boolean includeShared) { return dirIterator(null, includeShared); }
/** * Return all entries in storageDirs, potentially excluding shared dirs. * @param includeShared whether or not to include shared dirs. * @return an iterator over the configured storage dirs. */ public Iterator<StorageDirectory> dirIterator(boolean includeShared) { return dirIterator(null, includeShared); }
/** * Return default iterator * This iterator returns all entires of storageDirs */ public Iterator<StorageDirectory> dirIterator() { return dirIterator(null); }
/** * @return A list of the given File in every available storage directory, * regardless of whether it might exist. */ public List<File> getFiles(StorageDirType dirType, String fileName) { ArrayList<File> list = new ArrayList<File>(); Iterator<StorageDirectory> it = (dirType == null) ? dirIterator() : dirIterator(dirType); for ( ;it.hasNext(); ) { list.add(new File(it.next().getCurrentDir(), fileName)); } return list; }
/** * @return A list of the given File in every available storage directory, * regardless of whether it might exist. */ public List<File> getFiles(StorageDirType dirType, String fileName) { ArrayList<File> list = new ArrayList<File>(); Iterator<StorageDirectory> it = (dirType == null) ? dirIterator() : dirIterator(dirType); for ( ;it.hasNext(); ) { list.add(new File(it.next().getCurrentDir(), fileName)); } return list; }