Package nl.knaw.dans.bagit.verify
Class FileCountAndTotalSizeVistor
- All Implemented Interfaces:
FileVisitor<Path>
Implements
SimpleFileVisitor
to ensure that the encountered file is in one of the manifests.-
Field Summary
Modifier and TypeFieldDescriptionprivate long
private static final org.slf4j.Logger
private static final ResourceBundle
private long
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionlong
getCount()
long
preVisitDirectory
(Path dir, BasicFileAttributes attrs) visitFile
(Path path, BasicFileAttributes attrs) Methods inherited from class java.nio.file.SimpleFileVisitor
postVisitDirectory, visitFileFailed
-
Field Details
-
logger
private static final org.slf4j.Logger logger -
messages
-
totalSize
private transient long totalSize -
count
private transient long count
-
-
Constructor Details
-
FileCountAndTotalSizeVistor
public FileCountAndTotalSizeVistor()
-
-
Method Details
-
preVisitDirectory
- Specified by:
preVisitDirectory
in interfaceFileVisitor<Path>
- Overrides:
preVisitDirectory
in classSimpleFileVisitor<Path>
- Throws:
IOException
-
visitFile
- Specified by:
visitFile
in interfaceFileVisitor<Path>
- Overrides:
visitFile
in classSimpleFileVisitor<Path>
- Throws:
IOException
-
getCount
public long getCount() -
getTotalSize
public long getTotalSize()
-