component-installation-plugin / com.intershop.gradle.component.installation.filter / FilterContainer

FilterContainer

class FilterContainer : DefaultNamedDomainObjectList<FilterSpec>

This container is used for the definition of all filters. The name of the filter must be unique and the order of specified filters must be always the same.

Constructors

<init>

FilterContainer(project: Project, instantiator: Instantiator)

creates an container for filter declarations.

Functions

addClosure

fun addClosure(name: String, include: String, closure: Closure<*>): Unit
fun addClosure(name: String, includes: Set<String>, closure: Closure<*>): Unit
fun addClosure(name: String, pattern: PatternFilterable, closure: Closure<*>): Unit

Adds a 'Closure' to all installation tasks. This closure class will change the file based on each line.

addTransformer

fun addTransformer(name: String, include: String, transformer: Transformer<String, String>): Unit
fun addTransformer(name: String, includes: Set<String>, transformer: Transformer<String, String>): Unit
fun addTransformer(name: String, pattern: PatternFilterable, transformer: Transformer<String, String>): Unit

Adds a 'Transformer' to all installation tasks. This transformer class will change the file based on each line.

fullContent

fun fullContent(name: String, include: String, content: Closure<StringBuilder>): Unit
fun fullContent(name: String, include: String, content: Action<StringBuilder>): Unit
fun fullContent(name: String, includes: Set<String>, content: Action<StringBuilder>): Unit
fun fullContent(name: String, pattern: PatternFilterable, content: Action<StringBuilder>): Unit

Adds the 'FullContent' filter to all installation tasks. The configuration is based on StringBuilder.

fun fullContent(name: String, includes: Set<String>, content: Closure<StringBuilder>): Unit
fun fullContent(name: String, pattern: PatternFilterable, content: Closure<StringBuilder>): Unit

Adds an 'FullContent' filter to all installation tasks. The configuration is based on StringBuilder.

overrideProperties

fun overrideProperties(name: String, include: String, properties: Closure<Properties>): Unit
fun overrideProperties(name: String, includes: Set<String>, properties: Closure<Properties>): Unit
fun overrideProperties(name: String, include: String, properties: Action<in Properties>): Unit
fun overrideProperties(name: String, includes: Set<String>, properties: Action<in Properties>): Unit
fun overrideProperties(name: String, pattern: PatternFilterable, properties: Closure<Properties>): Unit
fun overrideProperties(name: String, pattern: PatternFilterable, properties: Action<in Properties>): Unit

Adds an 'OverrideProperties' filter to all installation tasks. The configuration is based on formatted properties.

replacePlaceholders

fun replacePlaceholders(name: String, replacePlaceHolder: Closure<PlaceholderReplacementFilter>): Unit

Adds the 'ReplacePlaceholder' filter to all installation tasks. The configuration is based on PlaceholderReplacementFilter.

xmlContent

fun xmlContent(name: String, include: String, xml: Closure<XmlProvider>): Unit
fun xmlContent(name: String, includes: Set<String>, xml: Closure<XmlProvider>): Unit
fun xmlContent(name: String, include: String, xml: Action<in XmlProvider>): Unit
fun xmlContent(name: String, includes: Set<String>, xml: Action<in XmlProvider>): Unit
fun xmlContent(name: String, pattern: PatternFilterable, xml: Closure<XmlProvider>): Unit
fun xmlContent(name: String, pattern: PatternFilterable, xml: Action<in XmlProvider>): Unit

Adds the 'XMLContent' filter to all installation tasks. The configuration is based on XmlProvider.