public enum ArchiveFormat extends Enum<ArchiveFormat>
| Enum Constant and Description |
|---|
AR
Constant used to identify the AR archive format.
|
CPIO
Constant used to identify the CPIO archive format.
|
DUMP
Constant used to identify the Unix DUMP archive format.
|
JAR
Constant used to identify the JAR archive format.
|
TAR
Constant used to identify the TAR archive format.
|
ZIP
Constant used to identify the ZIP archive format.
|
| Modifier and Type | Method and Description |
|---|---|
static ArchiveFormat |
fromString(String archiveFormat)
Attempts to return the
ArchiveFormat instance from a possible given string representation. |
String |
getDefaultFileExtension()
Returns the default file extension for this compression type.
|
String |
getName()
Returns the name by which the archive format is identified.
|
static boolean |
isValidArchiveFormat(String archiveFormat)
Checks if the given archive format name is valid and known format.
|
static ArchiveFormat |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static ArchiveFormat[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final ArchiveFormat AR
public static final ArchiveFormat CPIO
public static final ArchiveFormat DUMP
public static final ArchiveFormat JAR
public static final ArchiveFormat TAR
public static final ArchiveFormat ZIP
public static ArchiveFormat[] values()
for (ArchiveFormat c : ArchiveFormat.values()) System.out.println(c);
public static ArchiveFormat valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant
with the specified nameNullPointerException - if the argument is nullpublic String getName()
public String getDefaultFileExtension()
public static boolean isValidArchiveFormat(String archiveFormat)
archiveFormat - the archive format namepublic static ArchiveFormat fromString(String archiveFormat)
ArchiveFormat instance from a possible given string representation. Ignores case.archiveFormat - string representation of the archive format. E.g. "tar" or "ZIP".IllegalArgumentException - if the given archive format is unknown.Copyright © 2013-2014. All Rights Reserved.