Enum ExistingFileBehavior

    • Enum Constant Detail

      • APPEND

        public static final ExistingFileBehavior APPEND
        The file behavior that indicates that the data written should be appended to any existing file.
      • OVERWRITE

        public static final ExistingFileBehavior OVERWRITE
        The file behavior that indicates that the data written should overwrite any existing file.
      • FAIL

        public static final ExistingFileBehavior FAIL
        The file behavior that indicates that the write should fail if the specified file already exists.
    • Method Detail

      • values

        public static ExistingFileBehavior[] 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 (ExistingFileBehavior c : ExistingFileBehavior.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static ExistingFileBehavior valueOf​(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:
        IllegalArgumentException - if this enum type has no constant with the specified name
        NullPointerException - if the argument is null
      • getName

        public String getName()
        Retrieves the name for this existing file behavior.
        Returns:
        The name for this existing file behavior.
      • toString

        public String toString()
        Retrieves a string representation of this existing file behavior.
        Overrides:
        toString in class Enum<ExistingFileBehavior>
        Returns:
        A string representation of this existing file behavior.