Package org.matheclipse.core.io
Enum Extension
- java.lang.Object
-
- java.lang.Enum<Extension>
-
- org.matheclipse.core.io.Extension
-
- All Implemented Interfaces:
Serializable
,Comparable<Extension>
public enum Extension extends Enum<Extension>
File extensions format.See Symja's
Import()
andExport()
functions.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description BMP
uncompressed loss-less image format, no alpha channelCSV
tableDAT
DataDOT
graph (theory) formatEXPRESSIONJSON
ExpressionJSONGIF
animation formatGRAPHML
graph (theory) formatGZ
compressed version of another format, for instance csv.gzJPEG
compressed, lossy image formatJSON
JSONM
MATLAB m filePNG
compressed image format with alpha channelRAWJSON
RawJSONSTRING
text formatTABLE
table formatTSV
Tab-Separated ValuesTXT
plain text formatWXF
WXF format
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Extension
exportExtension(String extensionString)
DetermineExtension
format from the extension string.static Extension
exportFilename(String filename)
DetermineExtension
format from the filename's extension.static Extension
importExtension(String extensionString)
DetermineExtension
format from the extension string.static Extension
importFilename(String filename)
DetermineExtension
format from the filename's extension.static boolean
isAllowedExtension(String extensionString)
static Extension
of(String string)
static Extension
valueOf(String name)
Returns the enum constant of this type with the specified name.static Extension[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
BMP
public static final Extension BMP
uncompressed loss-less image format, no alpha channel
-
CSV
public static final Extension CSV
table
-
DAT
public static final Extension DAT
Data
-
DOT
public static final Extension DOT
graph (theory) format
-
EXPRESSIONJSON
public static final Extension EXPRESSIONJSON
ExpressionJSON
-
GIF
public static final Extension GIF
animation format
-
GRAPHML
public static final Extension GRAPHML
graph (theory) format
-
GZ
public static final Extension GZ
compressed version of another format, for instance csv.gz
-
JPEG
public static final Extension JPEG
compressed, lossy image format
-
JSON
public static final Extension JSON
JSON
-
M
public static final Extension M
MATLAB m file
-
PNG
public static final Extension PNG
compressed image format with alpha channel
-
RAWJSON
public static final Extension RAWJSON
RawJSON
-
STRING
public static final Extension STRING
text format
-
TABLE
public static final Extension TABLE
table format
-
TSV
public static final Extension TSV
Tab-Separated Values
-
TXT
public static final Extension TXT
plain text format
-
WXF
public static final Extension WXF
WXF format
-
-
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 nameNullPointerException
- if the argument is null
-
isAllowedExtension
public static boolean isAllowedExtension(String extensionString)
-
exportFilename
public static Extension exportFilename(String filename)
DetermineExtension
format from the filename's extension. If noExtension
can be determined returnDAT
.- Parameters:
filename
-- Returns:
-
exportExtension
public static Extension exportExtension(String extensionString)
DetermineExtension
format from the extension string. If noExtension
can be determined returnDAT
.- Parameters:
extensionString
-- Returns:
-
importFilename
public static Extension importFilename(String filename)
DetermineExtension
format from the filename's extension. If noExtension
can be determined returnSTRING
.- Parameters:
filename
-- Returns:
-
importExtension
public static Extension importExtension(String extensionString)
DetermineExtension
format from the extension string. If noExtension
can be determined returnSTRING
.- Parameters:
extensionString
-- Returns:
-
of
public static Extension of(String string)
- Parameters:
string
-- Returns:
- Throws:
IllegalArgumentException
- if given string does not match any known file types
-
-