@ThreadSafe public final class UfsSyncPathCache extends Object
Constructor and Description |
---|
UfsSyncPathCache()
Creates a new instance of
UfsSyncPathCache . |
Modifier and Type | Method and Description |
---|---|
void |
notifySyncedPath(String path,
DescendantType descendantType)
Notifies the cache that the path was synced.
|
boolean |
shouldSyncPath(String path,
long intervalMs,
boolean isGetFileInfo)
The logic of shouldSyncPath need to consider the difference between file and directory,
with the variable isGetFileInfo we just process getFileInfo specially.
|
public UfsSyncPathCache()
UfsSyncPathCache
.public void notifySyncedPath(String path, DescendantType descendantType)
path
- the path that was synceddescendantType
- the descendant type that the path was synced withpublic boolean shouldSyncPath(String path, long intervalMs, boolean isGetFileInfo)
path
- the path to checkintervalMs
- the sync interval, in msisGetFileInfo
- the operate is from getFileInfo or notCopyright © 2023. All Rights Reserved.