component-build-plugin / com.intershop.gradle.component.build.extension / ComponentExtension

ComponentExtension

open class ComponentExtension

This class provides the main extension for the component build plugin.

Parameters

project - provides the current Gradle project instance.

Constructors

<init>

ComponentExtension(project: Project)

Creates a pre configured extension

Properties

componentDescription

var componentDescription: String

This attribute defines the description for a component.

containers

val containers: FileContainerItemContainer

The container for all single file configurations. These files will be installed as they are

dependencyMgmt

val dependencyMgmt: DependencyMgmtContainer

The container for dependencies configurations.

descriptorOutputFile

var descriptorOutputFile: File

This file configuration is used for the output of the descriptor file.

descriptorPath

var descriptorPath: String

The install path for the component descriptor file. Default value is 'component'.

directories

val directories: DirectoryContainer

The container for all single directory configurations. These directories will be created as they are.

displayName

var displayName: String

This attribute defines a component's display name.

excludes

val excludes: Set<String>

Files that matches to one of patterns will be excluded from the update installation.

excludesProvider

val excludesProvider: Provider<Set<String>>

This is a provider for dependencyExcludes property.

fileItems

val fileItems: FileItemContainer

The container for all single file configurations. These files will be installed as they are

inherits

val inherits: NamedDomainObjectContainer<InheritanceSpec>

The container for all inherit configurations. The component can inherit configuration from other components.

ivyPublicationName

var ivyPublicationName: String

This is used for the publishing configuration of this plugin.

libs

val libs: LibraryItemContainer

The container for all library configurations.

links

val links: LinkItemContainer

The container for all single link configurations. These links will be created as they are.

mavenPublicationName

var mavenPublicationName: String

This is used for the publishing configuration of this plugin.

modules

val modules: ModuleItemContainer

The container for all modules configurations.

preserve

val preserve: PatternFilterable

This is the configuration for preserved patterns.

propertyItems

val propertyItems: PropertyItemContainer

The container for all single file configurations. These files will be installed as they are

targetPath

var targetPath: String

This attribute defines a predefined install target. The default value is an empty string.

types

val types: Set<String>

This set contains deployment or environment type definitions, like 'production', 'test' etc. The set can be extended. The set is empty per default. It is defined as an task input property.

Functions

addType

fun addType(type: String): Boolean

Adds a new deployment or environment type. The characters will be changed to lower cases.

addTypes

fun addTypes(types: Collection<String>): Boolean

Adds a list of new deployment or environment types. The characters will be changed to lower cases.

containers

fun containers(action: Action<in FileContainerItemContainer>): Unit

Configures zip packages of a component.

dependencyMgmt

fun dependencyMgmt(action: Action<in DependencyMgmtContainer>): Unit

Configures dependencies container of a component.

directories

fun directories(action: Action<in DirectoryContainer>): Unit

Configures directories of a component.

exclude

fun exclude(pattern: String): Unit

Adds a pattern to the set of exclude patterns. Files that matches to one of patterns will be excluded from the installation.

fun exclude(patterns: Set<String>): Unit

Adds a set of patterns to the set of exclude patterns. Files that matches to one of patterns will be excluded from the installation. If one of the patterns is part of the list, the method returns false.

fileItems

fun fileItems(action: Action<in FileItemContainer>): Unit

Configures file container of a component.

inherit

fun inherit(name: String, inheritFrom: Action<in InheritanceSpec>): Unit

Add an inherit configuration to the component.

libs

fun libs(action: Action<in LibraryItemContainer>): Unit

Configures lib container of a component.

links

fun links(action: Action<in LinkItemContainer>): Unit

Configures links of a component.

modules

fun modules(action: Action<in ModuleItemContainer>): Unit

Configures module container of a component.

preserve

fun preserve(action: Action<in PatternFilterable>): Unit

Configure patternset for preserve files from update. Files that matches to one of patterns will be excluded or included to the update installation.

propertyItems

fun propertyItems(action: Action<in PropertyItemContainer>): Unit

Configures zip packages of a component.

Companion Object Properties

CLASSCOLLISION_REPORT

const val CLASSCOLLISION_REPORT: String

default path for report file.

DEFAULT_IVYPUBLICATION

const val DEFAULT_IVYPUBLICATION: String

Default name for ivy publication.

DEFAULT_MAVENPUBLICATION

const val DEFAULT_MAVENPUBLICATION: String

Default name for maven publication.

DESCRIPTOR_FILE

const val DESCRIPTOR_FILE: String

default path for descriptor file.