Beispiel #1
0
 public override bool Equals(System.Object otherTask)
 {
     if (!(otherTask is Task))
     {
         return(false);
     }
     else
     {
         Task newTask             = (Task)otherTask;
         bool idEquality          = this.GetId() == newTask.GetId();
         bool descriptionEquality = this.GetDescription() == newTask.GetDescription();
         bool categoryEquality    = this.GetCategoryId() == newTask.GetCategoryId();
         bool dateEquality        = this.GetCompleteBy() == newTask.GetCompleteBy();
         return(idEquality && descriptionEquality && categoryEquality && dateEquality);
     }
 }