93 |
* This method returns the <code>PageFormat</code> object for the |
* This method returns the <code>PageFormat</code> object for the |
94 |
* specified page. |
* specified page. |
95 |
* |
* |
96 |
* @param page_numbers The number of the page to get information for, where |
* @param page_number The number of the page to get information for, where |
97 |
* page numbers start at 0. |
* page numbers start at 0. |
98 |
* |
* |
99 |
* @return The <code>PageFormat</code> object for the specified page. |
* @return The <code>PageFormat</code> object for the specified page. |
112 |
* This method returns the <code>Printable</code> object for the |
* This method returns the <code>Printable</code> object for the |
113 |
* specified page. |
* specified page. |
114 |
* |
* |
115 |
* @param page_numbers The number of the page to get information for, where |
* @param page_number The number of the page to get information for, where |
116 |
* page numbers start at 0. |
* page numbers start at 0. |
117 |
* |
* |
118 |
* @return The <code>Printable</code> object for the specified page. |
* @return The <code>Printable</code> object for the specified page. |
155 |
* @exception NullPointerException If any argument is <code>null</code>. |
* @exception NullPointerException If any argument is <code>null</code>. |
156 |
*/ |
*/ |
157 |
public void |
public void |
158 |
append(Printable painter, PageFormat page_format, int num_pages) |
append(Printable printable, PageFormat page_format, int num_pages) |
159 |
{ |
{ |
160 |
for (int i = 0; i < num_pages; i++) |
for (int i = 0; i < num_pages; i++) |
161 |
{ |
{ |
162 |
printables.addElement(painter); |
printables.addElement(printable); |
163 |
page_formats.addElement(page_format); |
page_formats.addElement(page_format); |
164 |
} |
} |
165 |
} |
} |
175 |
* @param printable The new <code>Printable</code> for the page. |
* @param printable The new <code>Printable</code> for the page. |
176 |
* @param page_format The new <code>PageFormat</code> for the page. |
* @param page_format The new <code>PageFormat</code> for the page. |
177 |
* |
* |
178 |
* @param IndexOutOfBoundsException If the specified page does not exist. |
* @throws IndexOutOfBoundsException If the specified page does not exist. |
179 |
*/ |
*/ |
180 |
public void |
public void |
181 |
setPage(int page_num, Printable printable, PageFormat page_format) |
setPage(int page_num, Printable printable, PageFormat page_format) |
183 |
printables.setElementAt(printable, page_num); |
printables.setElementAt(printable, page_num); |
184 |
page_formats.setElementAt(page_format, page_num); |
page_formats.setElementAt(page_format, page_num); |
185 |
} |
} |
186 |
|
} |
|
} // class Book |
|
|
|
|