api / org.gradle.api.file / DirectoryProperty / file

file

abstract fun file(path: String): Provider<RegularFile>

Returns a RegularFile whose value is the given path resolved relative to the value of this directory.

Parameters

path - The path. Can be absolute.

Return
The file.

abstract fun file(path: Provider<out CharSequence>): Provider<RegularFile>

Returns a RegularFile whose value is the given path resolved relative to the value of this directory.

Parameters

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

Return
The file.