From 5a7e14eaaa4278343ff628c692d475be9732c94e Mon Sep 17 00:00:00 2001 From: "sebastian.sellmair" Date: Thu, 13 Aug 2020 10:32:52 +0200 Subject: Implement SourceSetMergingPageTransformer --- core/src/main/kotlin/model/properties/PropertyContainer.kt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'core/src/main/kotlin/model') diff --git a/core/src/main/kotlin/model/properties/PropertyContainer.kt b/core/src/main/kotlin/model/properties/PropertyContainer.kt index 6009bfe0..b14a30f5 100644 --- a/core/src/main/kotlin/model/properties/PropertyContainer.kt +++ b/core/src/main/kotlin/model/properties/PropertyContainer.kt @@ -26,6 +26,7 @@ class PropertyContainer internal constructor( operator fun PropertyContainer.plus(prop: ExtraProperty?): PropertyContainer = if (prop == null) this else PropertyContainer(map + (prop.key to prop)) + interface WithExtraProperties { val extra: PropertyContainer @@ -57,4 +58,4 @@ fun C.mergeExtras(left: C, right: C): C where C : Any, C : WithExtraProperti val newExtras = PropertyContainer((unambiguous.flatten() + replaces).associateBy { it.key }) return needingFullMerge.fold(withNewExtras(newExtras)) { acc, merger -> merger(acc, left, right) } -} \ No newline at end of file +} -- cgit