Package org.gradle.language.cpp
Interface CppComponent
- All Superinterfaces:
- ComponentWithBinaries,- ComponentWithDependencies,- ComponentWithTargetMachines,- Named,- SoftwareComponent
- All Known Subinterfaces:
- CppApplication,- CppLibrary,- CppTestSuite,- ProductionCppComponent
public interface CppComponent
extends ComponentWithBinaries, ComponentWithDependencies, ComponentWithTargetMachines
Configuration for a C++ component, such as a library or executable, defining the source files and private header directories that make up the component. Private headers are those that are visible only to the source files of the component.
 
A C++ component is composed of some C++ source files that are compiled and then linked into some binary.
An instance of this type is added as a project extension by the C++ plugins.
- Since:
- 4.2
- 
Nested Class SummaryNested classes/interfaces inherited from interface org.gradle.api.NamedNamed.Namer
- 
Method SummaryModifier and TypeMethodDescriptionSpecifies the base name for this component.BinaryCollection<? extends CppBinary> Returns the binaries for this library.Returns the C++ source files of this component, as defined ingetSource().Returns all header files of this component.Returns the implementation dependencies of this component.Returns the private header include directories of this component, as defined ingetPrivateHeaders().Defines the private header file directories of this library.Defines the source files or directories of this component.voidprivateHeaders(Action<? super ConfigurableFileCollection> action) Configures the private header directories for this component.voidsource(Action<? super ConfigurableFileCollection> action) Configures the source files or directories for this component.Methods inherited from interface org.gradle.language.ComponentWithDependenciesgetDependenciesMethods inherited from interface org.gradle.language.ComponentWithTargetMachinesgetTargetMachines
- 
Method Details- 
getBaseNameSpecifies the base name for this component. This name is used to calculate various output file names. The default value is calculated from the project name.
- 
getSourceConfigurableFileCollection getSource()Defines the source files or directories of this component. You can add files or directories to this collection. When a directory is added, all source files are included for compilation.When this collection is empty, the directory src/main/cppis used by default.
- 
sourceConfigures the source files or directories for this component.
- 
getCppSourceFileCollection getCppSource()Returns the C++ source files of this component, as defined ingetSource().
- 
getPrivateHeadersConfigurableFileCollection getPrivateHeaders()Defines the private header file directories of this library.When this collection is empty, the directory src/main/headersis used by default.
- 
privateHeadersConfigures the private header directories for this component.
- 
getPrivateHeaderDirsFileCollection getPrivateHeaderDirs()Returns the private header include directories of this component, as defined ingetPrivateHeaders().
- 
getHeaderFilesFileTree getHeaderFiles()Returns all header files of this component. Includes public and private header files.
- 
getImplementationDependenciesConfiguration getImplementationDependencies()Returns the implementation dependencies of this component.
- 
getBinariesBinaryCollection<? extends CppBinary> getBinaries()Returns the binaries for this library.- Specified by:
- getBinariesin interface- ComponentWithBinaries
- Since:
- 4.5
 
 
-