Reflection in .Net

Question posted in Computer Software on 11 2009
Rate question difficulty level 1 Votes
What is Reflection in .net and when do you use it ?
 
 
2 Answers
 
Reflection is a very powerful feature that any programming language would like to provide, because it allows us to get some information about objects in runtime. It can be used in the applications normally but this is provided for doing some advanced programming. This might be for runtime code generation (It goes through creating, compilation and execution of source code in runtime).

The namespace System.Reflection contains classes that can be used for interrogating the types for a module/assembly.We use reflection for examining data types sizes for marshalling  across process & machine boundaries.

Reflection is also used for :
- Dynamically invoke methods (System.Type.InvokeMember)
- Dynamically create type at runtime (System.reflection.Emit.TypeBuilder)

11/15/2009
 
 
--API, Capable to read metadata from dot net objects(Types).
--API, Capable to load types dynamically with the help of metadata

11/30/2009
 
 
Add an answer*
 
Email
Now hiring!
Intuit 
---------------------------
---------------------------
---------------------------
---------------------------
---------------------------
---------------------------
---------------------------