示例#1
0
 public static bool IsPluginClass(this ClassDeclarationSyntax classDeclaration)
 {
     return(classDeclaration.GetExports()
            .Intersect(allPlugins)
            .Any());
 }
示例#2
0
 public static string[] GetMissingInterfaces(this ClassDeclarationSyntax classDeclaration)
 {
     return(classDeclaration.GetExports()
            .Except(classDeclaration.GetInterfaces())
            .ToArray());
 }
示例#3
0
 public static bool IsExportIPlugin(this ClassDeclarationSyntax classDeclaration)
 => classDeclaration.GetExports().Contains(nameof(IPlugin));