How do I get the specific CPP type of the individual UProperty in C++?

Hi, I am currently working on an automation tool that can check if the values of the datatable entries are valid. The basic functionality includes grabbing a Uproperty in a Ustruct by the property name, finding out the specific CPP type(like float, int, static mesh, texture, etc.), then extracting its value to do further processing. However, I found that given a Ustruct, there is no way for me to auto detect the specific CPP type of the Uproperty; the only thing that I could do was to cast it to a specific property type(like UFloatProperty), then call GetPropertyValue() on it. I noticed that in the Editor when we create a datatable, unreal engine somehow can create the exact matching type and field for us to put our entries in, with the corresponding row structure. I was wondering how unreal engine did this? Is it done via reflection? Is there someway for me to replicate this method and put it in my own implementation? Below is my function on extracting a property value. Any help would be appreciated!