public static enum PrinterJob.JobStatus extends Enum<PrinterJob.JobStatus>
jobStatus
property, or may query it directly
using getJobStatus()
.
The typical life cycle of a job is as follows :
NOT_STARTED
and
will stay there during configuration via dialogs etc.
PRINTING
when the first page
is printed.
DONE
once the job is
successfully completed without being cancelled or encountering
an error. The job is now completed.
ERROR
or is
CANCELED
is also considered completed.
A job may not revert to an earlier status in its life cycle and the current job state affects operations that may be performed. For example a job may not begin printing again if it has previously passed that state and entered any of the termination states.
Enum Constant and Description |
---|
CANCELED
The job has been cancelled by the application.
|
DONE
The job initiated printing and later called endJob()
which reported success.
|
ERROR
The job encountered an error.
|
NOT_STARTED
The new job status.
|
PRINTING
The job has requested to print at least one page,
and has not terminated printing.
|
Modifier and Type | Method and Description |
---|---|
static PrinterJob.JobStatus |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static PrinterJob.JobStatus[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final PrinterJob.JobStatus NOT_STARTED
public static final PrinterJob.JobStatus PRINTING
public static final PrinterJob.JobStatus CANCELED
public static final PrinterJob.JobStatus ERROR
public static final PrinterJob.JobStatus DONE
public static PrinterJob.JobStatus[] values()
for (PrinterJob.JobStatus c : PrinterJob.JobStatus.values()) System.out.println(c);
public static PrinterJob.JobStatus valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullSubmit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 2008, 2017, Oracle and/or its affiliates. All rights reserved. Use is subject to license terms. Also see the documentation redistribution policy.