Methods Summary |
---|
public void | destroy()
// Allow the database to be garbage collected
books = null;
|
public BookDetails | getBookDetails(java.lang.String bookId)
return books.getBookDetails(bookId);
|
public BookDetails[] | getBooksSortedByTitle()
return books.getBooksSortedByTitle();
|
public int | getNumberOfBooks()
return books.getNumberOfBooks();
|
public java.lang.String | getServletInfo()
return "The BookDB servlet manages the bookstore database. " +
"It is called by other servlets, not directly by a user.";
|
public void | init(javax.servlet.ServletConfig config)
// Store the ServletConfig object and log the initialization
super.init(config);
// Load the database to prepare for requests
books = new BookstoreDB();
|
public void | service(javax.servlet.ServletRequest req, javax.servlet.ServletResponse res)
throw new UnavailableException(
this,
"This servlet does not accept client requests.");
|