Enum Extension

  • All Implemented Interfaces:
    Serializable, Comparable<Extension>

    public enum Extension
    extends Enum<Extension>
    Describes the available extensions for the exported files. Each extensions is associated with the inherent format. The subclasses of the Exporter class are responsible for observing adherence to that format.
    • Enum Constant Detail

      • HTML

        public static final Extension HTML
        The result will be a document with html tags that can be viewed in any web browser. Useful for complex formatting, but not for data manipulation, as the tags and special symbols do not allow simple parsing through the file.
      • CSV

        public static final Extension CSV
        The result will be a tab-delimited CSV document. Useful for data manipulations and plotting with external tools, e.g. gnuplot or LaTeX.
    • Method Detail

      • values

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

        public static Extension 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
      • toString

        public String toString()
        This will return the lower-case string with the name of the extension (e.g., html or csv).
        Overrides:
        toString in class Enum<Extension>