You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The current API introduced in 6.0.0 and driven by Newtonsoft JSON gives access to meta-data on any JSON object via a TryGetValue<T>(string key) method.
The properties (i.e. their keys and value type) are not know in some use-cases and for that users need to be able to query or iterate them.
Here's some initial suggestion to add on any de-serialization class:
bool HasProperty(string key, out Type propertyType)
IEnumerable<string> GetPropertyKeys which iterates all non-known properties.
T GetPropertyValue<T>(string key) to retrieve a property's value.
While Newtonsoft JSON would be capable of that, the dual de-serialization class setup (GLTFast.Schema vs. GLTFast.Newtonsoft.Schema) did not allow us to add this without breaking the API or compromising bad design in the API.
The text was updated successfully, but these errors were encountered:
The current API introduced in 6.0.0 and driven by Newtonsoft JSON gives access to meta-data on any JSON object via a
TryGetValue<T>(string key)
method.The properties (i.e. their keys and value type) are not know in some use-cases and for that users need to be able to query or iterate them.
Here's some initial suggestion to add on any de-serialization class:
bool HasProperty(string key, out Type propertyType)
IEnumerable<string> GetPropertyKeys
which iterates all non-known properties.T GetPropertyValue<T>(string key)
to retrieve a property's value.While Newtonsoft JSON would be capable of that, the dual de-serialization class setup (
GLTFast.Schema
vs.GLTFast.Newtonsoft.Schema
) did not allow us to add this without breaking the API or compromising bad design in the API.The text was updated successfully, but these errors were encountered: