diff --git a/content/en/docs/2023.11/Reference/Blocks/Text/find-text/find-all-text-block.md b/content/en/docs/2023.11/Reference/Blocks/Text/find-text/find-all-text-block.md index 0aca8fbf5..017e28955 100644 --- a/content/en/docs/2023.11/Reference/Blocks/Text/find-text/find-all-text-block.md +++ b/content/en/docs/2023.11/Reference/Blocks/Text/find-text/find-all-text-block.md @@ -329,7 +329,7 @@ It performs a [case-sensitive, culture-insensitive][Ordinal] comparison of text. #### Result -`"The quick brown fox jumps over the lazy dog"` contains 1 sequence starting with `"The"` and ending with `"jumps"`, which is `"The quick brown fox jumps"` Therefore, the variable `($)Matches` will be set to the following: +`"The quick brown fox jumps over the lazy dog"` contains 1 occurrence starting with `"The"` and ending with `"jumps"`, which is `"The quick brown fox jumps"` Therefore, the variable `($)Matches` will be set to the following: ```json [ @@ -399,7 +399,7 @@ It performs a [case-sensitive, culture-insensitive][Ordinal] comparison of text. #### Result -`"The quick brown fox jumps over the lazy dog. The dog woke up and tried to bite the fox. The fox jumps to get away."` has 0 sequences starting with `"The"` and ending with `"jumps"`, as [Contains][] being `null` will require an exact match for [Text to Find][TextToFind Property] in [Text][Text Property]. Therefore, the variable `($)Matches` will be set to the following: +`"The quick brown fox jumps over the lazy dog. The dog woke up and tried to bite the fox. The fox jumps to get away."` has 0 occurrences starting with `"The"` and ending with `"jumps"`, as [Contains][] being `null` will require an exact match for [Text to Find][TextToFind Property] in [Text][Text Property]. Therefore, the variable `($)Matches` will be set to the following: ```json [] @@ -520,15 +520,15 @@ If all properties of [Text To Find][TextToFind Property] are `null` or empty (i. ### Null or empty property of Text To Find If at least one, but not all properties of [Text To Find][TextToFind Property] are `null` or empty (i.e. `""`), then that section of the query is not included as a specific [Group][] in the returned [Match][]; see [Find all occurrences that start with and end with a Text To Find in Text][]. -There exist two special cases involving the Contains nested property of [Text To Find][TextToFind Property]; see below. +There exist two special cases involving the [Contains][] nested property of [Text To Find][TextToFind Property]; see below. #### Empty contains property of Text To Find -If the [Contains][] nested property of [Text To Find][TextToFind Property] is empty (i.e. `""`), and both the [StartsWith][] and [EndsWith][] nested properties are properly defined, then a valid match will be one starting with [StartsWith][], and ending with [EndsWith][], including and regardless of any content between the two; see [Find all occurrences that start with and end with a Text To Find in Text][]. +If the [Contains][] nested property of [Text To Find][TextToFind Property] is empty (i.e. `""`), and both the [StartsWith][] and [EndsWith][] nested properties are not null, then a valid match will be one starting with [StartsWith][], and ending with [EndsWith][], including of any content between the two groups; see [Find all occurrences that start with and end with a Text To Find in Text][]. #### Null contains property of Text To Find -If the [Contains][] nested property of [Text To Find][TextToFind Property] is `null`, and both the [StartsWith][] and [EndsWith][] nested properties are properly defined, then a valid match will be one starting with [StartsWith][], and ending with [EndsWith][], with no content allowed between the two, i.e. an exact match only; see [Find all occurrences that start with and end with a Text To Find in Text (Null contains)][]. +If the [Contains][] nested property of [Text To Find][TextToFind Property] is `null`, and both the [StartsWith][] and [EndsWith][] nested properties are not null, then a valid match will be one starting with [StartsWith][], and ending with [EndsWith][], with no content between the two groups, i.e. an exact match only; see [Find all occurrences that start with and end with a Text To Find in Text (Null contains)][]. ### Known Limitations diff --git a/content/en/docs/2023.11/Reference/Blocks/Text/find-text/find-text-block.md b/content/en/docs/2023.11/Reference/Blocks/Text/find-text/find-text-block.md index 1f8abeb88..ceea73cdc 100644 --- a/content/en/docs/2023.11/Reference/Blocks/Text/find-text/find-text-block.md +++ b/content/en/docs/2023.11/Reference/Blocks/Text/find-text/find-text-block.md @@ -11,13 +11,13 @@ description: "Finds the specified occurrence of a text in a given text." ## Description -Finds the nth of [Text To Find][TextToFind Property] in a given [Text][Text Property]. +Finds the specified [Occurrence][Occurrence Property] of [Text To Find][TextToFind Property] in a given [Text][Text Property]. [Search Options][SearchOptions Property] can be specified to choose whether to use a ContainsText, PatternMatching or Regex search to match the [Text To Find][TextToFind Property] input. ## Examples -### Find the nth occurrence of Text To Find (Ordinal) +### Find the specified Occurrence of Text To Find (Ordinal) This example will find the first occurrence of `"The"` in `"The quick brown fox jumps over the lazy dog"`. @@ -74,7 +74,7 @@ As this example is performing a [case-sensitive, culture-insensitive][Ordinal] c *** -### Find the nth occurrence of Text To Find (Ordinal Ignore Case) +### Find the specified Occurrence of Text To Find (Ordinal Ignore Case) This example will find the second occurrence of `"The"` in `"The quick brown fox jumps over the lazy dog"`. @@ -207,7 +207,7 @@ It performs a [case-insensitive, culture-insensitive][OrdinalIgnoreCase] compari #### Result -As this example is performing a [case-insensitive, culture-insensitive][OrdinalIgnoreCase] comparison of text, `"The quick brown fox jumps over the lazy dog"` contains the text `"The"` twice; the first occurrence is `"The"` and the second occurrence is `"the"`. As we are looking for [Occurrence][Occurrence Property] `2`, and there are only 2 matches, we cannot return a valid match. Therefore, the variable `($)Match` will be set to the following: +As this example is performing a [case-insensitive, culture-insensitive][OrdinalIgnoreCase] comparison of text, `"The quick brown fox jumps over the lazy dog"` contains the text `"The"` twice; the first occurrence is `"The"` and the second occurrence is `"the"`. As we are looking for [Occurrence][Occurrence Property] `2`, and there are only 2 matches, there is not a valid match. Therefore, the variable `($)Match` will be set to the following: ```json null @@ -215,7 +215,7 @@ null *** -### Find the nth occurrence that matches the pattern in Text To Find +### Find the specified Occurrence that matches the pattern in Text To Find This example will find the first occurrence of text that match a pattern containing `"?he"` in `"The quick brown fox jumps over the lazy dog"`. @@ -272,7 +272,7 @@ It performs a [case-sensitive, culture-insensitive][Ordinal] comparison of text. *** -### Find the nth occurrence that matches the regex in Text To Find +### Find the specified Occurrence that matches the regex in Text To Find This example will find the first occurrence of text that match the regex `"^The"` from `"The quick brown fox jumps over the lazy dog"`. @@ -329,7 +329,7 @@ It performs a [case-sensitive, culture-insensitive][Ordinal] comparison of text. *** -### Find the nth occurrence that starts with and ends with a Text To Find in Text +### Find the specified Occurrence that starts with and ends with a Text To Find in Text This example will find the first occurrence of text that starts with `"The"` and ends with `"jumps"` from `"The quick brown fox jumps over the lazy dog."`. @@ -348,7 +348,7 @@ It performs a [case-sensitive, culture-insensitive][Ordinal] comparison of text. #### Result -`"The quick brown fox jumps over the lazy dog"` contains 1 sequence starting with `"The"` and ending with `"jumps"`, which is `"The quick brown fox jumps"` Therefore, the variable `($)Match` will be set to the following: +`"The quick brown fox jumps over the lazy dog"` contains 1 occurrence starting with `"The"` and ending with `"jumps"`, which is `"The quick brown fox jumps"` Therefore, the variable `($)Match` will be set to the following: ```json { @@ -398,7 +398,7 @@ It performs a [case-sensitive, culture-insensitive][Ordinal] comparison of text. *** -### Find the nth occurrence that starts with and ends with a Text To Find in Text (Null contains) +### Find the specified Occurrence that starts with and ends with a Text To Find in Text (Null contains) This example will find the first occurrence of text that start with `"The"`, contains `null` and ends with `"jumps"` from `"The quick brown fox jumps over the lazy dog."`. To clarify, this [Text To Find][TextToFind Property] input is searching for matches of `"Thejumps"` exactly in [Text][Text Property]. @@ -417,7 +417,7 @@ It performs a [case-sensitive, culture-insensitive][Ordinal] comparison of text. #### Result -`"The quick brown fox jumps over the lazy dog."` has 0 sequences starting with `"The"` and ending with `"jumps"`, as [Contains][] being `null` will require an exact match for [Text to Find][TextToFind Property] in [Text][Text Property]. Therefore, the variable `($)Match` will be set to the following: +`"The quick brown fox jumps over the lazy dog."` has 0 occurrences starting with `"The"` and ending with `"jumps"`, as [Contains][] being `null` will require an exact match for [Text to Find][TextToFind Property] in [Text][Text Property]. Therefore, the variable `($)Match` will be set to the following: ```json null @@ -429,7 +429,7 @@ null ### Text -The [Text][Text Property] to find the nth occurrence of [Text To Find][TextToFind Property] in. +The [Text][Text Property] to find the specified occurrence of [Text To Find][TextToFind Property] in. | | | |--------------------|---------------------------| @@ -441,7 +441,7 @@ The [Text][Text Property] to find the nth occurrence of [Text To Find][TextToFin ### Text To Find -The [Text To Find][TextToFind Property] search query to find the nth occurrence of in [Text][Text Property]. This property contains all of the information in relation to the conditions for a valid match; these are: +The [Text To Find][TextToFind Property] search query to find the specified occurrence of in [Text][Text Property]. This property contains all of the information in relation to the conditions for a valid match; these are: * [Starts With][StartsWith] * [Contains][Contains] @@ -465,7 +465,7 @@ The [Text To Find][TextToFind Property] search query to find the nth occurrence ### Occurrence -The [Occurrence][Occurrence Property] of [Text To Find][TextToFind Property] in [Text][Text Property]. A value of `0` refers to the first occurrence, a value of `1` to the second occurrence and a value of `-1` to the last occurrence. +The [Occurrence][Occurrence Property] of [Text To Find][TextToFind Property] in [Text][Text Property]. For information about [supported values][Occurrences] for the [Occurrence][Occurrence Property] property and examples of how it can be used, please see [Occurrences][]. @@ -552,16 +552,16 @@ If all properties of [Text To Find][TextToFind Property] are `null` or empty (i. ### Null or empty property of Text To Find -If at least one, but not all properties of [Text To Find][TextToFind Property] are `null` or empty (i.e. `""`), then that section of the query is not included as a specific [Group][] in the returned [Match][]; see [Find the nth occurrence that starts with and ends with a Text To Find in Text][]. +If at least one, but not all properties of [Text To Find][TextToFind Property] are `null` or empty (i.e. `""`), then that section of the query is not included as a specific [Group][] in the returned [Match][]; see [Find the specified Occurrence that starts with and ends with a Text To Find in Text][]. There exist two special cases involving the [Contains][] nested property of [Text To Find][TextToFind Property]; see below. #### Empty contains property of Text To Find -If the [Contains][] nested property of [Text To Find][TextToFind Property] is empty (i.e. `""`), and both the [StartsWith][] and [EndsWith][] nested properties are properly defined, then a valid match will be one starting with [StartsWith][], and ending with [EndsWith][], including and regardless of any content between the two; see [Find the nth occurrence that starts with and ends with a Text To Find in Text][]. +If the [Contains][] nested property of [Text To Find][TextToFind Property] is empty (i.e. `""`), and both the [StartsWith][] and [EndsWith][] nested properties are not null, then a valid match will be one starting with [StartsWith][], and ending with [EndsWith][], including any content between the two groups; see [Find the specified Occurrence that starts with and ends with a Text To Find in Text][]. #### Null contains property of Text To Find -If the [Contains][] nested property of [Text To Find][TextToFind Property] is `null`, and both the [StartsWith][] and [EndsWith][] nested properties are properly defined, then a valid match will be one starting with [StartsWith][], and ending with [EndsWith][], with no content allowed between the two, i.e. an exact match only; see [Find the nth occurrence that starts with and ends with a Text To Find in Text (Null contains)][]. +If the [Contains][] nested property of [Text To Find][TextToFind Property] is `null`, and both the [StartsWith][] and [EndsWith][] nested properties are not null, then a valid match will be one starting with [StartsWith][], and ending with [EndsWith][], with no content between the two groups, i.e. an exact match only; see [Find the specified Occurrence that starts with and ends with a Text To Find in Text (Null contains)][]. ### Known Limitations @@ -573,8 +573,8 @@ If [Search Options][SearchOptions Property] is set to `SearchOptions.Regex` or ` [TextToFind Property]: {{< ref "#text-to-find" >}} [SearchOptions Property]: {{< ref "#search-options" >}} [ComparisonType Property]: {{< ref "#comparison-type" >}} -[Find the nth occurrence that starts with and ends with a Text To Find in Text]: {{}} -[Find the nth occurrence that starts with and ends with a Text To Find in Text (Null contains)]: {{}} +[Find the specified Occurrence that starts with and ends with a Text To Find in Text]: {{}} +[Find the specified Occurrence that starts with and ends with a Text To Find in Text (Null contains)]: {{}} [Input]: {{< url path="Cortex.Reference.Concepts.Fundamentals.Blocks.BlockProperties.WhatIsABlockProperty.Input" >}} [InputOutput]: {{< url path="Cortex.Reference.Concepts.Fundamentals.Blocks.BlockProperties.WhatIsABlockProperty.InputOutput" >}} diff --git a/content/en/docs/2023.11/Reference/Concepts/working-with/collections/occurrences.md b/content/en/docs/2023.11/Reference/Concepts/working-with/collections/occurrences.md index 7e277e889..ceec95a19 100644 --- a/content/en/docs/2023.11/Reference/Concepts/working-with/collections/occurrences.md +++ b/content/en/docs/2023.11/Reference/Concepts/working-with/collections/occurrences.md @@ -15,6 +15,7 @@ TODO - How are they accessed? - Positive or Negative int properties on blocks that operate on single items - Difference between occurrence and indexes +- specified occurrence ## Positive Occurrences diff --git a/content/en/docs/2023.11/Reference/data-types/text/regex/_index.md b/content/en/docs/2023.11/Reference/data-types/text/regex/_index.md index 2f70bdb3c..8bde0833f 100644 --- a/content/en/docs/2023.11/Reference/data-types/text/regex/_index.md +++ b/content/en/docs/2023.11/Reference/data-types/text/regex/_index.md @@ -1,6 +1,6 @@ --- title: "Regex" linkTitle: "Regex" -description: "Data types used for mirroring .NET Regex data types" +description: "Used to represent Regex data types" weight: 1 --- \ No newline at end of file diff --git a/content/en/docs/2023.11/Reference/data-types/text/regex/capturedetails.md b/content/en/docs/2023.11/Reference/data-types/text/regex/capturedetails.md index 04246679b..326f21377 100644 --- a/content/en/docs/2023.11/Reference/data-types/text/regex/capturedetails.md +++ b/content/en/docs/2023.11/Reference/data-types/text/regex/capturedetails.md @@ -1,7 +1,7 @@ --- title: "CaptureDetails" linkTitle: "CaptureDetails" -description: "Used to represent a capture within a group within a match for a text search performed by the Find Text and Find All Text sets of blocks." +description: "Used to represent a single capture for a given group" --- # {{% param title %}} diff --git a/content/en/docs/2023.11/Reference/data-types/text/regex/group.md b/content/en/docs/2023.11/Reference/data-types/text/regex/group.md index cba847ca8..b88c623ae 100644 --- a/content/en/docs/2023.11/Reference/data-types/text/regex/group.md +++ b/content/en/docs/2023.11/Reference/data-types/text/regex/group.md @@ -1,7 +1,7 @@ --- title: "Group" linkTitle: "Group" -description: "Used to represent a group within a match for a text search performed by the Find Text and Find All Text sets of blocks." +description: "Used to represent a regex match group. It contains all of the captures for a given group pattern." --- # {{% param title %}} diff --git a/content/en/docs/2023.11/Reference/data-types/text/regex/match.md b/content/en/docs/2023.11/Reference/data-types/text/regex/match.md index 6b0f0ba40..ffa46e477 100644 --- a/content/en/docs/2023.11/Reference/data-types/text/regex/match.md +++ b/content/en/docs/2023.11/Reference/data-types/text/regex/match.md @@ -1,7 +1,7 @@ --- title: "Match" linkTitle: "Match" -description: "Used to represent a text matching a text search performed by the Find Text and Find All Text sets of blocks" +description: "Used to represent a regex match. It contains all of the groups found in the regex pattern." --- # {{% param title %}} diff --git a/content/en/docs/2023.11/Reference/data-types/text/texttofind.md b/content/en/docs/2023.11/Reference/data-types/text/texttofind.md index 66ec9b589..607cb1ab1 100644 --- a/content/en/docs/2023.11/Reference/data-types/text/texttofind.md +++ b/content/en/docs/2023.11/Reference/data-types/text/texttofind.md @@ -1,7 +1,7 @@ --- title: "TextToFind" linkTitle: "TextToFind" -description: "Used to represent a search query for FindText blocks." +description: "Used to represent a search query for finding text." --- # {{% param title %}} @@ -10,7 +10,7 @@ description: "Used to represent a search query for FindText blocks." ## Summary -The `TextToFind` data type is used to represent a search query for finding text in another body of text. It specifies what a valid [match][Match] should start, contain and end with. +The `TextToFind` data type is used to represent a search query for finding text.

It specifies what a valid [match][Match] should start, contain and end with. | | | |-|-| @@ -27,9 +27,7 @@ The `TextToFind` data type is used to represent a search query for finding text ### Starts With -[Starts With][StartsWith Property] is used to define the string a valid match should start with. - -This property is not required. +[Starts With][StartsWith Property] is used to define the [String][] a valid match should start with. | | | |--------------------|---------------------------| @@ -40,9 +38,7 @@ This property is not required. ### Contains -[Contains][Contains Property] is used to define the string a valid match should contain. - -This property is not required. +[Contains][Contains Property] is used to define the [String][] a valid match should contains between [Starts With][StartsWith Property] and [Ends With][EndsWith Property]. | | | |--------------------|---------------------------| @@ -53,9 +49,7 @@ This property is not required. ### Ends With -[Ends With][EndsWith Property] is used to define the string a valid match should end with. - -This property is not required. +[Ends With][EndsWith Property] is used to define the [String][] a valid match should end with. | | | |--------------------|---------------------------| @@ -72,17 +66,17 @@ The following table shows some of the ways that a `TextToFind` can be created. | Method | Example | Result | Editor Support | Notes | |-|-|-|-|-| -| Use a `TextToFind` constructor | `new TextToFind(startsWith: "the", contains: "quick", endsWith: "fox")`| `{"StartsWith":"the", "Contains":"quick", "EndsWith":"fox"}` | Expression | All fields specified || +| Use a `TextToFind` constructor | `new TextToFind(startsWith: "the", contains: "quick", endsWith: "fox")`| `{"StartsWith":"the", "Contains":"quick", "EndsWith":"fox"}` | Expression | || A `TextToFind` can also be created using the Literal Editor by filling in the necessary values for the following properties: | Property | Data Type | Example | Notes | |-|-|-|-| -| `Starts With` | `String` | `"the"` | [Starts With][StartsWith Property] defines the string a valid match should start with. | +| `StartsWith` | `String` | `"the"` | [Starts With][StartsWith Property] defines the string a valid match should start with. | | `Contains` | `String` | `"quick"` | [Contains][Contains Property] defines the string a valid match should contain. | -| `Ends With` | `String` | `"fox"` | [Ends With][EndsWith Property] defines the string a valid match should end with. | +| `EndsWith` | `String` | `"fox"` | [Ends With][EndsWith Property] defines the string a valid match should end with. | -### Convert EmailAddress to Text +### Convert TextToFind to Text | Method | Example | Result | Editor Support | Notes | |-|-|-|-|-| @@ -102,7 +96,7 @@ None ### Related Data Types -None +* [String][] ### Related Concepts