Author: rgoers Date: Mon Nov 15 07:25:58 2010 New Revision: 1035161 URL: http://svn.apache.org/viewvc?rev=1035161&view=rev Log: Convert enum pattern to Java 5 enum
Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/FileType.java Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/FileType.java URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/FileType.java?rev=1035161&r1=1035160&r2=1035161&view=diff ============================================================================== --- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/FileType.java (original) +++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/FileType.java Mon Nov 15 07:25:58 2010 @@ -22,31 +22,31 @@ package org.apache.commons.vfs2; * @author <a href="http://commons.apache.org/vfs/team-list.html">Commons VFS team</a> * @version $Revision$ $Date$ */ -public final class FileType +public enum FileType { /** * A folder. May contain other files, and have attributes, but does not * have any data content. */ - public static final FileType FOLDER = new FileType("folder", true, false, true); + FOLDER("folder", true, false, true), /** * A regular file. May have data content and attributes, but cannot * contain other files. */ - public static final FileType FILE = new FileType("file", false, true, true); + FILE("file", false, true, true), /** * A file or folder. May have data content and attributes, and can * contain other files. */ - public static final FileType FILE_OR_FOLDER = new FileType("fileOrFolder", true, true, true); + FILE_OR_FOLDER("fileOrFolder", true, true, true), /** * A file that does not exist. May not have data content, attributes, * or contain other files. */ - public static final FileType IMAGINARY = new FileType("imaginary", false, false, false); + IMAGINARY("imaginary", false, false, false); /** The name of the FileType */ private final String name;