public class SubDirectory extends Directory
| Modifier and Type | Method and Description |
|---|---|
void |
addWatchedDirectory(ch.sourcepond.io.fileobserver.spi.WatchedDirectory pDirectoryKey)
Adds the watched-directory specified to this directory instance.
|
Directory |
getParent() |
boolean |
hasKeys() |
boolean |
isRoot() |
Directory |
rebase(Directory pBaseDirectory) |
boolean |
remove(ch.sourcepond.io.fileobserver.spi.WatchedDirectory pDirectoryKey)
INTERNAL API, only ot be used in class hierarchy
|
Directory |
toRootDirectory() |
cancelKey, forceInform, getPath, getResource, informCreatedOrInitial, informDiscard, informIfChanged, informIfChanged, isDirectParentOf, removeWatchedDirectorypublic void addWatchedDirectory(ch.sourcepond.io.fileobserver.spi.WatchedDirectory pDirectoryKey)
DirectoryAdds the watched-directory specified to this directory instance. When a change is detected, a
DispatchKey will be generated for every WatchedDirectory.getKey()/relative-path combination.
This DispatchKey instance will then be delivered (along with the readable file path)
to the PathChangeListener objects which should be informed.
Note: The object returned by WatchedDirectory.getKey() should be immutable,
String or an Enum objects are good condidates for being directory-keys.
addWatchedDirectory in class DirectorypDirectoryKey - Directory key, must not be nullpublic boolean remove(ch.sourcepond.io.fileobserver.spi.WatchedDirectory pDirectoryKey)
DirectoryINTERNAL API, only ot be used in class hierarchy
Removes the directory-key specified from this directory instance. If no such key is registered nothing happens.
pDirectoryKey - Directory-key to be removed, must be not nulltrue if the directory-key specified was removed, false otherwise.public Directory toRootDirectory()
toRootDirectory in class Directorypublic Directory getParent()
Copyright © 2017 SourcePond. All rights reserved.