3 ms·
Reflection is the concept of having a program have knowledge about it's own structure. Kinda like having your code look into a mirror. A really basic example o
by robbbbbbbbb 10y ago
Reflection is the concept of having a program have knowledge about it's own structure. Kinda like having your code look into a mirror.
A really basic example of this is having you code get a list of all the names of fields of a class. This would be very useful if you want to create a generic object serializer.
In the past I used this to create a framework that would generate a UI for you based on class definitions.
Reflection can also include being able to modify your own code structure during run time.
- bogomipz 10y agoGreat explanation, thanks.