public class Book extends Product {

  private String publisher;    /* Publisher's name */
  private String[] authors;    /* Array of authors */

  public Book(String inName, String inDescription, String inPublisher, 
    String[] inAuthors) {
    super(inName, inDescription);
    publisher = inPublisher;
    authors = inAuthors;
  }

  public String getAuthors() {
    StringBuffer authorBuffer = new StringBuffer(initialBufferLength);
    for(int i=0; i<authors.length; i++) {
      if(i!= 0) {
        authorBuffer.append(",");
      }
      authorBuffer.append(authors[i]);
    }
    return authorBuffer.toString();
  }
  public String toString() {
    StringBuffer outputBuffer = new StringBuffer(initialBufferLength);
    outputBuffer.append("Name=" + getName() + ";" + "Description=" +
      getDescription() + ";" + "Publisher=" + publisher +
      "Authors=" + getAuthors());
    return outputBuffer.toString();
  }
}
