gradle
8.5

# CppComponent

interface CppComponent : ComponentWithBinaries, ComponentWithDependencies, ComponentWithTargetMachines(source)

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.

#### Inheritors

CppTestSuite
ProductionCppComponent

## Functions

getBaseName
Link copied to clipboard
abstract fun getBaseName(): Property<String>
Specifies the base name for this component.
getBinaries
Link copied to clipboard
abstract fun getBinaries(): BinaryCollection<out CppBinary>
Returns the binaries for this library.
getCppSource
Link copied to clipboard
abstract fun getCppSource(): FileCollection
Returns the C++ source files of this component, as defined in getSource.
getDependencies
Link copied to clipboard
abstract fun getDependencies(): ComponentDependencies
getHeaderFiles
Link copied to clipboard
abstract fun getHeaderFiles(): FileTree
Returns all header files of this component.
getImplementationDependencies
Link copied to clipboard
abstract fun getImplementationDependencies(): Configuration
Returns the implementation dependencies of this component.
getName
Link copied to clipboard
abstract fun getName(): String
getPrivateHeaderDirs
Link copied to clipboard
abstract fun getPrivateHeaderDirs(): FileCollection
Returns the private header include directories of this component, as defined in getPrivateHeaders.
getPrivateHeaders
Link copied to clipboard
abstract fun getPrivateHeaders(): ConfigurableFileCollection
Defines the private header file directories of this library.
getSource
Link copied to clipboard
abstract fun getSource(): ConfigurableFileCollection
Defines the source files or directories of this component.
getTargetMachines
Link copied to clipboard
abstract fun getTargetMachines(): SetProperty<TargetMachine>
privateHeaders
Link copied to clipboard
abstract fun privateHeaders(action: Action<out Any>)
Configures the private header directories for this component.
source
Link copied to clipboard
abstract fun source(action: Action<out Any>)
Configures the source files or directories for this component.