Replies: 2 comments 1 reply
-
|
(Sorry, i deleted my former comment. I confused serialization and deserialization) Would the object graph to be serialized suitable for serialization into a |
Beta Was this translation helpful? Give feedback.
-
|
TypeInfoResolver alone definitely wont be enough. Im not 100% sure but my guts are telling me that you could try writing custom converter that tracks at what path you are and skip writing json/delegating to actual converter when hitting correct path |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
I am attempting to create a utility that will allow consumers to skip particular fields during serialization, using a simple string syntax (e.g.,
ParentObject.ChildObject.Property). However, I cannot find a way to resolve the full JSON path from aJsonTypeInfo. My solution must resolve the target property by all property names rather than their types, as it is possible in my domain model to have multiple properties that share a type but should have different handling.Here's a brief example showing what I'm trying to do:
Is there anything I'm missing, or is this just not possible with
System.Text.Json?Beta Was this translation helpful? Give feedback.
All reactions