Package de.uhilger.httpserver.cm
Class OrdnerBearbeiter
- java.lang.Object
-
- de.uhilger.httpserver.cm.FileTransporter
-
- de.uhilger.httpserver.cm.OrdnerBearbeiter
-
- All Implemented Interfaces:
FileVisitor
public class OrdnerBearbeiter extends FileTransporter implements FileVisitor
Ein FileVisitor zum Verschieben oder Kopieren ganzer Ordnerstrukturen mit Hilfe der Methode Files.walkFileTree von java.nio.
-
-
Constructor Summary
Constructors Constructor Description OrdnerBearbeiter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description FileVisitResultpostVisitDirectory(Object dir, IOException exc)FileVisitResultpreVisitDirectory(Object dir, BasicFileAttributes attrs)voidsetOperation(int op)OP_COPY oder OP_MOVEvoidsetTargetDir(Path targetDir)FileVisitResultvisitFile(Object file, BasicFileAttributes attrs)FileVisitResultvisitFileFailed(Object file, IOException exc)-
Methods inherited from class de.uhilger.httpserver.cm.FileTransporter
getNewFileName
-
-
-
-
Method Detail
-
setTargetDir
public void setTargetDir(Path targetDir)
-
setOperation
public void setOperation(int op)
OP_COPY oder OP_MOVE- Parameters:
op-
-
preVisitDirectory
public FileVisitResult preVisitDirectory(Object dir, BasicFileAttributes attrs) throws IOException
- Specified by:
preVisitDirectoryin interfaceFileVisitor- Throws:
IOException
-
visitFile
public FileVisitResult visitFile(Object file, BasicFileAttributes attrs) throws IOException
- Specified by:
visitFilein interfaceFileVisitor- Throws:
IOException
-
visitFileFailed
public FileVisitResult visitFileFailed(Object file, IOException exc) throws IOException
- Specified by:
visitFileFailedin interfaceFileVisitor- Throws:
IOException
-
postVisitDirectory
public FileVisitResult postVisitDirectory(Object dir, IOException exc) throws IOException
- Specified by:
postVisitDirectoryin interfaceFileVisitor- Throws:
IOException
-
-