public Book(ISBN exactISBN, string exactAuthor, string exactName, string exactPublishingHouse, DateTime exactPublishmentYear, int exactPagesNumber, decimal exactPrice) { isbn = exactISBN; author = exactAuthor; name = exactName; publishingHouse = exactPublishingHouse; publishmentYear = exactPublishmentYear; pagesNumber = exactPagesNumber; price = exactPrice; }
public override bool Equals(object obj) { if (obj == null) { return(false); } if (obj.GetType() != GetType()) { return(false); } ISBN isbn = (ISBN)obj; return(Equals(isbn)); }
public int CompareTo(object o) { Book book = o as Book; return(ISBN.CompareTo(book.ISBN)); }
public bool Equals(ISBN isbn) { return(CountryCode == isbn.CountryCode && PublishingHouseCode == isbn.PublishingHouseCode && NumberOfBook == isbn.NumberOfBook && ControlNumber == isbn.ControlNumber); }