1 package com
.easysw
.cups
;
4 * @version 1.00 06-NOV-2002
5 * @author Easy Software Products
7 * Internet Printing Protocol definitions for the Common UNIX Printing
10 * Copyright 1997-2002 by Easy Software Products.
12 * These coded instructions, statements, and computer programs are the
13 * property of Easy Software Products and are protected by Federal
14 * copyright law. Distribution and use rights are outlined in the file
15 * "LICENSE.txt" which should have been included with this file. If this
16 * file is missing or damaged please contact Easy Software Products
19 * Attn: CUPS Licensing Information
20 * Easy Software Products
21 * 44141 Airport View Drive, Suite 204
22 * Hollywood, Maryland 20636-3111 USA
24 * Voice: (301) 373-9603
25 * EMail: cups-info@cups.org
26 * WWW: http://www.cups.org
30 * Class to convert a status code to text.
37 public class IPPStatus
43 * Constructor, access the <code>status_text</code> member
46 * @param <code>p_status</code> Status code to convert.
47 * @see <code>IPPDefs</code>
49 public IPPStatus( int p_status
)
57 case IPPDefs
.OK_SUBST
:
58 status_text
= "OK, substituted";
60 case IPPDefs
.OK_CONFLICT
:
61 status_text
= "OK, conflict";
63 case IPPDefs
.OK_IGNORED_SUBSCRIPTIONS
:
64 status_text
= "OK, ignored subscriptions";
66 case IPPDefs
.OK_IGNORED_NOTIFICATIONS
:
67 status_text
= "OK, ignored notifications";
69 case IPPDefs
.OK_TOO_MANY_EVENTS
:
70 status_text
= "OK, too many events";
72 case IPPDefs
.OK_BUT_CANCEL_SUBSCRIPTION
:
73 status_text
= "OK, but cancel subscription";
75 case IPPDefs
.REDIRECTION_OTHER_SITE
:
76 status_text
= "Redirected to other site";
78 case IPPDefs
.BAD_REQUEST
:
79 status_text
= "Bad request";
81 case IPPDefs
.FORBIDDEN
:
82 status_text
= "Forbidden";
84 case IPPDefs
.NOT_AUTHENTICATED
:
85 status_text
= "Not authenticated";
87 case IPPDefs
.NOT_AUTHORIZED
:
88 status_text
= "Not authorized";
90 case IPPDefs
.NOT_POSSIBLE
:
91 status_text
= "Not possible";
94 status_text
= "Timeout";
96 case IPPDefs
.NOT_FOUND
:
97 status_text
= "Not found";
100 status_text
= "Gone";
102 case IPPDefs
.REQUEST_ENTITY
:
103 status_text
= "Request entity";
105 case IPPDefs
.REQUEST_VALUE
:
106 status_text
= "Request value";
108 case IPPDefs
.DOCUMENT_FORMAT
:
109 status_text
= "Document format";
111 case IPPDefs
.ATTRIBUTES
:
112 status_text
= "Attributes";
114 case IPPDefs
.URI_SCHEME
:
115 status_text
= "URI scheme";
117 case IPPDefs
.CHARSET
:
118 status_text
= "Charset";
120 case IPPDefs
.CONFLICT
:
121 status_text
= "Conflict";
123 case IPPDefs
.COMPRESSION_NOT_SUPPORTED
:
124 status_text
= "Compression not supported";
126 case IPPDefs
.COMPRESSION_ERROR
:
127 status_text
= "Compression error";
129 case IPPDefs
.DOCUMENT_FORMAT_ERROR
:
130 status_text
= "Document format error";
132 case IPPDefs
.DOCUMENT_ACCESS_ERROR
:
133 status_text
= "Document access error";
135 case IPPDefs
.ATTRIBUTES_NOT_SETTABLE
:
136 status_text
= "Attributes not settable";
138 case IPPDefs
.IGNORED_ALL_SUBSCRIPTIONS
:
139 status_text
= "Ignored all subscriptions";
141 case IPPDefs
.TOO_MANY_SUBSCRIPTIONS
:
142 status_text
= "Too many subscriptions";
144 case IPPDefs
.IGNORED_ALL_NOTIFICATIONS
:
145 status_text
= "Ingored all notifications";
147 case IPPDefs
.PRINT_SUPPORT_FILE_NOT_FOUND
:
148 status_text
= "Support file not found";
150 case IPPDefs
.INTERNAL_ERROR
:
151 status_text
= "Internal error";
153 case IPPDefs
.OPERATION_NOT_SUPPORTED
:
154 status_text
= "Operation not supported";
156 case IPPDefs
.SERVICE_UNAVAILABLE
:
157 status_text
= "Service unavailable";
159 case IPPDefs
.VERSION_NOT_SUPPORTED
:
160 status_text
= "Version not supported";
162 case IPPDefs
.DEVICE_ERROR
:
163 status_text
= "Device error";
165 case IPPDefs
.TEMPORARY_ERROR
:
166 status_text
= "Temporary error";
168 case IPPDefs
.NOT_ACCEPTING
:
169 status_text
= "Not accepting";
171 case IPPDefs
.PRINTER_BUSY
:
172 status_text
= "Printer busy";
174 case IPPDefs
.ERROR_JOB_CANCELLED
:
175 status_text
= "Error, job cancelled";
177 case IPPDefs
.MULTIPLE_JOBS_NOT_SUPPORTED
:
178 status_text
= "Multiple jobs not supported";
180 case IPPDefs
.PRINTER_IS_DEACTIVATED
:
181 status_text
= "Printer is de-activated";
184 status_text
= "Unknown error";
192 } // End of IPPStatus class