Ejemplo n.º 1
0
 protected IEnumerable <AnalyzerTreeNode> FetchChildren(CancellationToken ct)
 {
     if (symbol is IEntity)
     {
         var context = new AnalyzerContext()
         {
             CancellationToken = ct,
             Language          = Language,
             AssemblyList      = MainWindow.Instance.CurrentAssemblyList
         };
         foreach (var result in analyzer.Analyze(symbol, context))
         {
             yield return(SymbolTreeNodeFactory(result));
         }
     }
     else
     {
         throw new NotSupportedException("Currently symbols that are not entities are not supported!");
     }
 }
Ejemplo n.º 2
0
 protected IEnumerable <AnalyzerTreeNode> FetchChildren(CancellationToken ct)
 {
     if (symbol is IEntity)
     {
         var context = new AnalyzerContext()
         {
             CancellationToken = ct,
             Language          = Language,
             AssemblyList      = MainWindow.Instance.CurrentAssemblyList
         };
         var results = analyzer.Analyze(symbol, context).Select(SymbolTreeNodeFactory);
         if (context.SortResults)
         {
             results = results.OrderBy(tn => tn.Text?.ToString(), NaturalStringComparer.Instance);
         }
         return(results);
     }
     else
     {
         throw new NotSupportedException("Currently symbols that are not entities are not supported!");
     }
 }