public static class PathWatcher.PathPendingEvents extends Object
Constructor and Description |
---|
PathPendingEvents(Path path) |
PathPendingEvents(Path path,
PathWatcher.PathWatchEvent event) |
Modifier and Type | Method and Description |
---|---|
void |
addEvent(PathWatcher.PathWatchEvent event) |
List<PathWatcher.PathWatchEvent> |
getEvents() |
long |
getTimestamp() |
boolean |
isQuiet(long now,
long expiredDuration,
TimeUnit expiredUnit)
Check to see if the file referenced by this Event is quiet.
|
public PathPendingEvents(Path path)
public PathPendingEvents(Path path, PathWatcher.PathWatchEvent event)
public void addEvent(PathWatcher.PathWatchEvent event)
public List<PathWatcher.PathWatchEvent> getEvents()
public long getTimestamp()
public boolean isQuiet(long now, long expiredDuration, TimeUnit expiredUnit)
Will validate the timestamp to see if it is expired, as well as if the file size hasn't changed within the quiet period.
Always updates timestamp to 'now' on use of this method.
now
- the time nowexpiredDuration
- the expired duration past the timestamp to be considered expiredexpiredUnit
- the unit of time for the expired checkCopyright © 1995-2015 Webtide. All Rights Reserved.