Your initial code included "PrefetchPathAuditInfoDetail".
That's what I was asking about. Is this hardcoded as shown in your initial code?
i.e. is this for real, or just to demonstrate your issue.
Anyway.
V.4.0 introduces no new solution for this. But there is a technique you can use to avoid reflection.
From your code it appears that you have some entities that should have this property "PrefetchPathAuditInfoDetail", but then since the type of the entity is not known at coding time, you are residing to reflection to access this property.
Well you can define an Interface having this property, then for those entities that share this common property, they should implement that interface. (you can add this in a separate file, for each entity "partial classes" to avoid being overwritten when regenerating the code).
Now in the piece of code at hand, you should cast the auditInfo entity to that Interface, and access the prefetchPath property.