Example #1
0
 public override bool Equals(System.Object otherStylist)
 {
     if (!(otherStylist is Stylist))
     {
         return(false);
     }
     else
     {
         Stylist newStylist      = (Stylist)otherStylist;
         bool    stylistEquality = (this.GetFirstName() == newStylist.GetFirstName() && this.GetLastName() == newStylist.GetLastName() && this.GetPhoneNumber() == newStylist.GetPhoneNumber() && this.GetEmail() == newStylist.GetEmail() && this.GetID() == newStylist.GetID());
         return(stylistEquality);
     }
 }
Example #2
0
 public override bool Equals(System.Object otherStylist)
 {
     if (!(otherStylist is Stylist))
     {
         return(false);
     }
     else
     {
         Stylist newStylist        = (Stylist)otherStylist;
         bool    firstNameEquality = this.GetFirstName().Equals(newStylist.GetFirstName());
         bool    lastNameEquality  = this.GetLastName().Equals(newStylist.GetLastName());
         return(firstNameEquality && lastNameEquality);
     }
 }
Example #3
0
 public override bool Equals(System.Object stylist2)
 {
     if (!(stylist2 is Stylist))
     {
         return(false);
     }
     else
     {
         Stylist stylist1          = (Stylist)stylist2;
         bool    idEquality        = (this.GetId() == stylist1.GetId());
         bool    firstNameEquality = (this.GetFirstName() == stylist1.GetFirstName());
         bool    lastNameEquality  = (this.GetLastName() == stylist1.GetLastName());
         return(idEquality && firstNameEquality && lastNameEquality);
     }
 }