@Incubating public interface ProjectLayout
An instance of this type can be injected into a task, plugin or other object by annotating a public constructor or method with javax.inject.Inject. It is also available via Project.getLayout().
Directory getProjectDirectory()
DirectoryProperty getBuildDirectory()
@Deprecated DirectoryProperty directoryProperty()
ObjectFactory.directoryProperty()DirectoryProperty that uses the project directory to resolve relative paths, if required. The property has no initial value.@Deprecated DirectoryProperty directoryProperty(Provider<? extends Directory> initialProvider)
ObjectFactory.directoryProperty()DirectoryProperty that uses the project directory to resolve relative paths, if required. The property has the initial provider specified.initialProvider - initial provider for the property@Deprecated RegularFileProperty fileProperty()
ObjectFactory.fileProperty()RegularFileProperty that uses the project directory to resolve relative paths, if required. The property has no initial value.@Deprecated RegularFileProperty fileProperty(Provider<? extends RegularFile> initialProvider)
ObjectFactory.fileProperty()RegularFileProperty that uses the project directory to resolve relative paths, if required. The property has the initial provider specified.initialProvider - initial provider for the propertyProvider<RegularFile> file(Provider<File> file)
RegularFile provider whose location is calculated from the given Provider.FileCollection files(Object... paths)
Creates a FileCollection containing the given files, as defined by Project.files(Object...).
This method can also be used to create an empty collection, but the collection may not be mutated later.
paths - The paths to the files. May be empty.@Deprecated ConfigurableFileCollection configurableFiles(Object... paths)
ObjectFactory.fileCollection() instead.Returns a ConfigurableFileCollection containing the given files, as defined by Project.files(Object...).
This method can also be used to create an empty collection, which can later be mutated to add elements.
paths - The paths to the files. May be empty.