public bool Equals(Order other)
 {
     if (!Id.Equals(other.Id))
     {
         return(false);
     }
     if (!CreationDateTime.Equals(other.CreationDateTime))
     {
         return(false);
     }
     if (!Address.Equals(other.Address))
     {
         return(false);
     }
     if (!Contacts.Equals(other.Contacts))
     {
         return(false);
     }
     if (!Note.Equals(other.Note))
     {
         return(false);
     }
     if (!Manager.Equals(other.Manager))
     {
         return(false);
     }
     if (!CreationDateTime.Equals(other.CreationDateTime))
     {
         return(false);
     }
     if (!Items.SequenceEqual(other.Items))
     {
         return(false);
     }
     return(true);
 }
예제 #2
0
 protected bool Equals(ContainerImage other)
 {
     return(Repository == other.Repository && Hash == other.Hash && Tag == other.Tag && CreationDateTime.Equals(other.CreationDateTime));
 }
예제 #3
0
        /// <summary>
        /// Displays the various information for a comment, including: the title, description, who it was created by, and the creation datetime.
        /// </summary>
        /// <returns>Returns the title, description, creator, and the creation datetime of a Comment type object, in the form of a string statement.</returns>
        public String DisplayComment()
        {
            if (string.IsNullOrEmpty(Title) || string.IsNullOrEmpty(Description) || string.IsNullOrEmpty(CreatedBy) || CreationDateTime.Equals(null))
            {
                DisplayUtility.ErrorMessageForNullOrEmpty();
            }

            return("_____________________________________\n\n" + "Title: " + Title + "\n\nDescription: " + Description + "\n\nCreated By: " + CreatedBy + "\n" + CreationDateTime);
        }