Skip to main content

Questions tagged [reflection]

Reflection is the ability of a computer program to examine, introspect, and modify its own structure and behavior at runtime.

3 votes
0 answers
117 views

I am in the process of writing my own software renderer. I am currently working on setting up a shader system that allows users of the renderer to create their own Vertex Shader and Fragment Shader. ...
PiastriTheBottler's user avatar
1 vote
7 answers
538 views

In my multiplayer game I keep track of each player's inventory. I have a class for each inventory action that extends the abstract class InventoryItem. I then polymorphically call use() on the ...
Marvin's user avatar
  • 222
13 votes
6 answers
10k views

Suppose we have an Instance class in a C++ program, which has a GUID/UUID, name, parents, children, and other properties which can be saved to or loaded from an XML file. The intuitive approach for ...
Bunabyte's user avatar
  • 641
1 vote
1 answer
114 views

I'm modeling a part of Python/Qt GUI code which uses reflection to construct a collection of widgets, in a form. The code works like this: There is a Model which has attributes of various types, ...
Daniël Schenk's user avatar
0 votes
1 answer
2k views

I had an idea for a piece of software using .NET C# as technology. Basically, in my idea Im thinking of using reflection to do the mapping between a class to another class using interactivity with a ...
Nmaster88's user avatar
  • 167
1 vote
1 answer
188 views

At my company we needed access to some variable to call a method on it, this variable is hidden about 6 layers down of different libraries code and each time it is behind a private variables (that ...
JustSomeGuy's user avatar
17 votes
4 answers
6k views

For example if I have a class like class Foo { public int bar; public Foo(int constructor_var) { bar = construction_var; } public bar_plus_one() { return bar++; }...
ewhiting's user avatar
  • 319
2 votes
2 answers
1k views

Imagine the following situation: 1. Consume a 3rd party WSDL, out comes thousands of classes. 2. There's an opportunity to optimize performance by using a custom paralleled implementation. 3. Wsdl ...
Chad Harrison's user avatar
3 votes
1 answer
2k views

I will directly come to our current working flow so that you can understand the problem in a clear picture. I am attached in Laboratory Automation System in which Analyzer (a machine that performs ...
Faizan Mubasher's user avatar
2 votes
3 answers
4k views

Lets say I am building an application where clients can book bus tickets. The only thing they do is select, origin, destination and the type of service (express or standard). The system will then book ...
masber's user avatar
  • 327
0 votes
1 answer
225 views

Are there any patterns that address how to have and application load and run user defined code at run-time? I am looking into developing a C# library that the users of a Test Executive application (...
Doug Tait's user avatar
2 votes
3 answers
313 views

I am currently working on a project that generates videos from templates (a template being a collection of JSON files and assets). It seems natural to have a Template class that contains all the info ...
Jan Hettenkofer's user avatar
0 votes
1 answer
93 views

I don't normally use reflection directly while programming in Java. But I do use APIs and frameworks that internally rely on reflection or annotations to provide customization points. A lot of ...
Tim Seguine's user avatar
1 vote
1 answer
1k views

I need to call a method that is available in a third party library, but it is a private method. There is no direct or indirect way to obtain the same functionality via public methods available. I ...
h22's user avatar
  • 966
1 vote
1 answer
105 views

I'm working on a project where I have two programs which need to invoke methods on some of each other's objects. I do this by sending JSON objects over a TCP connection. These objects have a ...
lane spangler's user avatar

15 30 50 per page