From f4c5f5d858dd587ee23faad0af5f74d7a2a0a56e Mon Sep 17 00:00:00 2001 From: Crossplane Date: Fri, 18 Nov 2022 23:43:42 +0000 Subject: [PATCH] docs snapshot for crossplane version `master` --- content/docs/master/reference/composition.md | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/content/docs/master/reference/composition.md b/content/docs/master/reference/composition.md index f0f617df..b49a3758 100644 --- a/content/docs/master/reference/composition.md +++ b/content/docs/master/reference/composition.md @@ -557,6 +557,25 @@ You can use the following types of transform on a value being patched: au-east: Australia East ``` +`match`. A more complex version of `map` that can match different kinds of +patterns. It should be used if more advanced pattern matchings than a simple +string equality check are required. +The result of the first matching pattern is used as the output of this +transform. + +```yaml +- type: match + match: + patterns: + - type: literal # Not needed. This is the default. + literal: us-west + result: West US + - type: regexp + regexp: '^af-.*' + result: Somewhere in Africa + fallbackValue: Unknown +``` + `math`. Transforms values using math. The input value must be an integer. Currently only `multiply` is supported.