title: How to get Type from TypeInfo in WinRT?
body: <p>I want to register all my view models for serialization, by convention.</p>
  
  <p>However the following code will not compile because the var <code>viewmodel</code> in the foreach loop is of type <code>TypeInfo</code>:</p>
  
  <pre><code>protected override void OnRegisterKnownTypesForSerialization()
  {
      var viewModels = this.GetType().GetTypeInfo().Assembly.DefinedTypes
              .Where(t =&gt; _viewModelNameRegex.IsMatch(t.FullName))
              .ToList();
  
      foreach (var viewmodel in viewModels)
      {
          SessionStateService.RegisterKnownType(viewmodel);
      }
  }
  </code></pre>
  
  <p>Apparently <code>TypeInfo</code> does not inherit from <code>Type</code>:</p>
  
  <pre><code>public abstract class TypeInfo : MemberInfo, IReflectableType
  </code></pre>
  
  <p>Unlike the <a href="http://msdn.microsoft.com/en-us/library/system.reflection.typeinfo.aspx" rel="noreferrer">full featured version</a>, which does inherit from <code>Type</code>.</p>
  
  <p>So how can I get to <code>Type</code> from a WinRT <code>TypeInfo</code>?</p>