Example #1
0
        public override bool Equals(System.Object otherBand)
        {
            if (!(otherBand is Band))
            {
                return(false);
            }
            else
            {
                Band newBand              = (Band)otherBand;
                bool idEquality           = this.GetId() == newBand.GetId();
                bool nameEquality         = this.GetName() == newBand.GetName();
                bool agentContactEquality = this.GetAgentContact() == newBand.GetAgentContact();
                bool agentEquality        = this.GetAgent() == newBand.GetAgent();
                bool genreEquality        = this.GetGenre() == newBand.GetGenre();
                bool leaderEquality       = this.GetLeader() == newBand.GetLeader();
                bool membersEquality      = this.GetMembers() == newBand.GetMembers();
                bool originPlaceEquality  = this.GetOriginplace() == newBand.GetOriginplace();
                bool originYearEquality   = this.GetoriginYear() == newBand.GetoriginYear();

                return(idEquality && nameEquality && agentEquality && agentContactEquality && genreEquality && leaderEquality && membersEquality && originPlaceEquality && originYearEquality);
            }
        }