title: How do I use regex to split only on commas not in angle brackets?
body: <p>I have the string
  <code>DobuleGeneric&lt;DoubleGeneric&lt;int,string&gt;,string&gt;</code></p>
  
  <p>I am trying to grab the 2 type arguments:
  <code>DoubleGeneric&lt;int,string&gt;</code> and <code>string</code></p>
  
  <p>Initially I was using a split on ','. This worked, but only if the generic args are not themeselves generic.</p>
  
  <p><strong>My Code:</strong></p>
  
  <pre><code>string fullName = "DobuleGeneric&lt;DoubleGeneric&lt;int,string&gt;,string&gt;";
  Regex regex = new Regex( @"([a-zA-Z\._]+)\&lt;(.+)\&gt;$" );
  Match m = regex.Match( fullName );
  string frontName = m.Groups[1].Value;
  string[] innerTypes = m.Groups[2].Value.Split( ',' );
  
  foreach( string strInnerType in innerTypes ) {
          Console.WriteLine( strInnerType );
  }
  </code></pre>
  
  <p><strong>Question:</strong>
  How do I do a regex split on commas that are not encapsulated in angle brackets?</p>