What is reflection?
Answer Posted / kirti
All .NET compilers produce metadata about the types defined in the modules they produce. This metadata is packaged along with the module (modules in turn are packaged together in assemblies), and can be accessed by a mechanism called reflection. The System.Reflection namespace contains classes that can be used to interrogate the types for a module/assembly.
Using reflection to access .NET metadata is very similar to using ITypeLib/ITypeInfo to access type library data in COM, and it is used for similar purposes - e.g. determining data type sizes for marshaling data across context/process/machine boundaries.
Reflection can also be used to dynamically invoke methods (see System.Type.InvokeMember ) , or even create types dynamically at run-time (see System.Reflection.Emit.TypeBuilder).
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What are Code Blocks in Views?
What is representational state transfer (rest) mean?
What is Peek method in Tempdata in ASP.Net MVC?
What is entity graph? : Entity framework
What is domain class model?
Will c# 3.0, vb.net 9.0, atlas, or linq be included in the .net framework 3.0?
When using razor views, do you have to take any special steps to protect your asp.net mvc application from cross site scripting (xss) attacks?
Why we need a separate mobile project template, while we can render our web application in mobile ?
Which is the root namespace for fundamental types in .net framework?
How do I install .net framework?
What “beforFilter()”,“beforeRender” and “afterFilter” functions do in Controller?
what is way of loading data in ef (entity framework)?
What is the version number for the next version of the .net framework, codenamed �orcas�?
What is viewdata?
How route table is created in ASP.NET MVC?