So i've been having trouble with finding a solution to this task: I need to split out the following example string:
(item:940x1 || (item:941x1 && item:935x2)) && item:942x2 && (item:123x1 && item:123x1)
into the following array of strings:
(item:940x1 || (item:941x1 && item:935x2)) //Will split this nested group later
item:942x2
(item:123x1 && item:123x1) //Do not need the parenthesis here retained. Can be removed after splitting.
I've tried various ways to split it, including Regex(which i was told doesn't handled nested patterns). Does anyone have a good solution?