Is Reflection a nested namespace inside System namespace in C#?


December 2018


32 time


I was wondering why we need to specify using System.Reflection separately from using System while making use of methods in class Type. Is Reflection a nested namespace, inside System namespace?

2 answers


Using System namespace does not include all child namespaces.

Here, System.Reflection is a child namespace of System.So you have to import it explicitly by using directive.

Note:Same principle applies to all namespace in c# for example System and System.IO and many more.


Yes, System.Reflection is a namespace inside the System namespace.