Package net.sourceforge.jnlp.util
Enum FileUtils.OpenFileResult
- java.lang.Object
-
- java.lang.Enum<FileUtils.OpenFileResult>
-
- net.sourceforge.jnlp.util.FileUtils.OpenFileResult
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<FileUtils.OpenFileResult>
- Enclosing class:
- FileUtils
public static enum FileUtils.OpenFileResult extends java.lang.Enum<FileUtils.OpenFileResult>
Indicates whether a file was successfully opened. If not, provides specific reasons along with a general failure case
-
-
Enum Constant Summary
Enum Constants Enum Constant Description CANT_CREATE
The file could not be opened because it did not exist and could not be createdCANT_WRITE
The file can be opened but in read-onlyFAILURE
The file could not be opened, for non-specified reasonsNOT_FILE
The specified path pointed to a non-file filesystem object, ie a directorySUCCESS
The file was successfully opened
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static FileUtils.OpenFileResult
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static FileUtils.OpenFileResult[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
SUCCESS
public static final FileUtils.OpenFileResult SUCCESS
The file was successfully opened
-
FAILURE
public static final FileUtils.OpenFileResult FAILURE
The file could not be opened, for non-specified reasons
-
CANT_CREATE
public static final FileUtils.OpenFileResult CANT_CREATE
The file could not be opened because it did not exist and could not be created
-
CANT_WRITE
public static final FileUtils.OpenFileResult CANT_WRITE
The file can be opened but in read-only
-
NOT_FILE
public static final FileUtils.OpenFileResult NOT_FILE
The specified path pointed to a non-file filesystem object, ie a directory
-
-
Method Detail
-
values
public static FileUtils.OpenFileResult[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (FileUtils.OpenFileResult c : FileUtils.OpenFileResult.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static FileUtils.OpenFileResult valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
-