// =================================================================================================== public static string isSameBookTitle(BookTitle bt1, BookTitle bt2) { if (bt1.Equals(bt2)) { return("Одинаковые:\n" + "BookTitle1: " + bt1.Value + "\n" + "BookTitle2: " + bt2.Value); } else { return("Нет:\n" + "BookTitle1" + bt1.Value + "\n" + "BookTitle2" + bt2.Value); } }
public static void gebugTestIsSameBookTitle() { BookTitle bt1 = new BookTitle("11"); BookTitle bt2 = new BookTitle("1"); if (bt1.Equals(bt2)) { MessageBox.Show("Да", "Test - BookTitle", MessageBoxButtons.OK, MessageBoxIcon.Information); } else { MessageBox.Show("Нет", "Test - BookTitle", MessageBoxButtons.OK, MessageBoxIcon.Information); } }