// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.

namespace Azure.Iot.Operations.Services.SchemaRegistry.SchemaRegistry
{
    using System.Collections.Generic;

    // Note that this class was once a generated class from the DTDL protocol compiler and it was included in a public facing API.
    // It is no longer generated by the WoT protocol compiler, but this class must be preserved as-is (namespace included) to avoid
    // breaking changes.

    /// <summary>
    /// Schema object
    /// </summary>
    public partial class Schema
    {
        /// <summary>
        /// Human-readable description of the schema.
        /// </summary>
        public string? Description { get; set; } = default;

        /// <summary>
        /// Human-readable display name.
        /// </summary>
        public string? DisplayName { get; set; } = default;

        /// <summary>
        /// Format of the schema.
        /// </summary>
        public Format Format { get; set; } = default!;

        /// <summary>
        /// Hash of the schema content.
        /// </summary>
        public string? Hash { get; set; } = default;

        /// <summary>
        /// Schema name.
        /// </summary>
        public string Name { get; set; } = default!;

        /// <summary>
        /// Schema registry namespace. Uniquely identifies a schema registry within a tenant.
        /// </summary>
        public string Namespace { get; set; } = default!;

        /// <summary>
        /// Content stored in the schema.
        /// </summary>
        public string SchemaContent { get; set; } = default!;

        /// <summary>
        /// Type of the schema.
        /// </summary>
        public SchemaType SchemaType { get; set; } = default!;

        /// <summary>
        /// Schema tags.
        /// </summary>
        public Dictionary<string, string>? Tags { get; set; } = default;

        /// <summary>
        /// Version of the schema. Allowed between 0-9.
        /// </summary>
        public string Version { get; set; } = default!;
    }
}
