Page 1 of 1

Runtime reflections

Posted: 28 Jul 2024, 05:06
by n3b
Hey guys, if I'm not missing anything, the c++ reflections docs are referring to templates/macros only, implying types are to be known at compile time.
I wonder if there is a public API or something else to use it in a way like .Net proxies do?
i.e. what's the proper way to map type names from xaml to whatever instances I have?

P.S. heads up for the StencilMode enum has less values in c# sdk than in c++ (3.2.4)

Re: Runtime reflections

Posted: 29 Jul 2024, 01:10
by n3b
never mind, figured it out by unwrapping all the macros!

Re: Runtime reflections

Posted: 29 Jul 2024, 15:03
by jsantos
Thank you, could you please create a ticket for StencilMode enum issue?

Re: Runtime reflections

Posted: 29 Jul 2024, 18:11
by n3b
So after digging into it a little bit more I figured out that nested properties are locked to static types only due to TypeProperty::FindMeta(const TypeClass* metaDataType) relying on StaticGetClassType.
Would be really nice to have FindMeta to be virtual as well...

Going to create a ticket for StencilMode and maybe for FindMeta as well?

Re: Runtime reflections

Posted: 30 Jul 2024, 13:37
by jsantos
Thanks for the tickets, let's continue the conversations there (#3565, #3564)