public enum WatchKind extends Enum<WatchKind>
1. 事件丢失 OVERFLOW -》StandardWatchEventKinds.OVERFLOW 2. 修改事件 MODIFY -》StandardWatchEventKinds.ENTRY_MODIFY 3. 创建事件 CREATE -》StandardWatchEventKinds.ENTRY_CREATE 4. 删除事件 DELETE -》StandardWatchEventKinds.ENTRY_DELETE
Enum Constant and Description |
---|
CREATE
创建事件
|
DELETE
删除事件
|
MODIFY
修改事件
|
OVERFLOW
事件丢失
|
Modifier and Type | Field and Description |
---|---|
static WatchEvent.Kind<?>[] |
ALL
全部事件
|
Modifier and Type | Method and Description |
---|---|
WatchEvent.Kind<?> |
getValue()
获取枚举对应的事件类型
|
static WatchKind |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static WatchKind[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final WatchKind OVERFLOW
public static final WatchKind MODIFY
public static final WatchKind CREATE
public static final WatchKind DELETE
public static final WatchEvent.Kind<?>[] ALL
public static WatchKind[] values()
for (WatchKind c : WatchKind.values()) System.out.println(c);
public static WatchKind 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 WatchEvent.Kind<?> getValue()
Copyright © 2024. All rights reserved.