| 限定符和类型 | 字段 | 说明 |
|---|---|---|
static int |
_SC_CLK_TCK |
Used in the
OsHelper#getSystemConfig(int) method for querying the number of clock ticks per second. |
static int |
EEXIST |
Error value indicating that the file does not exist.
|
static int |
ENOENT |
Error value indicating that the file or directory does not exist.
|
static int |
ENOSPC |
Error value indicating that there is no space available on the device.
|
static int |
EXDEV |
Error value returned when trying to establish a cross-device link.
|
static int |
F_OK |
File permission mode used to check whether a file exists.
|
static int |
PR_SET_DUMPABLE |
A flag set for a process that determines whether the process performs
core dump when it receives such a default signal.
|
static int |
R_OK |
File permission mode used to check whether a file exists, and give read permissions.
|
static int |
S_IRGRP |
File permission mode to specify whether a file can be read group.
|
static int |
S_IROTH |
File permission mode to specify whether a file can be read by other users.
|
static int |
S_IRUSR |
File permission mode to specify whether a file can be read by user.
|
static int |
S_IRWXG |
File permission mode to specify whether a file can be read、written and executed by group.
|
static int |
S_IRWXO |
File permission mode to specify whether a file can be read、written and executed by others.
|
static int |
S_IRWXU |
File permission mode to specify whether a file can be read、written and executed by owner.
|
static int |
S_ISUID |
Set user id.
|
static int |
S_ISVTX |
The permissions for file holders, can renamed or deleted.
|
static int |
S_IWGRP |
File permission mode to specify whether a file can be written by user.
|
static int |
S_IWOTH |
File permission mode to specify whether a file can be written by others.
|
static int |
S_IWUSR |
File permission mode to specify whether a file can be written by owner.
|
static int |
S_IXGRP |
File permission mode to specify whether a file can be executed or searched by other members
in the group to which the file owner belongs.
|
static int |
S_IXOTH |
File permission mode to specify whether a file can be executed or searched by other users.
|
static int |
S_IXUSR |
File permission mode to specify whether a file can be executed or searched by the file owner.
|
static int |
SEEK_CUR |
File offset, current position plus offset
|
static int |
SEEK_END |
Set the file offset to be offset add the size of file.
|
static int |
SEEK_SET |
File operation mode, which is used together with the offset value to specify the
offset of the file operation position.
|
static int |
SO_SNDTIMEO |
A socket option to specify the sending timeout, upon which an error is reported.
|
static int |
SOL_SOCKET |
Used as a level option to obtain or set the attribute of the socket level.
|
static int |
W_OK |
File permission mode used to check whether a file exists, and give write permissions.
|
static int |
X_OK |
File permission mode used to check whether a file exists, and give execute permissions.
|
| 限定符和类型 | 方法 | 说明 |
|---|---|---|
static boolean |
isDir(int mode) |
Checks whether the file is a directory based on the specified file mode.
|
static boolean |
isRegularFile(int mode) |
Checks whether the file is a regular file based on the specified file mode.
|
public static final int EEXIST
public static final int ENOENT
public static final int ENOSPC
public static final int EXDEV
public static final int F_OK
public static final int PR_SET_DUMPABLE
public static final int R_OK
public static final int SEEK_CUR
public static final int SEEK_END
public static final int SEEK_SET
public static final int SOL_SOCKET
public static final int SO_SNDTIMEO
public static final int S_IRGRP
public static final int S_IROTH
public static final int S_IRUSR
public static final int S_IRWXG
public static final int S_IRWXO
public static final int S_IRWXU
public static final int S_ISUID
public static final int S_ISVTX
public static final int S_IWGRP
public static final int S_IWOTH
public static final int S_IWUSR
public static final int S_IXGRP
public static final int S_IXOTH
public static final int S_IXUSR
public static final int W_OK
public static final int X_OK
public static final int _SC_CLK_TCK
OsHelper#getSystemConfig(int) method for querying the number of clock ticks per second.public static boolean isRegularFile(int mode)
S_ISREG macro in the Linux sys/stat.h file.mode - Indicates the file mode.true if the file is a regular file; returns false otherwise.public static boolean isDir(int mode)
S_ISDIR macro in the Linux sys/stat.h file.mode - Indicates the file mode.true if the file is a directory; returns false otherwise.