toRootPath

fun List<String>.toRootPath(addTrailing: Boolean = false, separator: CharSequence = "/"): String

Joins this list of strings into a root-relative path (with a leading separator).

Extension function on List<String>.

Return

the joined path string

Parameters

addTrailing

whether to add a trailing separator (default false)

separator

the path separator (default "/")