/*
 * ProxMox VE API
 *
 * ProxMox VE API
 *
 * The version of the OpenAPI document: 2.0
 * Contact: support@lumaserv.com
 * Generated by: https://github.com/openapitools/openapi-generator.git
 */


using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using Newtonsoft.Json.Linq;
using System.ComponentModel.DataAnnotations;
using OpenAPIDateConverter = ProxmoxSharp.Client.OpenAPIDateConverter;

namespace ProxmoxSharp.Model
{
    /// <summary>
    /// GetClusterConfigJoin200ResponseData
    /// </summary>
    [DataContract(Name = "getClusterConfigJoin_200_response_data")]
    public partial class GetClusterConfigJoin200ResponseData : IValidatableObject
    {
        /// <summary>
        /// Initializes a new instance of the <see cref="GetClusterConfigJoin200ResponseData" /> class.
        /// </summary>
        /// <param name="configDigest">configDigest.</param>
        /// <param name="nodelist">nodelist.</param>
        /// <param name="preferredNode">The cluster node name..</param>
        /// <param name="totem">totem.</param>
        public GetClusterConfigJoin200ResponseData(string configDigest = default(string), List<GetClusterConfigJoin200ResponseDataNodelistInner> nodelist = default(List<GetClusterConfigJoin200ResponseDataNodelistInner>), string preferredNode = default(string), Object totem = default(Object))
        {
            this.ConfigDigest = configDigest;
            this.Nodelist = nodelist;
            this.PreferredNode = preferredNode;
            this.Totem = totem;
        }

        /// <summary>
        /// Gets or Sets ConfigDigest
        /// </summary>
        [DataMember(Name = "config_digest", EmitDefaultValue = false)]
        public string ConfigDigest { get; set; }

        /// <summary>
        /// Gets or Sets Nodelist
        /// </summary>
        [DataMember(Name = "nodelist", EmitDefaultValue = false)]
        public List<GetClusterConfigJoin200ResponseDataNodelistInner> Nodelist { get; set; }

        /// <summary>
        /// The cluster node name.
        /// </summary>
        /// <value>The cluster node name.</value>
        [DataMember(Name = "preferred_node", EmitDefaultValue = false)]
        public string PreferredNode { get; set; }

        /// <summary>
        /// Gets or Sets Totem
        /// </summary>
        [DataMember(Name = "totem", EmitDefaultValue = false)]
        public Object Totem { get; set; }

        /// <summary>
        /// Returns the string presentation of the object
        /// </summary>
        /// <returns>String presentation of the object</returns>
        public override string ToString()
        {
            StringBuilder sb = new StringBuilder();
            sb.Append("class GetClusterConfigJoin200ResponseData {\n");
            sb.Append("  ConfigDigest: ").Append(ConfigDigest).Append("\n");
            sb.Append("  Nodelist: ").Append(Nodelist).Append("\n");
            sb.Append("  PreferredNode: ").Append(PreferredNode).Append("\n");
            sb.Append("  Totem: ").Append(Totem).Append("\n");
            sb.Append("}\n");
            return sb.ToString();
        }

        /// <summary>
        /// Returns the JSON string presentation of the object
        /// </summary>
        /// <returns>JSON string presentation of the object</returns>
        public virtual string ToJson()
        {
            return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
        }

        /// <summary>
        /// To validate all properties of the instance
        /// </summary>
        /// <param name="validationContext">Validation context</param>
        /// <returns>Validation Result</returns>
        IEnumerable<ValidationResult> IValidatableObject.Validate(ValidationContext validationContext)
        {
            yield break;
        }
    }

}
