Interface Scanner.BulkListener
- All Superinterfaces:
Scanner.Listener
- All Known Implementing Classes:
DeploymentScanner
- Enclosing class:
Scanner
Notification of files that changed in the last scan.
-
Method Summary
Modifier and TypeMethodDescriptiondefault void
filesChanged
(Set<String> filenames) Deprecated, for removal: This API element is subject to removal in a future version.default void
pathsChanged
(Map<Path, Scanner.Notification> changeSet) Main entry point for BulkListener events.default void
pathsChanged
(Set<Path> paths) Deprecated, for removal: This API element is subject to removal in a future version.usepathsChanged(Map)
instead.
-
Method Details
-
pathsChanged
Main entry point for BulkListener events.Override this to see a Map of Path to Notification.
- Parameters:
changeSet
- the raw changeset that was detected by the last scan.- Throws:
Exception
- if unable to report the events.
-
pathsChanged
@Deprecated(since="12.1.0", forRemoval=true) default void pathsChanged(Set<Path> paths) throws Exception Deprecated, for removal: This API element is subject to removal in a future version.usepathsChanged(Map)
instead.Only the list of Paths that changed, with no knowledge of how it changed (Added, Removed, Changed).Use this if you have a need to interrogate the state of the Paths yourself, otherwise use the
pathsChanged(Map)
for a more complete set of changes detected.Note: this method is inherently racy, as by the time you investigate the status of the paths that changed, those paths might have changed again in an unexpected way.
- Parameters:
paths
- the paths that changed (includes all ADDED, REMOVED, CHANGED entries)- Throws:
Exception
- if unable to report the events.
-
filesChanged
@Deprecated(since="12.1.0", forRemoval=true) default void filesChanged(Set<String> filenames) throws Exception Deprecated, for removal: This API element is subject to removal in a future version.usepathsChanged(Map)
insteadOnly the list of filenames that have changed, with no knowledge of how it changed (Added, Removed, Changed).Use this if you have a need to interrogate the state of the filenames yourself, otherwise use the
pathsChanged(Map)
for a more complete set of changes detected.Note: this method is inherently racy, as by the time you investigate the status of the paths that changed, those paths might have changed again in an unexpected way.
- Parameters:
filenames
- the set of filenames that changed (includes all ADDED, REMOVED, CHANGED entries)- Throws:
Exception
- if unable to report the events.
-
pathsChanged(Map)
instead