return Email public class Document private String title title of document

Return email public class document private string

This preview shows page 3 - 6 out of 13 pages.

return "Email"; } } public class Document { private String title; // title of document private int numPages; // number of pages of the document /** Constructor: document with title t and p pages */ public Document(String t, int p) { title= t; numPages= p; } /** = title of this document */ public String getTitle() { return title; } /** = number of pages of this document */ public int getNumPages() { return numPages; } /** = the priority of the document */ public int priority() { return 50 - numPages; } } public class Abstract extends Document { /** Constructor: an abstract with title t */ public Abstract(String t) { super(t, 1); } }
Image of page 3