api / org.gradle.api.file / Directory / dir

dir

abstract fun dir(path: String): Directory

Returns a Directory whose location is the given path, resolved relative to this directory.

Parameters

path - The path. Can be absolute.

Return
The directory.

abstract fun dir(path: Provider<out CharSequence>): Provider<Directory>

Returns a Provider whose value is a Directory whose location is the given path resolved relative to this directory.

The return value is live and the provided path is queried each time the return value is queried.

Parameters

path - The path provider. Can have value that is an absolute path.

Return
The provider.