//------------------------------------------------------------------------------ // // This code was generated by a tool. // // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. // //------------------------------------------------------------------------------ namespace Brutal.GltfApi { using System.Linq; using System.Runtime.Serialization; using System.Text.Json.Serialization; /// /// Object part of the GLTF file schema /// Sparse storage of accessor values that deviate from their initialization value. /// public partial class AccessorSparse { /// /// Backing field for Count. /// private int m_count; /// /// Backing field for Indices. /// private AccessorSparseIndices m_indices; /// /// Backing field for Values. /// private AccessorSparseValues m_values; /// /// Backing field for Extensions. /// private System.Collections.Generic.Dictionary m_extensions; /// /// Backing field for Extras. /// private Extras m_extras; /// /// Number of deviating accessor values stored in the sparse array. /// [System.Text.Json.Serialization.JsonRequiredAttribute()] [System.Text.Json.Serialization.JsonPropertyNameAttribute("count")] public int Count { get { return this.m_count; } set { if ((value < 1)) { throw new System.ArgumentOutOfRangeException("Count", value, "Expected value to be greater than or equal to 1"); } this.m_count = value; } } /// /// An object pointing to a buffer view containing the indices of deviating accessor values. The number of indices is equal to `count`. Indices **MUST** strictly increase. /// [System.Text.Json.Serialization.JsonRequiredAttribute()] [System.Text.Json.Serialization.JsonPropertyNameAttribute("indices")] public AccessorSparseIndices Indices { get { return this.m_indices; } set { this.m_indices = value; } } /// /// An object pointing to a buffer view containing the deviating accessor values. /// [System.Text.Json.Serialization.JsonRequiredAttribute()] [System.Text.Json.Serialization.JsonPropertyNameAttribute("values")] public AccessorSparseValues Values { get { return this.m_values; } set { this.m_values = value; } } /// /// JSON object with extension-specific objects. /// [System.Text.Json.Serialization.JsonPropertyNameAttribute("extensions")] public System.Collections.Generic.Dictionary Extensions { get { return this.m_extensions; } set { this.m_extensions = value; } } /// /// Application-specific data. /// [System.Text.Json.Serialization.JsonPropertyNameAttribute("extras")] public Extras Extras { get { return this.m_extras; } set { this.m_extras = value; } } /// /// This method is used to determine if the Indices property should be serialized. /// public bool ShouldSerializeIndices() { return ((m_indices == null) == false); } /// /// This method is used to determine if the Values property should be serialized. /// public bool ShouldSerializeValues() { return ((m_values == null) == false); } /// /// This method is used to determine if the Extensions property should be serialized. /// public bool ShouldSerializeExtensions() { return ((m_extensions == null) == false); } /// /// This method is used to determine if the Extras property should be serialized. /// public bool ShouldSerializeExtras() { return ((m_extras == null) == false); } } }