Package org.gnome.gio
Enum Class FileType
- All Implemented Interfaces:
Enumeration
,Serializable
,Comparable<FileType>
,Constable
@Generated("io.github.jwharm.JavaGI")
public enum FileType
extends Enum<FileType>
implements Enumeration
Indicates the file's on-disk type.
On Windows systems a file will never have SYMBOLIC_LINK
type;
use GFileInfo
and G_FILE_ATTRIBUTE_STANDARD_IS_SYMLINK
to determine
whether a file is a symlink or not. This is due to the fact that NTFS does
not have a single filesystem object type for symbolic links - it has
files that symlink to files, and directories that symlink to directories.
GFileType
enumeration cannot precisely represent this important distinction,
which is why all Windows symlinks will continue to be reported as
REGULAR
or DIRECTORY
.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionFile handle represents a directory.File is a mountable location.File handle represents a regular file.File is a shortcut (Windows systems).File is a "special" file, such as a socket, fifo, block device, or character device.File handle represents a symbolic link (Unix systems).File's type is unknown. -
Method Summary
Modifier and TypeMethodDescriptionstatic Type
getType()
Get the GType of the FileType classint
getValue()
Get the numeric value of this enumstatic FileType
of
(int value) Create a new FileType for the provided valuestatic FileType
Returns the enum constant of this class with the specified name.static FileType[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
UNKNOWN
File's type is unknown. -
REGULAR
File handle represents a regular file. -
DIRECTORY
File handle represents a directory. -
SYMBOLIC_LINK
File handle represents a symbolic link (Unix systems). -
SPECIAL
File is a "special" file, such as a socket, fifo, block device, or character device. -
SHORTCUT
File is a shortcut (Windows systems). -
MOUNTABLE
File is a mountable location.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified nameNullPointerException
- if the argument is null
-
of
Create a new FileType for the provided value- Parameters:
value
- the enum value- Returns:
- the enum for the provided value
-
getValue
public int getValue()Get the numeric value of this enum- Specified by:
getValue
in interfaceEnumeration
- Returns:
- the enum value
-
getType
-