![]() ![]() When writing a C# code that uses reflection, the coder can use the typeof operator to get the object's type or use the GetType() method to get the type of the current instance. The System.Reflection namespace contains classes and interfaces that provide a managed view of loaded types, methods, and fields, with the ability to dynamically create and invoke types. By using Reflection in C#, one is able to find out details of an object, method, and create objects and invoke methods at runtime. Reflection is similar to C++ RTTI (Runtime Type Information), but much broader in scope and capability. A program reflects on itself by extracting metadata from its assembly and using that metadata either to inform the user or to modify its own behavior. In other words, reflection provides objects that encapsulate assemblies, modules and types. ![]() Reflection is the ability of a managed code to read its own metadata for the purpose of finding assemblies, modules and type information at runtime. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |