Ejemplo n.º 1
0
 public string Save(Book aBook)
 {
     if (bookGateway.HasBookName(aBook.Title))
     {
         throw new Exception("This system has this book name.Please try again.");
     }
     else if (bookGateway.HasISBNNo(aBook.ISbnNo))
     {
         throw new Exception("This system already have this ISBN No.Please try again.");
     }
     else
     {
         return(bookGateway.Save(aBook));
     }
 }