Enum CopyMode
- java.lang.Object
-
- java.lang.Enum<CopyMode>
-
- nl.esciencecenter.xenon.filesystems.CopyMode
-
-
Enum Constant Summary
Enum Constants Enum Constant Description CREATE
Copy to a new destination file, failing if the file already exists.IGNORE
Skip the copy if the destination file if it already exists.REPLACE
If the source and destination are a regular file, the destination file will be replaced.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static CopyMode
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static CopyMode[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
CREATE
public static final CopyMode CREATE
Copy to a new destination file, failing if the file already exists.
-
REPLACE
public static final CopyMode REPLACE
If the source and destination are a regular file, the destination file will be replaced. If the destination exists and is not a file and the source is a file, then the destination will be (recursively) deleted before copying. If the source and destination are directories then additional files in the destination directory are not touched.
-
IGNORE
public static final CopyMode IGNORE
Skip the copy if the destination file if it already exists.
-
-
Method Detail
-
values
public static CopyMode[] 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 (CopyMode c : CopyMode.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static CopyMode 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
-
-