You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by ec...@apache.org on 2014/05/05 02:44:58 UTC

svn commit: r1592434 - in /commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2: ./ cache/ impl/ provider/ provider/ftp/

Author: ecki
Date: Mon May  5 00:44:57 2014
New Revision: 1592434

URL: http://svn.apache.org/r1592434
Log:
Remove commented out code and straighten doc comments.

Modified:
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/FileSystem.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/FileSystemManager.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/AbstractFilesCache.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/DefaultFilesCache.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/FileSystemAndNameKey.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/LRUFilesCache.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/NullFilesCache.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/SoftRefFilesCache.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/WeakRefFilesCache.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/DefaultFileSystemManager.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/FileContentInfoFilenameFactory.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/FileTypeMap.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/PrivilegedFileReplicator.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/ProviderConfiguration.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/Resource.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/StandardFileSystemManager.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/VFSClassLoader.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/VirtualFileProvider.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileObject.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileProvider.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileSystem.java
    commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/ftp/FtpFileSystemConfigBuilder.java

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/FileSystem.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/FileSystem.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/FileSystem.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/FileSystem.java Mon May  5 00:44:57 2014
@@ -154,7 +154,7 @@ public interface FileSystem
      * <p>
      * Note that the local copy may include additonal files, that were
      * not selected by the given selector.
-     * <P>
+     * <p>
      * TODO - Add options to indicate whether the caller is happy to deal with
      * extra files being present locally (eg if the file has been
      * replicated previously), or whether the caller expects only

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/FileSystemManager.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/FileSystemManager.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/FileSystemManager.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/FileSystemManager.java Mon May  5 00:44:57 2014
@@ -165,7 +165,7 @@ public interface FileSystemManager
 
     /**
      * Closes the given filesystem.
-     * <P>
+     * <p>
      * If you use VFS as singleton it is VERY dangerous to call this method.
      *
      * @param filesystem The FileSystem to close.

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/AbstractFilesCache.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/AbstractFilesCache.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/AbstractFilesCache.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/AbstractFilesCache.java Mon May  5 00:44:57 2014
@@ -19,9 +19,7 @@ package org.apache.commons.vfs2.cache;
 import org.apache.commons.vfs2.FilesCache;
 import org.apache.commons.vfs2.provider.AbstractVfsComponent;
 
-/**
- * Description.
- */
+
 public abstract class AbstractFilesCache extends AbstractVfsComponent implements FilesCache
 {
 }

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/DefaultFilesCache.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/DefaultFilesCache.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/DefaultFilesCache.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/DefaultFilesCache.java Mon May  5 00:44:57 2014
@@ -25,7 +25,8 @@ import org.apache.commons.vfs2.FileObjec
 import org.apache.commons.vfs2.FileSystem;
 
 /**
- * A {@link org.apache.commons.vfs2.FilesCache} implementation.<br>
+ * A {@link org.apache.commons.vfs2.FilesCache} implementation.
+ * <p>
  * This implementation caches every file for the complete lifetime of the used
  * {@link org.apache.commons.vfs2.FileSystemManager}.
  */

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/FileSystemAndNameKey.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/FileSystemAndNameKey.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/FileSystemAndNameKey.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/FileSystemAndNameKey.java Mon May  5 00:44:57 2014
@@ -23,7 +23,6 @@ import org.apache.commons.vfs2.FileSyste
  * Key for various cache implementations.
  * <p>
  * It compares the fileSystem (by hashCode) and the filename.
- * </p>
  */
 class FileSystemAndNameKey implements Comparable<FileSystemAndNameKey>
 {

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/LRUFilesCache.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/LRUFilesCache.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/LRUFilesCache.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/LRUFilesCache.java Mon May  5 00:44:57 2014
@@ -35,16 +35,16 @@ import org.apache.commons.vfs2.VfsLog;
 import org.apache.commons.vfs2.util.Messages;
 
 /**
- * This implementation caches every file using {@link LRUMap}.<br>
+ * This implementation caches every file using {@link LRUMap}.
+ * <p>
  * The default constructor uses a LRU size of 100 per filesystem.
  */
 public class LRUFilesCache extends AbstractFilesCache
 {
     /** The default LRU size */
     private static final int DEFAULT_LRU_SIZE = 100;
-    /**
-     * The logger to use.
-     */
+
+    /** The logger to use. */
     private final Log log = LogFactory.getLog(LRUFilesCache.class);
 
     /** The FileSystem cache */
@@ -148,8 +148,6 @@ public class LRUFilesCache extends Abstr
         writeLock.lock();
         try
         {
-            // System.err.println(">>> " + files.size() + " put:" + file.toString());
-
             files.put(file.getName(), file);
         }
         finally
@@ -169,7 +167,6 @@ public class LRUFilesCache extends Abstr
         {
             final FileName name = file.getName();
 
-            // System.err.println(">>> " + files.size() + " put:" + file.toString());
             if (files.containsKey(name))
             {
                 return false;
@@ -192,9 +189,6 @@ public class LRUFilesCache extends Abstr
         readLock.lock();
         try
         {
-            // FileObject fo = (FileObject) files.get(name);
-            // System.err.println(">>> " + files.size() + " get:" + name.toString() + " " + fo);
-
             return files.get(name);
         }
         finally
@@ -211,8 +205,6 @@ public class LRUFilesCache extends Abstr
         writeLock.lock();
         try
         {
-            // System.err.println(">>> clear fs " + filesystem);
-
             files.clear();
 
             filesystemCache.remove(filesystem);
@@ -228,8 +220,6 @@ public class LRUFilesCache extends Abstr
         Map<FileName, FileObject> files = filesystemCache.get(filesystem);
         if (files == null)
         {
-            // System.err.println(">>> create fs " + filesystem);
-
             files = new MyLRUMap(filesystem, lruSize);
             filesystemCache.putIfAbsent(filesystem, files);
         }
@@ -240,9 +230,6 @@ public class LRUFilesCache extends Abstr
     public void close()
     {
         super.close();
-
-        // System.err.println(">>> clear all");
-
         filesystemCache.clear();
     }
 
@@ -254,8 +241,6 @@ public class LRUFilesCache extends Abstr
         writeLock.lock();
         try
         {
-            // System.err.println(">>> " + files.size() + " remove:" + name.toString());
-
             files.remove(name);
 
             if (files.size() < 1)

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/NullFilesCache.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/NullFilesCache.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/NullFilesCache.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/NullFilesCache.java Mon May  5 00:44:57 2014
@@ -21,15 +21,12 @@ import org.apache.commons.vfs2.FileObjec
 import org.apache.commons.vfs2.FileSystem;
 
 /**
+ * A {@link org.apache.commons.vfs2.FilesCache} implementation.
  * <p>
- * A {@link org.apache.commons.vfs2.FilesCache} implementation.<br>
  * This implementation never ever caches a single file.
- * </p>
  * <p>
- * <b>Notice: if you use resolveFile(uri) multiple times with the same path, the system will always
- * create a new instance.
- * Changes on one instance of this file are not seen by the others.</b>
- * </p>
+ * <b>Notice</b>: if you use resolveFile(uri) multiple times with the same path, the system will always
+ * create a new instance. Changes on one instance of this file are not seen by the others.
  */
 public class NullFilesCache extends AbstractFilesCache
 {

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/SoftRefFilesCache.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/SoftRefFilesCache.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/SoftRefFilesCache.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/SoftRefFilesCache.java Mon May  5 00:44:57 2014
@@ -41,15 +41,12 @@ import org.apache.commons.vfs2.util.Mess
  * the java vm. As soon as the vm needs memory - every softly reachable file
  * will be discarded.
  *
- *          2005) $
  * @see SoftReference
  */
 public class SoftRefFilesCache extends AbstractFilesCache
 {
     private static final int TIMEOUT = 1000;
-    /**
-     * The logger to use.
-     */
+
     private final Log log = LogFactory.getLog(SoftRefFilesCache.class);
 
     private final ConcurrentMap<FileSystem, Map<FileName, Reference<FileObject>>> fileSystemCache =
@@ -96,7 +93,7 @@ public class SoftRefFilesCache extends A
                     {
                         final FileSystemAndNameKey key = refReverseMap.get(ref);
 
-                        if (key != null && removeFile(key)) 
+                        if (key != null && removeFile(key))
                         {
                             close(key.getFileSystem());
                         }

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/WeakRefFilesCache.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/WeakRefFilesCache.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/WeakRefFilesCache.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/cache/WeakRefFilesCache.java Mon May  5 00:44:57 2014
@@ -28,7 +28,6 @@ import org.apache.commons.vfs2.FileObjec
  * In contrast to the SoftRefFilesCache this implementation might free resources faster
  * as it don't wait until a memory limitation.
  *
- *          2005) $
  * @see java.lang.ref.WeakReference
  */
 public class WeakRefFilesCache extends SoftRefFilesCache

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/DefaultFileSystemManager.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/DefaultFileSystemManager.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/DefaultFileSystemManager.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/DefaultFileSystemManager.java Mon May  5 00:44:57 2014
@@ -197,6 +197,7 @@ public class DefaultFileSystemManager im
 
     /**
      * Returns true if this manager has a provider for a particular scheme.
+     *
      * @param scheme The scheme to check.
      * @return true if a provider is configured for this scheme, false otherwise.
      */
@@ -781,8 +782,6 @@ public class DefaultFileSystemManager im
             buffer.insert(0, realBase.getPath());
         }
 
-        // // UriParser.canonicalizePath(buffer, 0, name.length());
-
         // Normalise the path
         final FileType fileType = UriParser.normalisePath(buffer);
 
@@ -808,7 +807,7 @@ public class DefaultFileSystemManager im
         final FileProvider provider = providers.get(scheme);
         if (provider != null)
         {
-            // todo: extend the filename parser to be able to parse
+            // TODO: extend the filename parser to be able to parse
             // only a pathname and take the missing informations from
             // the base. Then we can get rid of the string operation.
             // // String fullPath = base.getRootURI() +
@@ -826,7 +825,7 @@ public class DefaultFileSystemManager im
             }
         }
 
-        // todo: avoid fallback to this point
+        // TODO: avoid fallback to this point
         // this happens if we have a virtual filesystem (no provider for scheme)
         return ((AbstractFileName) realBase).createName(resolvedPath, fileType);
     }

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/FileContentInfoFilenameFactory.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/FileContentInfoFilenameFactory.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/FileContentInfoFilenameFactory.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/FileContentInfoFilenameFactory.java Mon May  5 00:44:57 2014
@@ -24,8 +24,9 @@ import org.apache.commons.vfs2.FileConte
 import org.apache.commons.vfs2.FileContentInfoFactory;
 
 /**
- * The FileContentInfoFilenameFactory.<br>
- * Uses the filename extension to determine the content-type.<br>
+ * The FileContentInfoFilenameFactory.
+ * <p>
+ * Uses the filename extension to determine the content-type.
  * The content-encoding is not resolved.
  */
 public class FileContentInfoFilenameFactory implements FileContentInfoFactory

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/FileTypeMap.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/FileTypeMap.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/FileTypeMap.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/FileTypeMap.java Mon May  5 00:44:57 2014
@@ -54,7 +54,6 @@ class FileTypeMap
     {
         // Check the file's mime type for a match
         final FileContent content = file.getContent();
-        // final String mimeType = (String) content.getAttribute("content-type");
         final String mimeType = content.getContentInfo().getContentType();
         if (mimeType != null)
         {

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/PrivilegedFileReplicator.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/PrivilegedFileReplicator.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/PrivilegedFileReplicator.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/PrivilegedFileReplicator.java Mon May  5 00:44:57 2014
@@ -55,6 +55,7 @@ public class PrivilegedFileReplicator
 
     /**
      * Sets the Logger to use for the component.
+     *
      * @param logger The logger.
      */
     @Override
@@ -68,6 +69,7 @@ public class PrivilegedFileReplicator
 
     /**
      * Sets the context for the replicator.
+     *
      * @param context The component context.
      */
     @Override
@@ -81,6 +83,7 @@ public class PrivilegedFileReplicator
 
     /**
      * Initializes the component.
+     *
      * @throws FileSystemException if an error occurs.
      */
     @Override
@@ -113,6 +116,7 @@ public class PrivilegedFileReplicator
 
     /**
      * Creates a local copy of the file, and all its descendants.
+     *
      * @param srcFile The source FileObject.
      * @param selector The file selector.
      * @return The replicated file.

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/ProviderConfiguration.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/ProviderConfiguration.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/ProviderConfiguration.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/ProviderConfiguration.java Mon May  5 00:44:57 2014
@@ -20,7 +20,8 @@ import java.util.ArrayList;
 import java.util.List;
 
 /**
- * This class describes the configuration for a provider.<br>
+ * This class describes the configuration for a provider.
+ * <p>
  * Used by digester in StandardFileSystemManager
  */
 public class ProviderConfiguration

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/Resource.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/Resource.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/Resource.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/Resource.java Mon May  5 00:44:57 2014
@@ -25,8 +25,8 @@ import org.apache.commons.vfs2.FileSyste
 import org.apache.commons.vfs2.FileUtil;
 
 /**
- * Helper class for VFSClassLoader. This represents a resource loaded with
- * the classloader.
+ * Helper class for VFSClassLoader.
+ * This represents a resource loaded with the classloader.
  *
  * @see VFSClassLoader
  */

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/StandardFileSystemManager.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/StandardFileSystemManager.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/StandardFileSystemManager.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/StandardFileSystemManager.java Mon May  5 00:44:57 2014
@@ -37,7 +37,8 @@ import org.w3c.dom.NodeList;
 
 /**
  * A {@link org.apache.commons.vfs2.FileSystemManager} that configures itself
- * from an XML (Default: providers.xml) configuration file.<br>
+ * from an XML (Default: providers.xml) configuration file.
+ * <p>
  * Certain providers are only loaded and available if the dependent library is in your
  * classpath. You have to configure your debugging facility to log "debug" messages to see
  * if a provider was skipped due to "unresolved externals".
@@ -53,6 +54,7 @@ public class StandardFileSystemManager
 
     /**
      * Sets the configuration file for this manager.
+     *
      * @param configUri The URI for this manager.
      */
     public void setConfiguration(final String configUri)
@@ -69,6 +71,7 @@ public class StandardFileSystemManager
 
     /**
      * Sets the configuration file for this manager.
+     *
      * @param configUri The URI forthis manager.
      */
     public void setConfiguration(final URL configUri)
@@ -77,8 +80,9 @@ public class StandardFileSystemManager
     }
 
     /**
-     * Sets the ClassLoader to use to load the providers.  Default is to
-     * use the ClassLoader that loaded this class.
+     * Sets the ClassLoader to use to load the providers.
+     * Default is to use the ClassLoader that loaded this class.
+     *
      * @param classLoader The ClassLoader.
      */
     public void setClassLoader(final ClassLoader classLoader)
@@ -87,7 +91,8 @@ public class StandardFileSystemManager
     }
 
     /**
-     * Initializes this manager.  Adds the providers and replicator.
+     * Initializes this manager. Adds the providers and replicator.
+     *
      * @throws FileSystemException if an error occurs.
      */
     @Override
@@ -98,14 +103,6 @@ public class StandardFileSystemManager
         setReplicator(new PrivilegedFileReplicator(replicator));
         setTemporaryFileStore(replicator);
 
-        /* replaced by findClassLoader
-        if (classLoader == null)
-        {
-            // Use default classloader
-            classLoader = getClass().getClassLoader();
-        }
-        */
-
         if (configUri == null)
         {
             // Use default config
@@ -117,10 +114,7 @@ public class StandardFileSystemManager
             configUri = url;
         }
 
-        // Configure
         configure(configUri);
-
-        // Configure Plugins
         configurePlugins();
 
         // Initialise super-class
@@ -178,6 +172,7 @@ public class StandardFileSystemManager
 
     /**
      * Configures this manager from an XML configuration file.
+     *
      * @param configUri The URI of the configuration.
      * @throws FileSystemException if an error occus.
      */
@@ -216,6 +211,7 @@ public class StandardFileSystemManager
 
     /**
      * Configures this manager from an XML configuration file.
+     *
      * @param configUri The URI of the configuration.
      * @param configStream An InputStream containing the configuration.
      * @throws FileSystemException if an error occurs.
@@ -242,6 +238,7 @@ public class StandardFileSystemManager
 
     /**
      * Configure and create a DocumentBuilder
+     *
      * @return A DocumentBuilder for the configuration.
      * @throws ParserConfigurationException if an error occurs.
      */
@@ -256,6 +253,7 @@ public class StandardFileSystemManager
 
     /**
      * Configures this manager from an parsed XML configuration file
+     *
      * @param config The configuration Element.
      * @throws FileSystemException if an error occurs.
      */
@@ -305,6 +303,7 @@ public class StandardFileSystemManager
 
     /**
      * Adds an extension map.
+     *
      * @param map containing the Elements.
      */
     private void addExtensionMap(final Element map)
@@ -319,6 +318,7 @@ public class StandardFileSystemManager
 
     /**
      * Adds a mime-type map.
+     *
      * @param map containing the Elements.
      */
     private void addMimeTypeMap(final Element map)
@@ -330,6 +330,7 @@ public class StandardFileSystemManager
 
     /**
      * Adds a provider from a provider definition.
+     *
      * @param providerDef the provider definition
      * @param isDefault true if the default should be used.
      * @throws FileSystemException if an error occurs.

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/VFSClassLoader.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/VFSClassLoader.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/VFSClassLoader.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/VFSClassLoader.java Mon May  5 00:44:57 2014
@@ -39,10 +39,12 @@ import org.apache.commons.vfs2.NameScope
 
 
 /**
- * A class loader that can load classes and resources from a search path
- * VFS FileObjects referring both to folders and JAR files. Any FileObject
- * of type FileType.FILE is assumed to be a JAR and is opened
- * by creating a layered file system with the "jar" scheme.
+ * A class loader that can load classes and resources from a search path.
+ * <p>
+ * The search path can consist of VFS FileObjects referring both to folders
+ * and JAR files. Any FileObject of type FileType.FILE is assumed to be a JAR and
+ * is opened by creating a layered file system with the "jar" scheme.
+ * <p>
  * TODO - Test this with signed Jars and a SecurityManager.
  *
  * @see FileSystemManager#createFileSystem
@@ -119,6 +121,7 @@ public class VFSClassLoader extends Secu
 
     /**
      * Provide access to the file objects this class loader represents.
+     *
      * @return An array of FileObjects.
      * @since 2.0
      */

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/VirtualFileProvider.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/VirtualFileProvider.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/VirtualFileProvider.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/impl/VirtualFileProvider.java Mon May  5 00:44:57 2014
@@ -31,6 +31,7 @@ public class VirtualFileProvider extends
 {
     /**
      * Creates a virtual file system, with the supplied file as its root.
+     *
      * @param rootFile The root of the file system.
      * @return A FileObject in the FileSystem.
      * @throws FileSystemException if an error occurs.
@@ -39,8 +40,6 @@ public class VirtualFileProvider extends
     {
         final AbstractFileName rootName = (AbstractFileName)
             getContext().getFileSystemManager().resolveName(rootFile.getName(), FileName.ROOT_PATH);
-        // final FileName rootName =
-        //    new BasicFileName(rootFile.getName(), FileName.ROOT_PATH);
         final VirtualFileSystem fs = new VirtualFileSystem(rootName, rootFile.getFileSystem().getFileSystemOptions());
         addComponent(fs);
         fs.addJunction(FileName.ROOT_PATH, rootFile);
@@ -49,6 +48,7 @@ public class VirtualFileProvider extends
 
     /**
      * Creates an empty virtual file system.
+     *
      * @param rootUri The root of the file system.
      * @return A FileObject in the FileSystem.
      * @throws FileSystemException if an error occurs.
@@ -57,8 +57,6 @@ public class VirtualFileProvider extends
     {
         final AbstractFileName rootName =
             new VirtualFileName(rootUri, FileName.ROOT_PATH, FileType.FOLDER);
-        // final FileName rootName =
-        //    new BasicFileName(rootUri, FileName.ROOT_PATH);
         final VirtualFileSystem fs = new VirtualFileSystem(rootName, null);
         addComponent(fs);
         return fs.getRoot();

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileObject.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileObject.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileObject.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileObject.java Mon May  5 00:44:57 2014
@@ -68,7 +68,6 @@ public abstract class AbstractFileObject
      * (eg 'this file type does not support listing children', vs 'this is not a folder')
      */
 
-    // private static final FileObject[] EMPTY_FILE_ARRAY = {};
     private static final FileName[] EMPTY_FILE_ARRAY = {};
 
     private static final int INITIAL_LIST_SIZE = 5;
@@ -313,13 +312,6 @@ public abstract class AbstractFileObject
         {
             throw new FileSystemException("vfs.provider/copy-missing-file.error", file);
         }
-        /* we do not alway know if a file is writeable
-        if (!isWriteable())
-        {
-            throw new FileSystemException("vfs.provider/copy-read-only.error", new Object[]{file.getType(),
-            file.getName(), this}, null);
-        }
-        */
 
         // Locate the files to copy across
         final ArrayList<FileObject> files = new ArrayList<FileObject>();
@@ -537,12 +529,7 @@ public abstract class AbstractFileObject
     {
         synchronized (fs)
         {
-            /* Its possible to delete a read-only file if you have write-execute access to the directory
-            if (!isWriteable())
-            {
-                throw new FileSystemException("vfs.provider/delete-read-only.error", name);
-            }
-            */
+            //Its possible to delete a read-only file if you have write-execute access to the directory
 
             /* VFS-210
             if (getType() == FileType.IMAGINARY)
@@ -1113,10 +1100,8 @@ public abstract class AbstractFileObject
         final FileObject[] children = getChildren();
         for (final FileObject element : children)
         {
-            // final FileObject child = children[i];
             final FileName child = element.getName();
             // TODO - use a comparator to compare names
-            // if (child.getName().getBaseName().equals(name))
             if (child.getBaseName().equals(name))
             {
                 return resolveFile(child);
@@ -1208,13 +1193,10 @@ public abstract class AbstractFileObject
             else
             {
                 // Create file objects for the children
-                // children = new FileObject[files.length];
                 final FileName[] cache = new FileName[files.length];
                 for (int i = 0; i < files.length; i++)
                 {
                     final String file = files[i];
-                    // children[i] = fs.resolveFile(name.resolveName(file, NameScope.CHILD));
-                    // children[i] = name.resolveName(file, NameScope.CHILD);
                     cache[i] = fs.getFileSystemManager().resolveName(fileName, file, NameScope.CHILD);
                 }
                 // VFS-285: only assign the children filenames after all of them have been
@@ -1586,7 +1568,6 @@ public abstract class AbstractFileObject
                 injectType(newType);
 
                 removeChildrenCache();
-                // children = EMPTY_FILE_ARRAY;
 
                 // Notify subclass
                 onChange();
@@ -1614,7 +1595,6 @@ public abstract class AbstractFileObject
                 // Fix up state
                 injectType(FileType.IMAGINARY);
                 removeChildrenCache();
-                // children = null;
 
                 // Notify subclass
                 onChange();
@@ -1997,17 +1977,6 @@ public abstract class AbstractFileObject
 
     private void removeChildrenCache()
     {
-        /*
-        if (children != null)
-        {
-            for (int iterChildren = 0; iterChildren < children.length; iterChildren++)
-            {
-                fs.removeFileFromCache(children[iterChildren].getName());
-            }
-
-            children = null;
-        }
-        */
         children = null;
     }
 

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileProvider.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileProvider.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileProvider.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileProvider.java Mon May  5 00:44:57 2014
@@ -39,7 +39,6 @@ public abstract class AbstractFileProvid
      * The cached file systems.  This is a mapping from root URI to
      * FileSystem object.
      */
-    // private final Map fileSystems = new HashMap();
     private final Map<FileSystemKey, FileSystem> fileSystems = new TreeMap<FileSystemKey, FileSystem>();
 
     private FileNameParser parser;
@@ -190,6 +189,5 @@ public abstract class AbstractFileProvid
         }
 
         throw new FileSystemException("vfs.provider/filename-parser-missing.error");
-        // return GenericFileName.parseUri(getFileNameParser(), uri, 0);
     }
 }

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileSystem.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileSystem.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileSystem.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileSystem.java Mon May  5 00:44:57 2014
@@ -70,14 +70,9 @@ public abstract class AbstractFileSystem
      */
     private final String rootURI;
 
-    private FileObject parentLayer;
-    // private FileObject root;
     private final Collection<Capability> caps = new HashSet<Capability>();
 
-    /**
-     * Map from FileName to FileObject.
-     */
-    // private FilesCache files;
+    private FileObject parentLayer;
 
     /**
      * Map from FileName to an ArrayList of listeners for that file.
@@ -106,7 +101,6 @@ public abstract class AbstractFileSystem
                                  final FileObject parentLayer,
                                  final FileSystemOptions fileSystemOptions)
     {
-        // this.parentLayer = parentLayer;
         this.parentLayer = parentLayer;
         this.rootName = rootName;
         this.fileSystemOptions = fileSystemOptions;
@@ -196,20 +190,16 @@ public abstract class AbstractFileSystem
     protected void putFileToCache(final FileObject file)
     {
         getCache().putFile(file);
-        // files.put(file.getName(), file);
     }
 
     private FilesCache getCache()
     {
         FilesCache files;
-        //if (this.files == null)
-        //{
-            files = getContext().getFileSystemManager().getFilesCache();
-            if (files == null)
-            {
-                throw new RuntimeException(Messages.getString("vfs.provider/files-cache-missing.error"));
-            }
-        //}
+        files = getContext().getFileSystemManager().getFilesCache();
+        if (files == null)
+        {
+            throw new RuntimeException(Messages.getString("vfs.provider/files-cache-missing.error"));
+        }
 
         return files;
     }
@@ -220,7 +210,6 @@ public abstract class AbstractFileSystem
     protected FileObject getFileFromCache(final FileName name)
     {
         return getCache().getFile(this, name);
-        // return (FileObject) files.get(name);
     }
 
     /**
@@ -289,13 +278,6 @@ public abstract class AbstractFileSystem
     public FileObject getRoot() throws FileSystemException
     {
         return resolveFile(rootName);
-        /*
-        if (root == null)
-        {
-            root = resolveFile(rootName);
-        }
-        return root;
-        */
     }
 
     /**
@@ -342,7 +324,7 @@ public abstract class AbstractFileSystem
         {
             file = null;
         }
-        // FileObject file = (FileObject) files.get(name);
+
         if (file == null)
         {
             try
@@ -361,7 +343,6 @@ public abstract class AbstractFileSystem
             {
                 putFileToCache(file);
             }
-            // files.put(name, file);
         }
 
         /**
@@ -453,7 +434,6 @@ public abstract class AbstractFileSystem
     public FileSystemManager getFileSystemManager()
     {
         return getContext().getFileSystemManager();
-        // return manager;
     }
 
     /**
@@ -625,19 +605,6 @@ public abstract class AbstractFileSystem
         }
     }
 
-    /*
-    void fileDetached(FileObject fileObject)
-    {
-        useCount--;
-    }
-
-    void fileAttached(FileObject fileObject)
-    {
-        useCount++;
-
-    }
-    */
-
     void fileObjectHanded(final FileObject fileObject)
     {
         useCount.incrementAndGet();

Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/ftp/FtpFileSystemConfigBuilder.java
URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/ftp/FtpFileSystemConfigBuilder.java?rev=1592434&r1=1592433&r2=1592434&view=diff
==============================================================================
--- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/ftp/FtpFileSystemConfigBuilder.java (original)
+++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/ftp/FtpFileSystemConfigBuilder.java Mon May  5 00:44:57 2014
@@ -345,7 +345,7 @@ public class FtpFileSystemConfigBuilder 
 
     /**
      * Sets the Proxy.
-     * <P>
+     * <p>
      * You might need to make sure that {@link #setPassiveMode(FileSystemOptions, boolean) passive mode}
      * is activated.
      *