public class DefaultEventHandler extends Object implements EventHandler
Constructor and Description |
---|
DefaultEventHandler() |
Modifier and Type | Method and Description |
---|---|
void |
onAccess(File file,
FileAttribute before,
FileAttribute current)
文件被访问
|
void |
onCreate(File file,
FileAttribute current)
文件被创建
|
void |
onDelete(File file,
FileAttribute before)
文件被删除
|
void |
onModified(File file,
FileAttribute before,
FileAttribute current)
文件被修改
|
public void onAccess(File file, FileAttribute before, FileAttribute current)
EventHandler
onAccess
in interface EventHandler
file
- 文件before
- 上次文件属性current
- 当前文件属性public void onModified(File file, FileAttribute before, FileAttribute current)
EventHandler
onModified
in interface EventHandler
file
- 文件before
- 上次文件属性current
- 当前文件属性public void onCreate(File file, FileAttribute current)
EventHandler
onCreate
in interface EventHandler
file
- 文件current
- 当前文件属性public void onDelete(File file, FileAttribute before)
EventHandler
onDelete
in interface EventHandler
file
- 文件before
- 上次文件属性Copyright © 2024. All rights reserved.