Answers for "c# Get all class by namespace"

C#
0

c# Get all class by namespace

using System.Reflection;
private Type[] GetTypesInNamespace(Assembly assembly, string nameSpace)
{
    return 
      assembly.GetTypes()
              .Where(t => String.Equals(t.Namespace, nameSpace, StringComparison.Ordinal))
              .ToArray();
}
Posted by: Guest on December-15-2020

C# Answers by Framework

Browse Popular Code Answers by Language