code: Collection<File> getDirectories(NameNodeDirType dirType)
        throws IOException {
      ArrayList<File> list = new ArrayList<File>();
      Iterator<StorageDirectory> it = (dirType == null) ? dirIterator() :
                                      dirIterator(dirType);
      for ( ;it.hasNext(); ) {
        StorageDirectory sd = it.next();
        list.add(sd.getRoot());
      }
      return list;
    }
docs: Return the list of locations being used for a specific purpose.
  i.e. Image or edit log storage.
  
  @param dirType Purpose of locations requested.
  @throws IOException