/* 
 * TSE Cloud - CO
 *
 * This is Swagger Docs for Document WebApi Teamsystemn Enterprise Cloud, more detail at [https://swagger.io](https://swagger.io).
 *
 * OpenAPI spec version: v2025.3000
 * 
 * Generated by: https://github.com/swagger-api/swagger-codegen.git
 */
using System;
using System.Linq;
using System.IO;
using System.Text;
using System.Text.RegularExpressions;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Runtime.Serialization;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using System.ComponentModel.DataAnnotations;
using SwaggerDateConverter = IO.Swagger.Client.SwaggerDateConverter;
namespace IO.Swagger.Model
{
    /// <summary>
    /// CG1J_INDIRIZZI - AddressCO&lt;br&gt;Proprietà chiave:&lt;ul&gt;&lt;li&gt;&lt;b&gt;Id&lt;/b&gt;&lt;/li&gt;&lt;/ul&gt;
    /// </summary>
    [DataContract]
        public partial class AddressCODTO :  IEquatable<AddressCODTO>, IValidatableObject
    {
        /// <summary>
        /// Initializes a new instance of the <see cref="AddressCODTO" /> class.
        /// </summary>
        /// <param name="codiceCg16">codiceCg16.</param>
        /// <param name="cap">CG1J_CAP - Cap.</param>
        /// <param name="cellnum">CG1J_CELLNUM - Cellulare.</param>
        /// <param name="citta">CG1J_CITTA - Città.</param>
        /// <param name="codicesfed">CG1J_CODICESFED - Stato federato.</param>
        /// <param name="codlinguaMg52">CG1J_CODLINGUA_MG52 - Codice lingua.</param>
        /// <param name="comanaCg01">CG1J_COMANA_CG01 - ComanaCg01.</param>
        /// <param name="contea">CG1J_CONTEA - Contea.</param>
        /// <param name="datacre">CG1J_DATACRE - Data creazione.</param>
        /// <param name="datamod">CG1J_DATAMOD - Data modifica.</param>
        /// <param name="edificio">CG1J_EDIFICIO - Edificio.</param>
        /// <param name="email">CG1J_EMAIL - Email.</param>
        /// <param name="emailPec">CG1J_EMAIL_PEC - Email pec.</param>
        /// <param name="fax">CG1J_FAX - Fax.</param>
        /// <param name="frazione">CG1J_FRAZIONE - Frazione.</param>
        /// <param name="guid">CG1J_GUID - GUID.</param>
        /// <param name="id">CG1J_ID - ID (Required only in PUT/PATCH).</param>
        /// <param name="idTeamportal">CG1J_ID_TEAMPORTAL - IdTeamportal.</param>
        /// <param name="indirizzocomp">CG1J_INDIRIZZOCOMP - Indirizzo completo.</param>
        /// <param name="indirizzocomp2">CG1J_INDIRIZZOCOMP2 - Indirizzo completo aggiuntivo.</param>
        /// <param name="indirizzoex">CG1J_INDIRIZZOEX - Indirizzo esteso.</param>
        /// <param name="indweb">CG1J_INDWEB - Indirizzo web.</param>
        /// <param name="latitudine">CG1J_LATITUDINE - Latitudine.</param>
        /// <param name="longitudine">CG1J_LONGITUDINE - Longitudine.</param>
        /// <param name="numciv">CG1J_NUMCIV - Numero civico.</param>
        /// <param name="precisione">CG1J_PRECISIONE - Precisione.</param>
        /// <param name="presso">CG1J_PRESSO - c/o - Edificio.</param>
        /// <param name="pv">CG1J_PV - PV.</param>
        /// <param name="ragsoc">CG1J_RAGSOC - Ragione sociale.</param>
        /// <param name="ragsocex">CG1J_RAGSOCEX - Ragsocex.</param>
        /// <param name="rifindirizzo">CG1J_RIFINDIRIZZO - Rifindirizzo.</param>
        /// <param name="risregione">CG1J_RISREGIONE - Risregione.</param>
        /// <param name="risstato">CG1J_RISSTATO - Risstato.</param>
        /// <param name="riswarning">CG1J_RISWARNING - Riswarning.</param>
        /// <param name="riszip">CG1J_RISZIP - Riszip.</param>
        /// <param name="statoCg07">CG1J_STATO_CG07 - StatoCg07.</param>
        /// <param name="statofed">CG1J_STATOFED - Stato federato.</param>
        /// <param name="telefono">CG1J_TELEFONO - Telefono.</param>
        /// <param name="tipologia">CG1J_TIPOLOGIA - Tipologia.</param>
        /// <param name="via">CG1J_VIA - Indirizzo - N.civico.</param>
        /// <param name="addressesType">addressesType.</param>
        /// <param name="federalStateViewCO">federalStateViewCO.</param>
        /// <param name="statoEst">statoEst.</param>
        /// <param name="additionalData">additionalData.</param>
        /// <param name="pluginData">pluginData.</param>
        public AddressCODTO(int? codiceCg16 = default(int?), string cap = default(string), string cellnum = default(string), string citta = default(string), string codicesfed = default(string), string codlinguaMg52 = default(string), string comanaCg01 = default(string), string contea = default(string), DateTime? datacre = default(DateTime?), DateTime? datamod = default(DateTime?), string edificio = default(string), string email = default(string), string emailPec = default(string), string fax = default(string), string frazione = default(string), Guid? guid = default(Guid?), long? id = default(long?), long? idTeamportal = default(long?), string indirizzocomp = default(string), string indirizzocomp2 = default(string), string indirizzoex = default(string), string indweb = default(string), double? latitudine = default(double?), double? longitudine = default(double?), string numciv = default(string), string precisione = default(string), string presso = default(string), string pv = default(string), string ragsoc = default(string), string ragsocex = default(string), string rifindirizzo = default(string), string risregione = default(string), string risstato = default(string), string riswarning = default(string), string riszip = default(string), double? statoCg07 = default(double?), string statofed = default(string), string telefono = default(string), string tipologia = default(string), string via = default(string), List<AddressTypeCODTO> addressesType = default(List<AddressTypeCODTO>), FederalStateViewCODTO federalStateViewCO = default(FederalStateViewCODTO), NationCODTO statoEst = default(NationCODTO), Dictionary<string, Object> additionalData = default(Dictionary<string, Object>), Dictionary<string, Object> pluginData = default(Dictionary<string, Object>))
        {
            this.CodiceCg16 = codiceCg16;
            this.Cap = cap;
            this.Cellnum = cellnum;
            this.Citta = citta;
            this.Codicesfed = codicesfed;
            this.CodlinguaMg52 = codlinguaMg52;
            this.ComanaCg01 = comanaCg01;
            this.Contea = contea;
            this.Datacre = datacre;
            this.Datamod = datamod;
            this.Edificio = edificio;
            this.Email = email;
            this.EmailPec = emailPec;
            this.Fax = fax;
            this.Frazione = frazione;
            this.Guid = guid;
            this.Id = id;
            this.IdTeamportal = idTeamportal;
            this.Indirizzocomp = indirizzocomp;
            this.Indirizzocomp2 = indirizzocomp2;
            this.Indirizzoex = indirizzoex;
            this.Indweb = indweb;
            this.Latitudine = latitudine;
            this.Longitudine = longitudine;
            this.Numciv = numciv;
            this.Precisione = precisione;
            this.Presso = presso;
            this.Pv = pv;
            this.Ragsoc = ragsoc;
            this.Ragsocex = ragsocex;
            this.Rifindirizzo = rifindirizzo;
            this.Risregione = risregione;
            this.Risstato = risstato;
            this.Riswarning = riswarning;
            this.Riszip = riszip;
            this.StatoCg07 = statoCg07;
            this.Statofed = statofed;
            this.Telefono = telefono;
            this.Tipologia = tipologia;
            this.Via = via;
            this.AddressesType = addressesType;
            this.FederalStateViewCO = federalStateViewCO;
            this.StatoEst = statoEst;
            this.AdditionalData = additionalData;
            this.PluginData = pluginData;
        }
        
        /// <summary>
        /// Gets or Sets CodiceCg16
        /// </summary>
        [DataMember(Name="codiceCg16", EmitDefaultValue=false)]
        public int? CodiceCg16 { get; set; }

        /// <summary>
        /// CG1J_CAP - Cap
        /// </summary>
        /// <value>CG1J_CAP - Cap</value>
        [DataMember(Name="cap", EmitDefaultValue=false)]
        public string Cap { get; set; }

        /// <summary>
        /// CG1J_CELLNUM - Cellulare
        /// </summary>
        /// <value>CG1J_CELLNUM - Cellulare</value>
        [DataMember(Name="cellnum", EmitDefaultValue=false)]
        public string Cellnum { get; set; }

        /// <summary>
        /// CG1J_CITTA - Città
        /// </summary>
        /// <value>CG1J_CITTA - Città</value>
        [DataMember(Name="citta", EmitDefaultValue=false)]
        public string Citta { get; set; }

        /// <summary>
        /// CG1J_CODICESFED - Stato federato
        /// </summary>
        /// <value>CG1J_CODICESFED - Stato federato</value>
        [DataMember(Name="codicesfed", EmitDefaultValue=false)]
        public string Codicesfed { get; set; }

        /// <summary>
        /// CG1J_CODLINGUA_MG52 - Codice lingua
        /// </summary>
        /// <value>CG1J_CODLINGUA_MG52 - Codice lingua</value>
        [DataMember(Name="codlinguaMg52", EmitDefaultValue=false)]
        public string CodlinguaMg52 { get; set; }

        /// <summary>
        /// CG1J_COMANA_CG01 - ComanaCg01
        /// </summary>
        /// <value>CG1J_COMANA_CG01 - ComanaCg01</value>
        [DataMember(Name="comanaCg01", EmitDefaultValue=false)]
        public string ComanaCg01 { get; set; }

        /// <summary>
        /// CG1J_CONTEA - Contea
        /// </summary>
        /// <value>CG1J_CONTEA - Contea</value>
        [DataMember(Name="contea", EmitDefaultValue=false)]
        public string Contea { get; set; }

        /// <summary>
        /// CG1J_DATACRE - Data creazione
        /// </summary>
        /// <value>CG1J_DATACRE - Data creazione</value>
        [DataMember(Name="datacre", EmitDefaultValue=false)]
        public DateTime? Datacre { get; set; }

        /// <summary>
        /// CG1J_DATAMOD - Data modifica
        /// </summary>
        /// <value>CG1J_DATAMOD - Data modifica</value>
        [DataMember(Name="datamod", EmitDefaultValue=false)]
        public DateTime? Datamod { get; set; }

        /// <summary>
        /// CG1J_EDIFICIO - Edificio
        /// </summary>
        /// <value>CG1J_EDIFICIO - Edificio</value>
        [DataMember(Name="edificio", EmitDefaultValue=false)]
        public string Edificio { get; set; }

        /// <summary>
        /// CG1J_EMAIL - Email
        /// </summary>
        /// <value>CG1J_EMAIL - Email</value>
        [DataMember(Name="email", EmitDefaultValue=false)]
        public string Email { get; set; }

        /// <summary>
        /// CG1J_EMAIL_PEC - Email pec
        /// </summary>
        /// <value>CG1J_EMAIL_PEC - Email pec</value>
        [DataMember(Name="emailPec", EmitDefaultValue=false)]
        public string EmailPec { get; set; }

        /// <summary>
        /// CG1J_FAX - Fax
        /// </summary>
        /// <value>CG1J_FAX - Fax</value>
        [DataMember(Name="fax", EmitDefaultValue=false)]
        public string Fax { get; set; }

        /// <summary>
        /// CG1J_FRAZIONE - Frazione
        /// </summary>
        /// <value>CG1J_FRAZIONE - Frazione</value>
        [DataMember(Name="frazione", EmitDefaultValue=false)]
        public string Frazione { get; set; }

        /// <summary>
        /// CG1J_GUID - GUID
        /// </summary>
        /// <value>CG1J_GUID - GUID</value>
        [DataMember(Name="guid", EmitDefaultValue=false)]
        public Guid? Guid { get; set; }

        /// <summary>
        /// CG1J_ID - ID (Required only in PUT/PATCH)
        /// </summary>
        /// <value>CG1J_ID - ID (Required only in PUT/PATCH)</value>
        [DataMember(Name="id", EmitDefaultValue=false)]
        public long? Id { get; set; }

        /// <summary>
        /// CG1J_ID_TEAMPORTAL - IdTeamportal
        /// </summary>
        /// <value>CG1J_ID_TEAMPORTAL - IdTeamportal</value>
        [DataMember(Name="idTeamportal", EmitDefaultValue=false)]
        public long? IdTeamportal { get; set; }

        /// <summary>
        /// CG1J_INDIRIZZOCOMP - Indirizzo completo
        /// </summary>
        /// <value>CG1J_INDIRIZZOCOMP - Indirizzo completo</value>
        [DataMember(Name="indirizzocomp", EmitDefaultValue=false)]
        public string Indirizzocomp { get; set; }

        /// <summary>
        /// CG1J_INDIRIZZOCOMP2 - Indirizzo completo aggiuntivo
        /// </summary>
        /// <value>CG1J_INDIRIZZOCOMP2 - Indirizzo completo aggiuntivo</value>
        [DataMember(Name="indirizzocomp2", EmitDefaultValue=false)]
        public string Indirizzocomp2 { get; set; }

        /// <summary>
        /// CG1J_INDIRIZZOEX - Indirizzo esteso
        /// </summary>
        /// <value>CG1J_INDIRIZZOEX - Indirizzo esteso</value>
        [DataMember(Name="indirizzoex", EmitDefaultValue=false)]
        public string Indirizzoex { get; set; }

        /// <summary>
        /// CG1J_INDWEB - Indirizzo web
        /// </summary>
        /// <value>CG1J_INDWEB - Indirizzo web</value>
        [DataMember(Name="indweb", EmitDefaultValue=false)]
        public string Indweb { get; set; }

        /// <summary>
        /// CG1J_LATITUDINE - Latitudine
        /// </summary>
        /// <value>CG1J_LATITUDINE - Latitudine</value>
        [DataMember(Name="latitudine", EmitDefaultValue=false)]
        public double? Latitudine { get; set; }

        /// <summary>
        /// CG1J_LONGITUDINE - Longitudine
        /// </summary>
        /// <value>CG1J_LONGITUDINE - Longitudine</value>
        [DataMember(Name="longitudine", EmitDefaultValue=false)]
        public double? Longitudine { get; set; }

        /// <summary>
        /// CG1J_NUMCIV - Numero civico
        /// </summary>
        /// <value>CG1J_NUMCIV - Numero civico</value>
        [DataMember(Name="numciv", EmitDefaultValue=false)]
        public string Numciv { get; set; }

        /// <summary>
        /// CG1J_PRECISIONE - Precisione
        /// </summary>
        /// <value>CG1J_PRECISIONE - Precisione</value>
        [DataMember(Name="precisione", EmitDefaultValue=false)]
        public string Precisione { get; set; }

        /// <summary>
        /// CG1J_PRESSO - c/o - Edificio
        /// </summary>
        /// <value>CG1J_PRESSO - c/o - Edificio</value>
        [DataMember(Name="presso", EmitDefaultValue=false)]
        public string Presso { get; set; }

        /// <summary>
        /// CG1J_PV - PV
        /// </summary>
        /// <value>CG1J_PV - PV</value>
        [DataMember(Name="pv", EmitDefaultValue=false)]
        public string Pv { get; set; }

        /// <summary>
        /// CG1J_RAGSOC - Ragione sociale
        /// </summary>
        /// <value>CG1J_RAGSOC - Ragione sociale</value>
        [DataMember(Name="ragsoc", EmitDefaultValue=false)]
        public string Ragsoc { get; set; }

        /// <summary>
        /// CG1J_RAGSOCEX - Ragsocex
        /// </summary>
        /// <value>CG1J_RAGSOCEX - Ragsocex</value>
        [DataMember(Name="ragsocex", EmitDefaultValue=false)]
        public string Ragsocex { get; set; }

        /// <summary>
        /// CG1J_RIFINDIRIZZO - Rifindirizzo
        /// </summary>
        /// <value>CG1J_RIFINDIRIZZO - Rifindirizzo</value>
        [DataMember(Name="rifindirizzo", EmitDefaultValue=false)]
        public string Rifindirizzo { get; set; }

        /// <summary>
        /// CG1J_RISREGIONE - Risregione
        /// </summary>
        /// <value>CG1J_RISREGIONE - Risregione</value>
        [DataMember(Name="risregione", EmitDefaultValue=false)]
        public string Risregione { get; set; }

        /// <summary>
        /// CG1J_RISSTATO - Risstato
        /// </summary>
        /// <value>CG1J_RISSTATO - Risstato</value>
        [DataMember(Name="risstato", EmitDefaultValue=false)]
        public string Risstato { get; set; }

        /// <summary>
        /// CG1J_RISWARNING - Riswarning
        /// </summary>
        /// <value>CG1J_RISWARNING - Riswarning</value>
        [DataMember(Name="riswarning", EmitDefaultValue=false)]
        public string Riswarning { get; set; }

        /// <summary>
        /// CG1J_RISZIP - Riszip
        /// </summary>
        /// <value>CG1J_RISZIP - Riszip</value>
        [DataMember(Name="riszip", EmitDefaultValue=false)]
        public string Riszip { get; set; }

        /// <summary>
        /// CG1J_STATO_CG07 - StatoCg07
        /// </summary>
        /// <value>CG1J_STATO_CG07 - StatoCg07</value>
        [DataMember(Name="statoCg07", EmitDefaultValue=false)]
        public double? StatoCg07 { get; set; }

        /// <summary>
        /// CG1J_STATOFED - Stato federato
        /// </summary>
        /// <value>CG1J_STATOFED - Stato federato</value>
        [DataMember(Name="statofed", EmitDefaultValue=false)]
        public string Statofed { get; set; }

        /// <summary>
        /// CG1J_TELEFONO - Telefono
        /// </summary>
        /// <value>CG1J_TELEFONO - Telefono</value>
        [DataMember(Name="telefono", EmitDefaultValue=false)]
        public string Telefono { get; set; }

        /// <summary>
        /// CG1J_TIPOLOGIA - Tipologia
        /// </summary>
        /// <value>CG1J_TIPOLOGIA - Tipologia</value>
        [DataMember(Name="tipologia", EmitDefaultValue=false)]
        public string Tipologia { get; set; }

        /// <summary>
        /// CG1J_VIA - Indirizzo - N.civico
        /// </summary>
        /// <value>CG1J_VIA - Indirizzo - N.civico</value>
        [DataMember(Name="via", EmitDefaultValue=false)]
        public string Via { get; set; }

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

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

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

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

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

        /// <summary>
        /// Returns the string presentation of the object
        /// </summary>
        /// <returns>String presentation of the object</returns>
        public override string ToString()
        {
            var sb = new StringBuilder();
            sb.Append("class AddressCODTO {\n");
            sb.Append("  CodiceCg16: ").Append(CodiceCg16).Append("\n");
            sb.Append("  Cap: ").Append(Cap).Append("\n");
            sb.Append("  Cellnum: ").Append(Cellnum).Append("\n");
            sb.Append("  Citta: ").Append(Citta).Append("\n");
            sb.Append("  Codicesfed: ").Append(Codicesfed).Append("\n");
            sb.Append("  CodlinguaMg52: ").Append(CodlinguaMg52).Append("\n");
            sb.Append("  ComanaCg01: ").Append(ComanaCg01).Append("\n");
            sb.Append("  Contea: ").Append(Contea).Append("\n");
            sb.Append("  Datacre: ").Append(Datacre).Append("\n");
            sb.Append("  Datamod: ").Append(Datamod).Append("\n");
            sb.Append("  Edificio: ").Append(Edificio).Append("\n");
            sb.Append("  Email: ").Append(Email).Append("\n");
            sb.Append("  EmailPec: ").Append(EmailPec).Append("\n");
            sb.Append("  Fax: ").Append(Fax).Append("\n");
            sb.Append("  Frazione: ").Append(Frazione).Append("\n");
            sb.Append("  Guid: ").Append(Guid).Append("\n");
            sb.Append("  Id: ").Append(Id).Append("\n");
            sb.Append("  IdTeamportal: ").Append(IdTeamportal).Append("\n");
            sb.Append("  Indirizzocomp: ").Append(Indirizzocomp).Append("\n");
            sb.Append("  Indirizzocomp2: ").Append(Indirizzocomp2).Append("\n");
            sb.Append("  Indirizzoex: ").Append(Indirizzoex).Append("\n");
            sb.Append("  Indweb: ").Append(Indweb).Append("\n");
            sb.Append("  Latitudine: ").Append(Latitudine).Append("\n");
            sb.Append("  Longitudine: ").Append(Longitudine).Append("\n");
            sb.Append("  Numciv: ").Append(Numciv).Append("\n");
            sb.Append("  Precisione: ").Append(Precisione).Append("\n");
            sb.Append("  Presso: ").Append(Presso).Append("\n");
            sb.Append("  Pv: ").Append(Pv).Append("\n");
            sb.Append("  Ragsoc: ").Append(Ragsoc).Append("\n");
            sb.Append("  Ragsocex: ").Append(Ragsocex).Append("\n");
            sb.Append("  Rifindirizzo: ").Append(Rifindirizzo).Append("\n");
            sb.Append("  Risregione: ").Append(Risregione).Append("\n");
            sb.Append("  Risstato: ").Append(Risstato).Append("\n");
            sb.Append("  Riswarning: ").Append(Riswarning).Append("\n");
            sb.Append("  Riszip: ").Append(Riszip).Append("\n");
            sb.Append("  StatoCg07: ").Append(StatoCg07).Append("\n");
            sb.Append("  Statofed: ").Append(Statofed).Append("\n");
            sb.Append("  Telefono: ").Append(Telefono).Append("\n");
            sb.Append("  Tipologia: ").Append(Tipologia).Append("\n");
            sb.Append("  Via: ").Append(Via).Append("\n");
            sb.Append("  AddressesType: ").Append(AddressesType).Append("\n");
            sb.Append("  FederalStateViewCO: ").Append(FederalStateViewCO).Append("\n");
            sb.Append("  StatoEst: ").Append(StatoEst).Append("\n");
            sb.Append("  AdditionalData: ").Append(AdditionalData).Append("\n");
            sb.Append("  PluginData: ").Append(PluginData).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 JsonConvert.SerializeObject(this, Formatting.Indented);
        }

        /// <summary>
        /// Returns true if objects are equal
        /// </summary>
        /// <param name="input">Object to be compared</param>
        /// <returns>Boolean</returns>
        public override bool Equals(object input)
        {
            return this.Equals(input as AddressCODTO);
        }

        /// <summary>
        /// Returns true if AddressCODTO instances are equal
        /// </summary>
        /// <param name="input">Instance of AddressCODTO to be compared</param>
        /// <returns>Boolean</returns>
        public bool Equals(AddressCODTO input)
        {
            if (input == null)
                return false;

            return 
                (
                    this.CodiceCg16 == input.CodiceCg16 ||
                    (this.CodiceCg16 != null &&
                    this.CodiceCg16.Equals(input.CodiceCg16))
                ) && 
                (
                    this.Cap == input.Cap ||
                    (this.Cap != null &&
                    this.Cap.Equals(input.Cap))
                ) && 
                (
                    this.Cellnum == input.Cellnum ||
                    (this.Cellnum != null &&
                    this.Cellnum.Equals(input.Cellnum))
                ) && 
                (
                    this.Citta == input.Citta ||
                    (this.Citta != null &&
                    this.Citta.Equals(input.Citta))
                ) && 
                (
                    this.Codicesfed == input.Codicesfed ||
                    (this.Codicesfed != null &&
                    this.Codicesfed.Equals(input.Codicesfed))
                ) && 
                (
                    this.CodlinguaMg52 == input.CodlinguaMg52 ||
                    (this.CodlinguaMg52 != null &&
                    this.CodlinguaMg52.Equals(input.CodlinguaMg52))
                ) && 
                (
                    this.ComanaCg01 == input.ComanaCg01 ||
                    (this.ComanaCg01 != null &&
                    this.ComanaCg01.Equals(input.ComanaCg01))
                ) && 
                (
                    this.Contea == input.Contea ||
                    (this.Contea != null &&
                    this.Contea.Equals(input.Contea))
                ) && 
                (
                    this.Datacre == input.Datacre ||
                    (this.Datacre != null &&
                    this.Datacre.Equals(input.Datacre))
                ) && 
                (
                    this.Datamod == input.Datamod ||
                    (this.Datamod != null &&
                    this.Datamod.Equals(input.Datamod))
                ) && 
                (
                    this.Edificio == input.Edificio ||
                    (this.Edificio != null &&
                    this.Edificio.Equals(input.Edificio))
                ) && 
                (
                    this.Email == input.Email ||
                    (this.Email != null &&
                    this.Email.Equals(input.Email))
                ) && 
                (
                    this.EmailPec == input.EmailPec ||
                    (this.EmailPec != null &&
                    this.EmailPec.Equals(input.EmailPec))
                ) && 
                (
                    this.Fax == input.Fax ||
                    (this.Fax != null &&
                    this.Fax.Equals(input.Fax))
                ) && 
                (
                    this.Frazione == input.Frazione ||
                    (this.Frazione != null &&
                    this.Frazione.Equals(input.Frazione))
                ) && 
                (
                    this.Guid == input.Guid ||
                    (this.Guid != null &&
                    this.Guid.Equals(input.Guid))
                ) && 
                (
                    this.Id == input.Id ||
                    (this.Id != null &&
                    this.Id.Equals(input.Id))
                ) && 
                (
                    this.IdTeamportal == input.IdTeamportal ||
                    (this.IdTeamportal != null &&
                    this.IdTeamportal.Equals(input.IdTeamportal))
                ) && 
                (
                    this.Indirizzocomp == input.Indirizzocomp ||
                    (this.Indirizzocomp != null &&
                    this.Indirizzocomp.Equals(input.Indirizzocomp))
                ) && 
                (
                    this.Indirizzocomp2 == input.Indirizzocomp2 ||
                    (this.Indirizzocomp2 != null &&
                    this.Indirizzocomp2.Equals(input.Indirizzocomp2))
                ) && 
                (
                    this.Indirizzoex == input.Indirizzoex ||
                    (this.Indirizzoex != null &&
                    this.Indirizzoex.Equals(input.Indirizzoex))
                ) && 
                (
                    this.Indweb == input.Indweb ||
                    (this.Indweb != null &&
                    this.Indweb.Equals(input.Indweb))
                ) && 
                (
                    this.Latitudine == input.Latitudine ||
                    (this.Latitudine != null &&
                    this.Latitudine.Equals(input.Latitudine))
                ) && 
                (
                    this.Longitudine == input.Longitudine ||
                    (this.Longitudine != null &&
                    this.Longitudine.Equals(input.Longitudine))
                ) && 
                (
                    this.Numciv == input.Numciv ||
                    (this.Numciv != null &&
                    this.Numciv.Equals(input.Numciv))
                ) && 
                (
                    this.Precisione == input.Precisione ||
                    (this.Precisione != null &&
                    this.Precisione.Equals(input.Precisione))
                ) && 
                (
                    this.Presso == input.Presso ||
                    (this.Presso != null &&
                    this.Presso.Equals(input.Presso))
                ) && 
                (
                    this.Pv == input.Pv ||
                    (this.Pv != null &&
                    this.Pv.Equals(input.Pv))
                ) && 
                (
                    this.Ragsoc == input.Ragsoc ||
                    (this.Ragsoc != null &&
                    this.Ragsoc.Equals(input.Ragsoc))
                ) && 
                (
                    this.Ragsocex == input.Ragsocex ||
                    (this.Ragsocex != null &&
                    this.Ragsocex.Equals(input.Ragsocex))
                ) && 
                (
                    this.Rifindirizzo == input.Rifindirizzo ||
                    (this.Rifindirizzo != null &&
                    this.Rifindirizzo.Equals(input.Rifindirizzo))
                ) && 
                (
                    this.Risregione == input.Risregione ||
                    (this.Risregione != null &&
                    this.Risregione.Equals(input.Risregione))
                ) && 
                (
                    this.Risstato == input.Risstato ||
                    (this.Risstato != null &&
                    this.Risstato.Equals(input.Risstato))
                ) && 
                (
                    this.Riswarning == input.Riswarning ||
                    (this.Riswarning != null &&
                    this.Riswarning.Equals(input.Riswarning))
                ) && 
                (
                    this.Riszip == input.Riszip ||
                    (this.Riszip != null &&
                    this.Riszip.Equals(input.Riszip))
                ) && 
                (
                    this.StatoCg07 == input.StatoCg07 ||
                    (this.StatoCg07 != null &&
                    this.StatoCg07.Equals(input.StatoCg07))
                ) && 
                (
                    this.Statofed == input.Statofed ||
                    (this.Statofed != null &&
                    this.Statofed.Equals(input.Statofed))
                ) && 
                (
                    this.Telefono == input.Telefono ||
                    (this.Telefono != null &&
                    this.Telefono.Equals(input.Telefono))
                ) && 
                (
                    this.Tipologia == input.Tipologia ||
                    (this.Tipologia != null &&
                    this.Tipologia.Equals(input.Tipologia))
                ) && 
                (
                    this.Via == input.Via ||
                    (this.Via != null &&
                    this.Via.Equals(input.Via))
                ) && 
                (
                    this.AddressesType == input.AddressesType ||
                    this.AddressesType != null &&
                    input.AddressesType != null &&
                    this.AddressesType.SequenceEqual(input.AddressesType)
                ) && 
                (
                    this.FederalStateViewCO == input.FederalStateViewCO ||
                    (this.FederalStateViewCO != null &&
                    this.FederalStateViewCO.Equals(input.FederalStateViewCO))
                ) && 
                (
                    this.StatoEst == input.StatoEst ||
                    (this.StatoEst != null &&
                    this.StatoEst.Equals(input.StatoEst))
                ) && 
                (
                    this.AdditionalData == input.AdditionalData ||
                    this.AdditionalData != null &&
                    input.AdditionalData != null &&
                    this.AdditionalData.SequenceEqual(input.AdditionalData)
                ) && 
                (
                    this.PluginData == input.PluginData ||
                    this.PluginData != null &&
                    input.PluginData != null &&
                    this.PluginData.SequenceEqual(input.PluginData)
                );
        }

        /// <summary>
        /// Gets the hash code
        /// </summary>
        /// <returns>Hash code</returns>
        public override int GetHashCode()
        {
            unchecked // Overflow is fine, just wrap
            {
                int hashCode = 41;
                if (this.CodiceCg16 != null)
                    hashCode = hashCode * 59 + this.CodiceCg16.GetHashCode();
                if (this.Cap != null)
                    hashCode = hashCode * 59 + this.Cap.GetHashCode();
                if (this.Cellnum != null)
                    hashCode = hashCode * 59 + this.Cellnum.GetHashCode();
                if (this.Citta != null)
                    hashCode = hashCode * 59 + this.Citta.GetHashCode();
                if (this.Codicesfed != null)
                    hashCode = hashCode * 59 + this.Codicesfed.GetHashCode();
                if (this.CodlinguaMg52 != null)
                    hashCode = hashCode * 59 + this.CodlinguaMg52.GetHashCode();
                if (this.ComanaCg01 != null)
                    hashCode = hashCode * 59 + this.ComanaCg01.GetHashCode();
                if (this.Contea != null)
                    hashCode = hashCode * 59 + this.Contea.GetHashCode();
                if (this.Datacre != null)
                    hashCode = hashCode * 59 + this.Datacre.GetHashCode();
                if (this.Datamod != null)
                    hashCode = hashCode * 59 + this.Datamod.GetHashCode();
                if (this.Edificio != null)
                    hashCode = hashCode * 59 + this.Edificio.GetHashCode();
                if (this.Email != null)
                    hashCode = hashCode * 59 + this.Email.GetHashCode();
                if (this.EmailPec != null)
                    hashCode = hashCode * 59 + this.EmailPec.GetHashCode();
                if (this.Fax != null)
                    hashCode = hashCode * 59 + this.Fax.GetHashCode();
                if (this.Frazione != null)
                    hashCode = hashCode * 59 + this.Frazione.GetHashCode();
                if (this.Guid != null)
                    hashCode = hashCode * 59 + this.Guid.GetHashCode();
                if (this.Id != null)
                    hashCode = hashCode * 59 + this.Id.GetHashCode();
                if (this.IdTeamportal != null)
                    hashCode = hashCode * 59 + this.IdTeamportal.GetHashCode();
                if (this.Indirizzocomp != null)
                    hashCode = hashCode * 59 + this.Indirizzocomp.GetHashCode();
                if (this.Indirizzocomp2 != null)
                    hashCode = hashCode * 59 + this.Indirizzocomp2.GetHashCode();
                if (this.Indirizzoex != null)
                    hashCode = hashCode * 59 + this.Indirizzoex.GetHashCode();
                if (this.Indweb != null)
                    hashCode = hashCode * 59 + this.Indweb.GetHashCode();
                if (this.Latitudine != null)
                    hashCode = hashCode * 59 + this.Latitudine.GetHashCode();
                if (this.Longitudine != null)
                    hashCode = hashCode * 59 + this.Longitudine.GetHashCode();
                if (this.Numciv != null)
                    hashCode = hashCode * 59 + this.Numciv.GetHashCode();
                if (this.Precisione != null)
                    hashCode = hashCode * 59 + this.Precisione.GetHashCode();
                if (this.Presso != null)
                    hashCode = hashCode * 59 + this.Presso.GetHashCode();
                if (this.Pv != null)
                    hashCode = hashCode * 59 + this.Pv.GetHashCode();
                if (this.Ragsoc != null)
                    hashCode = hashCode * 59 + this.Ragsoc.GetHashCode();
                if (this.Ragsocex != null)
                    hashCode = hashCode * 59 + this.Ragsocex.GetHashCode();
                if (this.Rifindirizzo != null)
                    hashCode = hashCode * 59 + this.Rifindirizzo.GetHashCode();
                if (this.Risregione != null)
                    hashCode = hashCode * 59 + this.Risregione.GetHashCode();
                if (this.Risstato != null)
                    hashCode = hashCode * 59 + this.Risstato.GetHashCode();
                if (this.Riswarning != null)
                    hashCode = hashCode * 59 + this.Riswarning.GetHashCode();
                if (this.Riszip != null)
                    hashCode = hashCode * 59 + this.Riszip.GetHashCode();
                if (this.StatoCg07 != null)
                    hashCode = hashCode * 59 + this.StatoCg07.GetHashCode();
                if (this.Statofed != null)
                    hashCode = hashCode * 59 + this.Statofed.GetHashCode();
                if (this.Telefono != null)
                    hashCode = hashCode * 59 + this.Telefono.GetHashCode();
                if (this.Tipologia != null)
                    hashCode = hashCode * 59 + this.Tipologia.GetHashCode();
                if (this.Via != null)
                    hashCode = hashCode * 59 + this.Via.GetHashCode();
                if (this.AddressesType != null)
                    hashCode = hashCode * 59 + this.AddressesType.GetHashCode();
                if (this.FederalStateViewCO != null)
                    hashCode = hashCode * 59 + this.FederalStateViewCO.GetHashCode();
                if (this.StatoEst != null)
                    hashCode = hashCode * 59 + this.StatoEst.GetHashCode();
                if (this.AdditionalData != null)
                    hashCode = hashCode * 59 + this.AdditionalData.GetHashCode();
                if (this.PluginData != null)
                    hashCode = hashCode * 59 + this.PluginData.GetHashCode();
                return hashCode;
            }
        }

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