kotlin.io.java.io.File.relativeToOrNull

relativeToOrNull

fun File.relativeToOrNull(base: File): File?

Platform and version requirements: JVM

Calculates the relative path for this file from base file. Note that the base file is treated as a directory. If this file matches the base file, then a File with empty path will be returned.

Return File with relative path from base to this, or null if this and base paths have different roots.

© 2010–2017 JetBrains s.r.o.
Licensed under the Apache License, Version 2.0.
https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.io/java.io.-file/relative-to-or-null.html

在线笔记
App下载
App下载

扫描二维码

下载编程狮App

公众号
微信公众号

编程狮公众号

意见反馈
返回顶部