import java.util.Date;
/** 
 * A book in a public library.
 */
public class Book {
  /** The title of the book. */
  private String title;
  /** The author of the book. */
  private String author;
  /** The publisher of the book. */
  private String publisher;
  /** The book category. */
  private String category;
  /** The publication date of the book.*/
  private Date publicationDate;
  /** The availability of the book */
  private boolean checkedOut;
  /** The date the book is due back */
  private Date dueDate;
  /** The reference number of the book */
  private String reference;
  /** The number of books in the library */
  private static int numBooks;
  /**
   * Create a book setting the title, author, and
   * the publication date.
   */
  public Book(String t, String a, Date d) {
    this.title = t;
    this.author = a;
    this.publicationDate = d;
    this.numBooks += 1;
  }
  /** return the number of books in the libraryu */
  public static int getBookCount() {
    return numBooks;
  }
  
  /** Return a string showing the book name.
   *  the book's author and the book publication
   *  date.
   */
  public String toString() {
    return "Title: " + this.title + "\nAuthor: " + this.author +  "\nPublication Date: " + this.publicationDate;
  }  
  
  /** Set the title of the book to String t */
  public void setTitle(String t) {
    this.title = t;
  }
  /** Get the title of the book */
  public String getTitle() {
    return this.title;
  }
  
}

