Preserving Original Type Information with Schema Validation

Is it possible to define a schema so it validates all the fields you are interested in, but it also keeps a reference to the original value retaining the type information? For example, when you want to validate something like fields inside a class? I know you can configure it as "preserve" extra fields, but the type information is lost
Was this page helpful?