net.dankito.utils.filesystem.VisitedFile.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of java-utils Show documentation
Show all versions of java-utils Show documentation
Some basic utils needed in many projects
package net.dankito.utils.filesystem
import java.nio.file.Path
import java.nio.file.attribute.BasicFileAttributes
open class VisitedFile(
val path: Path?,
val attributes: BasicFileAttributes? = null,
val error: Exception? = null
) {
val visitSuccessful = path != null && error == null
override fun toString(): String {
return "${if (visitSuccessful) "Success" else "Error"} visiting file $path"
}
}