T
- the type used by the concrete subclass to keep track of statepublic abstract class AbstractFileSubtreeWalker<T> extends Object
Constructor and Description |
---|
AbstractFileSubtreeWalker() |
Modifier and Type | Method and Description |
---|---|
protected abstract T |
handleDirectory(File dir,
T state)
Handles encountering a directory.
|
protected abstract void |
handleFile(File f,
T state)
Handles encountering a file.
|
void |
walkSubtree(File f,
T state)
Walks a subtree starting from a specified file or directory.
|
public void walkSubtree(File f, T state)
f
- a file or directorystate
- the state managed by the callerprotected abstract T handleDirectory(File dir, T state) throws Exception
dir
- the directory encounteredstate
- the current walking stateException
- if there is an error processing the directoryprotected abstract void handleFile(File f, T state) throws Exception
f
- the file encounteredstate
- the current walking stateException
- if there is an error processing the fileCopyright © 2010–2016 Planetary Data System. All rights reserved.