public static List<String> split(final String inlineExpression) {
        List<String> result = new ArrayList<>();
        StringBuilder segment = new StringBuilder();
        int bracketsDepth = 0;
        for (int i = 0; i < inlineExpression.length(); i++) {
            char each = inlineExpression.charAt(i);
            switch (each) {
                case ',':
                    handleSplitter(bracketsDepth, segment, each, result);
                    break;
                case '$':
                    bracketsDepth = handleDollarSign(inlineExpression, i, bracketsDepth, segment, each);
                    break;
                case '}':
                    bracketsDepth = handleClosingBracket(bracketsDepth, segment, each);
                    break;
                default:
                    segment.append(each);
                    break;
            }
        }
        if (segment.length() > 0) {
            result.add(segment.toString().trim());
        }
        return result;
    }
@Test
    void assertSplit() {
        assertThat(GroovyUtils.split(" t_order_0, t_order_1 "), is(Arrays.asList("t_order_0", "t_order_1")));
        assertThat(GroovyUtils.split("t_order_${null}"), is(Collections.singletonList("t_order_${null}")));
        assertThat(GroovyUtils.split("t_order_${'xx'}"), is(Collections.singletonList("t_order_${'xx'}")));
        assertThat(GroovyUtils.split("t_order_${[0, 1, 2]},t_order_item_${[0, 2]}"),
                is(Arrays.asList("t_order_${[0, 1, 2]}", "t_order_item_${[0, 2]}")));
        assertThat(GroovyUtils.split("t_order_${0..2},t_order_item_${0..1}"), is(Arrays.asList("t_order_${0..2}", "t_order_item_${0..1}")));
        assertThat(GroovyUtils.split("t_${[\"new${1+2}\",'old']}_order_${1..2}"),
                is(Collections.singletonList("t_${[\"new${1+2}\",'old']}_order_${1..2}")));
        assertThat(GroovyUtils.split("t_$->{[\"new$->{1+2}\",'old']}_order_$->{1..2}"),
                is(Collections.singletonList("t_$->{[\"new$->{1+2}\",'old']}_order_$->{1..2}")));
    }