We know that, for the Extract text action, we can use Regex and capture the (1) First match, (2) Group 1, (3) Full match. But I wonder if we can capture multiple groups and let's say put the captured texts in an array or concatenate them with comma?
Here is an example, a html snippet showing the tag of a manga, I want to extract the tags (Sci-Fi, Monsters, Comedy, Military, Slice of Life):
<div><!----><a class="a"><!---->Sci-Fi</a><a class="b"><!---->Monsters</a><a class="c"><!---->Comedy</a><a><!---->Military</a><a><!---->Slice of Life</a></div>
A stupid method is to use a loop: extract group 1 > put it in an array > delete it from the raw string > loop again until no any match.
Another method is using Split to array action, but this always assume the tags are separated by the same delimiter, but this is not always the case. So I will need extra text manipulation steps for the splitted segments.
Both methods require extra steps other than the text extraction action and this is CPU consuming. Programming language can usually do this in simple step, e.g., matches = re.findall(pattern, text) in Python, so I wonder if there is more simple, elegant way to do the same in MacroDroid?