Registers an object with a watch service.
An invocation of this method behaves in exactly the same way as the invocation
watchable.register(watcher, events, new WatchEvent.Modifier[0]);
watcher
| the watch service to which this object is to be registered | |
events
| the events for which this object should be registered |
UnsupportedOperationException
| if unsupported events are specified | |
IllegalArgumentException
| if an invalid of combination of events are specified | |
ClosedWatchServiceException
| if the watch service is closed | |
IOException
| if an I/O error occurs | |
SecurityException
| if a security manager is installed and it denies an unspecified permission required to monitor this object. Implementations of this interface should specify the permission checks. |
Diagram: Watch