|
Préférences
Moteurs de recherche
|
|||||||
JavaTM 2 Platform Std. Ed. v1.6.0
javax.print
|
Method Summary | |
---|---|
void |
cancel()
Stops further processing of a print job. |
Methods inherited from interface javax.print.DocPrintJob |
---|
addPrintJobAttributeListener, addPrintJobListener, getAttributes, getPrintService, print, removePrintJobAttributeListener, removePrintJobListener |
Method Detail |
---|
void cancel() throws PrintException
If a service supports this method it cannot be concluded that job cancellation will always suceeed. A job may not be able to be cancelled once it has reached and passed some point in its processing. A successful cancellation means only that the entire job was not printed, some portion may already have printed when cancel returns.
The service will throw a PrintException if the cancellation did not succeed. A job which has not yet been submitted for printing should throw this exception. Cancelling an already successfully cancelled Print Job is not considered an error and will always succeed.
Cancellation in some services may be a lengthy process, involving requests to a server and processing of its print queue. Clients may wish to execute cancel in a thread which does not affect application execution.
PrintException
- if the job could not be successfully cancelled.