jdk/src/java.desktop/share/classes/javax/print/attribute/standard/PrinterStateReason.java
author serb
Sat, 06 May 2017 14:58:04 -0700
changeset 45025 9ad3afa82b5e
parent 35667 ed476aba94de
child 47196 a3211bb4daff
permissions -rw-r--r--
8179596: Update java.desktop to be HTML-5 friendly Reviewed-by: prr, amenkov
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
     1
/*
22584
eed64ee05369 8032733: Fix cast lint warnings in client libraries
darcy
parents: 21278
diff changeset
     2
 * Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
90ce3da70b43 Initial load
duke
parents:
diff changeset
     4
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
90ce3da70b43 Initial load
duke
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
     7
 * published by the Free Software Foundation.  Oracle designates this
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
     8
 * particular file as subject to the "Classpath" exception as provided
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
     9
 * by Oracle in the LICENSE file that accompanied this code.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    10
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    11
 * This code is distributed in the hope that it will be useful, but WITHOUT
90ce3da70b43 Initial load
duke
parents:
diff changeset
    12
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
90ce3da70b43 Initial load
duke
parents:
diff changeset
    13
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
90ce3da70b43 Initial load
duke
parents:
diff changeset
    14
 * version 2 for more details (a copy is included in the LICENSE file that
90ce3da70b43 Initial load
duke
parents:
diff changeset
    15
 * accompanied this code).
90ce3da70b43 Initial load
duke
parents:
diff changeset
    16
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    17
 * You should have received a copy of the GNU General Public License version
90ce3da70b43 Initial load
duke
parents:
diff changeset
    18
 * 2 along with this work; if not, write to the Free Software Foundation,
90ce3da70b43 Initial load
duke
parents:
diff changeset
    19
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    20
 *
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
    21
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
    22
 * or visit www.oracle.com if you need additional information or have any
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
    23
 * questions.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    24
 */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    25
package javax.print.attribute.standard;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    26
90ce3da70b43 Initial load
duke
parents:
diff changeset
    27
import javax.print.attribute.EnumSyntax;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    28
import javax.print.attribute.Attribute;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    29
90ce3da70b43 Initial load
duke
parents:
diff changeset
    30
/**
90ce3da70b43 Initial load
duke
parents:
diff changeset
    31
 * Class PrinterStateReason is a printing attribute class, an enumeration,
90ce3da70b43 Initial load
duke
parents:
diff changeset
    32
 * that provides additional information about the printer's current state,
90ce3da70b43 Initial load
duke
parents:
diff changeset
    33
 * i.e., information that augments the value of the printer's
90ce3da70b43 Initial load
duke
parents:
diff changeset
    34
 * {@link PrinterState PrinterState} attribute.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    35
 * Class PrinterStateReason defines standard printer
90ce3da70b43 Initial load
duke
parents:
diff changeset
    36
 * state reason values. A Print Service implementation only needs to report
90ce3da70b43 Initial load
duke
parents:
diff changeset
    37
 * those printer state reasons which are appropriate for the particular
90ce3da70b43 Initial load
duke
parents:
diff changeset
    38
 * implementation; it does not have to report every defined printer state
90ce3da70b43 Initial load
duke
parents:
diff changeset
    39
 * reason.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    40
 * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
    41
 * Instances of PrinterStateReason do not appear in a Print Service's
90ce3da70b43 Initial load
duke
parents:
diff changeset
    42
 * attribute set directly.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    43
 * Rather, a {@link PrinterStateReasons PrinterStateReasons}
90ce3da70b43 Initial load
duke
parents:
diff changeset
    44
 * attribute appears in the Print Service's attribute set. The {@link
90ce3da70b43 Initial load
duke
parents:
diff changeset
    45
 * PrinterStateReasons PrinterStateReasons} attribute contains zero, one, or
90ce3da70b43 Initial load
duke
parents:
diff changeset
    46
 * more than one PrinterStateReason objects which pertain to the
90ce3da70b43 Initial load
duke
parents:
diff changeset
    47
 * Print Service's status, and each PrinterStateReason object is
90ce3da70b43 Initial load
duke
parents:
diff changeset
    48
 * associated with a {@link Severity Severity} level of REPORT (least severe),
90ce3da70b43 Initial load
duke
parents:
diff changeset
    49
 * WARNING, or ERROR (most severe). The printer adds a PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
    50
 * object to the Print Service's
90ce3da70b43 Initial load
duke
parents:
diff changeset
    51
 * {@link PrinterStateReasons PrinterStateReasons} attribute when the
90ce3da70b43 Initial load
duke
parents:
diff changeset
    52
 * corresponding condition becomes true of the printer, and the printer
21278
ef8a3a2a72f2 8022746: List of spelling errors in API doc
malenkov
parents: 5506
diff changeset
    53
 * removes the PrinterStateReason object again when the corresponding
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    54
 * condition becomes false, regardless of whether the Print Service's overall
90ce3da70b43 Initial load
duke
parents:
diff changeset
    55
 * {@link PrinterState PrinterState} also changed.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    56
 * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
    57
 * <B>IPP Compatibility:</B>
90ce3da70b43 Initial load
duke
parents:
diff changeset
    58
 * The string values returned by each individual {@link PrinterStateReason} and
35667
ed476aba94de 8138838: docs cleanup for java.desktop
avstepan
parents: 25859
diff changeset
    59
 * associated {@link Severity} object's {@code toString()}
ed476aba94de 8138838: docs cleanup for java.desktop
avstepan
parents: 25859
diff changeset
    60
 * methods, concatenated together with a hyphen ({@code "-"}) in
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    61
 * between, gives the IPP keyword value for a {@link PrinterStateReasons}.
35667
ed476aba94de 8138838: docs cleanup for java.desktop
avstepan
parents: 25859
diff changeset
    62
 * The category name returned by {@code getName()} gives the IPP
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    63
 * attribute name.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    64
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    65
 * @author  Alan Kaminsky
90ce3da70b43 Initial load
duke
parents:
diff changeset
    66
 */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    67
public class PrinterStateReason extends EnumSyntax implements Attribute {
90ce3da70b43 Initial load
duke
parents:
diff changeset
    68
90ce3da70b43 Initial load
duke
parents:
diff changeset
    69
    private static final long serialVersionUID = -1623720656201472593L;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    70
90ce3da70b43 Initial load
duke
parents:
diff changeset
    71
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
    72
     * The printer has detected an error other than ones listed below.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    73
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    74
    public static final PrinterStateReason OTHER = new PrinterStateReason(0);
90ce3da70b43 Initial load
duke
parents:
diff changeset
    75
90ce3da70b43 Initial load
duke
parents:
diff changeset
    76
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
    77
     * A tray has run out of media.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    78
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    79
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
    80
        MEDIA_NEEDED = new PrinterStateReason(1);
90ce3da70b43 Initial load
duke
parents:
diff changeset
    81
90ce3da70b43 Initial load
duke
parents:
diff changeset
    82
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
    83
     * The device has a media jam.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    84
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    85
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
    86
        MEDIA_JAM = new PrinterStateReason(2);
90ce3da70b43 Initial load
duke
parents:
diff changeset
    87
90ce3da70b43 Initial load
duke
parents:
diff changeset
    88
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
    89
     * Someone has paused the printer, but the device(s) are taking an
90ce3da70b43 Initial load
duke
parents:
diff changeset
    90
     * appreciable time to stop. Later, when all output has stopped,
90ce3da70b43 Initial load
duke
parents:
diff changeset
    91
     * the {@link  PrinterState PrinterState} becomes STOPPED,
90ce3da70b43 Initial load
duke
parents:
diff changeset
    92
     * and the PAUSED value replaces
90ce3da70b43 Initial load
duke
parents:
diff changeset
    93
     * the MOVING_TO_PAUSED value in the {@link PrinterStateReasons
90ce3da70b43 Initial load
duke
parents:
diff changeset
    94
     * PrinterStateReasons} attribute. This value must be supported if the
90ce3da70b43 Initial load
duke
parents:
diff changeset
    95
     * printer can be paused and the implementation takes significant time to
90ce3da70b43 Initial load
duke
parents:
diff changeset
    96
     * pause a device in certain circumstances.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    97
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    98
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
    99
        MOVING_TO_PAUSED = new PrinterStateReason(3);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   100
90ce3da70b43 Initial load
duke
parents:
diff changeset
   101
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   102
     * Someone has paused the printer and the printer's {@link PrinterState
90ce3da70b43 Initial load
duke
parents:
diff changeset
   103
     * PrinterState} is STOPPED. In this state, a printer must not produce
90ce3da70b43 Initial load
duke
parents:
diff changeset
   104
     * printed output, but it must perform other operations requested by a
90ce3da70b43 Initial load
duke
parents:
diff changeset
   105
     * client. If a printer had been printing a job when the printer was
90ce3da70b43 Initial load
duke
parents:
diff changeset
   106
     * paused,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   107
     * the Printer must resume printing that job when the printer is no longer
90ce3da70b43 Initial load
duke
parents:
diff changeset
   108
     * paused and leave no evidence in the printed output of such a pause.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   109
     * This value must be supported if the printer can be paused.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   110
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   111
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   112
        PAUSED = new PrinterStateReason(4);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   113
90ce3da70b43 Initial load
duke
parents:
diff changeset
   114
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   115
     * Someone has removed a printer from service, and the device may be
90ce3da70b43 Initial load
duke
parents:
diff changeset
   116
     * powered down or physically removed.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   117
     * In this state, a printer must not produce
90ce3da70b43 Initial load
duke
parents:
diff changeset
   118
     * printed output, and unless the printer is realized by a print server
90ce3da70b43 Initial load
duke
parents:
diff changeset
   119
     * that is still active, the printer must perform no other operations
90ce3da70b43 Initial load
duke
parents:
diff changeset
   120
     * requested by a client.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   121
     * If a printer had been printing a job when it was shut down,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   122
     * the printer need not resume printing that job when the printer is no
90ce3da70b43 Initial load
duke
parents:
diff changeset
   123
     * longer shut down. If the printer resumes printing such a job, it may
90ce3da70b43 Initial load
duke
parents:
diff changeset
   124
     * leave evidence in the printed output of such a shutdown, e.g. the part
90ce3da70b43 Initial load
duke
parents:
diff changeset
   125
     * printed before the shutdown may be printed a second time after the
90ce3da70b43 Initial load
duke
parents:
diff changeset
   126
     * shutdown.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   127
         */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   128
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   129
        SHUTDOWN = new PrinterStateReason(5);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   130
90ce3da70b43 Initial load
duke
parents:
diff changeset
   131
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   132
     * The printer has scheduled a job on the output device and is in the
90ce3da70b43 Initial load
duke
parents:
diff changeset
   133
     * process of connecting to a shared network output device (and might not
90ce3da70b43 Initial load
duke
parents:
diff changeset
   134
     * be able to actually start printing the job for an arbitrarily long time
90ce3da70b43 Initial load
duke
parents:
diff changeset
   135
     * depending on the usage of the output device by other servers on the
90ce3da70b43 Initial load
duke
parents:
diff changeset
   136
     * network).
90ce3da70b43 Initial load
duke
parents:
diff changeset
   137
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   138
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   139
        CONNECTING_TO_DEVICE = new PrinterStateReason(6);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   140
90ce3da70b43 Initial load
duke
parents:
diff changeset
   141
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   142
     * The server was able to connect to the output device (or is always
90ce3da70b43 Initial load
duke
parents:
diff changeset
   143
     * connected), but was unable to get a response from the output device.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   144
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   145
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   146
        TIMED_OUT = new PrinterStateReason(7);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   147
90ce3da70b43 Initial load
duke
parents:
diff changeset
   148
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   149
     * The printer is in the process of stopping the device and will be
90ce3da70b43 Initial load
duke
parents:
diff changeset
   150
     * stopped in a while.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   151
     * When the device is stopped, the printer will change the
90ce3da70b43 Initial load
duke
parents:
diff changeset
   152
     * {@link PrinterState PrinterState} to STOPPED. The STOPPING reason is
90ce3da70b43 Initial load
duke
parents:
diff changeset
   153
     * never an error, even for a printer with a single output device. When an
90ce3da70b43 Initial load
duke
parents:
diff changeset
   154
     * output device ceases accepting jobs, the printer's {@link
90ce3da70b43 Initial load
duke
parents:
diff changeset
   155
     * PrinterStateReasons PrinterStateReasons} will have this reason while
90ce3da70b43 Initial load
duke
parents:
diff changeset
   156
     * the output device completes printing.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   157
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   158
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   159
        STOPPING = new PrinterStateReason(8);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   160
90ce3da70b43 Initial load
duke
parents:
diff changeset
   161
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   162
     * When a printer controls more than one output device, this reason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   163
     * indicates that one or more output devices are stopped. If the reason's
90ce3da70b43 Initial load
duke
parents:
diff changeset
   164
     * severity is a report, fewer than half of the output devices are
90ce3da70b43 Initial load
duke
parents:
diff changeset
   165
     * stopped.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   166
     * If the reason's severity is a warning, half or more but fewer than
90ce3da70b43 Initial load
duke
parents:
diff changeset
   167
     * all of the output devices are stopped.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   168
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   169
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   170
        STOPPED_PARTLY = new PrinterStateReason(9);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   171
90ce3da70b43 Initial load
duke
parents:
diff changeset
   172
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   173
     * The device is low on toner.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   174
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   175
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   176
        TONER_LOW = new PrinterStateReason(10);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   177
90ce3da70b43 Initial load
duke
parents:
diff changeset
   178
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   179
     * The device is out of toner.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   180
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   181
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   182
        TONER_EMPTY = new PrinterStateReason(11);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   183
90ce3da70b43 Initial load
duke
parents:
diff changeset
   184
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   185
     * The limit of persistent storage allocated for spooling has been
90ce3da70b43 Initial load
duke
parents:
diff changeset
   186
     * reached.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   187
     * The printer is temporarily unable to accept more jobs. The printer will
90ce3da70b43 Initial load
duke
parents:
diff changeset
   188
     * remove this reason when it is able to accept more jobs.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   189
     * This value should  be used by a non-spooling printer that only
90ce3da70b43 Initial load
duke
parents:
diff changeset
   190
     * accepts one or a small number
90ce3da70b43 Initial load
duke
parents:
diff changeset
   191
     * jobs at a time or a spooling printer that has filled the spool space.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   192
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   193
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   194
        SPOOL_AREA_FULL = new PrinterStateReason(12);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   195
90ce3da70b43 Initial load
duke
parents:
diff changeset
   196
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   197
     * One or more covers on the device are open.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   198
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   199
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   200
        COVER_OPEN = new PrinterStateReason(13);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   201
90ce3da70b43 Initial load
duke
parents:
diff changeset
   202
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   203
     * One or more interlock devices on the printer are unlocked.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   204
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   205
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   206
        INTERLOCK_OPEN = new PrinterStateReason(14);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   207
90ce3da70b43 Initial load
duke
parents:
diff changeset
   208
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   209
     * One or more doors on the device are open.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   210
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   211
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   212
        DOOR_OPEN = new PrinterStateReason(15);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   213
90ce3da70b43 Initial load
duke
parents:
diff changeset
   214
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   215
     * One or more input trays are not in the device.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   216
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   217
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   218
        INPUT_TRAY_MISSING = new PrinterStateReason(16);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   219
90ce3da70b43 Initial load
duke
parents:
diff changeset
   220
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   221
     * At least one input tray is low on media.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   222
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   223
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   224
        MEDIA_LOW = new PrinterStateReason(17);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   225
90ce3da70b43 Initial load
duke
parents:
diff changeset
   226
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   227
     * At least one input tray is empty.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   228
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   229
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   230
        MEDIA_EMPTY = new PrinterStateReason(18);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   231
90ce3da70b43 Initial load
duke
parents:
diff changeset
   232
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   233
     * One or more output trays are not in the device.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   234
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   235
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   236
        OUTPUT_TRAY_MISSING = new PrinterStateReason(19);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   237
90ce3da70b43 Initial load
duke
parents:
diff changeset
   238
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   239
     * One or more output areas are almost full
90ce3da70b43 Initial load
duke
parents:
diff changeset
   240
     * (e.g. tray, stacker, collator).
90ce3da70b43 Initial load
duke
parents:
diff changeset
   241
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   242
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   243
        OUTPUT_AREA_ALMOST_FULL = new PrinterStateReason(20);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   244
90ce3da70b43 Initial load
duke
parents:
diff changeset
   245
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   246
     * One or more output areas are full (e.g. tray, stacker, collator).
90ce3da70b43 Initial load
duke
parents:
diff changeset
   247
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   248
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   249
        OUTPUT_AREA_FULL = new PrinterStateReason(21);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   250
90ce3da70b43 Initial load
duke
parents:
diff changeset
   251
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   252
     * The device is low on at least one marker supply (e.g. toner, ink,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   253
     * ribbon).
90ce3da70b43 Initial load
duke
parents:
diff changeset
   254
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   255
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   256
        MARKER_SUPPLY_LOW = new PrinterStateReason(22);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   257
90ce3da70b43 Initial load
duke
parents:
diff changeset
   258
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   259
     * The device is out of at least one marker supply (e.g. toner, ink,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   260
     * ribbon).
90ce3da70b43 Initial load
duke
parents:
diff changeset
   261
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   262
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   263
        MARKER_SUPPLY_EMPTY = new PrinterStateReason(23);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   264
90ce3da70b43 Initial load
duke
parents:
diff changeset
   265
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   266
     * The device marker supply waste receptacle is almost full.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   267
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   268
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   269
        MARKER_WASTE_ALMOST_FULL = new PrinterStateReason(24);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   270
90ce3da70b43 Initial load
duke
parents:
diff changeset
   271
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   272
     * The device marker supply waste receptacle is full.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   273
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   274
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   275
        MARKER_WASTE_FULL = new PrinterStateReason(25);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   276
90ce3da70b43 Initial load
duke
parents:
diff changeset
   277
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   278
     * The fuser temperature is above normal.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   279
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   280
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   281
        FUSER_OVER_TEMP = new PrinterStateReason(26);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   282
90ce3da70b43 Initial load
duke
parents:
diff changeset
   283
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   284
     * The fuser temperature is below normal.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   285
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   286
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   287
        FUSER_UNDER_TEMP = new PrinterStateReason(27);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   288
90ce3da70b43 Initial load
duke
parents:
diff changeset
   289
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   290
     * The optical photo conductor is near end of life.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   291
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   292
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   293
        OPC_NEAR_EOL = new PrinterStateReason(28);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   294
90ce3da70b43 Initial load
duke
parents:
diff changeset
   295
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   296
     * The optical photo conductor is no longer functioning.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   297
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   298
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   299
        OPC_LIFE_OVER = new PrinterStateReason(29);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   300
90ce3da70b43 Initial load
duke
parents:
diff changeset
   301
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   302
     * The device is low on developer.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   303
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   304
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   305
        DEVELOPER_LOW = new PrinterStateReason(30);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   306
90ce3da70b43 Initial load
duke
parents:
diff changeset
   307
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   308
     * The device is out of developer.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   309
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   310
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   311
        DEVELOPER_EMPTY = new PrinterStateReason(31);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   312
90ce3da70b43 Initial load
duke
parents:
diff changeset
   313
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   314
     * An interpreter resource is unavailable (e.g., font, form).
90ce3da70b43 Initial load
duke
parents:
diff changeset
   315
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   316
    public static final PrinterStateReason
90ce3da70b43 Initial load
duke
parents:
diff changeset
   317
        INTERPRETER_RESOURCE_UNAVAILABLE = new PrinterStateReason(32);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   318
90ce3da70b43 Initial load
duke
parents:
diff changeset
   319
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   320
     * Construct a new printer state reason enumeration value with
90ce3da70b43 Initial load
duke
parents:
diff changeset
   321
     * the given integer value.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   322
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   323
     * @param  value  Integer value.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   324
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   325
    protected PrinterStateReason(int value) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   326
        super (value);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   327
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   328
90ce3da70b43 Initial load
duke
parents:
diff changeset
   329
    private static final String[] myStringTable = {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   330
        "other",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   331
        "media-needed",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   332
        "media-jam",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   333
        "moving-to-paused",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   334
        "paused",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   335
        "shutdown",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   336
        "connecting-to-device",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   337
        "timed-out",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   338
        "stopping",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   339
        "stopped-partly",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   340
        "toner-low",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   341
        "toner-empty",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   342
        "spool-area-full",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   343
        "cover-open",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   344
        "interlock-open",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   345
        "door-open",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   346
        "input-tray-missing",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   347
        "media-low",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   348
        "media-empty",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   349
        "output-tray-missing",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   350
        "output-area-almost-full",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   351
        "output-area-full",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   352
        "marker-supply-low",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   353
        "marker-supply-empty",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   354
        "marker-waste-almost-full",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   355
        "marker-waste-full",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   356
        "fuser-over-temp",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   357
        "fuser-under-temp",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   358
        "opc-near-eol",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   359
        "opc-life-over",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   360
        "developer-low",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   361
        "developer-empty",
90ce3da70b43 Initial load
duke
parents:
diff changeset
   362
        "interpreter-resource-unavailable"
90ce3da70b43 Initial load
duke
parents:
diff changeset
   363
    };
90ce3da70b43 Initial load
duke
parents:
diff changeset
   364
90ce3da70b43 Initial load
duke
parents:
diff changeset
   365
    private static final PrinterStateReason[] myEnumValueTable = {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   366
        OTHER,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   367
        MEDIA_NEEDED,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   368
        MEDIA_JAM,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   369
        MOVING_TO_PAUSED,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   370
        PAUSED,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   371
        SHUTDOWN,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   372
        CONNECTING_TO_DEVICE,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   373
        TIMED_OUT,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   374
        STOPPING,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   375
        STOPPED_PARTLY,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   376
        TONER_LOW,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   377
        TONER_EMPTY,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   378
        SPOOL_AREA_FULL,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   379
        COVER_OPEN,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   380
        INTERLOCK_OPEN,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   381
        DOOR_OPEN,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   382
        INPUT_TRAY_MISSING,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   383
        MEDIA_LOW,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   384
        MEDIA_EMPTY,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   385
        OUTPUT_TRAY_MISSING,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   386
        OUTPUT_AREA_ALMOST_FULL,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   387
        OUTPUT_AREA_FULL,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   388
        MARKER_SUPPLY_LOW,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   389
        MARKER_SUPPLY_EMPTY,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   390
        MARKER_WASTE_ALMOST_FULL,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   391
        MARKER_WASTE_FULL,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   392
        FUSER_OVER_TEMP,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   393
        FUSER_UNDER_TEMP,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   394
        OPC_NEAR_EOL,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   395
        OPC_LIFE_OVER,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   396
        DEVELOPER_LOW,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   397
        DEVELOPER_EMPTY,
90ce3da70b43 Initial load
duke
parents:
diff changeset
   398
        INTERPRETER_RESOURCE_UNAVAILABLE
90ce3da70b43 Initial load
duke
parents:
diff changeset
   399
    };
90ce3da70b43 Initial load
duke
parents:
diff changeset
   400
90ce3da70b43 Initial load
duke
parents:
diff changeset
   401
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   402
     * Returns the string table for class PrinterStateReason.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   403
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   404
    protected String[] getStringTable() {
22584
eed64ee05369 8032733: Fix cast lint warnings in client libraries
darcy
parents: 21278
diff changeset
   405
        return myStringTable.clone();
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   406
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   407
90ce3da70b43 Initial load
duke
parents:
diff changeset
   408
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   409
     * Returns the enumeration value table for class PrinterStateReason.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   410
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   411
    protected EnumSyntax[] getEnumValueTable() {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   412
        return (EnumSyntax[])myEnumValueTable.clone();
90ce3da70b43 Initial load
duke
parents:
diff changeset
   413
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   414
90ce3da70b43 Initial load
duke
parents:
diff changeset
   415
90ce3da70b43 Initial load
duke
parents:
diff changeset
   416
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   417
     * Get the printing attribute class which is to be used as the "category"
90ce3da70b43 Initial load
duke
parents:
diff changeset
   418
     * for this printing attribute value.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   419
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
   420
     * For class PrinterStateReason and any vendor-defined subclasses, the
90ce3da70b43 Initial load
duke
parents:
diff changeset
   421
     * category is class PrinterStateReason itself.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   422
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   423
     * @return  Printing attribute class (category), an instance of class
90ce3da70b43 Initial load
duke
parents:
diff changeset
   424
     *          {@link java.lang.Class java.lang.Class}.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   425
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   426
    public final Class<? extends Attribute> getCategory() {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   427
        return PrinterStateReason.class;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   428
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   429
90ce3da70b43 Initial load
duke
parents:
diff changeset
   430
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   431
     * Get the name of the category of which this attribute value is an
90ce3da70b43 Initial load
duke
parents:
diff changeset
   432
     * instance.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   433
     * <P>
90ce3da70b43 Initial load
duke
parents:
diff changeset
   434
     * For class PrinterStateReason and any vendor-defined subclasses, the
35667
ed476aba94de 8138838: docs cleanup for java.desktop
avstepan
parents: 25859
diff changeset
   435
     * category name is {@code "printer-state-reason"}.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   436
     *
90ce3da70b43 Initial load
duke
parents:
diff changeset
   437
     * @return  Attribute category name.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   438
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   439
    public final String getName() {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   440
        return "printer-state-reason";
90ce3da70b43 Initial load
duke
parents:
diff changeset
   441
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   442
90ce3da70b43 Initial load
duke
parents:
diff changeset
   443
}