]>
Commit | Line | Data |
---|---|---|
745129be | 1 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> |
ef416fc2 | 2 | <html> |
3 | <!-- SECTION: Programming --> | |
4 | <head> | |
0268488e MS |
5 | <title>HTTP and IPP APIs </title> |
6 | <meta name="keywords" content="Programming"> | |
7 | <meta http-equiv="Content-Type" content="text/html;charset=utf-8"> | |
dd3fdd2c | 8 | <meta name="creator" content="Mini-XML v2.7"> |
5a738aea MS |
9 | <style type="text/css"><!-- |
10 | BODY { | |
11 | font-family: lucida grande, geneva, helvetica, arial, sans-serif; | |
12 | } | |
13 | ||
14 | H1, H2, H3, H4, H5, H6, P, TD, TH { | |
15 | font-family: lucida grande, geneva, helvetica, arial, sans-serif; | |
16 | } | |
17 | ||
18 | KBD { | |
19 | font-family: monaco, courier, monospace; | |
20 | font-weight: bold; | |
21 | } | |
22 | ||
23 | PRE { | |
24 | font-family: monaco, courier, monospace; | |
25 | } | |
26 | ||
27 | PRE.command { | |
10d09e33 | 28 | border: dotted thin #7f7f7f; |
5a738aea | 29 | margin-left: 36pt; |
10d09e33 | 30 | padding: 10px; |
5a738aea MS |
31 | } |
32 | ||
f11a948a MS |
33 | P.compact { |
34 | margin: 0; | |
35 | } | |
36 | ||
e4572d57 MS |
37 | P.example { |
38 | font-style: italic; | |
39 | margin-left: 36pt; | |
40 | } | |
ca6b43fc | 41 | |
240214ef MS |
42 | DL.man DD { |
43 | margin-left: 5em; | |
44 | } | |
45 | ||
46 | DL.man DT { | |
47 | margin-left: 0; | |
48 | } | |
49 | ||
50 | PRE.man { | |
51 | margin: 0; | |
52 | } | |
53 | ||
5a738aea MS |
54 | PRE.example { |
55 | background: #eeeeee; | |
56 | border: dotted thin #999999; | |
57 | margin-left: 36pt; | |
178cb736 | 58 | padding: 10pt; |
5a738aea MS |
59 | } |
60 | ||
61 | PRE.command EM, PRE.example EM { | |
62 | font-family: lucida grande, geneva, helvetica, arial, sans-serif; | |
63 | } | |
64 | ||
65 | P.command { | |
66 | font-family: monaco, courier, monospace; | |
67 | margin-left: 36pt; | |
68 | } | |
69 | ||
70 | P.formula { | |
71 | font-style: italic; | |
72 | margin-left: 36pt; | |
73 | } | |
74 | ||
75 | BLOCKQUOTE { | |
178cb736 | 76 | background: #eeeeee; |
5a738aea MS |
77 | border: solid thin #999999; |
78 | padding: 10pt; | |
79 | } | |
80 | ||
e4572d57 MS |
81 | A IMG { |
82 | border: none; | |
83 | } | |
84 | ||
85 | A:link:hover IMG { | |
86 | background: #f0f0f0; | |
87 | border-radius: 10px; | |
88 | -moz-border-radius: 10px; | |
89 | } | |
90 | ||
5a738aea | 91 | A:link, A:visited { |
ca6b43fc | 92 | font-weight: inherit; |
5a738aea | 93 | text-decoration: none; |
5a738aea MS |
94 | } |
95 | ||
96 | A:link:hover, A:visited:hover, A:active { | |
97 | text-decoration: underline; | |
5a738aea MS |
98 | } |
99 | ||
100 | SUB, SUP { | |
101 | font-size: 50%; | |
102 | } | |
103 | ||
e4572d57 MS |
104 | TR.data, TD.data, TR.data TD { |
105 | margin-top: 10pt; | |
106 | padding: 5pt; | |
107 | border-bottom: solid 1pt #999999; | |
108 | } | |
109 | ||
110 | TR.data TH { | |
111 | border-bottom: solid 1pt #999999; | |
112 | padding-top: 10pt; | |
113 | padding-left: 5pt; | |
114 | text-align: left; | |
115 | } | |
116 | ||
5a738aea MS |
117 | DIV.table TABLE { |
118 | border: solid thin #999999; | |
119 | border-collapse: collapse; | |
120 | border-spacing: 0; | |
121 | margin-left: auto; | |
122 | margin-right: auto; | |
123 | } | |
124 | ||
125 | DIV.table CAPTION { | |
126 | caption-side: top; | |
127 | font-size: 120%; | |
128 | font-style: italic; | |
129 | font-weight: bold; | |
130 | margin-left: auto; | |
131 | margin-right: auto; | |
132 | } | |
133 | ||
134 | DIV.table TABLE TD { | |
135 | border: solid thin #cccccc; | |
136 | padding-top: 5pt; | |
137 | } | |
138 | ||
139 | DIV.table TABLE TH { | |
140 | background: #cccccc; | |
141 | border: none; | |
142 | border-bottom: solid thin #999999; | |
143 | } | |
144 | ||
145 | DIV.figure TABLE { | |
146 | margin-left: auto; | |
147 | margin-right: auto; | |
148 | } | |
149 | ||
150 | DIV.figure CAPTION { | |
151 | caption-side: bottom; | |
152 | font-size: 120%; | |
153 | font-style: italic; | |
154 | font-weight: bold; | |
155 | margin-left: auto; | |
156 | margin-right: auto; | |
157 | } | |
158 | ||
159 | TH.label { | |
5a738aea MS |
160 | text-align: right; |
161 | vertical-align: top; | |
162 | } | |
163 | ||
e4572d57 MS |
164 | TH.sublabel { |
165 | text-align: right; | |
166 | font-weight: normal; | |
167 | } | |
168 | ||
5a738aea MS |
169 | HR { |
170 | border: solid thin; | |
171 | } | |
172 | ||
173 | SPAN.info { | |
e4572d57 MS |
174 | background: black; |
175 | border: thin solid black; | |
176 | color: white; | |
5a738aea MS |
177 | font-size: 80%; |
178 | font-style: italic; | |
179 | font-weight: bold; | |
180 | white-space: nowrap; | |
181 | } | |
182 | ||
183 | H2 SPAN.info, H3 SPAN.info, H4 SPAN.info { | |
184 | float: right; | |
185 | font-size: 100%; | |
186 | } | |
187 | ||
178cb736 MS |
188 | H1.title { |
189 | } | |
190 | ||
5a738aea MS |
191 | H2.title, H3.title { |
192 | border-bottom: solid 2pt #000000; | |
193 | } | |
194 | ||
e4572d57 MS |
195 | DIV.indent, TABLE.indent { |
196 | margin-top: 2em; | |
197 | margin-left: auto; | |
198 | margin-right: auto; | |
199 | width: 90%; | |
200 | } | |
201 | ||
202 | TABLE.indent { | |
203 | border-collapse: collapse; | |
204 | } | |
205 | ||
206 | TABLE.indent TD, TABLE.indent TH { | |
207 | padding: 0; | |
208 | } | |
209 | ||
210 | TABLE.list { | |
211 | border-collapse: collapse; | |
212 | margin-left: auto; | |
213 | margin-right: auto; | |
214 | width: 90%; | |
215 | } | |
216 | ||
217 | TABLE.list TH { | |
218 | background: white; | |
219 | border-bottom: solid thin #cccccc; | |
220 | color: #444444; | |
221 | padding-top: 10pt; | |
222 | padding-left: 5pt; | |
223 | text-align: left; | |
224 | vertical-align: bottom; | |
225 | white-space: nowrap; | |
226 | } | |
227 | ||
228 | TABLE.list TH A { | |
229 | color: #4444cc; | |
230 | } | |
231 | ||
232 | TABLE.list TD { | |
233 | border-bottom: solid thin #eeeeee; | |
234 | padding-top: 5pt; | |
235 | padding-left: 5pt; | |
236 | } | |
237 | ||
238 | TABLE.list TR:nth-child(even) { | |
239 | background: #f8f8f8; | |
240 | } | |
241 | ||
242 | TABLE.list TR:nth-child(odd) { | |
243 | background: #f4f4f4; | |
244 | } | |
245 | ||
5a738aea MS |
246 | DT { |
247 | margin-left: 36pt; | |
248 | margin-top: 12pt; | |
249 | } | |
250 | ||
251 | DD { | |
252 | margin-left: 54pt; | |
253 | } | |
254 | ||
255 | DL.category DT { | |
256 | font-weight: bold; | |
257 | } | |
258 | ||
259 | P.summary { | |
260 | margin-left: 36pt; | |
261 | font-family: monaco, courier, monospace; | |
262 | } | |
263 | ||
5a738aea MS |
264 | DIV.summary TABLE { |
265 | border: solid thin #999999; | |
266 | border-collapse: collapse; | |
267 | border-spacing: 0; | |
268 | margin: 10px; | |
269 | } | |
270 | ||
271 | DIV.summary TABLE TD, DIV.summary TABLE TH { | |
272 | border: solid thin #999999; | |
273 | padding: 5px; | |
274 | text-align: left; | |
275 | vertical-align: top; | |
276 | } | |
277 | ||
278 | DIV.summary TABLE THEAD TH { | |
279 | background: #eeeeee; | |
280 | } | |
281 | ||
282 | /* API documentation styles... */ | |
283 | div.body h1 { | |
284 | margin: 0; | |
285 | } | |
286 | div.body h2 { | |
287 | margin-top: 1.5em; | |
288 | } | |
289 | div.body h3, div.body h4, div.body h5 { | |
290 | margin-bottom: 0.5em; | |
291 | margin-top: 1.5em; | |
292 | } | |
293 | .class, .enumeration, .function, .struct, .typedef, .union { | |
294 | border-bottom: solid thin #999999; | |
295 | margin-bottom: 0; | |
296 | margin-top: 2em; | |
297 | } | |
298 | .description { | |
299 | margin-top: 0.5em; | |
300 | } | |
301 | code, p.code, pre, ul.code li { | |
302 | font-family: monaco, courier, monospace; | |
303 | font-size: 90%; | |
304 | } | |
305 | ul.code, ul.contents, ul.subcontents { | |
306 | list-style-type: none; | |
307 | margin: 0; | |
308 | padding-left: 0; | |
309 | } | |
310 | ul.code li { | |
311 | margin: 0; | |
312 | } | |
313 | ul.contents > li { | |
314 | margin-top: 1em; | |
315 | } | |
316 | ul.contents li ul.code, ul.contents li ul.subcontents { | |
317 | padding-left: 2em; | |
318 | } | |
319 | div.body dl { | |
320 | margin-left: 0; | |
321 | margin-top: 0; | |
322 | } | |
323 | div.body dt { | |
324 | font-style: italic; | |
325 | margin-left: 0; | |
326 | margin-top: 0; | |
327 | } | |
328 | div.body dd { | |
329 | margin-bottom: 0.5em; | |
330 | } | |
331 | ||
332 | /* This is just for the HTML files generated with the framedhelp target */ | |
333 | div.contents { | |
334 | background: #e8e8e8; | |
335 | border: solid thin black; | |
336 | padding: 10px; | |
337 | } | |
338 | div.contents h1 { | |
339 | font-size: 110%; | |
340 | } | |
341 | div.contents h2 { | |
342 | font-size: 100%; | |
343 | } | |
344 | div.contents ul.contents { | |
345 | font-size: 80%; | |
346 | } | |
ac884b6a MS |
347 | div.contents ul.subcontents li { |
348 | margin-left: 1em; | |
349 | text-indent: -1em; | |
350 | } | |
5a738aea | 351 | --></style> |
ef416fc2 | 352 | </head> |
353 | <body> | |
5a738aea | 354 | <div class='body'> |
ef416fc2 | 355 | <!-- |
321d8d57 | 356 | HTTP and IPP API header for CUPS. |
5a738aea | 357 | |
321d8d57 | 358 | Copyright 2007-2011 by Apple Inc. |
5a738aea MS |
359 | Copyright 1997-2006 by Easy Software Products, all rights reserved. |
360 | ||
361 | These coded instructions, statements, and computer programs are the | |
362 | property of Apple Inc. and are protected by Federal copyright | |
363 | law. Distribution and use rights are outlined in the file "LICENSE.txt" | |
364 | which should have been included with this file. If this file is | |
365 | file is missing or damaged, see the license at "http://www.cups.org/". | |
366 | --> | |
367 | ||
178cb736 MS |
368 | <h1 class='title'>HTTP and IPP APIs</h1> |
369 | ||
5a738aea MS |
370 | <div class='summary'><table summary='General Information'> |
371 | <thead> | |
372 | <tr> | |
373 | <th>Header</th> | |
374 | <th>cups/cups.h</th> | |
375 | </tr> | |
376 | </thead> | |
377 | <tbody> | |
378 | <tr> | |
379 | <th>Library</th> | |
380 | <td>-lcups</td> | |
381 | </tr> | |
382 | <tr> | |
383 | <th>See Also</th> | |
384 | <td>Programming: <a href='api-overview.html'>Introduction to CUPS Programming</a><br> | |
385 | Programming: <a href='api-cups.html'>CUPS API</a><br> | |
386 | References: <a href='spec-ipp.html'>CUPS Implementation of IPP</a></td> | |
387 | </tr> | |
388 | </tbody> | |
389 | </table></div> | |
390 | <h2 class="title">Contents</h2> | |
391 | <ul class="contents"> | |
5a738aea | 392 | <li><a href="#OVERVIEW">Overview</a><ul class="subcontents"> |
0268488e MS |
393 | <li><a href="#CREATING_URI_STRINGS">Creating URI Strings</a></li> |
394 | <li><a href="#SENDING_REQUESTS_WITH_FILES">Sending Requests with Files</a></li> | |
395 | <li><a href="#ASYNCHRONOUS_REQUEST_PROCESSING">Asynchronous Request Processing</a></li> | |
5a738aea MS |
396 | </ul></li> |
397 | <li><a href="#FUNCTIONS">Functions</a><ul class="code"> | |
0268488e MS |
398 | <li><a href="#cupsDoAuthentication" title="Authenticate a request.">cupsDoAuthentication</a></li> |
399 | <li><a href="#cupsDoFileRequest" title="Do an IPP request with a file.">cupsDoFileRequest</a></li> | |
400 | <li><a href="#cupsDoIORequest" title="Do an IPP request with file descriptors.">cupsDoIORequest</a></li> | |
401 | <li><a href="#cupsDoRequest" title="Do an IPP request.">cupsDoRequest</a></li> | |
402 | <li><a href="#cupsEncodeOptions" title="Encode printer options into IPP attributes.">cupsEncodeOptions</a></li> | |
403 | <li><a href="#cupsEncodeOptions2" title="Encode printer options into IPP attributes for a group.">cupsEncodeOptions2</a></li> | |
404 | <li><a href="#cupsGetDevices" title="Get available printer devices.">cupsGetDevices</a></li> | |
405 | <li><a href="#cupsGetFd" title="Get a file from the server.">cupsGetFd</a></li> | |
406 | <li><a href="#cupsGetFile" title="Get a file from the server.">cupsGetFile</a></li> | |
407 | <li><a href="#cupsGetResponse" title="Get a response to an IPP request.">cupsGetResponse</a></li> | |
5a9febac MS |
408 | <li><a href="#cupsLastError" title="Return the last IPP status code received on the current |
409 | thread.">cupsLastError</a></li> | |
410 | <li><a href="#cupsLastErrorString" title="Return the last IPP status-message received on the | |
411 | current thread.">cupsLastErrorString</a></li> | |
0268488e MS |
412 | <li><a href="#cupsPutFd" title="Put a file on the server.">cupsPutFd</a></li> |
413 | <li><a href="#cupsPutFile" title="Put a file on the server.">cupsPutFile</a></li> | |
414 | <li><a href="#cupsReadResponseData" title="Read additional data after the IPP response.">cupsReadResponseData</a></li> | |
415 | <li><a href="#cupsSendRequest" title="Send an IPP request.">cupsSendRequest</a></li> | |
416 | <li><a href="#cupsWriteRequestData" title="Write additional data after an IPP request.">cupsWriteRequestData</a></li> | |
a469f8a5 MS |
417 | <li><a href="#httpAcceptConnection" title="Accept a new HTTP client connection from the |
418 | specified listening socket.">httpAcceptConnection</a></li> | |
0268488e MS |
419 | <li><a href="#httpAddCredential" title="Allocates and adds a single credential to an array.">httpAddCredential</a></li> |
420 | <li><a href="#httpAddrAny" title="Check for the "any" address.">httpAddrAny</a></li> | |
ca6b43fc MS |
421 | <li><a href="#httpAddrClose" title="Close a socket created by httpAddrConnect or |
422 | httpAddrListen.">httpAddrClose</a></li> | |
0268488e | 423 | <li><a href="#httpAddrEqual" title="Compare two addresses.">httpAddrEqual</a></li> |
ca6b43fc | 424 | <li><a href="#httpAddrFamily" title="Get the address family of an address.">httpAddrFamily</a></li> |
0268488e | 425 | <li><a href="#httpAddrLength" title="Return the length of the address in bytes.">httpAddrLength</a></li> |
a469f8a5 MS |
426 | <li><a href="#httpAddrListen" title="Create a listening socket bound to the specified |
427 | address and port.">httpAddrListen</a></li> | |
0268488e MS |
428 | <li><a href="#httpAddrLocalhost" title="Check for the local loopback address.">httpAddrLocalhost</a></li> |
429 | <li><a href="#httpAddrLookup" title="Lookup the hostname associated with the address.">httpAddrLookup</a></li> | |
a469f8a5 | 430 | <li><a href="#httpAddrPort" title="Get the port number associated with an address.">httpAddrPort</a></li> |
0268488e MS |
431 | <li><a href="#httpAddrString" title="Convert an address to a numeric string.">httpAddrString</a></li> |
432 | <li><a href="#httpAssembleURI" title="Assemble a uniform resource identifier from its | |
5a738aea | 433 | components.">httpAssembleURI</a></li> |
0268488e | 434 | <li><a href="#httpAssembleURIf" title="Assemble a uniform resource identifier from its |
5a738aea | 435 | components with a formatted resource.">httpAssembleURIf</a></li> |
db8b865d | 436 | <li><a href="#httpAssembleUUID" title="Assemble a name-based UUID URN conforming to RFC 4122.">httpAssembleUUID</a></li> |
0268488e MS |
437 | <li><a href="#httpBlocking" title="Set blocking/non-blocking behavior on a connection.">httpBlocking</a></li> |
438 | <li><a href="#httpCheck" title="Check to see if there is a pending response from the server.">httpCheck</a></li> | |
439 | <li><a href="#httpClearCookie" title="Clear the cookie value(s).">httpClearCookie</a></li> | |
440 | <li><a href="#httpClearFields" title="Clear HTTP request fields.">httpClearFields</a></li> | |
441 | <li><a href="#httpClose" title="Close an HTTP connection.">httpClose</a></li> | |
ca6b43fc | 442 | <li><a href="#httpCompareCredentials" title="Compare two sets of X.509 credentials.">httpCompareCredentials</a></li> |
0268488e | 443 | <li><a href="#httpConnect" title="Connect to a HTTP server.">httpConnect</a></li> |
a469f8a5 | 444 | <li><a href="#httpConnect2" title="Connect to a HTTP server.">httpConnect2</a></li> |
0268488e | 445 | <li><a href="#httpConnectEncrypt" title="Connect to a HTTP server using encryption.">httpConnectEncrypt</a></li> |
0268488e MS |
446 | <li><a href="#httpDecode64" title="Base64-decode a string.">httpDecode64</a></li> |
447 | <li><a href="#httpDecode64_2" title="Base64-decode a string.">httpDecode64_2</a></li> | |
448 | <li><a href="#httpDelete" title="Send a DELETE request to the server.">httpDelete</a></li> | |
449 | <li><a href="#httpEncode64" title="Base64-encode a string.">httpEncode64</a></li> | |
450 | <li><a href="#httpEncode64_2" title="Base64-encode a string.">httpEncode64_2</a></li> | |
451 | <li><a href="#httpEncryption" title="Set the required encryption on the link.">httpEncryption</a></li> | |
452 | <li><a href="#httpError" title="Get the last error on a connection.">httpError</a></li> | |
ca6b43fc MS |
453 | <li><a href="#httpFieldValue" title="Return the HTTP field enumeration value for a field |
454 | name.">httpFieldValue</a></li> | |
0268488e MS |
455 | <li><a href="#httpFlush" title="Flush data from a HTTP connection.">httpFlush</a></li> |
456 | <li><a href="#httpFlushWrite" title="Flush data in write buffer.">httpFlushWrite</a></li> | |
457 | <li><a href="#httpFreeCredentials" title="Free an array of credentials.">httpFreeCredentials</a></li> | |
458 | <li><a href="#httpGet" title="Send a GET request to the server.">httpGet</a></li> | |
ca6b43fc MS |
459 | <li><a href="#httpGetActivity" title="Get the most recent activity for a connection.">httpGetActivity</a></li> |
460 | <li><a href="#httpGetAddress" title="Get the address of the connected peer of a connection.">httpGetAddress</a></li> | |
0268488e MS |
461 | <li><a href="#httpGetAuthString" title="Get the current authorization string.">httpGetAuthString</a></li> |
462 | <li><a href="#httpGetBlocking" title="Get the blocking/non-block state of a connection.">httpGetBlocking</a></li> | |
a469f8a5 MS |
463 | <li><a href="#httpGetContentEncoding" title="Get a common content encoding, if any, between |
464 | the client and server.">httpGetContentEncoding</a></li> | |
0268488e MS |
465 | <li><a href="#httpGetCookie" title="Get any cookie data from the response.">httpGetCookie</a></li> |
466 | <li><a href="#httpGetDateString" title="Get a formatted date/time string from a time value.">httpGetDateString</a></li> | |
467 | <li><a href="#httpGetDateString2" title="Get a formatted date/time string from a time value.">httpGetDateString2</a></li> | |
468 | <li><a href="#httpGetDateTime" title="Get a time value from a formatted date/time string.">httpGetDateTime</a></li> | |
ca6b43fc | 469 | <li><a href="#httpGetEncryption" title="Get the current encryption mode of a connection.">httpGetEncryption</a></li> |
a469f8a5 | 470 | <li><a href="#httpGetExpect" title="Get the value of the Expect header, if any.">httpGetExpect</a></li> |
0268488e MS |
471 | <li><a href="#httpGetFd" title="Get the file descriptor associated with a connection.">httpGetFd</a></li> |
472 | <li><a href="#httpGetField" title="Get a field value from a request/response.">httpGetField</a></li> | |
473 | <li><a href="#httpGetHostByName" title="Lookup a hostname or IPv4 address, and return | |
5a738aea | 474 | address records for the specified name.">httpGetHostByName</a></li> |
0268488e | 475 | <li><a href="#httpGetHostname" title="Get the FQDN for the connection or local system.">httpGetHostname</a></li> |
ca6b43fc | 476 | <li><a href="#httpGetKeepAlive" title="Get the current Keep-Alive state of the connection.">httpGetKeepAlive</a></li> |
0268488e | 477 | <li><a href="#httpGetLength" title="Get the amount of data remaining from the |
5a738aea | 478 | content-length or transfer-encoding fields.">httpGetLength</a></li> |
0268488e | 479 | <li><a href="#httpGetLength2" title="Get the amount of data remaining from the |
5a738aea | 480 | content-length or transfer-encoding fields.">httpGetLength2</a></li> |
ca6b43fc MS |
481 | <li><a href="#httpGetPending" title="Get the number of bytes that are buffered for writing.">httpGetPending</a></li> |
482 | <li><a href="#httpGetReady" title="Get the number of bytes that can be read without blocking.">httpGetReady</a></li> | |
483 | <li><a href="#httpGetRemaining" title="Get the number of remaining bytes in the message | |
484 | body or current chunk.">httpGetRemaining</a></li> | |
a2326b5b | 485 | <li><a href="#httpGetState" title="Get the current state of the HTTP request.">httpGetState</a></li> |
0268488e MS |
486 | <li><a href="#httpGetStatus" title="Get the status of the last HTTP request.">httpGetStatus</a></li> |
487 | <li><a href="#httpGetSubField" title="Get a sub-field value.">httpGetSubField</a></li> | |
488 | <li><a href="#httpGetSubField2" title="Get a sub-field value.">httpGetSubField2</a></li> | |
a2326b5b | 489 | <li><a href="#httpGetVersion" title="Get the HTTP version at the other end.">httpGetVersion</a></li> |
0268488e MS |
490 | <li><a href="#httpGets" title="Get a line of text from a HTTP connection.">httpGets</a></li> |
491 | <li><a href="#httpHead" title="Send a HEAD request to the server.">httpHead</a></li> | |
492 | <li><a href="#httpInitialize" title="Initialize the HTTP interface library and set the | |
5a738aea | 493 | default HTTP proxy (if any).">httpInitialize</a></li> |
ca6b43fc MS |
494 | <li><a href="#httpIsChunked" title="Report whether a message body is chunked.">httpIsChunked</a></li> |
495 | <li><a href="#httpIsEncrypted" title="Report whether a connection is encrypted.">httpIsEncrypted</a></li> | |
0268488e MS |
496 | <li><a href="#httpMD5" title="Compute the MD5 sum of the username:group:password.">httpMD5</a></li> |
497 | <li><a href="#httpMD5Final" title="Combine the MD5 sum of the username, group, and password | |
5a738aea MS |
498 | with the server-supplied nonce value, method, and |
499 | request-uri.">httpMD5Final</a></li> | |
0268488e MS |
500 | <li><a href="#httpMD5String" title="Convert an MD5 sum to a character string.">httpMD5String</a></li> |
501 | <li><a href="#httpOptions" title="Send an OPTIONS request to the server.">httpOptions</a></li> | |
a469f8a5 | 502 | <li><a href="#httpPeek" title="Peek at data from a HTTP connection.">httpPeek</a></li> |
0268488e MS |
503 | <li><a href="#httpPost" title="Send a POST request to the server.">httpPost</a></li> |
504 | <li><a href="#httpPut" title="Send a PUT request to the server.">httpPut</a></li> | |
505 | <li><a href="#httpRead" title="Read data from a HTTP connection.">httpRead</a></li> | |
506 | <li><a href="#httpRead2" title="Read data from a HTTP connection.">httpRead2</a></li> | |
a469f8a5 | 507 | <li><a href="#httpReadRequest" title="Read a HTTP request from a connection.">httpReadRequest</a></li> |
0268488e | 508 | <li><a href="#httpReconnect" title="Reconnect to a HTTP server.">httpReconnect</a></li> |
3e7fe0ca MS |
509 | <li><a href="#httpReconnect2" title="Reconnect to a HTTP server with timeout and optional |
510 | cancel.">httpReconnect2</a></li> | |
ca6b43fc MS |
511 | <li><a href="#httpResolveHostname" title="Resolve the hostname of the HTTP connection |
512 | address.">httpResolveHostname</a></li> | |
0268488e | 513 | <li><a href="#httpSeparate" title="Separate a Universal Resource Identifier into its |
5a738aea | 514 | components.">httpSeparate</a></li> |
0268488e | 515 | <li><a href="#httpSeparate2" title="Separate a Universal Resource Identifier into its |
5a738aea | 516 | components.">httpSeparate2</a></li> |
0268488e | 517 | <li><a href="#httpSeparateURI" title="Separate a Universal Resource Identifier into its |
5a738aea | 518 | components.">httpSeparateURI</a></li> |
0268488e MS |
519 | <li><a href="#httpSetAuthString" title="Set the current authorization string.">httpSetAuthString</a></li> |
520 | <li><a href="#httpSetCookie" title="Set the cookie value(s).">httpSetCookie</a></li> | |
521 | <li><a href="#httpSetCredentials" title="Set the credentials associated with an encrypted | |
10d09e33 | 522 | connection.">httpSetCredentials</a></li> |
db8b865d | 523 | <li><a href="#httpSetDefaultField" title="Set the default value of an HTTP header.">httpSetDefaultField</a></li> |
0268488e MS |
524 | <li><a href="#httpSetExpect" title="Set the Expect: header in a request.">httpSetExpect</a></li> |
525 | <li><a href="#httpSetField" title="Set the value of an HTTP header.">httpSetField</a></li> | |
ca6b43fc | 526 | <li><a href="#httpSetKeepAlive" title="Set the current Keep-Alive state of a connection.">httpSetKeepAlive</a></li> |
0268488e | 527 | <li><a href="#httpSetLength" title="Set the content-length and content-encoding.">httpSetLength</a></li> |
f228370c | 528 | <li><a href="#httpSetTimeout" title="Set read/write timeouts and an optional callback.">httpSetTimeout</a></li> |
ca6b43fc MS |
529 | <li><a href="#httpShutdown" title="Shutdown one side of an HTTP connection.">httpShutdown</a></li> |
530 | <li><a href="#httpStateString" title="Return the string describing a HTTP state value.">httpStateString</a></li> | |
0268488e MS |
531 | <li><a href="#httpStatus" title="Return a short string describing a HTTP status code.">httpStatus</a></li> |
532 | <li><a href="#httpTrace" title="Send an TRACE request to the server.">httpTrace</a></li> | |
ca6b43fc | 533 | <li><a href="#httpURIStatusString" title="Return a string describing a URI status code.">httpURIStatusString</a></li> |
0268488e MS |
534 | <li><a href="#httpUpdate" title="Update the current HTTP state for incoming data.">httpUpdate</a></li> |
535 | <li><a href="#httpWait" title="Wait for data available on a connection.">httpWait</a></li> | |
536 | <li><a href="#httpWrite" title="Write data to a HTTP connection.">httpWrite</a></li> | |
537 | <li><a href="#httpWrite2" title="Write data to a HTTP connection.">httpWrite2</a></li> | |
a469f8a5 | 538 | <li><a href="#httpWriteResponse" title="Write a HTTP response to a client connection.">httpWriteResponse</a></li> |
0268488e MS |
539 | <li><a href="#ippAddBoolean" title="Add a boolean attribute to an IPP message.">ippAddBoolean</a></li> |
540 | <li><a href="#ippAddBooleans" title="Add an array of boolean values.">ippAddBooleans</a></li> | |
541 | <li><a href="#ippAddCollection" title="Add a collection value.">ippAddCollection</a></li> | |
542 | <li><a href="#ippAddCollections" title="Add an array of collection values.">ippAddCollections</a></li> | |
543 | <li><a href="#ippAddDate" title="Add a date attribute to an IPP message.">ippAddDate</a></li> | |
544 | <li><a href="#ippAddInteger" title="Add a integer attribute to an IPP message.">ippAddInteger</a></li> | |
545 | <li><a href="#ippAddIntegers" title="Add an array of integer values.">ippAddIntegers</a></li> | |
546 | <li><a href="#ippAddOctetString" title="Add an octetString value to an IPP message.">ippAddOctetString</a></li> | |
a2326b5b | 547 | <li><a href="#ippAddOutOfBand" title="Add an out-of-band value to an IPP message.">ippAddOutOfBand</a></li> |
0268488e MS |
548 | <li><a href="#ippAddRange" title="Add a range of values to an IPP message.">ippAddRange</a></li> |
549 | <li><a href="#ippAddRanges" title="Add ranges of values to an IPP message.">ippAddRanges</a></li> | |
550 | <li><a href="#ippAddResolution" title="Add a resolution value to an IPP message.">ippAddResolution</a></li> | |
551 | <li><a href="#ippAddResolutions" title="Add resolution values to an IPP message.">ippAddResolutions</a></li> | |
552 | <li><a href="#ippAddSeparator" title="Add a group separator to an IPP message.">ippAddSeparator</a></li> | |
553 | <li><a href="#ippAddString" title="Add a language-encoded string to an IPP message.">ippAddString</a></li> | |
a469f8a5 MS |
554 | <li><a href="#ippAddStringf" title="Add a formatted string to an IPP message.">ippAddStringf</a></li> |
555 | <li><a href="#ippAddStringfv" title="Add a formatted string to an IPP message.">ippAddStringfv</a></li> | |
0268488e | 556 | <li><a href="#ippAddStrings" title="Add language-encoded strings to an IPP message.">ippAddStrings</a></li> |
a2326b5b | 557 | <li><a href="#ippAttributeString" title="Convert the attribute's value to a string.">ippAttributeString</a></li> |
a469f8a5 MS |
558 | <li><a href="#ippContainsInteger" title="Determine whether an attribute contains the |
559 | specified value or is within the list of ranges.">ippContainsInteger</a></li> | |
560 | <li><a href="#ippContainsString" title="Determine whether an attribute contains the | |
561 | specified string value.">ippContainsString</a></li> | |
a2326b5b MS |
562 | <li><a href="#ippCopyAttribute" title="Copy an attribute.">ippCopyAttribute</a></li> |
563 | <li><a href="#ippCopyAttributes" title="Copy attributes from one IPP message to another.">ippCopyAttributes</a></li> | |
db8b865d MS |
564 | <li><a href="#ippCreateRequestedArray" title="Create a CUPS array of attribute names from the |
565 | given requested-attributes attribute.">ippCreateRequestedArray</a></li> | |
0268488e | 566 | <li><a href="#ippDateToTime" title="Convert from RFC 1903 Date/Time format to UNIX time |
5a738aea | 567 | in seconds.">ippDateToTime</a></li> |
0268488e MS |
568 | <li><a href="#ippDelete" title="Delete an IPP message.">ippDelete</a></li> |
569 | <li><a href="#ippDeleteAttribute" title="Delete a single attribute in an IPP message.">ippDeleteAttribute</a></li> | |
a2326b5b MS |
570 | <li><a href="#ippDeleteValues" title="Delete values in an attribute.">ippDeleteValues</a></li> |
571 | <li><a href="#ippEnumString" title="Return a string corresponding to the enum value.">ippEnumString</a></li> | |
572 | <li><a href="#ippEnumValue" title="Return the value associated with a given enum string.">ippEnumValue</a></li> | |
0268488e MS |
573 | <li><a href="#ippErrorString" title="Return a name for the given status code.">ippErrorString</a></li> |
574 | <li><a href="#ippErrorValue" title="Return a status code for the given name.">ippErrorValue</a></li> | |
3e7fe0ca MS |
575 | <li><a href="#ippFindAttribute" title="Find a named attribute in a request.">ippFindAttribute</a></li> |
576 | <li><a href="#ippFindNextAttribute" title="Find the next named attribute in a request.">ippFindNextAttribute</a></li> | |
a2326b5b MS |
577 | <li><a href="#ippFirstAttribute" title="Return the first attribute in the message.">ippFirstAttribute</a></li> |
578 | <li><a href="#ippGetBoolean" title="Get a boolean value for an attribute.">ippGetBoolean</a></li> | |
579 | <li><a href="#ippGetCollection" title="Get a collection value for an attribute.">ippGetCollection</a></li> | |
580 | <li><a href="#ippGetCount" title="Get the number of values in an attribute.">ippGetCount</a></li> | |
3e7fe0ca | 581 | <li><a href="#ippGetDate" title="Get a date value for an attribute.">ippGetDate</a></li> |
a2326b5b MS |
582 | <li><a href="#ippGetGroupTag" title="Get the group associated with an attribute.">ippGetGroupTag</a></li> |
583 | <li><a href="#ippGetInteger" title="Get the integer/enum value for an attribute.">ippGetInteger</a></li> | |
584 | <li><a href="#ippGetName" title="Get the attribute name.">ippGetName</a></li> | |
6961465f | 585 | <li><a href="#ippGetOctetString" title="Get an octetString value from an IPP attribute.">ippGetOctetString</a></li> |
a2326b5b | 586 | <li><a href="#ippGetOperation" title="Get the operation ID in an IPP message.">ippGetOperation</a></li> |
3e7fe0ca | 587 | <li><a href="#ippGetRange" title="Get a rangeOfInteger value from an attribute.">ippGetRange</a></li> |
a2326b5b MS |
588 | <li><a href="#ippGetRequestId" title="Get the request ID from an IPP message.">ippGetRequestId</a></li> |
589 | <li><a href="#ippGetResolution" title="Get a resolution value for an attribute.">ippGetResolution</a></li> | |
3e7fe0ca | 590 | <li><a href="#ippGetState" title="Get the IPP message state.">ippGetState</a></li> |
a2326b5b MS |
591 | <li><a href="#ippGetStatusCode" title="Get the status code from an IPP response or event message.">ippGetStatusCode</a></li> |
592 | <li><a href="#ippGetString" title="Return the value...">ippGetString</a></li> | |
593 | <li><a href="#ippGetValueTag" title="Get the value tag for an attribute.">ippGetValueTag</a></li> | |
594 | <li><a href="#ippGetVersion" title="Get the major and minor version number from an IPP message.">ippGetVersion</a></li> | |
0268488e MS |
595 | <li><a href="#ippLength" title="Compute the length of an IPP message.">ippLength</a></li> |
596 | <li><a href="#ippNew" title="Allocate a new IPP message.">ippNew</a></li> | |
597 | <li><a href="#ippNewRequest" title="Allocate a new IPP request message.">ippNewRequest</a></li> | |
a469f8a5 | 598 | <li><a href="#ippNewResponse" title="Allocate a new IPP response message.">ippNewResponse</a></li> |
a2326b5b | 599 | <li><a href="#ippNextAttribute" title="Return the next attribute in the message.">ippNextAttribute</a></li> |
0268488e MS |
600 | <li><a href="#ippOpString" title="Return a name for the given operation id.">ippOpString</a></li> |
601 | <li><a href="#ippOpValue" title="Return an operation id for the given name.">ippOpValue</a></li> | |
602 | <li><a href="#ippPort" title="Return the default IPP port number.">ippPort</a></li> | |
603 | <li><a href="#ippRead" title="Read data for an IPP message from a HTTP connection.">ippRead</a></li> | |
604 | <li><a href="#ippReadFile" title="Read data for an IPP message from a file.">ippReadFile</a></li> | |
605 | <li><a href="#ippReadIO" title="Read data for an IPP message.">ippReadIO</a></li> | |
a2326b5b MS |
606 | <li><a href="#ippSetBoolean" title="Set a boolean value in an attribute.">ippSetBoolean</a></li> |
607 | <li><a href="#ippSetCollection" title="Set a collection value in an attribute.">ippSetCollection</a></li> | |
3e7fe0ca | 608 | <li><a href="#ippSetDate" title="Set a date value in an attribute.">ippSetDate</a></li> |
a2326b5b MS |
609 | <li><a href="#ippSetGroupTag" title="Set the group tag of an attribute.">ippSetGroupTag</a></li> |
610 | <li><a href="#ippSetInteger" title="Set an integer or enum value in an attribute.">ippSetInteger</a></li> | |
611 | <li><a href="#ippSetName" title="Set the name of an attribute.">ippSetName</a></li> | |
6961465f | 612 | <li><a href="#ippSetOctetString" title="Set an octetString value in an IPP attribute.">ippSetOctetString</a></li> |
a2326b5b | 613 | <li><a href="#ippSetOperation" title="Set the operation ID in an IPP request message.">ippSetOperation</a></li> |
0268488e | 614 | <li><a href="#ippSetPort" title="Set the default port number.">ippSetPort</a></li> |
a2326b5b MS |
615 | <li><a href="#ippSetRange" title="Set a rangeOfInteger value in an attribute.">ippSetRange</a></li> |
616 | <li><a href="#ippSetRequestId" title="Set the request ID in an IPP message.">ippSetRequestId</a></li> | |
617 | <li><a href="#ippSetResolution" title="Set a resolution value in an attribute.">ippSetResolution</a></li> | |
3e7fe0ca | 618 | <li><a href="#ippSetState" title="Set the current state of the IPP message.">ippSetState</a></li> |
a2326b5b MS |
619 | <li><a href="#ippSetStatusCode" title="Set the status code in an IPP response or event message.">ippSetStatusCode</a></li> |
620 | <li><a href="#ippSetString" title="Set a string value in an attribute.">ippSetString</a></li> | |
a469f8a5 MS |
621 | <li><a href="#ippSetStringf" title="Set a formatted string value of an attribute.">ippSetStringf</a></li> |
622 | <li><a href="#ippSetStringfv" title="Set a formatted string value of an attribute.">ippSetStringfv</a></li> | |
a2326b5b MS |
623 | <li><a href="#ippSetValueTag" title="Set the value tag of an attribute.">ippSetValueTag</a></li> |
624 | <li><a href="#ippSetVersion" title="Set the version number in an IPP message.">ippSetVersion</a></li> | |
ca6b43fc | 625 | <li><a href="#ippStateString" title="Return the name corresponding to a state value.">ippStateString</a></li> |
0268488e MS |
626 | <li><a href="#ippTagString" title="Return the tag name corresponding to a tag value.">ippTagString</a></li> |
627 | <li><a href="#ippTagValue" title="Return the tag value corresponding to a tag name.">ippTagValue</a></li> | |
628 | <li><a href="#ippTimeToDate" title="Convert from UNIX time to RFC 1903 format.">ippTimeToDate</a></li> | |
db8b865d MS |
629 | <li><a href="#ippValidateAttribute" title="Validate the contents of an attribute.">ippValidateAttribute</a></li> |
630 | <li><a href="#ippValidateAttributes" title="Validate all attributes in an IPP message.">ippValidateAttributes</a></li> | |
0268488e MS |
631 | <li><a href="#ippWrite" title="Write data for an IPP message to a HTTP connection.">ippWrite</a></li> |
632 | <li><a href="#ippWriteFile" title="Write data for an IPP message to a file.">ippWriteFile</a></li> | |
633 | <li><a href="#ippWriteIO" title="Write data for an IPP message.">ippWriteIO</a></li> | |
8b450588 | 634 | </ul></li> |
5a738aea | 635 | <li><a href="#TYPES">Data Types</a><ul class="code"> |
eac3a0a0 | 636 | <li><a href="#gss_auth_identity_desc" title="Local functions...">gss_auth_identity_desc</a></li> |
f11a948a MS |
637 | <li><a href="#http_addr_t" title="Socket address union, which |
638 | makes using IPv6 and other | |
639 | address types easier and | |
640 | more portable. ">http_addr_t</a></li> | |
5a738aea MS |
641 | <li><a href="#http_addrlist_t" title="Socket address list, which is |
642 | used to enumerate all of the | |
643 | addresses that are associated | |
644 | with a hostname. ">http_addrlist_t</a></li> | |
645 | <li><a href="#http_auth_t" title="HTTP authentication types">http_auth_t</a></li> | |
f228370c | 646 | <li><a href="#http_credential_t" title="HTTP credential data ">http_credential_t</a></li> |
5a738aea MS |
647 | <li><a href="#http_encoding_t" title="HTTP transfer encoding values">http_encoding_t</a></li> |
648 | <li><a href="#http_encryption_t" title="HTTP encryption values">http_encryption_t</a></li> | |
79e1d494 | 649 | <li><a href="#http_field_t" title="HTTP field names">http_field_t</a></li> |
f11a948a MS |
650 | <li><a href="#http_keepalive_t" title="HTTP keep-alive values">http_keepalive_t</a></li> |
651 | <li><a href="#http_state_t" title="HTTP state values; states | |
652 | are server-oriented...">http_state_t</a></li> | |
5a738aea | 653 | <li><a href="#http_t" title="HTTP connection type">http_t</a></li> |
f228370c | 654 | <li><a href="#http_timeout_cb_t" title="HTTP timeout callback ">http_timeout_cb_t</a></li> |
240214ef | 655 | <li><a href="#http_trust_t" title="Level of trust for credentials ">http_trust_t</a></li> |
f11a948a MS |
656 | <li><a href="#http_uri_coding_t" title="URI en/decode flags">http_uri_coding_t</a></li> |
657 | <li><a href="#http_uri_status_t" title="URI separation status ">http_uri_status_t</a></li> | |
658 | <li><a href="#http_version_t" title="HTTP version numbers">http_version_t</a></li> | |
a2326b5b | 659 | <li><a href="#ipp_attribute_t" title="IPP attribute">ipp_attribute_t</a></li> |
f3c17241 MS |
660 | <li><a href="#ipp_copycb_t" title="The following structures are PRIVATE starting with CUPS 1.6/OS X 10.8. |
661 | Please use the new accessor functions available in CUPS 1.6 and later, as | |
662 | these definitions will be moved to a private header file in a future release.">ipp_copycb_t</a></li> | |
a2326b5b | 663 | <li><a href="#ipp_dstate_t" title="Document states">ipp_dstate_t</a></li> |
a469f8a5 | 664 | <li><a href="#ipp_finish_t" title="Job collation types">ipp_finish_t</a></li> |
5a738aea | 665 | <li><a href="#ipp_iocb_t" title="IPP IO Callback Function ">ipp_iocb_t</a></li> |
a2326b5b | 666 | <li><a href="#ipp_jcollate_t" title="Job collation types">ipp_jcollate_t</a></li> |
aaf19ab0 MS |
667 | <li><a href="#ipp_orient_t" title="Orientation values">ipp_orient_t</a></li> |
668 | <li><a href="#ipp_pstate_t" title="Printer states">ipp_pstate_t</a></li> | |
669 | <li><a href="#ipp_quality_t" title="Qualities">ipp_quality_t</a></li> | |
aaf19ab0 MS |
670 | <li><a href="#ipp_res_t" title="Resolution units">ipp_res_t</a></li> |
671 | <li><a href="#ipp_state_t" title="IPP states">ipp_state_t</a></li> | |
a2326b5b MS |
672 | <li><a href="#ipp_t" title="IPP request/response data">ipp_t</a></li> |
673 | <li><a href="#ipp_uchar_t" title="Unsigned 8-bit integer/character">ipp_uchar_t</a></li> | |
5a738aea MS |
674 | </ul></li> |
675 | <li><a href="#STRUCTURES">Structures</a><ul class="code"> | |
eac3a0a0 | 676 | <li><a href="#gss_auth_identity" title="Local functions...">gss_auth_identity</a></li> |
5a738aea MS |
677 | <li><a href="#http_addrlist_s" title="Socket address list, which is |
678 | used to enumerate all of the | |
679 | addresses that are associated | |
680 | with a hostname. ">http_addrlist_s</a></li> | |
f228370c | 681 | <li><a href="#http_credential_s" title="HTTP credential data ">http_credential_s</a></li> |
f3c17241 | 682 | <li><a href="#pollfd" title="User data (unused)">pollfd</a></li> |
5a738aea MS |
683 | </ul></li> |
684 | <li><a href="#ENUMERATIONS">Constants</a><ul class="code"> | |
685 | <li><a href="#http_auth_e" title="HTTP authentication types">http_auth_e</a></li> | |
686 | <li><a href="#http_encoding_e" title="HTTP transfer encoding values">http_encoding_e</a></li> | |
687 | <li><a href="#http_encryption_e" title="HTTP encryption values">http_encryption_e</a></li> | |
688 | <li><a href="#http_field_e" title="HTTP field names">http_field_e</a></li> | |
f11a948a MS |
689 | <li><a href="#http_keepalive_e" title="HTTP keep-alive values">http_keepalive_e</a></li> |
690 | <li><a href="#http_state_e" title="HTTP state values; states | |
691 | are server-oriented...">http_state_e</a></li> | |
5a738aea | 692 | <li><a href="#http_status_e" title="HTTP status codes">http_status_e</a></li> |
240214ef | 693 | <li><a href="#http_trust_e" title="Level of trust for credentials ">http_trust_e</a></li> |
f11a948a MS |
694 | <li><a href="#http_uri_coding_e" title="URI en/decode flags">http_uri_coding_e</a></li> |
695 | <li><a href="#http_uri_status_e" title="URI separation status ">http_uri_status_e</a></li> | |
696 | <li><a href="#http_version_e" title="HTTP version numbers">http_version_e</a></li> | |
a2326b5b | 697 | <li><a href="#ipp_dstate_e" title="Document states">ipp_dstate_e</a></li> |
a469f8a5 | 698 | <li><a href="#ipp_finishings_e" title="Finishings">ipp_finishings_e</a></li> |
a2326b5b | 699 | <li><a href="#ipp_jcollate_e" title="Job collation types">ipp_jcollate_e</a></li> |
aaf19ab0 MS |
700 | <li><a href="#ipp_jstate_e" title="Job states">ipp_jstate_e</a></li> |
701 | <li><a href="#ipp_op_e" title="IPP operations">ipp_op_e</a></li> | |
702 | <li><a href="#ipp_orient_e" title="Orientation values">ipp_orient_e</a></li> | |
703 | <li><a href="#ipp_pstate_e" title="Printer states">ipp_pstate_e</a></li> | |
704 | <li><a href="#ipp_quality_e" title="Qualities">ipp_quality_e</a></li> | |
705 | <li><a href="#ipp_res_e" title="Resolution units">ipp_res_e</a></li> | |
706 | <li><a href="#ipp_state_e" title="IPP states">ipp_state_e</a></li> | |
707 | <li><a href="#ipp_status_e" title="IPP status codes">ipp_status_e</a></li> | |
708 | <li><a href="#ipp_tag_e" title="Format tags for attributes">ipp_tag_e</a></li> | |
5a738aea | 709 | </ul></li> |
0268488e | 710 | </ul> |
5a738aea | 711 | <!-- |
eac3a0a0 | 712 | HTTP and IPP API introduction for CUPS. |
ef416fc2 | 713 | |
82cc1f9a | 714 | Copyright 2007-2012 by Apple Inc. |
bc44d920 | 715 | Copyright 1997-2006 by Easy Software Products, all rights reserved. |
ef416fc2 | 716 | |
717 | These coded instructions, statements, and computer programs are the | |
bc44d920 | 718 | property of Apple Inc. and are protected by Federal copyright |
719 | law. Distribution and use rights are outlined in the file "LICENSE.txt" | |
720 | which should have been included with this file. If this file is | |
721 | file is missing or damaged, see the license at "http://www.cups.org/". | |
ef416fc2 | 722 | --> |
723 | ||
5a738aea MS |
724 | <h2 class='title'><a name='OVERVIEW'>Overview</a></h2> |
725 | ||
726 | <p>The CUPS HTTP and IPP APIs provide low-level access to the HTTP and IPP | |
727 | protocols and CUPS scheduler. They are typically used by monitoring and | |
728 | administration programs to perform specific functions not supported by the | |
729 | high-level CUPS API functions.</p> | |
730 | ||
731 | <p>The HTTP APIs use an opaque structure called | |
732 | <a href='#http_t'><code>http_t</code></a> to manage connections to | |
733 | a particular HTTP or IPP server. The | |
734 | <a href='#httpConnectEncrypt'><code>httpConnectEncrypt</code></a> function is | |
735 | used to create an instance of this structure for a particular server. | |
736 | The constant <code>CUPS_HTTP_DEFAULT</code> can be used with all of the | |
737 | <code>cups</code> functions to refer to the default CUPS server - the functions | |
738 | create a per-thread <a href='#http_t'><code>http_t</code></a> as needed.</p> | |
739 | ||
82cc1f9a MS |
740 | <p>The IPP APIs use two opaque structures for requests (messages sent to the CUPS scheduler) and responses (messages sent back to your application from the scheduler). The <a href='#ipp_t'><code>ipp_t</code></a> type holds a complete request or response and is allocated using the <a href='#ippNew'><code>ippNew</code></a> or <a href='#ippNewRequest'><code>ippNewRequest</code></a> functions and freed using the <a href='#ippDelete'><code>ippDelete</code></a> function.</p> |
741 | ||
742 | <p>The second opaque structure is called <a href='#ipp_attribute_t'><code>ipp_attribute_t</code></a> and holds a single IPP attribute which consists of a group tag (<a href='#ippGetGroupTag'><code>ippGetGroupTag</code></a>), a value type tag (<a href='#ippGetValueTag'><code>ippGetValueTag</code></a>), the attribute name (<a href='#ippGetName'><code>ippGetName</code></a>), and 1 or more values (<a href='#ippGetCount'><code>ippGetCount</code></a>, <a href='#ippGetBoolean'><code>ippGetBoolean</code></a>, <a href='#ippGetCollection'><code>ippGetCollection</code></a>, <a href='#ippGetDate'><code>ippGetDate</code></a>, <a href='#ippGetInteger'><code>ippGetInteger</code></a>, <a href='#ippGetRange'><code>ippGetRange</code></a>, <a href='#ippGetResolution'><code>ippGetResolution</code></a>, and <a href='#ippGetString'><code>ippGetString</code></a>). Attributes are added to an <a href='#ipp_t'><code>ipp_t</code></a> pointer using one of the <code>ippAdd</code> functions. For example, use <a href='#ippAddString'><code>ippAddString</code></a> to add the "printer-uri" and "requesting-user-name" string attributes to a request:</p> | |
5a738aea MS |
743 | |
744 | <pre class='example'> | |
745 | <a href='#ipp_t'>ipp_t</a> *request = <a href='#ippNewRequest'>ippNewRequest</a>(IPP_GET_JOBS); | |
746 | ||
82cc1f9a MS |
747 | <a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_URI, "printer-uri", |
748 | NULL, "ipp://localhost/printers/"); | |
5a738aea MS |
749 | <a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "requesting-user-name", |
750 | NULL, cupsUser()); | |
751 | </pre> | |
ef416fc2 | 752 | |
82cc1f9a | 753 | <p>Once you have created an IPP request, use the <code>cups</code> functions to send the request to and read the response from the server. For example, the <a href='#cupsDoRequest'><code>cupsDoRequest</code></a> function can be used for simple query operations that do not involve files:</p> |
ef416fc2 | 754 | |
5a738aea MS |
755 | <pre class='example'> |
756 | #include <cups/cups.h> | |
ef416fc2 | 757 | |
ef416fc2 | 758 | |
5a738aea MS |
759 | <a href='#ipp_t'>ipp_t</a> *<a name='get_jobs'>get_jobs</a>(void) |
760 | { | |
761 | <a href='#ipp_t'>ipp_t</a> *request = <a href='#ippNewRequest'>ippNewRequest</a>(IPP_GET_JOBS); | |
ef416fc2 | 762 | |
82cc1f9a MS |
763 | <a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_URI, "printer-uri", |
764 | NULL, "ipp://localhost/printers/"); | |
5a738aea MS |
765 | <a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "requesting-user-name", |
766 | NULL, cupsUser()); | |
767 | ||
768 | return (<a href='#cupsDoRequest'>cupsDoRequest</a>(CUPS_HTTP_DEFAULT, request, "/")); | |
769 | } | |
ef416fc2 | 770 | </pre> |
771 | ||
82cc1f9a | 772 | <p>The <a href='#cupsDoRequest'><code>cupsDoRequest</code></a> function frees the request and returns an IPP response or <code>NULL</code> pointer if the request could not be sent to the server. Once you have a response from the server, you can either use the <a href='#ippFindAttribute'><code>ippFindAttribute</code></a> and <a href='#ippFindNextAttribute'><code>ippFindNextAttribute</code></a> functions to find specific attributes, for example:</p> |
ef416fc2 | 773 | |
5a738aea MS |
774 | <pre class='example'> |
775 | <a href='#ipp_t'>ipp_t</a> *response; | |
776 | <a href='#ipp_attribute_t'>ipp_attribute_t</a> *attr; | |
bc44d920 | 777 | |
5a738aea MS |
778 | attr = <a href='#ippFindAttribute'>ippFindAttribute</a>(response, "printer-state", IPP_TAG_ENUM); |
779 | </pre> | |
780 | ||
82cc1f9a | 781 | <p>You can also walk the list of attributes with a simple <code>for</code> loop like this:</p> |
5a738aea MS |
782 | |
783 | <pre class='example'> | |
784 | <a href='#ipp_t'>ipp_t</a> *response; | |
785 | <a href='#ipp_attribute_t'>ipp_attribute_t</a> *attr; | |
786 | ||
82cc1f9a MS |
787 | for (attr = <a href='#ippFirstAttribute'>ippFirstAttribute</a>(response); attr != NULL; attr = <a href='#ippNextAttribute'>ippNextAttribute</a>(response)) |
788 | if (ippGetName(attr) == NULL) | |
5a738aea MS |
789 | puts("--SEPARATOR--"); |
790 | else | |
82cc1f9a | 791 | puts(ippGetName(attr)); |
5a738aea MS |
792 | </pre> |
793 | ||
82cc1f9a | 794 | <p>The <code>for</code> loop approach is normally used when collecting attributes for multiple objects (jobs, printers, etc.) in a response. Attributes with <code>NULL</code> names indicate a separator between the attributes of each object. For example, the following code will list the jobs returned from our previous <a href='#get_jobs'><code>get_jobs</code></a> example code:</p> |
5a738aea MS |
795 | |
796 | <pre class='example'> | |
797 | <a href='#ipp_t'>ipp_t</a> *response = <a href='#get_jobs'>get_jobs</a>(); | |
798 | ||
799 | if (response != NULL) | |
800 | { | |
801 | <a href='#ipp_attribute_t'>ipp_attribute_t</a> *attr; | |
82cc1f9a | 802 | const char *attrname; |
5a738aea | 803 | int job_id = 0; |
82cc1f9a MS |
804 | const char *job_name = NULL; |
805 | const char *job_originating_user_name = NULL; | |
5a738aea MS |
806 | |
807 | puts("Job ID Owner Title"); | |
808 | puts("------ ---------------- ---------------------------------"); | |
809 | ||
82cc1f9a | 810 | for (attr = <a href='#ippFirstAttribute'>ippFirstAttribute</a>(response); attr != NULL; attr = <a href='#ippNextAttribute'>ippNextAttribute</a>(response)) |
5a738aea MS |
811 | { |
812 | /* Attributes without names are separators between jobs */ | |
82cc1f9a MS |
813 | attrname = ippGetName(attr); |
814 | if (attrname == NULL) | |
5a738aea | 815 | { |
82cc1f9a MS |
816 | if (job_id > 0) |
817 | { | |
818 | if (job_name == NULL) | |
819 | job_name = "(withheld)"; | |
820 | ||
821 | if (job_originating_user_name == NULL) | |
822 | job_originating_user_name = "(withheld)"; | |
823 | ||
5a738aea | 824 | printf("%5d %-16s %s\n", job_id, job_originating_user_name, job_name); |
82cc1f9a | 825 | } |
5a738aea MS |
826 | |
827 | job_id = 0; | |
828 | job_name = NULL; | |
829 | job_originating_user_name = NULL; | |
830 | continue; | |
831 | } | |
82cc1f9a MS |
832 | else if (!strcmp(attrname, "job-id") && ippGetValueTag(attr) == IPP_TAG_INTEGER) |
833 | job_id = ippGetInteger(attr, 0); | |
834 | else if (!strcmp(attrname, "job-name") && ippGetValueTag(attr) == IPP_TAG_NAME) | |
835 | job_name = ippGetString(attr, 0, NULL); | |
836 | else if (!strcmp(attrname, "job-originating-user-name") && | |
837 | ippGetValueTag(attr) == IPP_TAG_NAME) | |
838 | job_originating_user_name = ippGetString(attr, 0, NULL); | |
5a738aea MS |
839 | } |
840 | ||
82cc1f9a MS |
841 | if (job_id > 0) |
842 | { | |
843 | if (job_name == NULL) | |
844 | job_name = "(withheld)"; | |
845 | ||
846 | if (job_originating_user_name == NULL) | |
847 | job_originating_user_name = "(withheld)"; | |
848 | ||
5a738aea | 849 | printf("%5d %-16s %s\n", job_id, job_originating_user_name, job_name); |
82cc1f9a | 850 | } |
5a738aea MS |
851 | } |
852 | </pre> | |
853 | ||
854 | <h3><a name='CREATING_URI_STRINGS'>Creating URI Strings</a></h3> | |
855 | ||
856 | <p>To ensure proper encoding, the | |
857 | <a href='#httpAssembleURIf'><code>httpAssembleURIf</code></a> function must be | |
858 | used to format a "printer-uri" string for all printer-based requests:</p> | |
859 | ||
860 | <pre class='example'> | |
861 | const char *name = "Foo"; | |
862 | char uri[1024]; | |
863 | <a href='#ipp_t'>ipp_t</a> *request; | |
864 | ||
865 | <a href='#httpAssembleURIf'>httpAssembleURIf</a>(HTTP_URI_CODING_ALL, uri, sizeof(uri), "ipp", NULL, cupsServer(), | |
866 | ippPort(), "/printers/%s", name); | |
867 | <a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_URI, "printer-uri", NULL, uri); | |
868 | </pre> | |
869 | ||
870 | <h3><a name='SENDING_REQUESTS_WITH_FILES'>Sending Requests with Files</a></h3> | |
871 | ||
872 | <p>The <a href='#cupsDoFileRequest'><code>cupsDoFileRequest</code></a> and | |
873 | <a href='#cupsDoIORequest'><code>cupsDoIORequest</code></a> functions are | |
874 | used for requests involving files. The | |
875 | <a href='#cupsDoFileRequest'><code>cupsDoFileRequest</code></a> function | |
876 | attaches the named file to a request and is typically used when sending a print | |
877 | file or changing a printer's PPD file:</p> | |
878 | ||
879 | <pre class='example'> | |
880 | const char *filename = "/usr/share/cups/data/testprint.ps"; | |
881 | const char *name = "Foo"; | |
882 | char uri[1024]; | |
883 | char resource[1024]; | |
884 | <a href='#ipp_t'>ipp_t</a> *request = <a href='#ippNewRequest'>ippNewRequest</a>(IPP_PRINT_JOB); | |
885 | <a href='#ipp_t'>ipp_t</a> *response; | |
886 | ||
887 | /* Use httpAssembleURIf for the printer-uri string */ | |
888 | <a href='#httpAssembleURIf'>httpAssembleURIf</a>(HTTP_URI_CODING_ALL, uri, sizeof(uri), "ipp", NULL, cupsServer(), | |
889 | ippPort(), "/printers/%s", name); | |
890 | <a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_URI, "printer-uri", NULL, uri); | |
891 | <a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "requesting-user-name", | |
892 | NULL, cupsUser()); | |
893 | <a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "job-name", | |
894 | NULL, "testprint.ps"); | |
895 | ||
896 | /* Use snprintf for the resource path */ | |
897 | snprintf(resource, sizeof(resource), "/printers/%s", name); | |
898 | ||
899 | response = <a href='#cupsDoFileRequest'>cupsDoFileRequest</a>(CUPS_HTTP_DEFAULT, request, resource, filename); | |
900 | </pre> | |
901 | ||
902 | <p>The <a href='#cupsDoIORequest'><code>cupsDoIORequest</code></a> function | |
903 | optionally attaches a file to the request and optionally saves a file in the | |
904 | response from the server. It is used when using a pipe for the request | |
905 | attachment or when using a request that returns a file, currently only | |
906 | <code>CUPS_GET_DOCUMENT</code> and <code>CUPS_GET_PPD</code>. For example, | |
907 | the following code will download the PPD file for the sample HP LaserJet | |
908 | printer driver:</p> | |
909 | ||
910 | <pre class='example'> | |
911 | char tempfile[1024]; | |
912 | int tempfd; | |
913 | <a href='#ipp_t'>ipp_t</a> *request = <a href='#ippNewRequest'>ippNewRequest</a>(CUPS_GET_PPD); | |
914 | <a href='#ipp_t'>ipp_t</a> *response; | |
915 | ||
916 | <a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "ppd-name", | |
917 | NULL, "laserjet.ppd"); | |
918 | ||
919 | tempfd = cupsTempFd(tempfile, sizeof(tempfile)); | |
920 | ||
921 | response = <a href='#cupsDoIORequest'>cupsDoIORequest</a>(CUPS_HTTP_DEFAULT, request, "/", -1, tempfd); | |
922 | </pre> | |
923 | ||
924 | <p>The example passes <code>-1</code> for the input file descriptor to specify | |
925 | that no file is to be attached to the request. The PPD file attached to the | |
926 | response is written to the temporary file descriptor we created using the | |
927 | <code>cupsTempFd</code> function.</p> | |
928 | ||
929 | <h3><a name='ASYNCHRONOUS_REQUEST_PROCESSING'>Asynchronous Request Processing</a></h3> | |
930 | ||
931 | <p>The <a href='#cupsSendRequest'><code>cupsSendRequest</code></a> and | |
932 | <a href='#cupsGetResponse'><code>cupsGetResponse</code></a> support | |
933 | asynchronous communications with the server. Unlike the other request | |
934 | functions, the IPP request is not automatically freed, so remember to | |
935 | free your request with the <a href='#ippDelete'><code>ippDelete</code></a> | |
936 | function.</p> | |
937 | ||
938 | <p>File data is attached to the request using the | |
939 | <a href='#cupsWriteRequestData'><code>cupsWriteRequestData</code></a> | |
940 | function, while file data returned from the server is read using the | |
941 | <a href='#cupsReadResponseData'><code>cupsReadResponseData</code></a> | |
942 | function. We can rewrite the previous <code>CUPS_GET_PPD</code> example | |
943 | to use the asynchronous functions quite easily:</p> | |
944 | ||
945 | <pre class='example'> | |
946 | char tempfile[1024]; | |
947 | int tempfd; | |
948 | <a href='#ipp_t'>ipp_t</a> *request = <a href='#ippNewRequest'>ippNewRequest</a>(CUPS_GET_PPD); | |
949 | <a href='#ipp_t'>ipp_t</a> *response; | |
950 | ||
951 | <a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "ppd-name", | |
952 | NULL, "laserjet.ppd"); | |
953 | ||
954 | tempfd = cupsTempFd(tempfile, sizeof(tempfile)); | |
955 | ||
956 | if (<a href='#cupsSendRequest'>cupsSendRequest</a>(CUPS_HTTP_DEFAULT, request, "/") == HTTP_CONTINUE) | |
957 | { | |
958 | response = <a href='#cupsGetResponse'>cupsGetResponse</a>(CUPS_HTTP_DEFAULT, "/"); | |
959 | ||
960 | if (response != NULL) | |
961 | { | |
962 | ssize_t bytes; | |
963 | char buffer[8192]; | |
964 | ||
965 | while ((bytes = <a href='#cupsReadResponseData'>cupsReadResponseData</a>(CUPS_HTTP_DEFAULT, buffer, sizeof(buffer))) > 0) | |
966 | write(tempfd, buffer, bytes); | |
967 | } | |
968 | } | |
969 | ||
970 | /* Free the request! */ | |
971 | <a href='#ippDelete'>ippDelete</a>(request); | |
972 | </pre> | |
973 | ||
974 | <p>The <a href='#cupsSendRequest'><code>cupsSendRequest</code></a> function | |
975 | returns the initial HTTP request status, typically either | |
976 | <code>HTTP_CONTINUE</code> or <code>HTTP_UNAUTHORIZED</code>. The latter status | |
977 | is returned when the request requires authentication of some sort. The | |
978 | <a href='#cupsDoAuthentication'><code>cupsDoAuthentication</code></a> function | |
979 | must be called when your see <code>HTTP_UNAUTHORIZED</code> and the request | |
980 | re-sent. We can add authentication support to our example code by using a | |
981 | <code>do ... while</code> loop:</p> | |
982 | ||
983 | <pre class='example'> | |
984 | char tempfile[1024]; | |
985 | int tempfd; | |
986 | <a href='#ipp_t'>ipp_t</a> *request = <a href='#ippNewRequest'>ippNewRequest</a>(CUPS_GET_PPD); | |
987 | <a href='#ipp_t'>ipp_t</a> *response; | |
988 | http_status_t status; | |
989 | ||
990 | <a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "ppd-name", | |
991 | NULL, "laserjet.ppd"); | |
992 | ||
993 | tempfd = cupsTempFd(tempfile, sizeof(tempfile)); | |
994 | ||
995 | /* Loop for authentication */ | |
996 | do | |
997 | { | |
75bd9771 | 998 | status = <a href='#cupsSendRequest'>cupsSendRequest</a>(CUPS_HTTP_DEFAULT, request, "/"); |
5a738aea MS |
999 | |
1000 | if (status == HTTP_UNAUTHORIZED) | |
1001 | { | |
1002 | /* Try to authenticate, break out of the loop if that fails */ | |
1003 | if (<a href='#cupsDoAuthentication'>cupsDoAuthentication</a>(CUPS_HTTP_DEFAULT, "POST", "/")) | |
1004 | break; | |
1005 | } | |
1006 | } | |
1007 | while (status != HTTP_CONTINUE && status != HTTP_UNAUTHORIZED); | |
1008 | ||
1009 | if (status == HTTP_CONTINUE) | |
1010 | { | |
1011 | response = <a href='#cupsGetResponse'>cupsGetResponse</a>(CUPS_HTTP_DEFAULT, "/"); | |
1012 | ||
1013 | if (response != NULL) | |
1014 | { | |
1015 | ssize_t bytes; | |
1016 | char buffer[8192]; | |
1017 | ||
1018 | while ((bytes = <a href='#cupsReadResponseData'>cupsReadResponseData</a>(CUPS_HTTP_DEFAULT, buffer, sizeof(buffer))) > 0) | |
1019 | write(tempfd, buffer, bytes); | |
1020 | } | |
1021 | } | |
1022 | ||
1023 | /* Free the request! */ | |
1024 | <a href='#ippDelete'>ippDelete</a>(request); | |
1025 | </pre> | |
1026 | <h2 class="title"><a name="FUNCTIONS">Functions</a></h2> | |
f3c17241 | 1027 | <h3 class="function"><span class="info"> CUPS 1.1.20/OS X 10.4 </span><a name="cupsDoAuthentication">cupsDoAuthentication</a></h3> |
5a738aea MS |
1028 | <p class="description">Authenticate a request.</p> |
1029 | <p class="code"> | |
1030 | int cupsDoAuthentication (<br> | |
1031 | <a href="#http_t">http_t</a> *http,<br> | |
1032 | const char *method,<br> | |
1033 | const char *resource<br> | |
1034 | );</p> | |
1035 | <h4 class="parameters">Parameters</h4> | |
1036 | <dl> | |
1037 | <dt>http</dt> | |
568fa3fa | 1038 | <dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd> |
5a738aea MS |
1039 | <dt>method</dt> |
1040 | <dd class="description">Request method ("GET", "POST", "PUT")</dd> | |
1041 | <dt>resource</dt> | |
1042 | <dd class="description">Resource path</dd> | |
1043 | </dl> | |
1044 | <h4 class="returnvalue">Return Value</h4> | |
1045 | <p class="description">0 on success, -1 on error</p> | |
1046 | <h4 class="discussion">Discussion</h4> | |
6961465f | 1047 | <p class="discussion">This function should be called in response to a <code>HTTP_STATUS_UNAUTHORIZED</code> |
5a738aea MS |
1048 | status, prior to resubmitting your request. |
1049 | ||
1050 | </p> | |
1051 | <h3 class="function"><a name="cupsDoFileRequest">cupsDoFileRequest</a></h3> | |
1052 | <p class="description">Do an IPP request with a file.</p> | |
1053 | <p class="code"> | |
1054 | <a href="#ipp_t">ipp_t</a> *cupsDoFileRequest (<br> | |
1055 | <a href="#http_t">http_t</a> *http,<br> | |
1056 | <a href="#ipp_t">ipp_t</a> *request,<br> | |
1057 | const char *resource,<br> | |
1058 | const char *filename<br> | |
1059 | );</p> | |
1060 | <h4 class="parameters">Parameters</h4> | |
1061 | <dl> | |
1062 | <dt>http</dt> | |
568fa3fa | 1063 | <dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd> |
5a738aea MS |
1064 | <dt>request</dt> |
1065 | <dd class="description">IPP request</dd> | |
1066 | <dt>resource</dt> | |
1067 | <dd class="description">HTTP resource for POST</dd> | |
1068 | <dt>filename</dt> | |
568fa3fa | 1069 | <dd class="description">File to send or <code>NULL</code> for none</dd> |
5a738aea MS |
1070 | </dl> |
1071 | <h4 class="returnvalue">Return Value</h4> | |
1072 | <p class="description">Response data</p> | |
1073 | <h4 class="discussion">Discussion</h4> | |
5a9febac MS |
1074 | <p class="discussion">This function sends the IPP request and attached file to the specified |
1075 | server, retrying and authenticating as necessary. The request is freed with | |
1076 | <a href="#ippDelete"><code>ippDelete</code></a>.</p> | |
f3c17241 | 1077 | <h3 class="function"><span class="info"> CUPS 1.3/OS X 10.5 </span><a name="cupsDoIORequest">cupsDoIORequest</a></h3> |
5a738aea MS |
1078 | <p class="description">Do an IPP request with file descriptors.</p> |
1079 | <p class="code"> | |
1080 | <a href="#ipp_t">ipp_t</a> *cupsDoIORequest (<br> | |
1081 | <a href="#http_t">http_t</a> *http,<br> | |
1082 | <a href="#ipp_t">ipp_t</a> *request,<br> | |
1083 | const char *resource,<br> | |
1084 | int infile,<br> | |
1085 | int outfile<br> | |
1086 | );</p> | |
1087 | <h4 class="parameters">Parameters</h4> | |
1088 | <dl> | |
1089 | <dt>http</dt> | |
568fa3fa | 1090 | <dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd> |
5a738aea MS |
1091 | <dt>request</dt> |
1092 | <dd class="description">IPP request</dd> | |
1093 | <dt>resource</dt> | |
1094 | <dd class="description">HTTP resource for POST</dd> | |
1095 | <dt>infile</dt> | |
1096 | <dd class="description">File to read from or -1 for none</dd> | |
1097 | <dt>outfile</dt> | |
1098 | <dd class="description">File to write to or -1 for none</dd> | |
1099 | </dl> | |
1100 | <h4 class="returnvalue">Return Value</h4> | |
1101 | <p class="description">Response data</p> | |
1102 | <h4 class="discussion">Discussion</h4> | |
5a9febac MS |
1103 | <p class="discussion">This function sends the IPP request with the optional input file "infile" to |
1104 | the specified server, retrying and authenticating as necessary. The request | |
1105 | is freed with <a href="#ippDelete"><code>ippDelete</code></a>.<br> | |
5a738aea | 1106 | <br> |
5a9febac | 1107 | If "infile" is a valid file descriptor, <code>cupsDoIORequest</code> copies |
5a738aea MS |
1108 | all of the data from the file after the IPP request message.<br> |
1109 | <br> | |
5a9febac | 1110 | If "outfile" is a valid file descriptor, <code>cupsDoIORequest</code> copies |
bc44d920 | 1111 | all of the data after the IPP response message to the file. |
1112 | ||
5a738aea MS |
1113 | </p> |
1114 | <h3 class="function"><a name="cupsDoRequest">cupsDoRequest</a></h3> | |
1115 | <p class="description">Do an IPP request.</p> | |
1116 | <p class="code"> | |
1117 | <a href="#ipp_t">ipp_t</a> *cupsDoRequest (<br> | |
1118 | <a href="#http_t">http_t</a> *http,<br> | |
1119 | <a href="#ipp_t">ipp_t</a> *request,<br> | |
1120 | const char *resource<br> | |
1121 | );</p> | |
1122 | <h4 class="parameters">Parameters</h4> | |
1123 | <dl> | |
1124 | <dt>http</dt> | |
568fa3fa | 1125 | <dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd> |
5a738aea MS |
1126 | <dt>request</dt> |
1127 | <dd class="description">IPP request</dd> | |
1128 | <dt>resource</dt> | |
1129 | <dd class="description">HTTP resource for POST</dd> | |
1130 | </dl> | |
1131 | <h4 class="returnvalue">Return Value</h4> | |
1132 | <p class="description">Response data</p> | |
1133 | <h4 class="discussion">Discussion</h4> | |
1134 | <p class="discussion">This function sends the IPP request to the specified server, retrying | |
5a9febac | 1135 | and authenticating as necessary. The request is freed with <a href="#ippDelete"><code>ippDelete</code></a>.</p> |
5a738aea MS |
1136 | <h3 class="function"><a name="cupsEncodeOptions">cupsEncodeOptions</a></h3> |
1137 | <p class="description">Encode printer options into IPP attributes.</p> | |
1138 | <p class="code"> | |
1139 | void cupsEncodeOptions (<br> | |
1140 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
1141 | int num_options,<br> | |
1142 | cups_option_t *options<br> | |
1143 | );</p> | |
1144 | <h4 class="parameters">Parameters</h4> | |
1145 | <dl> | |
1146 | <dt>ipp</dt> | |
1147 | <dd class="description">Request to add to</dd> | |
1148 | <dt>num_options</dt> | |
1149 | <dd class="description">Number of options</dd> | |
1150 | <dt>options</dt> | |
1151 | <dd class="description">Options</dd> | |
1152 | </dl> | |
1153 | <h4 class="discussion">Discussion</h4> | |
1154 | <p class="discussion">This function adds operation, job, and then subscription attributes, | |
ecdc0628 | 1155 | in that order. Use the cupsEncodeOptions2() function to add attributes |
5a738aea | 1156 | for a single group.</p> |
f3c17241 | 1157 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="cupsEncodeOptions2">cupsEncodeOptions2</a></h3> |
5a738aea MS |
1158 | <p class="description">Encode printer options into IPP attributes for a group.</p> |
1159 | <p class="code"> | |
1160 | void cupsEncodeOptions2 (<br> | |
1161 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
1162 | int num_options,<br> | |
1163 | cups_option_t *options,<br> | |
a2326b5b | 1164 | ipp_tag_t group_tag<br> |
5a738aea MS |
1165 | );</p> |
1166 | <h4 class="parameters">Parameters</h4> | |
1167 | <dl> | |
1168 | <dt>ipp</dt> | |
1169 | <dd class="description">Request to add to</dd> | |
1170 | <dt>num_options</dt> | |
1171 | <dd class="description">Number of options</dd> | |
1172 | <dt>options</dt> | |
1173 | <dd class="description">Options</dd> | |
1174 | <dt>group_tag</dt> | |
1175 | <dd class="description">Group to encode</dd> | |
1176 | </dl> | |
1177 | <h4 class="discussion">Discussion</h4> | |
1178 | <p class="discussion">This function only adds attributes for a single group. Call this | |
ecdc0628 | 1179 | function multiple times for each group, or use cupsEncodeOptions() |
1180 | to add the standard groups. | |
ef416fc2 | 1181 | |
ae71f5de | 1182 | </p> |
f3c17241 | 1183 | <h3 class="function"><span class="info"> CUPS 1.4/OS X 10.6 </span><a name="cupsGetDevices">cupsGetDevices</a></h3> |
ae71f5de MS |
1184 | <p class="description">Get available printer devices.</p> |
1185 | <p class="code"> | |
1186 | ipp_status_t cupsGetDevices (<br> | |
1187 | <a href="#http_t">http_t</a> *http,<br> | |
1188 | int timeout,<br> | |
8b450588 | 1189 | const char *include_schemes,<br> |
ae71f5de MS |
1190 | const char *exclude_schemes,<br> |
1191 | cups_device_cb_t callback,<br> | |
1192 | void *user_data<br> | |
1193 | );</p> | |
1194 | <h4 class="parameters">Parameters</h4> | |
1195 | <dl> | |
1196 | <dt>http</dt> | |
1197 | <dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd> | |
1198 | <dt>timeout</dt> | |
1199 | <dd class="description">Timeout in seconds or <code>CUPS_TIMEOUT_DEFAULT</code></dd> | |
8b450588 MS |
1200 | <dt>include_schemes</dt> |
1201 | <dd class="description">Comma-separated URI schemes to include or <code>CUPS_INCLUDE_ALL</code></dd> | |
ae71f5de MS |
1202 | <dt>exclude_schemes</dt> |
1203 | <dd class="description">Comma-separated URI schemes to exclude or <code>CUPS_EXCLUDE_NONE</code></dd> | |
1204 | <dt>callback</dt> | |
1205 | <dd class="description">Callback function</dd> | |
1206 | <dt>user_data</dt> | |
1207 | <dd class="description">User data pointer</dd> | |
1208 | </dl> | |
1209 | <h4 class="returnvalue">Return Value</h4> | |
1210 | <p class="description">Request status - <code>IPP_OK</code> on success.</p> | |
1211 | <h4 class="discussion">Discussion</h4> | |
1212 | <p class="discussion">This function sends a CUPS-Get-Devices request and streams the discovered | |
1213 | devices to the specified callback function. The "timeout" parameter controls | |
8b450588 MS |
1214 | how long the request lasts, while the "include_schemes" and "exclude_schemes" |
1215 | parameters provide comma-delimited lists of backends to include or omit from | |
1216 | the request respectively. | |
ae71f5de MS |
1217 | |
1218 | </p> | |
f3c17241 | 1219 | <h3 class="function"><span class="info"> CUPS 1.1.20/OS X 10.4 </span><a name="cupsGetFd">cupsGetFd</a></h3> |
ae71f5de MS |
1220 | <p class="description">Get a file from the server.</p> |
1221 | <p class="code"> | |
a469f8a5 | 1222 | http_status_t cupsGetFd (<br> |
ae71f5de MS |
1223 | <a href="#http_t">http_t</a> *http,<br> |
1224 | const char *resource,<br> | |
1225 | int fd<br> | |
1226 | );</p> | |
1227 | <h4 class="parameters">Parameters</h4> | |
1228 | <dl> | |
1229 | <dt>http</dt> | |
1230 | <dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd> | |
1231 | <dt>resource</dt> | |
1232 | <dd class="description">Resource name</dd> | |
1233 | <dt>fd</dt> | |
1234 | <dd class="description">File descriptor</dd> | |
1235 | </dl> | |
1236 | <h4 class="returnvalue">Return Value</h4> | |
1237 | <p class="description">HTTP status</p> | |
1238 | <h4 class="discussion">Discussion</h4> | |
6961465f | 1239 | <p class="discussion">This function returns <code>HTTP_STATUS_OK</code> when the file is successfully retrieved. |
ae71f5de MS |
1240 | |
1241 | </p> | |
f3c17241 | 1242 | <h3 class="function"><span class="info"> CUPS 1.1.20/OS X 10.4 </span><a name="cupsGetFile">cupsGetFile</a></h3> |
ae71f5de MS |
1243 | <p class="description">Get a file from the server.</p> |
1244 | <p class="code"> | |
a469f8a5 | 1245 | http_status_t cupsGetFile (<br> |
ae71f5de MS |
1246 | <a href="#http_t">http_t</a> *http,<br> |
1247 | const char *resource,<br> | |
1248 | const char *filename<br> | |
1249 | );</p> | |
1250 | <h4 class="parameters">Parameters</h4> | |
1251 | <dl> | |
1252 | <dt>http</dt> | |
1253 | <dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd> | |
1254 | <dt>resource</dt> | |
1255 | <dd class="description">Resource name</dd> | |
1256 | <dt>filename</dt> | |
1257 | <dd class="description">Filename</dd> | |
1258 | </dl> | |
1259 | <h4 class="returnvalue">Return Value</h4> | |
1260 | <p class="description">HTTP status</p> | |
1261 | <h4 class="discussion">Discussion</h4> | |
6961465f | 1262 | <p class="discussion">This function returns <code>HTTP_STATUS_OK</code> when the file is successfully retrieved. |
ae71f5de | 1263 | |
5a738aea | 1264 | </p> |
f3c17241 | 1265 | <h3 class="function"><span class="info"> CUPS 1.4/OS X 10.6 </span><a name="cupsGetResponse">cupsGetResponse</a></h3> |
5a738aea MS |
1266 | <p class="description">Get a response to an IPP request.</p> |
1267 | <p class="code"> | |
1268 | <a href="#ipp_t">ipp_t</a> *cupsGetResponse (<br> | |
1269 | <a href="#http_t">http_t</a> *http,<br> | |
1270 | const char *resource<br> | |
1271 | );</p> | |
1272 | <h4 class="parameters">Parameters</h4> | |
1273 | <dl> | |
1274 | <dt>http</dt> | |
568fa3fa | 1275 | <dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd> |
5a738aea MS |
1276 | <dt>resource</dt> |
1277 | <dd class="description">HTTP resource for POST</dd> | |
1278 | </dl> | |
1279 | <h4 class="returnvalue">Return Value</h4> | |
568fa3fa | 1280 | <p class="description">Response or <code>NULL</code> on HTTP error</p> |
5a738aea MS |
1281 | <h4 class="discussion">Discussion</h4> |
1282 | <p class="discussion">Use this function to get the response for an IPP request sent using | |
5a9febac MS |
1283 | <a href="#cupsSendRequest"><code>cupsSendRequest</code></a>. For requests that return additional data, use |
1284 | <a href="#cupsReadResponseData"><code>cupsReadResponseData</code></a> after getting a successful response, | |
1285 | otherwise call <a href="#httpFlush"><code>httpFlush</code></a> to complete the response processing. | |
5a738aea | 1286 | |
ae71f5de | 1287 | </p> |
10d09e33 | 1288 | <h3 class="function"><a name="cupsLastError">cupsLastError</a></h3> |
5a9febac MS |
1289 | <p class="description">Return the last IPP status code received on the current |
1290 | thread.</p> | |
10d09e33 MS |
1291 | <p class="code"> |
1292 | ipp_status_t cupsLastError (void);</p> | |
1293 | <h4 class="returnvalue">Return Value</h4> | |
1294 | <p class="description">IPP status code from last request</p> | |
f3c17241 | 1295 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="cupsLastErrorString">cupsLastErrorString</a></h3> |
5a9febac MS |
1296 | <p class="description">Return the last IPP status-message received on the |
1297 | current thread.</p> | |
10d09e33 MS |
1298 | <p class="code"> |
1299 | const char *cupsLastErrorString (void);</p> | |
1300 | <h4 class="returnvalue">Return Value</h4> | |
1301 | <p class="description">status-message text from last request</p> | |
f3c17241 | 1302 | <h3 class="function"><span class="info"> CUPS 1.1.20/OS X 10.4 </span><a name="cupsPutFd">cupsPutFd</a></h3> |
ae71f5de MS |
1303 | <p class="description">Put a file on the server.</p> |
1304 | <p class="code"> | |
a469f8a5 | 1305 | http_status_t cupsPutFd (<br> |
ae71f5de MS |
1306 | <a href="#http_t">http_t</a> *http,<br> |
1307 | const char *resource,<br> | |
1308 | int fd<br> | |
1309 | );</p> | |
1310 | <h4 class="parameters">Parameters</h4> | |
1311 | <dl> | |
1312 | <dt>http</dt> | |
1313 | <dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd> | |
1314 | <dt>resource</dt> | |
1315 | <dd class="description">Resource name</dd> | |
1316 | <dt>fd</dt> | |
1317 | <dd class="description">File descriptor</dd> | |
1318 | </dl> | |
1319 | <h4 class="returnvalue">Return Value</h4> | |
1320 | <p class="description">HTTP status</p> | |
1321 | <h4 class="discussion">Discussion</h4> | |
6961465f | 1322 | <p class="discussion">This function returns <code>HTTP_STATUS_CREATED</code> when the file is stored |
ae71f5de MS |
1323 | successfully. |
1324 | ||
1325 | </p> | |
f3c17241 | 1326 | <h3 class="function"><span class="info"> CUPS 1.1.20/OS X 10.4 </span><a name="cupsPutFile">cupsPutFile</a></h3> |
ae71f5de MS |
1327 | <p class="description">Put a file on the server.</p> |
1328 | <p class="code"> | |
a469f8a5 | 1329 | http_status_t cupsPutFile (<br> |
ae71f5de MS |
1330 | <a href="#http_t">http_t</a> *http,<br> |
1331 | const char *resource,<br> | |
1332 | const char *filename<br> | |
1333 | );</p> | |
1334 | <h4 class="parameters">Parameters</h4> | |
1335 | <dl> | |
1336 | <dt>http</dt> | |
1337 | <dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd> | |
1338 | <dt>resource</dt> | |
1339 | <dd class="description">Resource name</dd> | |
1340 | <dt>filename</dt> | |
1341 | <dd class="description">Filename</dd> | |
1342 | </dl> | |
1343 | <h4 class="returnvalue">Return Value</h4> | |
1344 | <p class="description">HTTP status</p> | |
1345 | <h4 class="discussion">Discussion</h4> | |
1346 | <p class="discussion">This function returns <code>HTTP_CREATED</code> when the file is stored | |
1347 | successfully. | |
1348 | ||
5a738aea | 1349 | </p> |
f3c17241 | 1350 | <h3 class="function"><span class="info"> CUPS 1.4/OS X 10.6 </span><a name="cupsReadResponseData">cupsReadResponseData</a></h3> |
5a738aea MS |
1351 | <p class="description">Read additional data after the IPP response.</p> |
1352 | <p class="code"> | |
1353 | ssize_t cupsReadResponseData (<br> | |
1354 | <a href="#http_t">http_t</a> *http,<br> | |
1355 | char *buffer,<br> | |
1356 | size_t length<br> | |
1357 | );</p> | |
1358 | <h4 class="parameters">Parameters</h4> | |
1359 | <dl> | |
1360 | <dt>http</dt> | |
568fa3fa | 1361 | <dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd> |
5a738aea MS |
1362 | <dt>buffer</dt> |
1363 | <dd class="description">Buffer to use</dd> | |
1364 | <dt>length</dt> | |
1365 | <dd class="description">Number of bytes to read</dd> | |
1366 | </dl> | |
1367 | <h4 class="returnvalue">Return Value</h4> | |
1368 | <p class="description">Bytes read, 0 on EOF, -1 on error</p> | |
1369 | <h4 class="discussion">Discussion</h4> | |
5a9febac MS |
1370 | <p class="discussion">This function is used after <a href="#cupsGetResponse"><code>cupsGetResponse</code></a> to read the PPD or document |
1371 | files from <code>CUPS_GET_PPD</code> and <code>CUPS_GET_DOCUMENT</code> requests, | |
1372 | respectively. | |
5a738aea MS |
1373 | |
1374 | </p> | |
f3c17241 | 1375 | <h3 class="function"><span class="info"> CUPS 1.4/OS X 10.6 </span><a name="cupsSendRequest">cupsSendRequest</a></h3> |
5a738aea MS |
1376 | <p class="description">Send an IPP request.</p> |
1377 | <p class="code"> | |
a469f8a5 | 1378 | http_status_t cupsSendRequest (<br> |
5a738aea MS |
1379 | <a href="#http_t">http_t</a> *http,<br> |
1380 | <a href="#ipp_t">ipp_t</a> *request,<br> | |
1381 | const char *resource,<br> | |
1382 | size_t length<br> | |
1383 | );</p> | |
1384 | <h4 class="parameters">Parameters</h4> | |
1385 | <dl> | |
1386 | <dt>http</dt> | |
568fa3fa | 1387 | <dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd> |
5a738aea MS |
1388 | <dt>request</dt> |
1389 | <dd class="description">IPP request</dd> | |
1390 | <dt>resource</dt> | |
1391 | <dd class="description">Resource path</dd> | |
1392 | <dt>length</dt> | |
ae71f5de | 1393 | <dd class="description">Length of data to follow or <code>CUPS_LENGTH_VARIABLE</code></dd> |
5a738aea MS |
1394 | </dl> |
1395 | <h4 class="returnvalue">Return Value</h4> | |
1396 | <p class="description">Initial HTTP status</p> | |
1397 | <h4 class="discussion">Discussion</h4> | |
5a9febac MS |
1398 | <p class="discussion">Use <a href="#cupsWriteRequestData"><code>cupsWriteRequestData</code></a> to write any additional data (document, PPD |
1399 | file, etc.) for the request, <a href="#cupsGetResponse"><code>cupsGetResponse</code></a> to get the IPP response, | |
1400 | and <a href="#cupsReadResponseData"><code>cupsReadResponseData</code></a> to read any additional data following the | |
1401 | response. Only one request can be sent/queued at a time per <code>http_t</code> | |
1402 | connection.<br> | |
1403 | <br> | |
6961465f | 1404 | Returns the initial HTTP status code, which will be <code>HTTP_STATUS_CONTINUE</code> |
5a9febac | 1405 | on a successful send of the request.<br> |
5a738aea | 1406 | <br> |
5a9febac MS |
1407 | Note: Unlike <a href="#cupsDoFileRequest"><code>cupsDoFileRequest</code></a>, <a href="#cupsDoIORequest"><code>cupsDoIORequest</code></a>, and |
1408 | <a href="#cupsDoRequest"><code>cupsDoRequest</code></a>, the request is NOT freed with <a href="#ippDelete"><code>ippDelete</code></a>. | |
5a738aea MS |
1409 | |
1410 | </p> | |
f3c17241 | 1411 | <h3 class="function"><span class="info"> CUPS 1.4/OS X 10.6 </span><a name="cupsWriteRequestData">cupsWriteRequestData</a></h3> |
5a738aea MS |
1412 | <p class="description">Write additional data after an IPP request.</p> |
1413 | <p class="code"> | |
a469f8a5 | 1414 | http_status_t cupsWriteRequestData (<br> |
5a738aea MS |
1415 | <a href="#http_t">http_t</a> *http,<br> |
1416 | const char *buffer,<br> | |
1417 | size_t length<br> | |
1418 | );</p> | |
1419 | <h4 class="parameters">Parameters</h4> | |
1420 | <dl> | |
1421 | <dt>http</dt> | |
568fa3fa | 1422 | <dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd> |
5a738aea MS |
1423 | <dt>buffer</dt> |
1424 | <dd class="description">Bytes to write</dd> | |
1425 | <dt>length</dt> | |
1426 | <dd class="description">Number of bytes to write</dd> | |
1427 | </dl> | |
1428 | <h4 class="returnvalue">Return Value</h4> | |
6961465f | 1429 | <p class="description"><code>HTTP_STATUS_CONTINUE</code> if OK or HTTP status on error</p> |
5a738aea | 1430 | <h4 class="discussion">Discussion</h4> |
568fa3fa MS |
1431 | <p class="discussion">This function is used after <a href="#cupsSendRequest"><code>cupsSendRequest</code></a> to provide a PPD and |
1432 | after <a href="#cupsStartDocument"><code>cupsStartDocument</code></a> to provide a document file. | |
5a738aea | 1433 | |
10d09e33 | 1434 | </p> |
9c0e8e5d | 1435 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="httpAcceptConnection">httpAcceptConnection</a></h3> |
a469f8a5 MS |
1436 | <p class="description">Accept a new HTTP client connection from the |
1437 | specified listening socket.</p> | |
1438 | <p class="code"> | |
1439 | <a href="#http_t">http_t</a> *httpAcceptConnection (<br> | |
1440 | int fd,<br> | |
1441 | int blocking<br> | |
1442 | );</p> | |
1443 | <h4 class="parameters">Parameters</h4> | |
1444 | <dl> | |
1445 | <dt>fd</dt> | |
1446 | <dd class="description">Listen socket file descriptor</dd> | |
1447 | <dt>blocking</dt> | |
1448 | <dd class="description">1 if the connection should be | |
1449 | blocking, 0 otherwise</dd> | |
1450 | </dl> | |
1451 | <h4 class="returnvalue">Return Value</h4> | |
1452 | <p class="description">HTTP connection or <code>NULL</code></p> | |
f3c17241 | 1453 | <h3 class="function"><span class="info"> CUPS 1.5/OS X 10.7 </span><a name="httpAddCredential">httpAddCredential</a></h3> |
10d09e33 MS |
1454 | <p class="description">Allocates and adds a single credential to an array.</p> |
1455 | <p class="code"> | |
1456 | int httpAddCredential (<br> | |
1457 | cups_array_t *credentials,<br> | |
1458 | const void *data,<br> | |
1459 | size_t datalen<br> | |
1460 | );</p> | |
1461 | <h4 class="parameters">Parameters</h4> | |
1462 | <dl> | |
1463 | <dt>credentials</dt> | |
1464 | <dd class="description">Credentials array</dd> | |
1465 | <dt>data</dt> | |
1466 | <dd class="description">PEM-encoded X.509 data</dd> | |
1467 | <dt>datalen</dt> | |
1468 | <dd class="description">Length of data</dd> | |
1469 | </dl> | |
1470 | <h4 class="returnvalue">Return Value</h4> | |
1471 | <p class="description">0 on success, -1 on error</p> | |
1472 | <h4 class="discussion">Discussion</h4> | |
1473 | <p class="discussion">Use <code>cupsArrayNew(NULL, NULL)</code> to create a credentials array. | |
1474 | ||
5a738aea | 1475 | </p> |
f3c17241 | 1476 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpAddrAny">httpAddrAny</a></h3> |
5a738aea MS |
1477 | <p class="description">Check for the "any" address.</p> |
1478 | <p class="code"> | |
1479 | int httpAddrAny (<br> | |
1480 | const <a href="#http_addr_t">http_addr_t</a> *addr<br> | |
1481 | );</p> | |
1482 | <h4 class="parameters">Parameters</h4> | |
1483 | <dl> | |
1484 | <dt>addr</dt> | |
1485 | <dd class="description">Address to check</dd> | |
1486 | </dl> | |
1487 | <h4 class="returnvalue">Return Value</h4> | |
1488 | <p class="description">1 if "any", 0 otherwise</p> | |
e1f19878 | 1489 | <h3 class="function"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="httpAddrClose">httpAddrClose</a></h3> |
ca6b43fc MS |
1490 | <p class="description">Close a socket created by <a href="#httpAddrConnect"><code>httpAddrConnect</code></a> or |
1491 | <a href="#httpAddrListen"><code>httpAddrListen</code></a>.</p> | |
1492 | <p class="code"> | |
1493 | int httpAddrClose (<br> | |
1494 | <a href="#http_addr_t">http_addr_t</a> *addr,<br> | |
1495 | int fd<br> | |
1496 | );</p> | |
1497 | <h4 class="parameters">Parameters</h4> | |
1498 | <dl> | |
1499 | <dt>addr</dt> | |
1500 | <dd class="description">Listen address or <code>NULL</code></dd> | |
1501 | <dt>fd</dt> | |
1502 | <dd class="description">Socket file descriptor</dd> | |
1503 | </dl> | |
1504 | <h4 class="returnvalue">Return Value</h4> | |
1505 | <p class="description">0 on success, -1 on failure</p> | |
1506 | <h4 class="discussion">Discussion</h4> | |
1507 | <p class="discussion">Pass <code>NULL</code> for sockets created with <a href="#httpAddrConnect"><code>httpAddrConnect</code></a> and the | |
1508 | listen address for sockets created with <a href="#httpAddrListen"><code>httpAddrListen</code></a>. This will | |
1509 | ensure that domain sockets are removed when closed. | |
1510 | ||
1511 | </p> | |
f3c17241 | 1512 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpAddrEqual">httpAddrEqual</a></h3> |
5a738aea MS |
1513 | <p class="description">Compare two addresses.</p> |
1514 | <p class="code"> | |
1515 | int httpAddrEqual (<br> | |
1516 | const <a href="#http_addr_t">http_addr_t</a> *addr1,<br> | |
1517 | const <a href="#http_addr_t">http_addr_t</a> *addr2<br> | |
1518 | );</p> | |
1519 | <h4 class="parameters">Parameters</h4> | |
1520 | <dl> | |
1521 | <dt>addr1</dt> | |
1522 | <dd class="description">First address</dd> | |
1523 | <dt>addr2</dt> | |
1524 | <dd class="description">Second address</dd> | |
1525 | </dl> | |
1526 | <h4 class="returnvalue">Return Value</h4> | |
1527 | <p class="description">1 if equal, 0 if not</p> | |
ca6b43fc MS |
1528 | <h3 class="function"><a name="httpAddrFamily">httpAddrFamily</a></h3> |
1529 | <p class="description">Get the address family of an address.</p> | |
1530 | <p class="code"> | |
1531 | int httpAddrFamily (<br> | |
1532 | <a href="#http_addr_t">http_addr_t</a> *addr<br> | |
1533 | );</p> | |
1534 | <h4 class="parameters">Parameters</h4> | |
1535 | <dl> | |
1536 | <dt>addr</dt> | |
1537 | <dd class="description">Address</dd> | |
1538 | </dl> | |
1539 | <h4 class="returnvalue">Return Value</h4> | |
1540 | <p class="description">Address family</p> | |
f3c17241 | 1541 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpAddrLength">httpAddrLength</a></h3> |
5a738aea MS |
1542 | <p class="description">Return the length of the address in bytes.</p> |
1543 | <p class="code"> | |
1544 | int httpAddrLength (<br> | |
1545 | const <a href="#http_addr_t">http_addr_t</a> *addr<br> | |
1546 | );</p> | |
1547 | <h4 class="parameters">Parameters</h4> | |
1548 | <dl> | |
1549 | <dt>addr</dt> | |
1550 | <dd class="description">Address</dd> | |
1551 | </dl> | |
1552 | <h4 class="returnvalue">Return Value</h4> | |
1553 | <p class="description">Length in bytes</p> | |
9c0e8e5d | 1554 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="httpAddrListen">httpAddrListen</a></h3> |
a469f8a5 MS |
1555 | <p class="description">Create a listening socket bound to the specified |
1556 | address and port.</p> | |
1557 | <p class="code"> | |
1558 | int httpAddrListen (<br> | |
1559 | <a href="#http_addr_t">http_addr_t</a> *addr,<br> | |
1560 | int port<br> | |
1561 | );</p> | |
1562 | <h4 class="parameters">Parameters</h4> | |
1563 | <dl> | |
1564 | <dt>addr</dt> | |
1565 | <dd class="description">Address to bind to</dd> | |
1566 | <dt>port</dt> | |
1567 | <dd class="description">Port number to bind to</dd> | |
1568 | </dl> | |
1569 | <h4 class="returnvalue">Return Value</h4> | |
1570 | <p class="description">Socket or -1 on error</p> | |
f3c17241 | 1571 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpAddrLocalhost">httpAddrLocalhost</a></h3> |
5a738aea MS |
1572 | <p class="description">Check for the local loopback address.</p> |
1573 | <p class="code"> | |
1574 | int httpAddrLocalhost (<br> | |
1575 | const <a href="#http_addr_t">http_addr_t</a> *addr<br> | |
1576 | );</p> | |
1577 | <h4 class="parameters">Parameters</h4> | |
1578 | <dl> | |
1579 | <dt>addr</dt> | |
1580 | <dd class="description">Address to check</dd> | |
1581 | </dl> | |
1582 | <h4 class="returnvalue">Return Value</h4> | |
1583 | <p class="description">1 if local host, 0 otherwise</p> | |
f3c17241 | 1584 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpAddrLookup">httpAddrLookup</a></h3> |
5a738aea MS |
1585 | <p class="description">Lookup the hostname associated with the address.</p> |
1586 | <p class="code"> | |
1587 | char *httpAddrLookup (<br> | |
1588 | const <a href="#http_addr_t">http_addr_t</a> *addr,<br> | |
1589 | char *name,<br> | |
1590 | int namelen<br> | |
1591 | );</p> | |
1592 | <h4 class="parameters">Parameters</h4> | |
1593 | <dl> | |
1594 | <dt>addr</dt> | |
1595 | <dd class="description">Address to lookup</dd> | |
1596 | <dt>name</dt> | |
1597 | <dd class="description">Host name buffer</dd> | |
1598 | <dt>namelen</dt> | |
1599 | <dd class="description">Size of name buffer</dd> | |
1600 | </dl> | |
1601 | <h4 class="returnvalue">Return Value</h4> | |
1602 | <p class="description">Host name</p> | |
9c0e8e5d | 1603 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="httpAddrPort">httpAddrPort</a></h3> |
a469f8a5 MS |
1604 | <p class="description">Get the port number associated with an address.</p> |
1605 | <p class="code"> | |
1606 | int httpAddrPort (<br> | |
1607 | <a href="#http_addr_t">http_addr_t</a> *addr<br> | |
1608 | );</p> | |
1609 | <h4 class="parameters">Parameters</h4> | |
1610 | <dl> | |
1611 | <dt>addr</dt> | |
1612 | <dd class="description">Address</dd> | |
1613 | </dl> | |
1614 | <h4 class="returnvalue">Return Value</h4> | |
1615 | <p class="description">Port number</p> | |
f3c17241 | 1616 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpAddrString">httpAddrString</a></h3> |
5a738aea MS |
1617 | <p class="description">Convert an address to a numeric string.</p> |
1618 | <p class="code"> | |
1619 | char *httpAddrString (<br> | |
1620 | const <a href="#http_addr_t">http_addr_t</a> *addr,<br> | |
1621 | char *s,<br> | |
1622 | int slen<br> | |
1623 | );</p> | |
1624 | <h4 class="parameters">Parameters</h4> | |
1625 | <dl> | |
1626 | <dt>addr</dt> | |
1627 | <dd class="description">Address to convert</dd> | |
1628 | <dt>s</dt> | |
1629 | <dd class="description">String buffer</dd> | |
1630 | <dt>slen</dt> | |
1631 | <dd class="description">Length of string</dd> | |
1632 | </dl> | |
1633 | <h4 class="returnvalue">Return Value</h4> | |
1634 | <p class="description">Numeric address string</p> | |
f3c17241 | 1635 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpAssembleURI">httpAssembleURI</a></h3> |
5a738aea MS |
1636 | <p class="description">Assemble a uniform resource identifier from its |
1637 | components.</p> | |
1638 | <p class="code"> | |
79e1d494 MS |
1639 | <a href="#http_uri_status_t">http_uri_status_t</a> httpAssembleURI (<br> |
1640 | <a href="#http_uri_coding_t">http_uri_coding_t</a> encoding,<br> | |
5a738aea MS |
1641 | char *uri,<br> |
1642 | int urilen,<br> | |
1643 | const char *scheme,<br> | |
1644 | const char *username,<br> | |
1645 | const char *host,<br> | |
1646 | int port,<br> | |
1647 | const char *resource<br> | |
1648 | );</p> | |
1649 | <h4 class="parameters">Parameters</h4> | |
1650 | <dl> | |
1651 | <dt>encoding</dt> | |
1652 | <dd class="description">Encoding flags</dd> | |
1653 | <dt>uri</dt> | |
1654 | <dd class="description">URI buffer</dd> | |
1655 | <dt>urilen</dt> | |
1656 | <dd class="description">Size of URI buffer</dd> | |
1657 | <dt>scheme</dt> | |
1658 | <dd class="description">Scheme name</dd> | |
1659 | <dt>username</dt> | |
1660 | <dd class="description">Username</dd> | |
1661 | <dt>host</dt> | |
1662 | <dd class="description">Hostname or address</dd> | |
1663 | <dt>port</dt> | |
1664 | <dd class="description">Port number</dd> | |
1665 | <dt>resource</dt> | |
1666 | <dd class="description">Resource</dd> | |
1667 | </dl> | |
1668 | <h4 class="returnvalue">Return Value</h4> | |
1669 | <p class="description">URI status</p> | |
1670 | <h4 class="discussion">Discussion</h4> | |
1671 | <p class="discussion">This function escapes reserved characters in the URI depending on the | |
ecdc0628 | 1672 | value of the "encoding" argument. You should use this function in |
1673 | place of traditional string functions whenever you need to create a | |
1674 | URI string. | |
ef416fc2 | 1675 | |
5a738aea | 1676 | </p> |
f3c17241 | 1677 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpAssembleURIf">httpAssembleURIf</a></h3> |
5a738aea MS |
1678 | <p class="description">Assemble a uniform resource identifier from its |
1679 | components with a formatted resource.</p> | |
1680 | <p class="code"> | |
79e1d494 MS |
1681 | <a href="#http_uri_status_t">http_uri_status_t</a> httpAssembleURIf (<br> |
1682 | <a href="#http_uri_coding_t">http_uri_coding_t</a> encoding,<br> | |
5a738aea MS |
1683 | char *uri,<br> |
1684 | int urilen,<br> | |
1685 | const char *scheme,<br> | |
1686 | const char *username,<br> | |
1687 | const char *host,<br> | |
1688 | int port,<br> | |
1689 | const char *resourcef,<br> | |
1690 | ...<br> | |
1691 | );</p> | |
1692 | <h4 class="parameters">Parameters</h4> | |
1693 | <dl> | |
1694 | <dt>encoding</dt> | |
1695 | <dd class="description">Encoding flags</dd> | |
1696 | <dt>uri</dt> | |
1697 | <dd class="description">URI buffer</dd> | |
1698 | <dt>urilen</dt> | |
1699 | <dd class="description">Size of URI buffer</dd> | |
1700 | <dt>scheme</dt> | |
1701 | <dd class="description">Scheme name</dd> | |
1702 | <dt>username</dt> | |
1703 | <dd class="description">Username</dd> | |
1704 | <dt>host</dt> | |
1705 | <dd class="description">Hostname or address</dd> | |
1706 | <dt>port</dt> | |
1707 | <dd class="description">Port number</dd> | |
1708 | <dt>resourcef</dt> | |
1709 | <dd class="description">Printf-style resource</dd> | |
1710 | <dt>...</dt> | |
1711 | <dd class="description">Additional arguments as needed</dd> | |
1712 | </dl> | |
1713 | <h4 class="returnvalue">Return Value</h4> | |
1714 | <p class="description">URI status</p> | |
1715 | <h4 class="discussion">Discussion</h4> | |
1716 | <p class="discussion">This function creates a formatted version of the resource string | |
ecdc0628 | 1717 | argument "resourcef" and escapes reserved characters in the URI |
1718 | depending on the value of the "encoding" argument. You should use | |
1719 | this function in place of traditional string functions whenever | |
1720 | you need to create a URI string. | |
ef416fc2 | 1721 | |
5a738aea | 1722 | </p> |
9c0e8e5d | 1723 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="httpAssembleUUID">httpAssembleUUID</a></h3> |
db8b865d MS |
1724 | <p class="description">Assemble a name-based UUID URN conforming to RFC 4122.</p> |
1725 | <p class="code"> | |
1726 | char *httpAssembleUUID (<br> | |
1727 | const char *server,<br> | |
1728 | int port,<br> | |
1729 | const char *name,<br> | |
1730 | int number,<br> | |
1731 | char *buffer,<br> | |
1732 | size_t bufsize<br> | |
1733 | );</p> | |
1734 | <h4 class="parameters">Parameters</h4> | |
1735 | <dl> | |
1736 | <dt>server</dt> | |
1737 | <dd class="description">Server name</dd> | |
1738 | <dt>port</dt> | |
1739 | <dd class="description">Port number</dd> | |
1740 | <dt>name</dt> | |
1741 | <dd class="description">Object name or NULL</dd> | |
1742 | <dt>number</dt> | |
1743 | <dd class="description">Object number or 0</dd> | |
1744 | <dt>buffer</dt> | |
1745 | <dd class="description">String buffer</dd> | |
1746 | <dt>bufsize</dt> | |
1747 | <dd class="description">Size of buffer</dd> | |
1748 | </dl> | |
1749 | <h4 class="returnvalue">Return Value</h4> | |
1750 | <p class="description">UUID string</p> | |
1751 | <h4 class="discussion">Discussion</h4> | |
1752 | <p class="discussion">This function creates a unique 128-bit identifying number using the server | |
1753 | name, port number, random data, and optionally an object name and/or object | |
1754 | number. The result is formatted as a UUID URN as defined in RFC 4122.<br> | |
1755 | <br> | |
6961465f MS |
1756 | The buffer needs to be at least 46 bytes in size. |
1757 | ||
1758 | </p> | |
5a738aea MS |
1759 | <h3 class="function"><a name="httpBlocking">httpBlocking</a></h3> |
1760 | <p class="description">Set blocking/non-blocking behavior on a connection.</p> | |
1761 | <p class="code"> | |
1762 | void httpBlocking (<br> | |
1763 | <a href="#http_t">http_t</a> *http,<br> | |
1764 | int b<br> | |
1765 | );</p> | |
1766 | <h4 class="parameters">Parameters</h4> | |
1767 | <dl> | |
1768 | <dt>http</dt> | |
ca6b43fc | 1769 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
1770 | <dt>b</dt> |
1771 | <dd class="description">1 = blocking, 0 = non-blocking</dd> | |
1772 | </dl> | |
1773 | <h3 class="function"><a name="httpCheck">httpCheck</a></h3> | |
1774 | <p class="description">Check to see if there is a pending response from the server.</p> | |
1775 | <p class="code"> | |
1776 | int httpCheck (<br> | |
1777 | <a href="#http_t">http_t</a> *http<br> | |
1778 | );</p> | |
1779 | <h4 class="parameters">Parameters</h4> | |
1780 | <dl> | |
1781 | <dt>http</dt> | |
ca6b43fc | 1782 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
1783 | </dl> |
1784 | <h4 class="returnvalue">Return Value</h4> | |
1785 | <p class="description">0 = no data, 1 = data available</p> | |
f3c17241 | 1786 | <h3 class="function"><span class="info"> CUPS 1.1.19/OS X 10.3 </span><a name="httpClearCookie">httpClearCookie</a></h3> |
5a738aea MS |
1787 | <p class="description">Clear the cookie value(s).</p> |
1788 | <p class="code"> | |
1789 | void httpClearCookie (<br> | |
1790 | <a href="#http_t">http_t</a> *http<br> | |
1791 | );</p> | |
1792 | <h4 class="parameters">Parameters</h4> | |
1793 | <dl> | |
1794 | <dt>http</dt> | |
ca6b43fc | 1795 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
1796 | </dl> |
1797 | <h3 class="function"><a name="httpClearFields">httpClearFields</a></h3> | |
1798 | <p class="description">Clear HTTP request fields.</p> | |
1799 | <p class="code"> | |
1800 | void httpClearFields (<br> | |
1801 | <a href="#http_t">http_t</a> *http<br> | |
1802 | );</p> | |
1803 | <h4 class="parameters">Parameters</h4> | |
1804 | <dl> | |
1805 | <dt>http</dt> | |
ca6b43fc | 1806 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
1807 | </dl> |
1808 | <h3 class="function"><a name="httpClose">httpClose</a></h3> | |
10d09e33 | 1809 | <p class="description">Close an HTTP connection.</p> |
5a738aea MS |
1810 | <p class="code"> |
1811 | void httpClose (<br> | |
1812 | <a href="#http_t">http_t</a> *http<br> | |
1813 | );</p> | |
1814 | <h4 class="parameters">Parameters</h4> | |
1815 | <dl> | |
1816 | <dt>http</dt> | |
ca6b43fc | 1817 | <dd class="description">HTTP connection</dd> |
5a738aea | 1818 | </dl> |
e1f19878 | 1819 | <h3 class="function"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="httpCompareCredentials">httpCompareCredentials</a></h3> |
ca6b43fc MS |
1820 | <p class="description">Compare two sets of X.509 credentials.</p> |
1821 | <p class="code"> | |
1822 | int httpCompareCredentials (<br> | |
1823 | cups_array_t *cred1,<br> | |
1824 | cups_array_t *cred2<br> | |
1825 | );</p> | |
1826 | <h4 class="parameters">Parameters</h4> | |
1827 | <dl> | |
1828 | <dt>cred1</dt> | |
1829 | <dd class="description">First set of X.509 credentials</dd> | |
1830 | <dt>cred2</dt> | |
1831 | <dd class="description">Second set of X.509 credentials</dd> | |
1832 | </dl> | |
1833 | <h4 class="returnvalue">Return Value</h4> | |
1834 | <p class="description">1 if they match, 0 if they do not</p> | |
06d4e77b | 1835 | <h3 class="function"><span class="info"> DEPRECATED </span><a name="httpConnect">httpConnect</a></h3> |
5a738aea MS |
1836 | <p class="description">Connect to a HTTP server.</p> |
1837 | <p class="code"> | |
1838 | <a href="#http_t">http_t</a> *httpConnect (<br> | |
1839 | const char *host,<br> | |
1840 | int port<br> | |
1841 | );</p> | |
1842 | <h4 class="parameters">Parameters</h4> | |
1843 | <dl> | |
1844 | <dt>host</dt> | |
1845 | <dd class="description">Host to connect to</dd> | |
1846 | <dt>port</dt> | |
1847 | <dd class="description">Port number</dd> | |
1848 | </dl> | |
1849 | <h4 class="returnvalue">Return Value</h4> | |
1850 | <p class="description">New HTTP connection</p> | |
06d4e77b | 1851 | <h4 class="discussion">Discussion</h4> |
a469f8a5 | 1852 | <p class="discussion">This function is deprecated - use <a href="#httpConnect2"><code>httpConnect2</code></a> instead. |
06d4e77b MS |
1853 | |
1854 | </p> | |
9c0e8e5d | 1855 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="httpConnect2">httpConnect2</a></h3> |
a469f8a5 MS |
1856 | <p class="description">Connect to a HTTP server.</p> |
1857 | <p class="code"> | |
1858 | <a href="#http_t">http_t</a> *httpConnect2 (<br> | |
1859 | const char *host,<br> | |
1860 | int port,<br> | |
1861 | <a href="#http_addrlist_t">http_addrlist_t</a> *addrlist,<br> | |
1862 | int family,<br> | |
1863 | <a href="#http_encryption_t">http_encryption_t</a> encryption,<br> | |
1864 | int blocking,<br> | |
1865 | int msec,<br> | |
1866 | int *cancel<br> | |
1867 | );</p> | |
1868 | <h4 class="parameters">Parameters</h4> | |
1869 | <dl> | |
1870 | <dt>host</dt> | |
1871 | <dd class="description">Host to connect to</dd> | |
1872 | <dt>port</dt> | |
1873 | <dd class="description">Port number</dd> | |
1874 | <dt>addrlist</dt> | |
1875 | <dd class="description">List of addresses or NULL to lookup</dd> | |
1876 | <dt>family</dt> | |
1877 | <dd class="description">Address family to use or <code>AF_UNSPEC</code> for any</dd> | |
1878 | <dt>encryption</dt> | |
1879 | <dd class="description">Type of encryption to use</dd> | |
1880 | <dt>blocking</dt> | |
1881 | <dd class="description">1 for blocking connection, 0 for non-blocking</dd> | |
1882 | <dt>msec</dt> | |
db8b865d | 1883 | <dd class="description">Connection timeout in milliseconds, 0 means don't connect</dd> |
a469f8a5 MS |
1884 | <dt>cancel</dt> |
1885 | <dd class="description">Pointer to "cancel" variable</dd> | |
1886 | </dl> | |
1887 | <h4 class="returnvalue">Return Value</h4> | |
1888 | <p class="description">New HTTP connection</p> | |
1889 | <h3 class="function"><span class="info"> DEPRECATED </span><a name="httpConnectEncrypt">httpConnectEncrypt</a></h3> | |
5a738aea MS |
1890 | <p class="description">Connect to a HTTP server using encryption.</p> |
1891 | <p class="code"> | |
1892 | <a href="#http_t">http_t</a> *httpConnectEncrypt (<br> | |
1893 | const char *host,<br> | |
1894 | int port,<br> | |
1895 | <a href="#http_encryption_t">http_encryption_t</a> encryption<br> | |
1896 | );</p> | |
1897 | <h4 class="parameters">Parameters</h4> | |
1898 | <dl> | |
1899 | <dt>host</dt> | |
1900 | <dd class="description">Host to connect to</dd> | |
1901 | <dt>port</dt> | |
1902 | <dd class="description">Port number</dd> | |
1903 | <dt>encryption</dt> | |
1904 | <dd class="description">Type of encryption to use</dd> | |
1905 | </dl> | |
1906 | <h4 class="returnvalue">Return Value</h4> | |
1907 | <p class="description">New HTTP connection</p> | |
a469f8a5 MS |
1908 | <h4 class="discussion">Discussion</h4> |
1909 | <p class="discussion">This function is now deprecated. Please use the <a href="#httpConnect2"><code>httpConnect2</code></a> function | |
1910 | instead. | |
1911 | ||
1912 | </p> | |
5a738aea MS |
1913 | <h3 class="function"><span class="info"> DEPRECATED </span><a name="httpDecode64">httpDecode64</a></h3> |
1914 | <p class="description">Base64-decode a string.</p> | |
1915 | <p class="code"> | |
1916 | char *httpDecode64 (<br> | |
1917 | char *out,<br> | |
1918 | const char *in<br> | |
1919 | );</p> | |
1920 | <h4 class="parameters">Parameters</h4> | |
1921 | <dl> | |
1922 | <dt>out</dt> | |
1923 | <dd class="description">String to write to</dd> | |
1924 | <dt>in</dt> | |
1925 | <dd class="description">String to read from</dd> | |
1926 | </dl> | |
1927 | <h4 class="returnvalue">Return Value</h4> | |
1928 | <p class="description">Decoded string</p> | |
1929 | <h4 class="discussion">Discussion</h4> | |
1930 | <p class="discussion">This function is deprecated. Use the httpDecode64_2() function instead | |
ecdc0628 | 1931 | which provides buffer length arguments. |
1932 | ||
5a738aea | 1933 | </p> |
f3c17241 | 1934 | <h3 class="function"><span class="info"> CUPS 1.1.21/OS X 10.4 </span><a name="httpDecode64_2">httpDecode64_2</a></h3> |
5a738aea MS |
1935 | <p class="description">Base64-decode a string.</p> |
1936 | <p class="code"> | |
1937 | char *httpDecode64_2 (<br> | |
1938 | char *out,<br> | |
1939 | int *outlen,<br> | |
1940 | const char *in<br> | |
1941 | );</p> | |
1942 | <h4 class="parameters">Parameters</h4> | |
1943 | <dl> | |
1944 | <dt>out</dt> | |
1945 | <dd class="description">String to write to</dd> | |
1946 | <dt>outlen</dt> | |
1947 | <dd class="description">Size of output string</dd> | |
1948 | <dt>in</dt> | |
1949 | <dd class="description">String to read from</dd> | |
1950 | </dl> | |
1951 | <h4 class="returnvalue">Return Value</h4> | |
1952 | <p class="description">Decoded string</p> | |
1953 | <h3 class="function"><a name="httpDelete">httpDelete</a></h3> | |
1954 | <p class="description">Send a DELETE request to the server.</p> | |
1955 | <p class="code"> | |
1956 | int httpDelete (<br> | |
1957 | <a href="#http_t">http_t</a> *http,<br> | |
1958 | const char *uri<br> | |
1959 | );</p> | |
1960 | <h4 class="parameters">Parameters</h4> | |
1961 | <dl> | |
1962 | <dt>http</dt> | |
ca6b43fc | 1963 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
1964 | <dt>uri</dt> |
1965 | <dd class="description">URI to delete</dd> | |
1966 | </dl> | |
1967 | <h4 class="returnvalue">Return Value</h4> | |
1968 | <p class="description">Status of call (0 = success)</p> | |
1969 | <h3 class="function"><span class="info"> DEPRECATED </span><a name="httpEncode64">httpEncode64</a></h3> | |
1970 | <p class="description">Base64-encode a string.</p> | |
1971 | <p class="code"> | |
1972 | char *httpEncode64 (<br> | |
1973 | char *out,<br> | |
1974 | const char *in<br> | |
1975 | );</p> | |
1976 | <h4 class="parameters">Parameters</h4> | |
1977 | <dl> | |
1978 | <dt>out</dt> | |
1979 | <dd class="description">String to write to</dd> | |
1980 | <dt>in</dt> | |
1981 | <dd class="description">String to read from</dd> | |
1982 | </dl> | |
1983 | <h4 class="returnvalue">Return Value</h4> | |
1984 | <p class="description">Encoded string</p> | |
1985 | <h4 class="discussion">Discussion</h4> | |
1986 | <p class="discussion">This function is deprecated. Use the httpEncode64_2() function instead | |
ecdc0628 | 1987 | which provides buffer length arguments. |
1988 | ||
5a738aea | 1989 | </p> |
f3c17241 | 1990 | <h3 class="function"><span class="info"> CUPS 1.1.21/OS X 10.4 </span><a name="httpEncode64_2">httpEncode64_2</a></h3> |
5a738aea MS |
1991 | <p class="description">Base64-encode a string.</p> |
1992 | <p class="code"> | |
1993 | char *httpEncode64_2 (<br> | |
1994 | char *out,<br> | |
1995 | int outlen,<br> | |
1996 | const char *in,<br> | |
1997 | int inlen<br> | |
1998 | );</p> | |
1999 | <h4 class="parameters">Parameters</h4> | |
2000 | <dl> | |
2001 | <dt>out</dt> | |
2002 | <dd class="description">String to write to</dd> | |
2003 | <dt>outlen</dt> | |
2004 | <dd class="description">Size of output string</dd> | |
2005 | <dt>in</dt> | |
2006 | <dd class="description">String to read from</dd> | |
2007 | <dt>inlen</dt> | |
2008 | <dd class="description">Size of input string</dd> | |
2009 | </dl> | |
2010 | <h4 class="returnvalue">Return Value</h4> | |
2011 | <p class="description">Encoded string</p> | |
2012 | <h3 class="function"><a name="httpEncryption">httpEncryption</a></h3> | |
2013 | <p class="description">Set the required encryption on the link.</p> | |
2014 | <p class="code"> | |
2015 | int httpEncryption (<br> | |
2016 | <a href="#http_t">http_t</a> *http,<br> | |
2017 | <a href="#http_encryption_t">http_encryption_t</a> e<br> | |
2018 | );</p> | |
2019 | <h4 class="parameters">Parameters</h4> | |
2020 | <dl> | |
2021 | <dt>http</dt> | |
ca6b43fc | 2022 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2023 | <dt>e</dt> |
2024 | <dd class="description">New encryption preference</dd> | |
2025 | </dl> | |
2026 | <h4 class="returnvalue">Return Value</h4> | |
2027 | <p class="description">-1 on error, 0 on success</p> | |
2028 | <h3 class="function"><a name="httpError">httpError</a></h3> | |
2029 | <p class="description">Get the last error on a connection.</p> | |
2030 | <p class="code"> | |
2031 | int httpError (<br> | |
2032 | <a href="#http_t">http_t</a> *http<br> | |
2033 | );</p> | |
2034 | <h4 class="parameters">Parameters</h4> | |
2035 | <dl> | |
2036 | <dt>http</dt> | |
ca6b43fc | 2037 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2038 | </dl> |
2039 | <h4 class="returnvalue">Return Value</h4> | |
2040 | <p class="description">Error code (errno) value</p> | |
ca6b43fc MS |
2041 | <h3 class="function"><a name="httpFieldValue">httpFieldValue</a></h3> |
2042 | <p class="description">Return the HTTP field enumeration value for a field | |
2043 | name.</p> | |
2044 | <p class="code"> | |
2045 | <a href="#http_field_t">http_field_t</a> httpFieldValue (<br> | |
2046 | const char *name<br> | |
2047 | );</p> | |
2048 | <h4 class="parameters">Parameters</h4> | |
2049 | <dl> | |
2050 | <dt>name</dt> | |
2051 | <dd class="description">String name</dd> | |
2052 | </dl> | |
2053 | <h4 class="returnvalue">Return Value</h4> | |
2054 | <p class="description">Field index</p> | |
5a738aea MS |
2055 | <h3 class="function"><a name="httpFlush">httpFlush</a></h3> |
2056 | <p class="description">Flush data from a HTTP connection.</p> | |
2057 | <p class="code"> | |
2058 | void httpFlush (<br> | |
2059 | <a href="#http_t">http_t</a> *http<br> | |
2060 | );</p> | |
2061 | <h4 class="parameters">Parameters</h4> | |
2062 | <dl> | |
2063 | <dt>http</dt> | |
ca6b43fc | 2064 | <dd class="description">HTTP connection</dd> |
5a738aea | 2065 | </dl> |
f3c17241 | 2066 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpFlushWrite">httpFlushWrite</a></h3> |
5a738aea MS |
2067 | <p class="description">Flush data in write buffer.</p> |
2068 | <p class="code"> | |
2069 | int httpFlushWrite (<br> | |
2070 | <a href="#http_t">http_t</a> *http<br> | |
2071 | );</p> | |
2072 | <h4 class="parameters">Parameters</h4> | |
2073 | <dl> | |
2074 | <dt>http</dt> | |
ca6b43fc | 2075 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2076 | </dl> |
2077 | <h4 class="returnvalue">Return Value</h4> | |
2078 | <p class="description">Bytes written or -1 on error</p> | |
10d09e33 MS |
2079 | <h3 class="function"><a name="httpFreeCredentials">httpFreeCredentials</a></h3> |
2080 | <p class="description">Free an array of credentials.</p> | |
2081 | <p class="code"> | |
2082 | void httpFreeCredentials (<br> | |
2083 | cups_array_t *credentials<br> | |
2084 | );</p> | |
2085 | <h4 class="parameters">Parameters</h4> | |
2086 | <dl> | |
2087 | <dt>credentials</dt> | |
2088 | <dd class="description">Array of credentials</dd> | |
2089 | </dl> | |
5a738aea MS |
2090 | <h3 class="function"><a name="httpGet">httpGet</a></h3> |
2091 | <p class="description">Send a GET request to the server.</p> | |
2092 | <p class="code"> | |
2093 | int httpGet (<br> | |
2094 | <a href="#http_t">http_t</a> *http,<br> | |
2095 | const char *uri<br> | |
2096 | );</p> | |
2097 | <h4 class="parameters">Parameters</h4> | |
2098 | <dl> | |
2099 | <dt>http</dt> | |
ca6b43fc | 2100 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2101 | <dt>uri</dt> |
2102 | <dd class="description">URI to get</dd> | |
2103 | </dl> | |
2104 | <h4 class="returnvalue">Return Value</h4> | |
2105 | <p class="description">Status of call (0 = success)</p> | |
e1f19878 | 2106 | <h3 class="function"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="httpGetActivity">httpGetActivity</a></h3> |
ca6b43fc MS |
2107 | <p class="description">Get the most recent activity for a connection.</p> |
2108 | <p class="code"> | |
2109 | time_t httpGetActivity (<br> | |
2110 | <a href="#http_t">http_t</a> *http<br> | |
2111 | );</p> | |
2112 | <h4 class="parameters">Parameters</h4> | |
2113 | <dl> | |
2114 | <dt>http</dt> | |
2115 | <dd class="description">HTTP connection</dd> | |
2116 | </dl> | |
2117 | <h4 class="returnvalue">Return Value</h4> | |
2118 | <p class="description">Time of last read or write</p> | |
2119 | <h4 class="discussion">Discussion</h4> | |
2120 | <p class="discussion">The return value is the UNIX time of the last read or write. | |
2121 | ||
2122 | </p> | |
e1f19878 | 2123 | <h3 class="function"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="httpGetAddress">httpGetAddress</a></h3> |
ca6b43fc MS |
2124 | <p class="description">Get the address of the connected peer of a connection.</p> |
2125 | <p class="code"> | |
2126 | <a href="#http_addr_t">http_addr_t</a> *httpGetAddress (<br> | |
2127 | <a href="#http_t">http_t</a> *http<br> | |
2128 | );</p> | |
2129 | <h4 class="parameters">Parameters</h4> | |
2130 | <dl> | |
2131 | <dt>http</dt> | |
2132 | <dd class="description">HTTP connection</dd> | |
2133 | </dl> | |
2134 | <h4 class="returnvalue">Return Value</h4> | |
2135 | <p class="description">Connected address or <code>NULL</code></p> | |
2136 | <h4 class="discussion">Discussion</h4> | |
2137 | <p class="discussion">Returns <code>NULL</code> if the socket is currently unconnected. | |
2138 | ||
2139 | </p> | |
f3c17241 | 2140 | <h3 class="function"><span class="info"> CUPS 1.3/OS X 10.5 </span><a name="httpGetAuthString">httpGetAuthString</a></h3> |
5a738aea MS |
2141 | <p class="description">Get the current authorization string.</p> |
2142 | <p class="code"> | |
2143 | char *httpGetAuthString (<br> | |
2144 | <a href="#http_t">http_t</a> *http<br> | |
2145 | );</p> | |
2146 | <h4 class="parameters">Parameters</h4> | |
2147 | <dl> | |
2148 | <dt>http</dt> | |
ca6b43fc | 2149 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2150 | </dl> |
2151 | <h4 class="returnvalue">Return Value</h4> | |
2152 | <p class="description">Authorization string</p> | |
2153 | <h4 class="discussion">Discussion</h4> | |
2154 | <p class="discussion">The authorization string is set by cupsDoAuthentication() and | |
355e94dc MS |
2155 | httpSetAuthString(). Use httpGetAuthString() to retrieve the |
2156 | string to use with httpSetField() for the HTTP_FIELD_AUTHORIZATION | |
2157 | value. | |
2158 | ||
5a738aea | 2159 | </p> |
f3c17241 | 2160 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpGetBlocking">httpGetBlocking</a></h3> |
5a738aea MS |
2161 | <p class="description">Get the blocking/non-block state of a connection.</p> |
2162 | <p class="code"> | |
2163 | int httpGetBlocking (<br> | |
2164 | <a href="#http_t">http_t</a> *http<br> | |
2165 | );</p> | |
2166 | <h4 class="parameters">Parameters</h4> | |
2167 | <dl> | |
2168 | <dt>http</dt> | |
ca6b43fc | 2169 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2170 | </dl> |
2171 | <h4 class="returnvalue">Return Value</h4> | |
2172 | <p class="description">1 if blocking, 0 if non-blocking</p> | |
9c0e8e5d | 2173 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="httpGetContentEncoding">httpGetContentEncoding</a></h3> |
a469f8a5 MS |
2174 | <p class="description">Get a common content encoding, if any, between |
2175 | the client and server.</p> | |
2176 | <p class="code"> | |
2177 | const char *httpGetContentEncoding (<br> | |
2178 | <a href="#http_t">http_t</a> *http<br> | |
2179 | );</p> | |
2180 | <h4 class="parameters">Parameters</h4> | |
2181 | <dl> | |
2182 | <dt>http</dt> | |
ca6b43fc | 2183 | <dd class="description">HTTP connection</dd> |
a469f8a5 MS |
2184 | </dl> |
2185 | <h4 class="returnvalue">Return Value</h4> | |
2186 | <p class="description">Content-Coding value or | |
2187 | <code>NULL</code> for the identity | |
2188 | coding.</p> | |
2189 | <h4 class="discussion">Discussion</h4> | |
2190 | <p class="discussion">This function uses the value of the Accepts-Encoding HTTP header and must be | |
2191 | called after receiving a response from the server or a request from the | |
2192 | client. The value returned can be use in subsequent requests (for clients) | |
2193 | or in the response (for servers) in order to compress the content stream. | |
2194 | ||
2195 | </p> | |
f3c17241 | 2196 | <h3 class="function"><span class="info"> CUPS 1.1.19/OS X 10.3 </span><a name="httpGetCookie">httpGetCookie</a></h3> |
5a738aea MS |
2197 | <p class="description">Get any cookie data from the response.</p> |
2198 | <p class="code"> | |
2199 | const char *httpGetCookie (<br> | |
2200 | <a href="#http_t">http_t</a> *http<br> | |
2201 | );</p> | |
2202 | <h4 class="parameters">Parameters</h4> | |
2203 | <dl> | |
2204 | <dt>http</dt> | |
dd3fdd2c | 2205 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2206 | </dl> |
2207 | <h4 class="returnvalue">Return Value</h4> | |
2208 | <p class="description">Cookie data or NULL</p> | |
2209 | <h3 class="function"><span class="info"> DEPRECATED </span><a name="httpGetDateString">httpGetDateString</a></h3> | |
2210 | <p class="description">Get a formatted date/time string from a time value.</p> | |
2211 | <p class="code"> | |
2212 | const char *httpGetDateString (<br> | |
2213 | time_t t<br> | |
2214 | );</p> | |
2215 | <h4 class="parameters">Parameters</h4> | |
2216 | <dl> | |
2217 | <dt>t</dt> | |
2218 | <dd class="description">UNIX time</dd> | |
2219 | </dl> | |
2220 | <h4 class="returnvalue">Return Value</h4> | |
2221 | <p class="description">Date/time string</p> | |
f3c17241 | 2222 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpGetDateString2">httpGetDateString2</a></h3> |
5a738aea MS |
2223 | <p class="description">Get a formatted date/time string from a time value.</p> |
2224 | <p class="code"> | |
2225 | const char *httpGetDateString2 (<br> | |
2226 | time_t t,<br> | |
2227 | char *s,<br> | |
2228 | int slen<br> | |
2229 | );</p> | |
2230 | <h4 class="parameters">Parameters</h4> | |
2231 | <dl> | |
2232 | <dt>t</dt> | |
2233 | <dd class="description">UNIX time</dd> | |
2234 | <dt>s</dt> | |
2235 | <dd class="description">String buffer</dd> | |
2236 | <dt>slen</dt> | |
2237 | <dd class="description">Size of string buffer</dd> | |
2238 | </dl> | |
2239 | <h4 class="returnvalue">Return Value</h4> | |
2240 | <p class="description">Date/time string</p> | |
2241 | <h3 class="function"><a name="httpGetDateTime">httpGetDateTime</a></h3> | |
2242 | <p class="description">Get a time value from a formatted date/time string.</p> | |
2243 | <p class="code"> | |
2244 | time_t httpGetDateTime (<br> | |
2245 | const char *s<br> | |
2246 | );</p> | |
2247 | <h4 class="parameters">Parameters</h4> | |
2248 | <dl> | |
2249 | <dt>s</dt> | |
2250 | <dd class="description">Date/time string</dd> | |
2251 | </dl> | |
2252 | <h4 class="returnvalue">Return Value</h4> | |
2253 | <p class="description">UNIX time</p> | |
e1f19878 | 2254 | <h3 class="function"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="httpGetEncryption">httpGetEncryption</a></h3> |
ca6b43fc MS |
2255 | <p class="description">Get the current encryption mode of a connection.</p> |
2256 | <p class="code"> | |
2257 | <a href="#http_encryption_t">http_encryption_t</a> httpGetEncryption (<br> | |
2258 | <a href="#http_t">http_t</a> *http<br> | |
2259 | );</p> | |
2260 | <h4 class="parameters">Parameters</h4> | |
2261 | <dl> | |
2262 | <dt>http</dt> | |
2263 | <dd class="description">HTTP connection</dd> | |
2264 | </dl> | |
2265 | <h4 class="returnvalue">Return Value</h4> | |
2266 | <p class="description">Current encryption mode</p> | |
2267 | <h4 class="discussion">Discussion</h4> | |
2268 | <p class="discussion">This function returns the encryption mode for the connection. Use the | |
2269 | <a href="#httpIsEncrypted"><code>httpIsEncrypted</code></a> function to determine whether a TLS session has | |
2270 | been established. | |
2271 | ||
2272 | </p> | |
9c0e8e5d | 2273 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="httpGetExpect">httpGetExpect</a></h3> |
a469f8a5 MS |
2274 | <p class="description">Get the value of the Expect header, if any.</p> |
2275 | <p class="code"> | |
2276 | http_status_t httpGetExpect (<br> | |
2277 | <a href="#http_t">http_t</a> *http<br> | |
2278 | );</p> | |
2279 | <h4 class="parameters">Parameters</h4> | |
2280 | <dl> | |
2281 | <dt>http</dt> | |
ca6b43fc | 2282 | <dd class="description">HTTP connection</dd> |
a469f8a5 MS |
2283 | </dl> |
2284 | <h4 class="returnvalue">Return Value</h4> | |
2285 | <p class="description">Expect: status, if any</p> | |
2286 | <h4 class="discussion">Discussion</h4> | |
2287 | <p class="discussion">Returns <code>HTTP_STATUS_NONE</code> if there is no Expect header, otherwise | |
2288 | returns the expected HTTP status code, typically <code>HTTP_STATUS_CONTINUE</code>. | |
2289 | ||
2290 | </p> | |
f3c17241 | 2291 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpGetFd">httpGetFd</a></h3> |
5a738aea MS |
2292 | <p class="description">Get the file descriptor associated with a connection.</p> |
2293 | <p class="code"> | |
2294 | int httpGetFd (<br> | |
2295 | <a href="#http_t">http_t</a> *http<br> | |
2296 | );</p> | |
2297 | <h4 class="parameters">Parameters</h4> | |
2298 | <dl> | |
2299 | <dt>http</dt> | |
ca6b43fc | 2300 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2301 | </dl> |
2302 | <h4 class="returnvalue">Return Value</h4> | |
2303 | <p class="description">File descriptor or -1 if none</p> | |
2304 | <h3 class="function"><a name="httpGetField">httpGetField</a></h3> | |
2305 | <p class="description">Get a field value from a request/response.</p> | |
2306 | <p class="code"> | |
2307 | const char *httpGetField (<br> | |
2308 | <a href="#http_t">http_t</a> *http,<br> | |
79e1d494 | 2309 | <a href="#http_field_t">http_field_t</a> field<br> |
5a738aea MS |
2310 | );</p> |
2311 | <h4 class="parameters">Parameters</h4> | |
2312 | <dl> | |
2313 | <dt>http</dt> | |
ca6b43fc | 2314 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2315 | <dt>field</dt> |
2316 | <dd class="description">Field to get</dd> | |
2317 | </dl> | |
2318 | <h4 class="returnvalue">Return Value</h4> | |
2319 | <p class="description">Field value</p> | |
2320 | <h3 class="function"><span class="info"> DEPRECATED </span><a name="httpGetHostByName">httpGetHostByName</a></h3> | |
2321 | <p class="description">Lookup a hostname or IPv4 address, and return | |
2322 | address records for the specified name.</p> | |
2323 | <p class="code"> | |
2324 | struct hostent *httpGetHostByName (<br> | |
2325 | const char *name<br> | |
2326 | );</p> | |
2327 | <h4 class="parameters">Parameters</h4> | |
2328 | <dl> | |
2329 | <dt>name</dt> | |
2330 | <dd class="description">Hostname or IP address</dd> | |
2331 | </dl> | |
2332 | <h4 class="returnvalue">Return Value</h4> | |
2333 | <p class="description">Host entry</p> | |
f3c17241 | 2334 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpGetHostname">httpGetHostname</a></h3> |
5a738aea MS |
2335 | <p class="description">Get the FQDN for the connection or local system.</p> |
2336 | <p class="code"> | |
2337 | const char *httpGetHostname (<br> | |
2338 | <a href="#http_t">http_t</a> *http,<br> | |
2339 | char *s,<br> | |
2340 | int slen<br> | |
2341 | );</p> | |
2342 | <h4 class="parameters">Parameters</h4> | |
2343 | <dl> | |
2344 | <dt>http</dt> | |
2345 | <dd class="description">HTTP connection or NULL</dd> | |
2346 | <dt>s</dt> | |
2347 | <dd class="description">String buffer for name</dd> | |
2348 | <dt>slen</dt> | |
2349 | <dd class="description">Size of buffer</dd> | |
2350 | </dl> | |
2351 | <h4 class="returnvalue">Return Value</h4> | |
2352 | <p class="description">FQDN for connection or system</p> | |
2353 | <h4 class="discussion">Discussion</h4> | |
2354 | <p class="discussion">When "http" points to a connected socket, return the hostname or | |
ca6b43fc MS |
2355 | address that was used in the call to httpConnect() or httpConnectEncrypt(), |
2356 | or the address of the client for the connection from httpAcceptConnection(). | |
80ca4592 | 2357 | Otherwise, return the FQDN for the local system using both gethostname() |
2358 | and gethostbyname() to get the local hostname with domain. | |
ef416fc2 | 2359 | |
5a738aea | 2360 | </p> |
e1f19878 | 2361 | <h3 class="function"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="httpGetKeepAlive">httpGetKeepAlive</a></h3> |
ca6b43fc MS |
2362 | <p class="description">Get the current Keep-Alive state of the connection.</p> |
2363 | <p class="code"> | |
2364 | <a href="#http_keepalive_t">http_keepalive_t</a> httpGetKeepAlive (<br> | |
2365 | <a href="#http_t">http_t</a> *http<br> | |
2366 | );</p> | |
2367 | <h4 class="parameters">Parameters</h4> | |
2368 | <dl> | |
2369 | <dt>http</dt> | |
2370 | <dd class="description">HTTP connection</dd> | |
2371 | </dl> | |
2372 | <h4 class="returnvalue">Return Value</h4> | |
2373 | <p class="description">Keep-Alive state</p> | |
5a738aea MS |
2374 | <h3 class="function"><span class="info"> DEPRECATED </span><a name="httpGetLength">httpGetLength</a></h3> |
2375 | <p class="description">Get the amount of data remaining from the | |
2376 | content-length or transfer-encoding fields.</p> | |
2377 | <p class="code"> | |
2378 | int httpGetLength (<br> | |
2379 | <a href="#http_t">http_t</a> *http<br> | |
2380 | );</p> | |
2381 | <h4 class="parameters">Parameters</h4> | |
2382 | <dl> | |
2383 | <dt>http</dt> | |
ca6b43fc | 2384 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2385 | </dl> |
2386 | <h4 class="returnvalue">Return Value</h4> | |
2387 | <p class="description">Content length</p> | |
2388 | <h4 class="discussion">Discussion</h4> | |
2389 | <p class="discussion">This function is deprecated and will not return lengths larger than | |
ef416fc2 | 2390 | 2^31 - 1; use httpGetLength2() instead. |
2391 | ||
5a738aea | 2392 | </p> |
f3c17241 | 2393 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpGetLength2">httpGetLength2</a></h3> |
5a738aea MS |
2394 | <p class="description">Get the amount of data remaining from the |
2395 | content-length or transfer-encoding fields.</p> | |
2396 | <p class="code"> | |
2397 | off_t httpGetLength2 (<br> | |
2398 | <a href="#http_t">http_t</a> *http<br> | |
2399 | );</p> | |
2400 | <h4 class="parameters">Parameters</h4> | |
2401 | <dl> | |
2402 | <dt>http</dt> | |
ca6b43fc | 2403 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2404 | </dl> |
2405 | <h4 class="returnvalue">Return Value</h4> | |
2406 | <p class="description">Content length</p> | |
2407 | <h4 class="discussion">Discussion</h4> | |
2408 | <p class="discussion">This function returns the complete content length, even for | |
ecdc0628 | 2409 | content larger than 2^31 - 1. |
2410 | ||
ca6b43fc | 2411 | </p> |
e1f19878 | 2412 | <h3 class="function"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="httpGetPending">httpGetPending</a></h3> |
ca6b43fc MS |
2413 | <p class="description">Get the number of bytes that are buffered for writing.</p> |
2414 | <p class="code"> | |
2415 | size_t httpGetPending (<br> | |
2416 | <a href="#http_t">http_t</a> *http<br> | |
2417 | );</p> | |
2418 | <h4 class="parameters">Parameters</h4> | |
2419 | <dl> | |
2420 | <dt>http</dt> | |
2421 | <dd class="description">HTTP connection</dd> | |
2422 | </dl> | |
2423 | <h4 class="returnvalue">Return Value</h4> | |
2424 | <p class="description">Number of bytes buffered</p> | |
e1f19878 | 2425 | <h3 class="function"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="httpGetReady">httpGetReady</a></h3> |
ca6b43fc MS |
2426 | <p class="description">Get the number of bytes that can be read without blocking.</p> |
2427 | <p class="code"> | |
2428 | size_t httpGetReady (<br> | |
2429 | <a href="#http_t">http_t</a> *http<br> | |
2430 | );</p> | |
2431 | <h4 class="parameters">Parameters</h4> | |
2432 | <dl> | |
2433 | <dt>http</dt> | |
2434 | <dd class="description">HTTP connection</dd> | |
2435 | </dl> | |
2436 | <h4 class="returnvalue">Return Value</h4> | |
2437 | <p class="description">Number of bytes available</p> | |
e1f19878 | 2438 | <h3 class="function"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="httpGetRemaining">httpGetRemaining</a></h3> |
ca6b43fc MS |
2439 | <p class="description">Get the number of remaining bytes in the message |
2440 | body or current chunk.</p> | |
2441 | <p class="code"> | |
2442 | size_t httpGetRemaining (<br> | |
2443 | <a href="#http_t">http_t</a> *http<br> | |
2444 | );</p> | |
2445 | <h4 class="parameters">Parameters</h4> | |
2446 | <dl> | |
2447 | <dt>http</dt> | |
2448 | <dd class="description">HTTP connection</dd> | |
2449 | </dl> | |
2450 | <h4 class="returnvalue">Return Value</h4> | |
2451 | <p class="description">Remaining bytes</p> | |
2452 | <h4 class="discussion">Discussion</h4> | |
2453 | <p class="discussion">The <a href="#httpIsChunked"><code>httpIsChunked</code></a> function can be used to determine whether the | |
2454 | message body is chunked or fixed-length. | |
2455 | ||
5a738aea | 2456 | </p> |
a2326b5b MS |
2457 | <h3 class="function"><a name="httpGetState">httpGetState</a></h3> |
2458 | <p class="description">Get the current state of the HTTP request.</p> | |
2459 | <p class="code"> | |
2460 | <a href="#http_state_t">http_state_t</a> httpGetState (<br> | |
2461 | <a href="#http_t">http_t</a> *http<br> | |
2462 | );</p> | |
2463 | <h4 class="parameters">Parameters</h4> | |
2464 | <dl> | |
2465 | <dt>http</dt> | |
ca6b43fc | 2466 | <dd class="description">HTTP connection</dd> |
a2326b5b MS |
2467 | </dl> |
2468 | <h4 class="returnvalue">Return Value</h4> | |
2469 | <p class="description">HTTP state</p> | |
f3c17241 | 2470 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpGetStatus">httpGetStatus</a></h3> |
5a738aea MS |
2471 | <p class="description">Get the status of the last HTTP request.</p> |
2472 | <p class="code"> | |
a469f8a5 | 2473 | http_status_t httpGetStatus (<br> |
5a738aea MS |
2474 | <a href="#http_t">http_t</a> *http<br> |
2475 | );</p> | |
2476 | <h4 class="parameters">Parameters</h4> | |
2477 | <dl> | |
2478 | <dt>http</dt> | |
ca6b43fc | 2479 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2480 | </dl> |
2481 | <h4 class="returnvalue">Return Value</h4> | |
2482 | <p class="description">HTTP status</p> | |
2483 | <h3 class="function"><span class="info"> DEPRECATED </span><a name="httpGetSubField">httpGetSubField</a></h3> | |
2484 | <p class="description">Get a sub-field value.</p> | |
2485 | <p class="code"> | |
2486 | char *httpGetSubField (<br> | |
2487 | <a href="#http_t">http_t</a> *http,<br> | |
79e1d494 | 2488 | <a href="#http_field_t">http_field_t</a> field,<br> |
5a738aea MS |
2489 | const char *name,<br> |
2490 | char *value<br> | |
2491 | );</p> | |
2492 | <h4 class="parameters">Parameters</h4> | |
2493 | <dl> | |
2494 | <dt>http</dt> | |
ca6b43fc | 2495 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2496 | <dt>field</dt> |
2497 | <dd class="description">Field index</dd> | |
2498 | <dt>name</dt> | |
2499 | <dd class="description">Name of sub-field</dd> | |
2500 | <dt>value</dt> | |
2501 | <dd class="description">Value string</dd> | |
2502 | </dl> | |
2503 | <h4 class="returnvalue">Return Value</h4> | |
2504 | <p class="description">Value or NULL</p> | |
f3c17241 | 2505 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpGetSubField2">httpGetSubField2</a></h3> |
5a738aea MS |
2506 | <p class="description">Get a sub-field value.</p> |
2507 | <p class="code"> | |
2508 | char *httpGetSubField2 (<br> | |
2509 | <a href="#http_t">http_t</a> *http,<br> | |
79e1d494 | 2510 | <a href="#http_field_t">http_field_t</a> field,<br> |
5a738aea MS |
2511 | const char *name,<br> |
2512 | char *value,<br> | |
2513 | int valuelen<br> | |
2514 | );</p> | |
2515 | <h4 class="parameters">Parameters</h4> | |
2516 | <dl> | |
2517 | <dt>http</dt> | |
ca6b43fc | 2518 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2519 | <dt>field</dt> |
2520 | <dd class="description">Field index</dd> | |
2521 | <dt>name</dt> | |
2522 | <dd class="description">Name of sub-field</dd> | |
2523 | <dt>value</dt> | |
2524 | <dd class="description">Value string</dd> | |
2525 | <dt>valuelen</dt> | |
2526 | <dd class="description">Size of value buffer</dd> | |
2527 | </dl> | |
2528 | <h4 class="returnvalue">Return Value</h4> | |
2529 | <p class="description">Value or NULL</p> | |
a2326b5b MS |
2530 | <h3 class="function"><a name="httpGetVersion">httpGetVersion</a></h3> |
2531 | <p class="description">Get the HTTP version at the other end.</p> | |
2532 | <p class="code"> | |
2533 | <a href="#http_version_t">http_version_t</a> httpGetVersion (<br> | |
2534 | <a href="#http_t">http_t</a> *http<br> | |
2535 | );</p> | |
2536 | <h4 class="parameters">Parameters</h4> | |
2537 | <dl> | |
2538 | <dt>http</dt> | |
ca6b43fc | 2539 | <dd class="description">HTTP connection</dd> |
a2326b5b MS |
2540 | </dl> |
2541 | <h4 class="returnvalue">Return Value</h4> | |
2542 | <p class="description">Version number</p> | |
5a738aea MS |
2543 | <h3 class="function"><a name="httpGets">httpGets</a></h3> |
2544 | <p class="description">Get a line of text from a HTTP connection.</p> | |
2545 | <p class="code"> | |
2546 | char *httpGets (<br> | |
2547 | char *line,<br> | |
2548 | int length,<br> | |
2549 | <a href="#http_t">http_t</a> *http<br> | |
2550 | );</p> | |
2551 | <h4 class="parameters">Parameters</h4> | |
2552 | <dl> | |
2553 | <dt>line</dt> | |
2554 | <dd class="description">Line to read into</dd> | |
2555 | <dt>length</dt> | |
2556 | <dd class="description">Max length of buffer</dd> | |
2557 | <dt>http</dt> | |
ca6b43fc | 2558 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2559 | </dl> |
2560 | <h4 class="returnvalue">Return Value</h4> | |
2561 | <p class="description">Line or NULL</p> | |
2562 | <h3 class="function"><a name="httpHead">httpHead</a></h3> | |
2563 | <p class="description">Send a HEAD request to the server.</p> | |
2564 | <p class="code"> | |
2565 | int httpHead (<br> | |
2566 | <a href="#http_t">http_t</a> *http,<br> | |
2567 | const char *uri<br> | |
2568 | );</p> | |
2569 | <h4 class="parameters">Parameters</h4> | |
2570 | <dl> | |
2571 | <dt>http</dt> | |
ca6b43fc | 2572 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2573 | <dt>uri</dt> |
2574 | <dd class="description">URI for head</dd> | |
2575 | </dl> | |
2576 | <h4 class="returnvalue">Return Value</h4> | |
2577 | <p class="description">Status of call (0 = success)</p> | |
2578 | <h3 class="function"><a name="httpInitialize">httpInitialize</a></h3> | |
2579 | <p class="description">Initialize the HTTP interface library and set the | |
2580 | default HTTP proxy (if any).</p> | |
2581 | <p class="code"> | |
2582 | void httpInitialize (void);</p> | |
e1f19878 | 2583 | <h3 class="function"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="httpIsChunked">httpIsChunked</a></h3> |
ca6b43fc MS |
2584 | <p class="description">Report whether a message body is chunked.</p> |
2585 | <p class="code"> | |
2586 | int httpIsChunked (<br> | |
2587 | <a href="#http_t">http_t</a> *http<br> | |
2588 | );</p> | |
2589 | <h4 class="parameters">Parameters</h4> | |
2590 | <dl> | |
2591 | <dt>http</dt> | |
2592 | <dd class="description">HTTP connection</dd> | |
2593 | </dl> | |
2594 | <h4 class="returnvalue">Return Value</h4> | |
2595 | <p class="description">1 if chunked, 0 if not</p> | |
2596 | <h4 class="discussion">Discussion</h4> | |
2597 | <p class="discussion">This function returns non-zero if the message body is composed of | |
2598 | variable-length chunks. | |
2599 | ||
2600 | </p> | |
e1f19878 | 2601 | <h3 class="function"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="httpIsEncrypted">httpIsEncrypted</a></h3> |
ca6b43fc MS |
2602 | <p class="description">Report whether a connection is encrypted.</p> |
2603 | <p class="code"> | |
2604 | int httpIsEncrypted (<br> | |
2605 | <a href="#http_t">http_t</a> *http<br> | |
2606 | );</p> | |
2607 | <h4 class="parameters">Parameters</h4> | |
2608 | <dl> | |
2609 | <dt>http</dt> | |
2610 | <dd class="description">HTTP connection</dd> | |
2611 | </dl> | |
2612 | <h4 class="returnvalue">Return Value</h4> | |
2613 | <p class="description">1 if encrypted, 0 if not</p> | |
2614 | <h4 class="discussion">Discussion</h4> | |
2615 | <p class="discussion">This function returns non-zero if the connection is currently encrypted. | |
2616 | ||
2617 | </p> | |
5a738aea MS |
2618 | <h3 class="function"><a name="httpMD5">httpMD5</a></h3> |
2619 | <p class="description">Compute the MD5 sum of the username:group:password.</p> | |
2620 | <p class="code"> | |
2621 | char *httpMD5 (<br> | |
2622 | const char *username,<br> | |
2623 | const char *realm,<br> | |
2624 | const char *passwd,<br> | |
2625 | char md5[33]<br> | |
2626 | );</p> | |
2627 | <h4 class="parameters">Parameters</h4> | |
2628 | <dl> | |
2629 | <dt>username</dt> | |
2630 | <dd class="description">User name</dd> | |
2631 | <dt>realm</dt> | |
2632 | <dd class="description">Realm name</dd> | |
2633 | <dt>passwd</dt> | |
2634 | <dd class="description">Password string</dd> | |
2635 | <dt>md5[33]</dt> | |
2636 | <dd class="description">MD5 string</dd> | |
2637 | </dl> | |
2638 | <h4 class="returnvalue">Return Value</h4> | |
2639 | <p class="description">MD5 sum</p> | |
2640 | <h3 class="function"><a name="httpMD5Final">httpMD5Final</a></h3> | |
2641 | <p class="description">Combine the MD5 sum of the username, group, and password | |
ef416fc2 | 2642 | with the server-supplied nonce value, method, and |
5a738aea MS |
2643 | request-uri.</p> |
2644 | <p class="code"> | |
2645 | char *httpMD5Final (<br> | |
2646 | const char *nonce,<br> | |
2647 | const char *method,<br> | |
2648 | const char *resource,<br> | |
2649 | char md5[33]<br> | |
2650 | );</p> | |
2651 | <h4 class="parameters">Parameters</h4> | |
2652 | <dl> | |
2653 | <dt>nonce</dt> | |
2654 | <dd class="description">Server nonce value</dd> | |
2655 | <dt>method</dt> | |
2656 | <dd class="description">METHOD (GET, POST, etc.)</dd> | |
2657 | <dt>resource</dt> | |
2658 | <dd class="description">Resource path</dd> | |
2659 | <dt>md5[33]</dt> | |
2660 | <dd class="description">MD5 sum</dd> | |
2661 | </dl> | |
2662 | <h4 class="returnvalue">Return Value</h4> | |
2663 | <p class="description">New sum</p> | |
2664 | <h3 class="function"><a name="httpMD5String">httpMD5String</a></h3> | |
2665 | <p class="description">Convert an MD5 sum to a character string.</p> | |
2666 | <p class="code"> | |
2667 | char *httpMD5String (<br> | |
2668 | const unsigned char *sum,<br> | |
2669 | char md5[33]<br> | |
2670 | );</p> | |
2671 | <h4 class="parameters">Parameters</h4> | |
2672 | <dl> | |
2673 | <dt>sum</dt> | |
2674 | <dd class="description">MD5 sum data</dd> | |
2675 | <dt>md5[33]</dt> | |
2676 | <dd class="description">MD5 sum in hex</dd> | |
2677 | </dl> | |
2678 | <h4 class="returnvalue">Return Value</h4> | |
2679 | <p class="description">MD5 sum in hex</p> | |
2680 | <h3 class="function"><a name="httpOptions">httpOptions</a></h3> | |
2681 | <p class="description">Send an OPTIONS request to the server.</p> | |
2682 | <p class="code"> | |
2683 | int httpOptions (<br> | |
2684 | <a href="#http_t">http_t</a> *http,<br> | |
2685 | const char *uri<br> | |
2686 | );</p> | |
2687 | <h4 class="parameters">Parameters</h4> | |
2688 | <dl> | |
2689 | <dt>http</dt> | |
ca6b43fc | 2690 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2691 | <dt>uri</dt> |
2692 | <dd class="description">URI for options</dd> | |
2693 | </dl> | |
2694 | <h4 class="returnvalue">Return Value</h4> | |
2695 | <p class="description">Status of call (0 = success)</p> | |
9c0e8e5d | 2696 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="httpPeek">httpPeek</a></h3> |
a469f8a5 MS |
2697 | <p class="description">Peek at data from a HTTP connection.</p> |
2698 | <p class="code"> | |
2699 | ssize_t httpPeek (<br> | |
2700 | <a href="#http_t">http_t</a> *http,<br> | |
2701 | char *buffer,<br> | |
2702 | size_t length<br> | |
2703 | );</p> | |
2704 | <h4 class="parameters">Parameters</h4> | |
2705 | <dl> | |
2706 | <dt>http</dt> | |
ca6b43fc | 2707 | <dd class="description">HTTP connection</dd> |
a469f8a5 MS |
2708 | <dt>buffer</dt> |
2709 | <dd class="description">Buffer for data</dd> | |
2710 | <dt>length</dt> | |
2711 | <dd class="description">Maximum number of bytes</dd> | |
2712 | </dl> | |
2713 | <h4 class="returnvalue">Return Value</h4> | |
2714 | <p class="description">Number of bytes copied</p> | |
2715 | <h4 class="discussion">Discussion</h4> | |
2716 | <p class="discussion">This function copies available data from the given HTTP connection, reading | |
2717 | a buffer as needed. The data is still available for reading using | |
2718 | <a href="#httpRead"><code>httpRead</code></a> or <a href="#httpRead2"><code>httpRead2</code></a>.<br> | |
2719 | <br> | |
2720 | For non-blocking connections the usual timeouts apply. | |
2721 | ||
2722 | </p> | |
5a738aea MS |
2723 | <h3 class="function"><a name="httpPost">httpPost</a></h3> |
2724 | <p class="description">Send a POST request to the server.</p> | |
2725 | <p class="code"> | |
2726 | int httpPost (<br> | |
2727 | <a href="#http_t">http_t</a> *http,<br> | |
2728 | const char *uri<br> | |
2729 | );</p> | |
2730 | <h4 class="parameters">Parameters</h4> | |
2731 | <dl> | |
2732 | <dt>http</dt> | |
ca6b43fc | 2733 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2734 | <dt>uri</dt> |
2735 | <dd class="description">URI for post</dd> | |
2736 | </dl> | |
2737 | <h4 class="returnvalue">Return Value</h4> | |
2738 | <p class="description">Status of call (0 = success)</p> | |
2739 | <h3 class="function"><a name="httpPut">httpPut</a></h3> | |
2740 | <p class="description">Send a PUT request to the server.</p> | |
2741 | <p class="code"> | |
2742 | int httpPut (<br> | |
2743 | <a href="#http_t">http_t</a> *http,<br> | |
2744 | const char *uri<br> | |
2745 | );</p> | |
2746 | <h4 class="parameters">Parameters</h4> | |
2747 | <dl> | |
2748 | <dt>http</dt> | |
ca6b43fc | 2749 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2750 | <dt>uri</dt> |
2751 | <dd class="description">URI to put</dd> | |
2752 | </dl> | |
2753 | <h4 class="returnvalue">Return Value</h4> | |
2754 | <p class="description">Status of call (0 = success)</p> | |
2755 | <h3 class="function"><span class="info"> DEPRECATED </span><a name="httpRead">httpRead</a></h3> | |
2756 | <p class="description">Read data from a HTTP connection.</p> | |
2757 | <p class="code"> | |
2758 | int httpRead (<br> | |
2759 | <a href="#http_t">http_t</a> *http,<br> | |
2760 | char *buffer,<br> | |
2761 | int length<br> | |
2762 | );</p> | |
2763 | <h4 class="parameters">Parameters</h4> | |
2764 | <dl> | |
2765 | <dt>http</dt> | |
ca6b43fc | 2766 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2767 | <dt>buffer</dt> |
2768 | <dd class="description">Buffer for data</dd> | |
2769 | <dt>length</dt> | |
2770 | <dd class="description">Maximum number of bytes</dd> | |
2771 | </dl> | |
2772 | <h4 class="returnvalue">Return Value</h4> | |
2773 | <p class="description">Number of bytes read</p> | |
2774 | <h4 class="discussion">Discussion</h4> | |
2775 | <p class="discussion">This function is deprecated. Use the httpRead2() function which can | |
ecdc0628 | 2776 | read more than 2GB of data. |
2777 | ||
5a738aea | 2778 | </p> |
f3c17241 | 2779 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpRead2">httpRead2</a></h3> |
5a738aea MS |
2780 | <p class="description">Read data from a HTTP connection.</p> |
2781 | <p class="code"> | |
2782 | ssize_t httpRead2 (<br> | |
2783 | <a href="#http_t">http_t</a> *http,<br> | |
2784 | char *buffer,<br> | |
2785 | size_t length<br> | |
2786 | );</p> | |
2787 | <h4 class="parameters">Parameters</h4> | |
2788 | <dl> | |
2789 | <dt>http</dt> | |
ca6b43fc | 2790 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2791 | <dt>buffer</dt> |
2792 | <dd class="description">Buffer for data</dd> | |
2793 | <dt>length</dt> | |
2794 | <dd class="description">Maximum number of bytes</dd> | |
2795 | </dl> | |
2796 | <h4 class="returnvalue">Return Value</h4> | |
2797 | <p class="description">Number of bytes read</p> | |
9c0e8e5d | 2798 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="httpReadRequest">httpReadRequest</a></h3> |
a469f8a5 MS |
2799 | <p class="description">Read a HTTP request from a connection.</p> |
2800 | <p class="code"> | |
2801 | <a href="#http_state_t">http_state_t</a> httpReadRequest (<br> | |
2802 | <a href="#http_t">http_t</a> *http,<br> | |
2803 | char *uri,<br> | |
2804 | size_t urilen<br> | |
2805 | );</p> | |
2806 | <h4 class="parameters">Parameters</h4> | |
2807 | <dl> | |
2808 | <dt>http</dt> | |
2809 | <dd class="description">HTTP connection</dd> | |
2810 | <dt>uri</dt> | |
2811 | <dd class="description">URI buffer</dd> | |
2812 | <dt>urilen</dt> | |
2813 | <dd class="description">Size of URI buffer</dd> | |
2814 | </dl> | |
2815 | <h4 class="returnvalue">Return Value</h4> | |
2816 | <p class="description">New state of connection</p> | |
2817 | <h3 class="function"><span class="info"> DEPRECATED </span><a name="httpReconnect">httpReconnect</a></h3> | |
5a738aea MS |
2818 | <p class="description">Reconnect to a HTTP server.</p> |
2819 | <p class="code"> | |
2820 | int httpReconnect (<br> | |
2821 | <a href="#http_t">http_t</a> *http<br> | |
2822 | );</p> | |
2823 | <h4 class="parameters">Parameters</h4> | |
2824 | <dl> | |
2825 | <dt>http</dt> | |
ca6b43fc | 2826 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
2827 | </dl> |
2828 | <h4 class="returnvalue">Return Value</h4> | |
2829 | <p class="description">0 on success, non-zero on failure</p> | |
a469f8a5 MS |
2830 | <h4 class="discussion">Discussion</h4> |
2831 | <p class="discussion">This function is deprecated. Please use the <a href="#httpReconnect2"><code>httpReconnect2</code></a> function | |
2832 | instead. | |
2833 | ||
2834 | </p> | |
3e7fe0ca MS |
2835 | <h3 class="function"><a name="httpReconnect2">httpReconnect2</a></h3> |
2836 | <p class="description">Reconnect to a HTTP server with timeout and optional | |
2837 | cancel.</p> | |
2838 | <p class="code"> | |
2839 | int httpReconnect2 (<br> | |
2840 | <a href="#http_t">http_t</a> *http,<br> | |
2841 | int msec,<br> | |
2842 | int *cancel<br> | |
2843 | );</p> | |
2844 | <h4 class="parameters">Parameters</h4> | |
2845 | <dl> | |
2846 | <dt>http</dt> | |
ca6b43fc | 2847 | <dd class="description">HTTP connection</dd> |
3e7fe0ca MS |
2848 | <dt>msec</dt> |
2849 | <dd class="description">Timeout in milliseconds</dd> | |
2850 | <dt>cancel</dt> | |
2851 | <dd class="description">Pointer to "cancel" variable</dd> | |
2852 | </dl> | |
2853 | <h4 class="returnvalue">Return Value</h4> | |
2854 | <p class="description">0 on success, non-zero on failure</p> | |
e1f19878 | 2855 | <h3 class="function"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="httpResolveHostname">httpResolveHostname</a></h3> |
ca6b43fc MS |
2856 | <p class="description">Resolve the hostname of the HTTP connection |
2857 | address.</p> | |
2858 | <p class="code"> | |
2859 | const char *httpResolveHostname (<br> | |
2860 | <a href="#http_t">http_t</a> *http,<br> | |
2861 | char *buffer,<br> | |
2862 | size_t bufsize<br> | |
2863 | );</p> | |
2864 | <h4 class="parameters">Parameters</h4> | |
2865 | <dl> | |
2866 | <dt>http</dt> | |
2867 | <dd class="description">HTTP connection</dd> | |
2868 | <dt>buffer</dt> | |
2869 | <dd class="description">Hostname buffer</dd> | |
2870 | <dt>bufsize</dt> | |
2871 | <dd class="description">Size of buffer</dd> | |
2872 | </dl> | |
2873 | <h4 class="returnvalue">Return Value</h4> | |
2874 | <p class="description">Resolved hostname or <code>NULL</code></p> | |
5a738aea MS |
2875 | <h3 class="function"><span class="info"> DEPRECATED </span><a name="httpSeparate">httpSeparate</a></h3> |
2876 | <p class="description">Separate a Universal Resource Identifier into its | |
2877 | components.</p> | |
2878 | <p class="code"> | |
2879 | void httpSeparate (<br> | |
2880 | const char *uri,<br> | |
2881 | char *scheme,<br> | |
2882 | char *username,<br> | |
2883 | char *host,<br> | |
2884 | int *port,<br> | |
2885 | char *resource<br> | |
2886 | );</p> | |
2887 | <h4 class="parameters">Parameters</h4> | |
2888 | <dl> | |
2889 | <dt>uri</dt> | |
2890 | <dd class="description">Universal Resource Identifier</dd> | |
2891 | <dt>scheme</dt> | |
2892 | <dd class="description">Scheme [32] (http, https, etc.)</dd> | |
2893 | <dt>username</dt> | |
2894 | <dd class="description">Username [1024]</dd> | |
2895 | <dt>host</dt> | |
2896 | <dd class="description">Hostname [1024]</dd> | |
2897 | <dt>port</dt> | |
2898 | <dd class="description">Port number to use</dd> | |
2899 | <dt>resource</dt> | |
2900 | <dd class="description">Resource/filename [1024]</dd> | |
2901 | </dl> | |
2902 | <h4 class="discussion">Discussion</h4> | |
2903 | <p class="discussion">This function is deprecated; use the httpSeparateURI() function instead. | |
2904 | ||
2905 | </p> | |
f3c17241 | 2906 | <h3 class="function"><span class="info"> CUPS 1.1.21/OS X 10.4 </span><a name="httpSeparate2">httpSeparate2</a></h3> |
5a738aea MS |
2907 | <p class="description">Separate a Universal Resource Identifier into its |
2908 | components.</p> | |
2909 | <p class="code"> | |
2910 | void httpSeparate2 (<br> | |
2911 | const char *uri,<br> | |
2912 | char *scheme,<br> | |
2913 | int schemelen,<br> | |
2914 | char *username,<br> | |
2915 | int usernamelen,<br> | |
2916 | char *host,<br> | |
2917 | int hostlen,<br> | |
2918 | int *port,<br> | |
2919 | char *resource,<br> | |
2920 | int resourcelen<br> | |
2921 | );</p> | |
2922 | <h4 class="parameters">Parameters</h4> | |
2923 | <dl> | |
2924 | <dt>uri</dt> | |
2925 | <dd class="description">Universal Resource Identifier</dd> | |
2926 | <dt>scheme</dt> | |
2927 | <dd class="description">Scheme (http, https, etc.)</dd> | |
2928 | <dt>schemelen</dt> | |
2929 | <dd class="description">Size of scheme buffer</dd> | |
2930 | <dt>username</dt> | |
2931 | <dd class="description">Username</dd> | |
2932 | <dt>usernamelen</dt> | |
2933 | <dd class="description">Size of username buffer</dd> | |
2934 | <dt>host</dt> | |
2935 | <dd class="description">Hostname</dd> | |
2936 | <dt>hostlen</dt> | |
2937 | <dd class="description">Size of hostname buffer</dd> | |
2938 | <dt>port</dt> | |
2939 | <dd class="description">Port number to use</dd> | |
2940 | <dt>resource</dt> | |
2941 | <dd class="description">Resource/filename</dd> | |
2942 | <dt>resourcelen</dt> | |
2943 | <dd class="description">Size of resource buffer</dd> | |
2944 | </dl> | |
2945 | <h4 class="discussion">Discussion</h4> | |
2946 | <p class="discussion">This function is deprecated; use the httpSeparateURI() function instead. | |
2947 | ||
2948 | ||
2949 | </p> | |
f3c17241 | 2950 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpSeparateURI">httpSeparateURI</a></h3> |
5a738aea MS |
2951 | <p class="description">Separate a Universal Resource Identifier into its |
2952 | components.</p> | |
2953 | <p class="code"> | |
79e1d494 MS |
2954 | <a href="#http_uri_status_t">http_uri_status_t</a> httpSeparateURI (<br> |
2955 | <a href="#http_uri_coding_t">http_uri_coding_t</a> decoding,<br> | |
5a738aea MS |
2956 | const char *uri,<br> |
2957 | char *scheme,<br> | |
2958 | int schemelen,<br> | |
2959 | char *username,<br> | |
2960 | int usernamelen,<br> | |
2961 | char *host,<br> | |
2962 | int hostlen,<br> | |
2963 | int *port,<br> | |
2964 | char *resource,<br> | |
2965 | int resourcelen<br> | |
2966 | );</p> | |
2967 | <h4 class="parameters">Parameters</h4> | |
2968 | <dl> | |
2969 | <dt>decoding</dt> | |
2970 | <dd class="description">Decoding flags</dd> | |
2971 | <dt>uri</dt> | |
2972 | <dd class="description">Universal Resource Identifier</dd> | |
2973 | <dt>scheme</dt> | |
2974 | <dd class="description">Scheme (http, https, etc.)</dd> | |
2975 | <dt>schemelen</dt> | |
2976 | <dd class="description">Size of scheme buffer</dd> | |
2977 | <dt>username</dt> | |
2978 | <dd class="description">Username</dd> | |
2979 | <dt>usernamelen</dt> | |
2980 | <dd class="description">Size of username buffer</dd> | |
2981 | <dt>host</dt> | |
2982 | <dd class="description">Hostname</dd> | |
2983 | <dt>hostlen</dt> | |
2984 | <dd class="description">Size of hostname buffer</dd> | |
2985 | <dt>port</dt> | |
2986 | <dd class="description">Port number to use</dd> | |
2987 | <dt>resource</dt> | |
2988 | <dd class="description">Resource/filename</dd> | |
2989 | <dt>resourcelen</dt> | |
2990 | <dd class="description">Size of resource buffer</dd> | |
2991 | </dl> | |
2992 | <h4 class="returnvalue">Return Value</h4> | |
2993 | <p class="description">Result of separation</p> | |
f3c17241 | 2994 | <h3 class="function"><span class="info"> CUPS 1.3/OS X 10.5 </span><a name="httpSetAuthString">httpSetAuthString</a></h3> |
5a738aea MS |
2995 | <p class="description">Set the current authorization string.</p> |
2996 | <p class="code"> | |
2997 | void httpSetAuthString (<br> | |
2998 | <a href="#http_t">http_t</a> *http,<br> | |
2999 | const char *scheme,<br> | |
3000 | const char *data<br> | |
3001 | );</p> | |
3002 | <h4 class="parameters">Parameters</h4> | |
3003 | <dl> | |
3004 | <dt>http</dt> | |
ca6b43fc | 3005 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
3006 | <dt>scheme</dt> |
3007 | <dd class="description">Auth scheme (NULL to clear it)</dd> | |
3008 | <dt>data</dt> | |
3009 | <dd class="description">Auth data (NULL for none)</dd> | |
3010 | </dl> | |
3011 | <h4 class="discussion">Discussion</h4> | |
3012 | <p class="discussion">This function just stores a copy of the current authorization string in | |
355e94dc MS |
3013 | the HTTP connection object. You must still call httpSetField() to set |
3014 | HTTP_FIELD_AUTHORIZATION prior to issuing a HTTP request using httpGet(), | |
3015 | httpHead(), httpOptions(), httpPost, or httpPut(). | |
3016 | ||
5a738aea | 3017 | </p> |
f3c17241 | 3018 | <h3 class="function"><span class="info"> CUPS 1.1.19/OS X 10.3 </span><a name="httpSetCookie">httpSetCookie</a></h3> |
10d09e33 | 3019 | <p class="description">Set the cookie value(s).</p> |
5a738aea MS |
3020 | <p class="code"> |
3021 | void httpSetCookie (<br> | |
3022 | <a href="#http_t">http_t</a> *http,<br> | |
3023 | const char *cookie<br> | |
3024 | );</p> | |
3025 | <h4 class="parameters">Parameters</h4> | |
3026 | <dl> | |
3027 | <dt>http</dt> | |
3028 | <dd class="description">Connection</dd> | |
3029 | <dt>cookie</dt> | |
3030 | <dd class="description">Cookie string</dd> | |
3031 | </dl> | |
f3c17241 | 3032 | <h3 class="function"><span class="info"> CUPS 1.5/OS X 10.7 </span><a name="httpSetCredentials">httpSetCredentials</a></h3> |
10d09e33 MS |
3033 | <p class="description">Set the credentials associated with an encrypted |
3034 | connection.</p> | |
3035 | <p class="code"> | |
3036 | int httpSetCredentials (<br> | |
3037 | <a href="#http_t">http_t</a> *http,<br> | |
3038 | cups_array_t *credentials<br> | |
3039 | );</p> | |
3040 | <h4 class="parameters">Parameters</h4> | |
3041 | <dl> | |
3042 | <dt>http</dt> | |
ca6b43fc | 3043 | <dd class="description">HTTP connection</dd> |
10d09e33 MS |
3044 | <dt>credentials</dt> |
3045 | <dd class="description">Array of credentials</dd> | |
3046 | </dl> | |
3047 | <h4 class="returnvalue">Return Value</h4> | |
3048 | <p class="description">Status of call (0 = success)</p> | |
9c0e8e5d | 3049 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="httpSetDefaultField">httpSetDefaultField</a></h3> |
db8b865d MS |
3050 | <p class="description">Set the default value of an HTTP header.</p> |
3051 | <p class="code"> | |
3052 | void httpSetDefaultField (<br> | |
3053 | <a href="#http_t">http_t</a> *http,<br> | |
3054 | <a href="#http_field_t">http_field_t</a> field,<br> | |
3055 | const char *value<br> | |
3056 | );</p> | |
3057 | <h4 class="parameters">Parameters</h4> | |
3058 | <dl> | |
3059 | <dt>http</dt> | |
ca6b43fc | 3060 | <dd class="description">HTTP connection</dd> |
db8b865d MS |
3061 | <dt>field</dt> |
3062 | <dd class="description">Field index</dd> | |
3063 | <dt>value</dt> | |
3064 | <dd class="description">Value</dd> | |
3065 | </dl> | |
3066 | <h4 class="discussion">Discussion</h4> | |
6961465f MS |
3067 | <p class="discussion">Currently only <code>HTTP_FIELD_ACCEPT_ENCODING</code>, <code>HTTP_FIELD_SERVER</code>, |
3068 | and <code>HTTP_FIELD_USER_AGENT</code> can be set. | |
db8b865d MS |
3069 | |
3070 | </p> | |
f3c17241 | 3071 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpSetExpect">httpSetExpect</a></h3> |
5a738aea MS |
3072 | <p class="description">Set the Expect: header in a request.</p> |
3073 | <p class="code"> | |
3074 | void httpSetExpect (<br> | |
3075 | <a href="#http_t">http_t</a> *http,<br> | |
a469f8a5 | 3076 | http_status_t expect<br> |
5a738aea MS |
3077 | );</p> |
3078 | <h4 class="parameters">Parameters</h4> | |
3079 | <dl> | |
3080 | <dt>http</dt> | |
ca6b43fc | 3081 | <dd class="description">HTTP connection</dd> |
5a738aea | 3082 | <dt>expect</dt> |
a469f8a5 | 3083 | <dd class="description">HTTP status to expect |
6961465f | 3084 | (<code>HTTP_STATUS_CONTINUE</code>)</dd> |
5a738aea MS |
3085 | </dl> |
3086 | <h4 class="discussion">Discussion</h4> | |
a469f8a5 MS |
3087 | <p class="discussion">Currently only <code>HTTP_STATUS_CONTINUE</code> is supported for the "expect" |
3088 | argument. | |
5a738aea MS |
3089 | |
3090 | </p> | |
3091 | <h3 class="function"><a name="httpSetField">httpSetField</a></h3> | |
3092 | <p class="description">Set the value of an HTTP header.</p> | |
3093 | <p class="code"> | |
3094 | void httpSetField (<br> | |
3095 | <a href="#http_t">http_t</a> *http,<br> | |
79e1d494 | 3096 | <a href="#http_field_t">http_field_t</a> field,<br> |
5a738aea MS |
3097 | const char *value<br> |
3098 | );</p> | |
3099 | <h4 class="parameters">Parameters</h4> | |
3100 | <dl> | |
3101 | <dt>http</dt> | |
ca6b43fc | 3102 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
3103 | <dt>field</dt> |
3104 | <dd class="description">Field index</dd> | |
3105 | <dt>value</dt> | |
3106 | <dd class="description">Value</dd> | |
3107 | </dl> | |
e1f19878 | 3108 | <h3 class="function"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="httpSetKeepAlive">httpSetKeepAlive</a></h3> |
ca6b43fc MS |
3109 | <p class="description">Set the current Keep-Alive state of a connection.</p> |
3110 | <p class="code"> | |
3111 | void httpSetKeepAlive (<br> | |
3112 | <a href="#http_t">http_t</a> *http,<br> | |
3113 | <a href="#http_keepalive_t">http_keepalive_t</a> keep_alive<br> | |
3114 | );</p> | |
3115 | <h4 class="parameters">Parameters</h4> | |
3116 | <dl> | |
3117 | <dt>http</dt> | |
3118 | <dd class="description">HTTP connection</dd> | |
3119 | <dt>keep_alive</dt> | |
3120 | <dd class="description">New Keep-Alive value</dd> | |
3121 | </dl> | |
f3c17241 | 3122 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpSetLength">httpSetLength</a></h3> |
5a738aea MS |
3123 | <p class="description">Set the content-length and content-encoding.</p> |
3124 | <p class="code"> | |
3125 | void httpSetLength (<br> | |
3126 | <a href="#http_t">http_t</a> *http,<br> | |
3127 | size_t length<br> | |
3128 | );</p> | |
3129 | <h4 class="parameters">Parameters</h4> | |
3130 | <dl> | |
3131 | <dt>http</dt> | |
ca6b43fc | 3132 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
3133 | <dt>length</dt> |
3134 | <dd class="description">Length (0 for chunked)</dd> | |
3135 | </dl> | |
f3c17241 | 3136 | <h3 class="function"><span class="info"> CUPS 1.5/OS X 10.7 </span><a name="httpSetTimeout">httpSetTimeout</a></h3> |
f228370c MS |
3137 | <p class="description">Set read/write timeouts and an optional callback.</p> |
3138 | <p class="code"> | |
3139 | void httpSetTimeout (<br> | |
3140 | <a href="#http_t">http_t</a> *http,<br> | |
3141 | double timeout,<br> | |
3142 | <a href="#http_timeout_cb_t">http_timeout_cb_t</a> cb,<br> | |
3143 | void *user_data<br> | |
3144 | );</p> | |
3145 | <h4 class="parameters">Parameters</h4> | |
3146 | <dl> | |
3147 | <dt>http</dt> | |
ca6b43fc | 3148 | <dd class="description">HTTP connection</dd> |
f228370c MS |
3149 | <dt>timeout</dt> |
3150 | <dd class="description">Number of seconds for timeout, | |
3151 | must be greater than 0</dd> | |
3152 | <dt>cb</dt> | |
3153 | <dd class="description">Callback function or NULL</dd> | |
3154 | <dt>user_data</dt> | |
3155 | <dd class="description">User data pointer</dd> | |
3156 | </dl> | |
3157 | <h4 class="discussion">Discussion</h4> | |
3158 | <p class="discussion">The optional timeout callback receives both the HTTP connection and a user | |
3159 | data pointer and must return 1 to continue or 0 to error (time) out. | |
3160 | ||
3161 | </p> | |
e1f19878 | 3162 | <h3 class="function"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="httpShutdown">httpShutdown</a></h3> |
ca6b43fc MS |
3163 | <p class="description">Shutdown one side of an HTTP connection.</p> |
3164 | <p class="code"> | |
3165 | void httpShutdown (<br> | |
3166 | <a href="#http_t">http_t</a> *http<br> | |
3167 | );</p> | |
3168 | <h4 class="parameters">Parameters</h4> | |
3169 | <dl> | |
3170 | <dt>http</dt> | |
3171 | <dd class="description">HTTP connection</dd> | |
3172 | </dl> | |
e1f19878 | 3173 | <h3 class="function"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="httpStateString">httpStateString</a></h3> |
ca6b43fc MS |
3174 | <p class="description">Return the string describing a HTTP state value.</p> |
3175 | <p class="code"> | |
3176 | const char *httpStateString (<br> | |
3177 | <a href="#http_state_t">http_state_t</a> state<br> | |
3178 | );</p> | |
3179 | <h4 class="parameters">Parameters</h4> | |
3180 | <dl> | |
3181 | <dt>state</dt> | |
3182 | <dd class="description">HTTP state value</dd> | |
3183 | </dl> | |
3184 | <h4 class="returnvalue">Return Value</h4> | |
3185 | <p class="description">State string</p> | |
5a738aea MS |
3186 | <h3 class="function"><a name="httpStatus">httpStatus</a></h3> |
3187 | <p class="description">Return a short string describing a HTTP status code.</p> | |
3188 | <p class="code"> | |
3189 | const char *httpStatus (<br> | |
a469f8a5 | 3190 | http_status_t status<br> |
5a738aea MS |
3191 | );</p> |
3192 | <h4 class="parameters">Parameters</h4> | |
3193 | <dl> | |
3194 | <dt>status</dt> | |
3195 | <dd class="description">HTTP status code</dd> | |
3196 | </dl> | |
3197 | <h4 class="returnvalue">Return Value</h4> | |
06d4e77b MS |
3198 | <p class="description">Localized status string</p> |
3199 | <h4 class="discussion">Discussion</h4> | |
3200 | <p class="discussion">The returned string is localized to the current POSIX locale and is based | |
3201 | on the status strings defined in RFC 2616.</p> | |
5a738aea MS |
3202 | <h3 class="function"><a name="httpTrace">httpTrace</a></h3> |
3203 | <p class="description">Send an TRACE request to the server.</p> | |
3204 | <p class="code"> | |
3205 | int httpTrace (<br> | |
3206 | <a href="#http_t">http_t</a> *http,<br> | |
3207 | const char *uri<br> | |
3208 | );</p> | |
3209 | <h4 class="parameters">Parameters</h4> | |
3210 | <dl> | |
3211 | <dt>http</dt> | |
ca6b43fc | 3212 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
3213 | <dt>uri</dt> |
3214 | <dd class="description">URI for trace</dd> | |
3215 | </dl> | |
3216 | <h4 class="returnvalue">Return Value</h4> | |
3217 | <p class="description">Status of call (0 = success)</p> | |
e1f19878 | 3218 | <h3 class="function"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="httpURIStatusString">httpURIStatusString</a></h3> |
ca6b43fc MS |
3219 | <p class="description">Return a string describing a URI status code.</p> |
3220 | <p class="code"> | |
3221 | const char *httpURIStatusString (<br> | |
3222 | <a href="#http_uri_status_t">http_uri_status_t</a> status<br> | |
3223 | );</p> | |
3224 | <h4 class="parameters">Parameters</h4> | |
3225 | <dl> | |
3226 | <dt>status</dt> | |
3227 | <dd class="description">URI status code</dd> | |
3228 | </dl> | |
3229 | <h4 class="returnvalue">Return Value</h4> | |
3230 | <p class="description">Localized status string</p> | |
5a738aea MS |
3231 | <h3 class="function"><a name="httpUpdate">httpUpdate</a></h3> |
3232 | <p class="description">Update the current HTTP state for incoming data.</p> | |
3233 | <p class="code"> | |
a469f8a5 | 3234 | http_status_t httpUpdate (<br> |
5a738aea MS |
3235 | <a href="#http_t">http_t</a> *http<br> |
3236 | );</p> | |
3237 | <h4 class="parameters">Parameters</h4> | |
3238 | <dl> | |
3239 | <dt>http</dt> | |
ca6b43fc | 3240 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
3241 | </dl> |
3242 | <h4 class="returnvalue">Return Value</h4> | |
3243 | <p class="description">HTTP status</p> | |
f3c17241 | 3244 | <h3 class="function"><span class="info"> CUPS 1.1.19/OS X 10.3 </span><a name="httpWait">httpWait</a></h3> |
5a738aea MS |
3245 | <p class="description">Wait for data available on a connection.</p> |
3246 | <p class="code"> | |
3247 | int httpWait (<br> | |
3248 | <a href="#http_t">http_t</a> *http,<br> | |
3249 | int msec<br> | |
3250 | );</p> | |
3251 | <h4 class="parameters">Parameters</h4> | |
3252 | <dl> | |
3253 | <dt>http</dt> | |
ca6b43fc | 3254 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
3255 | <dt>msec</dt> |
3256 | <dd class="description">Milliseconds to wait</dd> | |
3257 | </dl> | |
3258 | <h4 class="returnvalue">Return Value</h4> | |
3259 | <p class="description">1 if data is available, 0 otherwise</p> | |
3260 | <h3 class="function"><span class="info"> DEPRECATED </span><a name="httpWrite">httpWrite</a></h3> | |
3261 | <p class="description">Write data to a HTTP connection.</p> | |
3262 | <p class="code"> | |
3263 | int httpWrite (<br> | |
3264 | <a href="#http_t">http_t</a> *http,<br> | |
3265 | const char *buffer,<br> | |
3266 | int length<br> | |
3267 | );</p> | |
3268 | <h4 class="parameters">Parameters</h4> | |
3269 | <dl> | |
3270 | <dt>http</dt> | |
ca6b43fc | 3271 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
3272 | <dt>buffer</dt> |
3273 | <dd class="description">Buffer for data</dd> | |
3274 | <dt>length</dt> | |
3275 | <dd class="description">Number of bytes to write</dd> | |
3276 | </dl> | |
3277 | <h4 class="returnvalue">Return Value</h4> | |
3278 | <p class="description">Number of bytes written</p> | |
3279 | <h4 class="discussion">Discussion</h4> | |
3280 | <p class="discussion">This function is deprecated. Use the httpWrite2() function which can | |
ecdc0628 | 3281 | write more than 2GB of data. |
3282 | ||
5a738aea | 3283 | </p> |
f3c17241 | 3284 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="httpWrite2">httpWrite2</a></h3> |
5a738aea MS |
3285 | <p class="description">Write data to a HTTP connection.</p> |
3286 | <p class="code"> | |
3287 | ssize_t httpWrite2 (<br> | |
3288 | <a href="#http_t">http_t</a> *http,<br> | |
3289 | const char *buffer,<br> | |
3290 | size_t length<br> | |
3291 | );</p> | |
3292 | <h4 class="parameters">Parameters</h4> | |
3293 | <dl> | |
3294 | <dt>http</dt> | |
ca6b43fc | 3295 | <dd class="description">HTTP connection</dd> |
5a738aea MS |
3296 | <dt>buffer</dt> |
3297 | <dd class="description">Buffer for data</dd> | |
3298 | <dt>length</dt> | |
3299 | <dd class="description">Number of bytes to write</dd> | |
3300 | </dl> | |
3301 | <h4 class="returnvalue">Return Value</h4> | |
3302 | <p class="description">Number of bytes written</p> | |
9c0e8e5d | 3303 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="httpWriteResponse">httpWriteResponse</a></h3> |
a469f8a5 MS |
3304 | <p class="description">Write a HTTP response to a client connection.</p> |
3305 | <p class="code"> | |
3306 | int httpWriteResponse (<br> | |
3307 | <a href="#http_t">http_t</a> *http,<br> | |
3308 | http_status_t status<br> | |
3309 | );</p> | |
3310 | <h4 class="parameters">Parameters</h4> | |
3311 | <dl> | |
3312 | <dt>http</dt> | |
3313 | <dd class="description">HTTP connection</dd> | |
3314 | <dt>status</dt> | |
3315 | <dd class="description">Status code</dd> | |
3316 | </dl> | |
3317 | <h4 class="returnvalue">Return Value</h4> | |
3318 | <p class="description">0 on success, -1 on error</p> | |
5a738aea MS |
3319 | <h3 class="function"><a name="ippAddBoolean">ippAddBoolean</a></h3> |
3320 | <p class="description">Add a boolean attribute to an IPP message.</p> | |
3321 | <p class="code"> | |
3322 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddBoolean (<br> | |
3323 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
a2326b5b | 3324 | ipp_tag_t group,<br> |
5a738aea MS |
3325 | const char *name,<br> |
3326 | char value<br> | |
3327 | );</p> | |
3328 | <h4 class="parameters">Parameters</h4> | |
3329 | <dl> | |
3330 | <dt>ipp</dt> | |
3331 | <dd class="description">IPP message</dd> | |
3332 | <dt>group</dt> | |
3333 | <dd class="description">IPP group</dd> | |
3334 | <dt>name</dt> | |
3335 | <dd class="description">Name of attribute</dd> | |
3336 | <dt>value</dt> | |
3337 | <dd class="description">Value of attribute</dd> | |
3338 | </dl> | |
3339 | <h4 class="returnvalue">Return Value</h4> | |
3340 | <p class="description">New attribute</p> | |
a2326b5b | 3341 | <h4 class="discussion">Discussion</h4> |
a469f8a5 MS |
3342 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
3343 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
3344 | <br> |
3345 | The <code>group</code> parameter specifies the IPP attribute group tag: none | |
3346 | (<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>), | |
3347 | event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation | |
3348 | (<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription | |
3349 | (<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).</p> | |
5a738aea MS |
3350 | <h3 class="function"><a name="ippAddBooleans">ippAddBooleans</a></h3> |
3351 | <p class="description">Add an array of boolean values.</p> | |
3352 | <p class="code"> | |
3353 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddBooleans (<br> | |
3354 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
a2326b5b | 3355 | ipp_tag_t group,<br> |
5a738aea MS |
3356 | const char *name,<br> |
3357 | int num_values,<br> | |
3358 | const char *values<br> | |
3359 | );</p> | |
3360 | <h4 class="parameters">Parameters</h4> | |
3361 | <dl> | |
3362 | <dt>ipp</dt> | |
3363 | <dd class="description">IPP message</dd> | |
3364 | <dt>group</dt> | |
3365 | <dd class="description">IPP group</dd> | |
3366 | <dt>name</dt> | |
3367 | <dd class="description">Name of attribute</dd> | |
3368 | <dt>num_values</dt> | |
3369 | <dd class="description">Number of values</dd> | |
3370 | <dt>values</dt> | |
3371 | <dd class="description">Values</dd> | |
3372 | </dl> | |
3373 | <h4 class="returnvalue">Return Value</h4> | |
3374 | <p class="description">New attribute</p> | |
a2326b5b | 3375 | <h4 class="discussion">Discussion</h4> |
a469f8a5 MS |
3376 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
3377 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
3378 | <br> |
3379 | The <code>group</code> parameter specifies the IPP attribute group tag: none | |
3380 | (<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>), | |
3381 | event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation | |
3382 | (<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription | |
3383 | (<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).</p> | |
f3c17241 | 3384 | <h3 class="function"><span class="info"> CUPS 1.1.19/OS X 10.3 </span><a name="ippAddCollection">ippAddCollection</a></h3> |
5a738aea MS |
3385 | <p class="description">Add a collection value.</p> |
3386 | <p class="code"> | |
3387 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddCollection (<br> | |
3388 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
a2326b5b | 3389 | ipp_tag_t group,<br> |
5a738aea MS |
3390 | const char *name,<br> |
3391 | <a href="#ipp_t">ipp_t</a> *value<br> | |
3392 | );</p> | |
3393 | <h4 class="parameters">Parameters</h4> | |
3394 | <dl> | |
3395 | <dt>ipp</dt> | |
3396 | <dd class="description">IPP message</dd> | |
3397 | <dt>group</dt> | |
3398 | <dd class="description">IPP group</dd> | |
3399 | <dt>name</dt> | |
3400 | <dd class="description">Name of attribute</dd> | |
3401 | <dt>value</dt> | |
3402 | <dd class="description">Value</dd> | |
3403 | </dl> | |
3404 | <h4 class="returnvalue">Return Value</h4> | |
3405 | <p class="description">New attribute</p> | |
a2326b5b | 3406 | <h4 class="discussion">Discussion</h4> |
a469f8a5 MS |
3407 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
3408 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
3409 | <br> |
3410 | The <code>group</code> parameter specifies the IPP attribute group tag: none | |
3411 | (<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>), | |
3412 | event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation | |
3413 | (<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription | |
3414 | (<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>). | |
3415 | ||
3416 | </p> | |
f3c17241 | 3417 | <h3 class="function"><span class="info"> CUPS 1.1.19/OS X 10.3 </span><a name="ippAddCollections">ippAddCollections</a></h3> |
5a738aea MS |
3418 | <p class="description">Add an array of collection values.</p> |
3419 | <p class="code"> | |
3420 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddCollections (<br> | |
3421 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
a2326b5b | 3422 | ipp_tag_t group,<br> |
5a738aea MS |
3423 | const char *name,<br> |
3424 | int num_values,<br> | |
3425 | const <a href="#ipp_t">ipp_t</a> **values<br> | |
3426 | );</p> | |
3427 | <h4 class="parameters">Parameters</h4> | |
3428 | <dl> | |
3429 | <dt>ipp</dt> | |
3430 | <dd class="description">IPP message</dd> | |
3431 | <dt>group</dt> | |
3432 | <dd class="description">IPP group</dd> | |
3433 | <dt>name</dt> | |
3434 | <dd class="description">Name of attribute</dd> | |
3435 | <dt>num_values</dt> | |
3436 | <dd class="description">Number of values</dd> | |
3437 | <dt>values</dt> | |
3438 | <dd class="description">Values</dd> | |
3439 | </dl> | |
3440 | <h4 class="returnvalue">Return Value</h4> | |
3441 | <p class="description">New attribute</p> | |
a2326b5b | 3442 | <h4 class="discussion">Discussion</h4> |
a469f8a5 MS |
3443 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
3444 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
3445 | <br> |
3446 | The <code>group</code> parameter specifies the IPP attribute group tag: none | |
3447 | (<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>), | |
3448 | event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation | |
3449 | (<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription | |
3450 | (<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>). | |
3451 | ||
3452 | </p> | |
5a738aea MS |
3453 | <h3 class="function"><a name="ippAddDate">ippAddDate</a></h3> |
3454 | <p class="description">Add a date attribute to an IPP message.</p> | |
3455 | <p class="code"> | |
3456 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddDate (<br> | |
3457 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
a2326b5b | 3458 | ipp_tag_t group,<br> |
5a738aea MS |
3459 | const char *name,<br> |
3460 | const <a href="#ipp_uchar_t">ipp_uchar_t</a> *value<br> | |
3461 | );</p> | |
3462 | <h4 class="parameters">Parameters</h4> | |
3463 | <dl> | |
3464 | <dt>ipp</dt> | |
3465 | <dd class="description">IPP message</dd> | |
3466 | <dt>group</dt> | |
3467 | <dd class="description">IPP group</dd> | |
3468 | <dt>name</dt> | |
3469 | <dd class="description">Name of attribute</dd> | |
3470 | <dt>value</dt> | |
3471 | <dd class="description">Value</dd> | |
3472 | </dl> | |
3473 | <h4 class="returnvalue">Return Value</h4> | |
3474 | <p class="description">New attribute</p> | |
a2326b5b | 3475 | <h4 class="discussion">Discussion</h4> |
a469f8a5 MS |
3476 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
3477 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
3478 | <br> |
3479 | The <code>group</code> parameter specifies the IPP attribute group tag: none | |
3480 | (<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>), | |
3481 | event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation | |
3482 | (<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription | |
3483 | (<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).</p> | |
5a738aea MS |
3484 | <h3 class="function"><a name="ippAddInteger">ippAddInteger</a></h3> |
3485 | <p class="description">Add a integer attribute to an IPP message.</p> | |
3486 | <p class="code"> | |
3487 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddInteger (<br> | |
3488 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
a2326b5b MS |
3489 | ipp_tag_t group,<br> |
3490 | ipp_tag_t value_tag,<br> | |
5a738aea MS |
3491 | const char *name,<br> |
3492 | int value<br> | |
3493 | );</p> | |
3494 | <h4 class="parameters">Parameters</h4> | |
3495 | <dl> | |
3496 | <dt>ipp</dt> | |
3497 | <dd class="description">IPP message</dd> | |
3498 | <dt>group</dt> | |
3499 | <dd class="description">IPP group</dd> | |
a2326b5b | 3500 | <dt>value_tag</dt> |
5a738aea MS |
3501 | <dd class="description">Type of attribute</dd> |
3502 | <dt>name</dt> | |
3503 | <dd class="description">Name of attribute</dd> | |
3504 | <dt>value</dt> | |
3505 | <dd class="description">Value of attribute</dd> | |
3506 | </dl> | |
3507 | <h4 class="returnvalue">Return Value</h4> | |
3508 | <p class="description">New attribute</p> | |
a2326b5b | 3509 | <h4 class="discussion">Discussion</h4> |
a469f8a5 MS |
3510 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
3511 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
3512 | <br> |
3513 | The <code>group</code> parameter specifies the IPP attribute group tag: none | |
3514 | (<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>), | |
3515 | event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation | |
3516 | (<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription | |
3517 | (<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).<br> | |
3518 | <br> | |
3519 | Supported values include enum (<code>IPP_TAG_ENUM</code>) and integer | |
3520 | (<code>IPP_TAG_INTEGER</code>).</p> | |
5a738aea MS |
3521 | <h3 class="function"><a name="ippAddIntegers">ippAddIntegers</a></h3> |
3522 | <p class="description">Add an array of integer values.</p> | |
3523 | <p class="code"> | |
3524 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddIntegers (<br> | |
3525 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
a2326b5b MS |
3526 | ipp_tag_t group,<br> |
3527 | ipp_tag_t value_tag,<br> | |
5a738aea MS |
3528 | const char *name,<br> |
3529 | int num_values,<br> | |
3530 | const int *values<br> | |
3531 | );</p> | |
3532 | <h4 class="parameters">Parameters</h4> | |
3533 | <dl> | |
3534 | <dt>ipp</dt> | |
3535 | <dd class="description">IPP message</dd> | |
3536 | <dt>group</dt> | |
3537 | <dd class="description">IPP group</dd> | |
a2326b5b | 3538 | <dt>value_tag</dt> |
5a738aea MS |
3539 | <dd class="description">Type of attribute</dd> |
3540 | <dt>name</dt> | |
3541 | <dd class="description">Name of attribute</dd> | |
3542 | <dt>num_values</dt> | |
3543 | <dd class="description">Number of values</dd> | |
3544 | <dt>values</dt> | |
3545 | <dd class="description">Values</dd> | |
3546 | </dl> | |
3547 | <h4 class="returnvalue">Return Value</h4> | |
3548 | <p class="description">New attribute</p> | |
a2326b5b | 3549 | <h4 class="discussion">Discussion</h4> |
a469f8a5 MS |
3550 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
3551 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
3552 | <br> |
3553 | The <code>group</code> parameter specifies the IPP attribute group tag: none | |
3554 | (<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>), | |
3555 | event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation | |
3556 | (<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription | |
3557 | (<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).<br> | |
3558 | <br> | |
3559 | Supported values include enum (<code>IPP_TAG_ENUM</code>) and integer | |
3560 | (<code>IPP_TAG_INTEGER</code>).</p> | |
f3c17241 | 3561 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="ippAddOctetString">ippAddOctetString</a></h3> |
5a738aea MS |
3562 | <p class="description">Add an octetString value to an IPP message.</p> |
3563 | <p class="code"> | |
3564 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddOctetString (<br> | |
3565 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
a2326b5b | 3566 | ipp_tag_t group,<br> |
5a738aea MS |
3567 | const char *name,<br> |
3568 | const void *data,<br> | |
3569 | int datalen<br> | |
3570 | );</p> | |
3571 | <h4 class="parameters">Parameters</h4> | |
3572 | <dl> | |
3573 | <dt>ipp</dt> | |
3574 | <dd class="description">IPP message</dd> | |
3575 | <dt>group</dt> | |
3576 | <dd class="description">IPP group</dd> | |
3577 | <dt>name</dt> | |
3578 | <dd class="description">Name of attribute</dd> | |
3579 | <dt>data</dt> | |
3580 | <dd class="description">octetString data</dd> | |
3581 | <dt>datalen</dt> | |
3582 | <dd class="description">Length of data in bytes</dd> | |
3583 | </dl> | |
3584 | <h4 class="returnvalue">Return Value</h4> | |
3585 | <p class="description">New attribute</p> | |
a2326b5b | 3586 | <h4 class="discussion">Discussion</h4> |
a469f8a5 MS |
3587 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
3588 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
3589 | <br> |
3590 | The <code>group</code> parameter specifies the IPP attribute group tag: none | |
3591 | (<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>), | |
3592 | event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation | |
3593 | (<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription | |
3594 | (<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>). | |
3595 | ||
3596 | </p> | |
f3c17241 | 3597 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippAddOutOfBand">ippAddOutOfBand</a></h3> |
a2326b5b MS |
3598 | <p class="description">Add an out-of-band value to an IPP message.</p> |
3599 | <p class="code"> | |
3600 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddOutOfBand (<br> | |
3601 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
3602 | ipp_tag_t group,<br> | |
3603 | ipp_tag_t value_tag,<br> | |
3604 | const char *name<br> | |
3605 | );</p> | |
3606 | <h4 class="parameters">Parameters</h4> | |
3607 | <dl> | |
3608 | <dt>ipp</dt> | |
3609 | <dd class="description">IPP message</dd> | |
3610 | <dt>group</dt> | |
3611 | <dd class="description">IPP group</dd> | |
3612 | <dt>value_tag</dt> | |
3613 | <dd class="description">Type of attribute</dd> | |
3614 | <dt>name</dt> | |
3615 | <dd class="description">Name of attribute</dd> | |
3616 | </dl> | |
3617 | <h4 class="returnvalue">Return Value</h4> | |
3618 | <p class="description">New attribute</p> | |
3619 | <h4 class="discussion">Discussion</h4> | |
a469f8a5 MS |
3620 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
3621 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
3622 | <br> |
3623 | The <code>group</code> parameter specifies the IPP attribute group tag: none | |
3624 | (<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>), | |
3625 | event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation | |
3626 | (<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription | |
3627 | (<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).<br> | |
3628 | <br> | |
3629 | Supported out-of-band values include unsupported-value | |
3630 | (<code>IPP_TAG_UNSUPPORTED_VALUE</code>), default (<code>IPP_TAG_DEFAULT</code>), unknown | |
3631 | (<code>IPP_TAG_UNKNOWN</code>), no-value (<code>IPP_TAG_NOVALUE</code>), not-settable | |
3632 | (<code>IPP_TAG_NOTSETTABLE</code>), delete-attribute (<code>IPP_TAG_DELETEATTR</code>), and | |
3633 | admin-define (<code>IPP_TAG_ADMINDEFINE</code>). | |
3634 | ||
3635 | </p> | |
5a738aea MS |
3636 | <h3 class="function"><a name="ippAddRange">ippAddRange</a></h3> |
3637 | <p class="description">Add a range of values to an IPP message.</p> | |
3638 | <p class="code"> | |
3639 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddRange (<br> | |
3640 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
a2326b5b | 3641 | ipp_tag_t group,<br> |
5a738aea MS |
3642 | const char *name,<br> |
3643 | int lower,<br> | |
3644 | int upper<br> | |
3645 | );</p> | |
3646 | <h4 class="parameters">Parameters</h4> | |
3647 | <dl> | |
3648 | <dt>ipp</dt> | |
3649 | <dd class="description">IPP message</dd> | |
3650 | <dt>group</dt> | |
3651 | <dd class="description">IPP group</dd> | |
3652 | <dt>name</dt> | |
3653 | <dd class="description">Name of attribute</dd> | |
3654 | <dt>lower</dt> | |
3655 | <dd class="description">Lower value</dd> | |
3656 | <dt>upper</dt> | |
3657 | <dd class="description">Upper value</dd> | |
3658 | </dl> | |
3659 | <h4 class="returnvalue">Return Value</h4> | |
3660 | <p class="description">New attribute</p> | |
a2326b5b | 3661 | <h4 class="discussion">Discussion</h4> |
a469f8a5 MS |
3662 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
3663 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
3664 | <br> |
3665 | The <code>group</code> parameter specifies the IPP attribute group tag: none | |
3666 | (<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>), | |
3667 | event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation | |
3668 | (<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription | |
3669 | (<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).<br> | |
3670 | <br> | |
3671 | The <code>lower</code> parameter must be less than or equal to the <code>upper</code> parameter.</p> | |
5a738aea MS |
3672 | <h3 class="function"><a name="ippAddRanges">ippAddRanges</a></h3> |
3673 | <p class="description">Add ranges of values to an IPP message.</p> | |
3674 | <p class="code"> | |
3675 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddRanges (<br> | |
3676 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
a2326b5b | 3677 | ipp_tag_t group,<br> |
5a738aea MS |
3678 | const char *name,<br> |
3679 | int num_values,<br> | |
3680 | const int *lower,<br> | |
3681 | const int *upper<br> | |
3682 | );</p> | |
3683 | <h4 class="parameters">Parameters</h4> | |
3684 | <dl> | |
3685 | <dt>ipp</dt> | |
3686 | <dd class="description">IPP message</dd> | |
3687 | <dt>group</dt> | |
3688 | <dd class="description">IPP group</dd> | |
3689 | <dt>name</dt> | |
3690 | <dd class="description">Name of attribute</dd> | |
3691 | <dt>num_values</dt> | |
3692 | <dd class="description">Number of values</dd> | |
3693 | <dt>lower</dt> | |
3694 | <dd class="description">Lower values</dd> | |
3695 | <dt>upper</dt> | |
3696 | <dd class="description">Upper values</dd> | |
3697 | </dl> | |
3698 | <h4 class="returnvalue">Return Value</h4> | |
3699 | <p class="description">New attribute</p> | |
a2326b5b | 3700 | <h4 class="discussion">Discussion</h4> |
a469f8a5 MS |
3701 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
3702 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
3703 | <br> |
3704 | The <code>group</code> parameter specifies the IPP attribute group tag: none | |
3705 | (<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>), | |
3706 | event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation | |
3707 | (<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription | |
3708 | (<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).</p> | |
5a738aea MS |
3709 | <h3 class="function"><a name="ippAddResolution">ippAddResolution</a></h3> |
3710 | <p class="description">Add a resolution value to an IPP message.</p> | |
3711 | <p class="code"> | |
3712 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddResolution (<br> | |
3713 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
a2326b5b | 3714 | ipp_tag_t group,<br> |
5a738aea | 3715 | const char *name,<br> |
79e1d494 | 3716 | <a href="#ipp_res_t">ipp_res_t</a> units,<br> |
5a738aea MS |
3717 | int xres,<br> |
3718 | int yres<br> | |
3719 | );</p> | |
3720 | <h4 class="parameters">Parameters</h4> | |
3721 | <dl> | |
3722 | <dt>ipp</dt> | |
3723 | <dd class="description">IPP message</dd> | |
3724 | <dt>group</dt> | |
3725 | <dd class="description">IPP group</dd> | |
3726 | <dt>name</dt> | |
3727 | <dd class="description">Name of attribute</dd> | |
3728 | <dt>units</dt> | |
3729 | <dd class="description">Units for resolution</dd> | |
3730 | <dt>xres</dt> | |
3731 | <dd class="description">X resolution</dd> | |
3732 | <dt>yres</dt> | |
3733 | <dd class="description">Y resolution</dd> | |
3734 | </dl> | |
3735 | <h4 class="returnvalue">Return Value</h4> | |
3736 | <p class="description">New attribute</p> | |
a2326b5b | 3737 | <h4 class="discussion">Discussion</h4> |
a469f8a5 MS |
3738 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
3739 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
3740 | <br> |
3741 | The <code>group</code> parameter specifies the IPP attribute group tag: none | |
3742 | (<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>), | |
3743 | event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation | |
3744 | (<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription | |
3745 | (<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).</p> | |
5a738aea MS |
3746 | <h3 class="function"><a name="ippAddResolutions">ippAddResolutions</a></h3> |
3747 | <p class="description">Add resolution values to an IPP message.</p> | |
3748 | <p class="code"> | |
3749 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddResolutions (<br> | |
3750 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
a2326b5b | 3751 | ipp_tag_t group,<br> |
5a738aea MS |
3752 | const char *name,<br> |
3753 | int num_values,<br> | |
79e1d494 | 3754 | <a href="#ipp_res_t">ipp_res_t</a> units,<br> |
5a738aea MS |
3755 | const int *xres,<br> |
3756 | const int *yres<br> | |
3757 | );</p> | |
3758 | <h4 class="parameters">Parameters</h4> | |
3759 | <dl> | |
3760 | <dt>ipp</dt> | |
3761 | <dd class="description">IPP message</dd> | |
3762 | <dt>group</dt> | |
3763 | <dd class="description">IPP group</dd> | |
3764 | <dt>name</dt> | |
3765 | <dd class="description">Name of attribute</dd> | |
3766 | <dt>num_values</dt> | |
3767 | <dd class="description">Number of values</dd> | |
3768 | <dt>units</dt> | |
3769 | <dd class="description">Units for resolution</dd> | |
3770 | <dt>xres</dt> | |
3771 | <dd class="description">X resolutions</dd> | |
3772 | <dt>yres</dt> | |
3773 | <dd class="description">Y resolutions</dd> | |
3774 | </dl> | |
3775 | <h4 class="returnvalue">Return Value</h4> | |
3776 | <p class="description">New attribute</p> | |
a2326b5b | 3777 | <h4 class="discussion">Discussion</h4> |
a469f8a5 MS |
3778 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
3779 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
3780 | <br> |
3781 | The <code>group</code> parameter specifies the IPP attribute group tag: none | |
3782 | (<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>), | |
3783 | event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation | |
3784 | (<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription | |
3785 | (<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).</p> | |
5a738aea MS |
3786 | <h3 class="function"><a name="ippAddSeparator">ippAddSeparator</a></h3> |
3787 | <p class="description">Add a group separator to an IPP message.</p> | |
3788 | <p class="code"> | |
3789 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddSeparator (<br> | |
3790 | <a href="#ipp_t">ipp_t</a> *ipp<br> | |
3791 | );</p> | |
3792 | <h4 class="parameters">Parameters</h4> | |
3793 | <dl> | |
3794 | <dt>ipp</dt> | |
3795 | <dd class="description">IPP message</dd> | |
3796 | </dl> | |
3797 | <h4 class="returnvalue">Return Value</h4> | |
3798 | <p class="description">New attribute</p> | |
a2326b5b | 3799 | <h4 class="discussion">Discussion</h4> |
a469f8a5 MS |
3800 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
3801 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.</p> | |
5a738aea MS |
3802 | <h3 class="function"><a name="ippAddString">ippAddString</a></h3> |
3803 | <p class="description">Add a language-encoded string to an IPP message.</p> | |
3804 | <p class="code"> | |
3805 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddString (<br> | |
3806 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
a2326b5b MS |
3807 | ipp_tag_t group,<br> |
3808 | ipp_tag_t value_tag,<br> | |
5a738aea | 3809 | const char *name,<br> |
a2326b5b | 3810 | const char *language,<br> |
5a738aea MS |
3811 | const char *value<br> |
3812 | );</p> | |
3813 | <h4 class="parameters">Parameters</h4> | |
3814 | <dl> | |
3815 | <dt>ipp</dt> | |
3816 | <dd class="description">IPP message</dd> | |
3817 | <dt>group</dt> | |
3818 | <dd class="description">IPP group</dd> | |
a2326b5b | 3819 | <dt>value_tag</dt> |
5a738aea MS |
3820 | <dd class="description">Type of attribute</dd> |
3821 | <dt>name</dt> | |
3822 | <dd class="description">Name of attribute</dd> | |
a2326b5b MS |
3823 | <dt>language</dt> |
3824 | <dd class="description">Language code</dd> | |
5a738aea MS |
3825 | <dt>value</dt> |
3826 | <dd class="description">Value</dd> | |
3827 | </dl> | |
3828 | <h4 class="returnvalue">Return Value</h4> | |
3829 | <p class="description">New attribute</p> | |
a2326b5b | 3830 | <h4 class="discussion">Discussion</h4> |
a469f8a5 MS |
3831 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
3832 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
3833 | <br> |
3834 | The <code>group</code> parameter specifies the IPP attribute group tag: none | |
3835 | (<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>), | |
3836 | event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation | |
3837 | (<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription | |
3838 | (<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).<br> | |
3839 | <br> | |
3840 | Supported string values include charset (<code>IPP_TAG_CHARSET</code>), keyword | |
3841 | (<code>IPP_TAG_KEYWORD</code>), language (<code>IPP_TAG_LANGUAGE</code>), mimeMediaType | |
3842 | (<code>IPP_TAG_MIMETYPE</code>), name (<code>IPP_TAG_NAME</code>), nameWithLanguage | |
3843 | (<code>IPP_TAG_NAMELANG), text (</code>code IPP_TAG_TEXT@), textWithLanguage | |
3844 | (<code>IPP_TAG_TEXTLANG</code>), uri (<code>IPP_TAG_URI</code>), and uriScheme | |
3845 | (<code>IPP_TAG_URISCHEME</code>).<br> | |
3846 | <br> | |
3847 | The <code>language</code> parameter must be non-<code>NULL</code> for nameWithLanguage and | |
3848 | textWithLanguage string values and must be <code>NULL</code> for all other string values.</p> | |
9c0e8e5d | 3849 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="ippAddStringf">ippAddStringf</a></h3> |
a469f8a5 MS |
3850 | <p class="description">Add a formatted string to an IPP message.</p> |
3851 | <p class="code"> | |
3852 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddStringf (<br> | |
3853 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
3854 | ipp_tag_t group,<br> | |
3855 | ipp_tag_t value_tag,<br> | |
3856 | const char *name,<br> | |
3857 | const char *language,<br> | |
3858 | const char *format,<br> | |
3859 | ...<br> | |
3860 | );</p> | |
3861 | <h4 class="parameters">Parameters</h4> | |
3862 | <dl> | |
3863 | <dt>ipp</dt> | |
3864 | <dd class="description">IPP message</dd> | |
3865 | <dt>group</dt> | |
3866 | <dd class="description">IPP group</dd> | |
3867 | <dt>value_tag</dt> | |
3868 | <dd class="description">Type of attribute</dd> | |
3869 | <dt>name</dt> | |
3870 | <dd class="description">Name of attribute</dd> | |
3871 | <dt>language</dt> | |
3872 | <dd class="description">Language code (<code>NULL</code> for default)</dd> | |
3873 | <dt>format</dt> | |
3874 | <dd class="description">Printf-style format string</dd> | |
3875 | <dt>...</dt> | |
3876 | <dd class="description">Additional arguments as needed</dd> | |
3877 | </dl> | |
3878 | <h4 class="returnvalue">Return Value</h4> | |
3879 | <p class="description">New attribute</p> | |
3880 | <h4 class="discussion">Discussion</h4> | |
3881 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using | |
3882 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
3883 | <br> | |
3884 | The <code>group</code> parameter specifies the IPP attribute group tag: none | |
3885 | (<code>IPP_TAG_ZERO</code>, for member attributes), document | |
3886 | (<code>IPP_TAG_DOCUMENT</code>), event notification | |
3887 | (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation (<code>IPP_TAG_OPERATION</code>), | |
3888 | printer (<code>IPP_TAG_PRINTER</code>), subscription (<code>IPP_TAG_SUBSCRIPTION</code>), | |
3889 | or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).<br> | |
3890 | <br> | |
3891 | Supported string values include charset (<code>IPP_TAG_CHARSET</code>), keyword | |
3892 | (<code>IPP_TAG_KEYWORD</code>), language (<code>IPP_TAG_LANGUAGE</code>), mimeMediaType | |
3893 | (<code>IPP_TAG_MIMETYPE</code>), name (<code>IPP_TAG_NAME</code>), nameWithLanguage | |
3894 | (<code>IPP_TAG_NAMELANG), text (</code>code IPP_TAG_TEXT@), textWithLanguage | |
3895 | (<code>IPP_TAG_TEXTLANG</code>), uri (<code>IPP_TAG_URI</code>), and uriScheme | |
3896 | (<code>IPP_TAG_URISCHEME</code>).<br> | |
3897 | <br> | |
3898 | The <code>language</code> parameter must be non-<code>NULL</code> for nameWithLanguage | |
3899 | and textWithLanguage string values and must be <code>NULL</code> for all other | |
3900 | string values.<br> | |
3901 | <br> | |
3902 | The <code>format</code> parameter uses formatting characters compatible with the | |
3903 | printf family of standard functions. Additional arguments follow it as | |
3904 | needed. The formatted string is truncated as needed to the maximum length of | |
3905 | the corresponding value type. | |
3906 | ||
3907 | </p> | |
9c0e8e5d | 3908 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="ippAddStringfv">ippAddStringfv</a></h3> |
a469f8a5 MS |
3909 | <p class="description">Add a formatted string to an IPP message.</p> |
3910 | <p class="code"> | |
3911 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddStringfv (<br> | |
3912 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
3913 | ipp_tag_t group,<br> | |
3914 | ipp_tag_t value_tag,<br> | |
3915 | const char *name,<br> | |
3916 | const char *language,<br> | |
3917 | const char *format,<br> | |
3918 | va_list ap<br> | |
3919 | );</p> | |
3920 | <h4 class="parameters">Parameters</h4> | |
3921 | <dl> | |
3922 | <dt>ipp</dt> | |
3923 | <dd class="description">IPP message</dd> | |
3924 | <dt>group</dt> | |
3925 | <dd class="description">IPP group</dd> | |
3926 | <dt>value_tag</dt> | |
3927 | <dd class="description">Type of attribute</dd> | |
3928 | <dt>name</dt> | |
3929 | <dd class="description">Name of attribute</dd> | |
3930 | <dt>language</dt> | |
3931 | <dd class="description">Language code (<code>NULL</code> for default)</dd> | |
3932 | <dt>format</dt> | |
3933 | <dd class="description">Printf-style format string</dd> | |
3934 | <dt>ap</dt> | |
3935 | <dd class="description">Additional arguments</dd> | |
3936 | </dl> | |
3937 | <h4 class="returnvalue">Return Value</h4> | |
3938 | <p class="description">New attribute</p> | |
3939 | <h4 class="discussion">Discussion</h4> | |
3940 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using | |
3941 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
3942 | <br> | |
3943 | The <code>group</code> parameter specifies the IPP attribute group tag: none | |
3944 | (<code>IPP_TAG_ZERO</code>, for member attributes), document | |
3945 | (<code>IPP_TAG_DOCUMENT</code>), event notification | |
3946 | (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation (<code>IPP_TAG_OPERATION</code>), | |
3947 | printer (<code>IPP_TAG_PRINTER</code>), subscription (<code>IPP_TAG_SUBSCRIPTION</code>), | |
3948 | or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).<br> | |
3949 | <br> | |
3950 | Supported string values include charset (<code>IPP_TAG_CHARSET</code>), keyword | |
3951 | (<code>IPP_TAG_KEYWORD</code>), language (<code>IPP_TAG_LANGUAGE</code>), mimeMediaType | |
3952 | (<code>IPP_TAG_MIMETYPE</code>), name (<code>IPP_TAG_NAME</code>), nameWithLanguage | |
3953 | (<code>IPP_TAG_NAMELANG), text (</code>code IPP_TAG_TEXT@), textWithLanguage | |
3954 | (<code>IPP_TAG_TEXTLANG</code>), uri (<code>IPP_TAG_URI</code>), and uriScheme | |
3955 | (<code>IPP_TAG_URISCHEME</code>).<br> | |
3956 | <br> | |
3957 | The <code>language</code> parameter must be non-<code>NULL</code> for nameWithLanguage | |
3958 | and textWithLanguage string values and must be <code>NULL</code> for all other | |
3959 | string values.<br> | |
3960 | <br> | |
3961 | The <code>format</code> parameter uses formatting characters compatible with the | |
3962 | printf family of standard functions. Additional arguments are passed in the | |
3963 | stdarg pointer <code>ap</code>. The formatted string is truncated as needed to the | |
3964 | maximum length of the corresponding value type. | |
3965 | ||
3966 | </p> | |
5a738aea MS |
3967 | <h3 class="function"><a name="ippAddStrings">ippAddStrings</a></h3> |
3968 | <p class="description">Add language-encoded strings to an IPP message.</p> | |
3969 | <p class="code"> | |
3970 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddStrings (<br> | |
3971 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
a2326b5b MS |
3972 | ipp_tag_t group,<br> |
3973 | ipp_tag_t value_tag,<br> | |
5a738aea MS |
3974 | const char *name,<br> |
3975 | int num_values,<br> | |
a2326b5b | 3976 | const char *language,<br> |
5a738aea MS |
3977 | const char *const *values<br> |
3978 | );</p> | |
3979 | <h4 class="parameters">Parameters</h4> | |
3980 | <dl> | |
3981 | <dt>ipp</dt> | |
3982 | <dd class="description">IPP message</dd> | |
3983 | <dt>group</dt> | |
3984 | <dd class="description">IPP group</dd> | |
a2326b5b | 3985 | <dt>value_tag</dt> |
5a738aea MS |
3986 | <dd class="description">Type of attribute</dd> |
3987 | <dt>name</dt> | |
3988 | <dd class="description">Name of attribute</dd> | |
3989 | <dt>num_values</dt> | |
3990 | <dd class="description">Number of values</dd> | |
a2326b5b MS |
3991 | <dt>language</dt> |
3992 | <dd class="description">Language code (<code>NULL</code> for default)</dd> | |
5a738aea MS |
3993 | <dt>values</dt> |
3994 | <dd class="description">Values</dd> | |
3995 | </dl> | |
3996 | <h4 class="returnvalue">Return Value</h4> | |
3997 | <p class="description">New attribute</p> | |
a2326b5b | 3998 | <h4 class="discussion">Discussion</h4> |
a469f8a5 MS |
3999 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
4000 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
4001 | <br> |
4002 | The <code>group</code> parameter specifies the IPP attribute group tag: none | |
4003 | (<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>), | |
4004 | event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation | |
4005 | (<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription | |
4006 | (<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).<br> | |
4007 | <br> | |
4008 | Supported string values include charset (<code>IPP_TAG_CHARSET</code>), keyword | |
4009 | (<code>IPP_TAG_KEYWORD</code>), language (<code>IPP_TAG_LANGUAGE</code>), mimeMediaType | |
4010 | (<code>IPP_TAG_MIMETYPE</code>), name (<code>IPP_TAG_NAME</code>), nameWithLanguage | |
4011 | (<code>IPP_TAG_NAMELANG), text (</code>code IPP_TAG_TEXT@), textWithLanguage | |
4012 | (<code>IPP_TAG_TEXTLANG</code>), uri (<code>IPP_TAG_URI</code>), and uriScheme | |
4013 | (<code>IPP_TAG_URISCHEME</code>).<br> | |
4014 | <br> | |
4015 | The <code>language</code> parameter must be non-<code>NULL</code> for nameWithLanguage and | |
4016 | textWithLanguage string values and must be <code>NULL</code> for all other string values.</p> | |
f3c17241 | 4017 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippAttributeString">ippAttributeString</a></h3> |
a2326b5b MS |
4018 | <p class="description">Convert the attribute's value to a string.</p> |
4019 | <p class="code"> | |
4020 | size_t ippAttributeString (<br> | |
4021 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br> | |
4022 | char *buffer,<br> | |
4023 | size_t bufsize<br> | |
4024 | );</p> | |
4025 | <h4 class="parameters">Parameters</h4> | |
4026 | <dl> | |
4027 | <dt>attr</dt> | |
4028 | <dd class="description">Attribute</dd> | |
4029 | <dt>buffer</dt> | |
4030 | <dd class="description">String buffer or NULL</dd> | |
4031 | <dt>bufsize</dt> | |
4032 | <dd class="description">Size of string buffer</dd> | |
4033 | </dl> | |
4034 | <h4 class="returnvalue">Return Value</h4> | |
4035 | <p class="description">Number of bytes less nul</p> | |
4036 | <h4 class="discussion">Discussion</h4> | |
4037 | <p class="discussion">Returns the number of bytes that would be written, not including the | |
4038 | trailing nul. The buffer pointer can be NULL to get the required length, | |
4039 | just like (v)snprintf. | |
4040 | ||
a469f8a5 | 4041 | </p> |
9c0e8e5d | 4042 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="ippContainsInteger">ippContainsInteger</a></h3> |
a469f8a5 MS |
4043 | <p class="description">Determine whether an attribute contains the |
4044 | specified value or is within the list of ranges.</p> | |
4045 | <p class="code"> | |
4046 | int ippContainsInteger (<br> | |
4047 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br> | |
4048 | int value<br> | |
4049 | );</p> | |
4050 | <h4 class="parameters">Parameters</h4> | |
4051 | <dl> | |
4052 | <dt>attr</dt> | |
4053 | <dd class="description">Attribute</dd> | |
4054 | <dt>value</dt> | |
4055 | <dd class="description">Integer/enum value</dd> | |
4056 | </dl> | |
4057 | <h4 class="returnvalue">Return Value</h4> | |
4058 | <p class="description">1 on a match, 0 on no match</p> | |
4059 | <h4 class="discussion">Discussion</h4> | |
4060 | <p class="discussion">Returns non-zero when the attribute contains either a matching integer or | |
4061 | enum value, or the value falls within one of the rangeOfInteger values for | |
4062 | the attribute. | |
4063 | ||
4064 | </p> | |
9c0e8e5d | 4065 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="ippContainsString">ippContainsString</a></h3> |
a469f8a5 MS |
4066 | <p class="description">Determine whether an attribute contains the |
4067 | specified string value.</p> | |
4068 | <p class="code"> | |
4069 | int ippContainsString (<br> | |
4070 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br> | |
4071 | const char *value<br> | |
4072 | );</p> | |
4073 | <h4 class="parameters">Parameters</h4> | |
4074 | <dl> | |
4075 | <dt>attr</dt> | |
4076 | <dd class="description">Attribute</dd> | |
4077 | <dt>value</dt> | |
4078 | <dd class="description">String value</dd> | |
4079 | </dl> | |
4080 | <h4 class="returnvalue">Return Value</h4> | |
4081 | <p class="description">1 on a match, 0 on no match</p> | |
4082 | <h4 class="discussion">Discussion</h4> | |
4083 | <p class="discussion">Returns non-zero when the attribute contains a matching charset, keyword, | |
4084 | language, mimeMediaType, name, text, URI, or URI scheme value. | |
4085 | ||
a2326b5b | 4086 | </p> |
f3c17241 | 4087 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippCopyAttribute">ippCopyAttribute</a></h3> |
a2326b5b MS |
4088 | <p class="description">Copy an attribute.</p> |
4089 | <p class="code"> | |
4090 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippCopyAttribute (<br> | |
4091 | <a href="#ipp_t">ipp_t</a> *dst,<br> | |
4092 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *srcattr,<br> | |
4093 | int quickcopy<br> | |
4094 | );</p> | |
4095 | <h4 class="parameters">Parameters</h4> | |
4096 | <dl> | |
4097 | <dt>dst</dt> | |
4098 | <dd class="description">Destination IPP message</dd> | |
4099 | <dt>srcattr</dt> | |
4100 | <dd class="description">Attribute to copy</dd> | |
4101 | <dt>quickcopy</dt> | |
4102 | <dd class="description">1 for a referenced copy, 0 for normal</dd> | |
4103 | </dl> | |
4104 | <h4 class="returnvalue">Return Value</h4> | |
4105 | <p class="description">New attribute</p> | |
4106 | <h4 class="discussion">Discussion</h4> | |
4107 | <p class="discussion">The specified attribute, <code>attr</code>, is copied to the destination IPP message. | |
4108 | When <code>quickcopy</code> is non-zero, a "shallow" reference copy of the attribute is | |
4109 | created - this should only be done as long as the original source IPP message will | |
4110 | not be freed for the life of the destination. | |
4111 | ||
4112 | </p> | |
f3c17241 | 4113 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippCopyAttributes">ippCopyAttributes</a></h3> |
a2326b5b MS |
4114 | <p class="description">Copy attributes from one IPP message to another.</p> |
4115 | <p class="code"> | |
4116 | int ippCopyAttributes (<br> | |
4117 | <a href="#ipp_t">ipp_t</a> *dst,<br> | |
4118 | <a href="#ipp_t">ipp_t</a> *src,<br> | |
4119 | int quickcopy,<br> | |
4120 | <a href="#ipp_copycb_t">ipp_copycb_t</a> cb,<br> | |
4121 | void *context<br> | |
4122 | );</p> | |
4123 | <h4 class="parameters">Parameters</h4> | |
4124 | <dl> | |
4125 | <dt>dst</dt> | |
4126 | <dd class="description">Destination IPP message</dd> | |
4127 | <dt>src</dt> | |
4128 | <dd class="description">Source IPP message</dd> | |
4129 | <dt>quickcopy</dt> | |
4130 | <dd class="description">1 for a referenced copy, 0 for normal</dd> | |
4131 | <dt>cb</dt> | |
4132 | <dd class="description">Copy callback or <code>NULL</code> for none</dd> | |
4133 | <dt>context</dt> | |
4134 | <dd class="description">Context pointer</dd> | |
4135 | </dl> | |
4136 | <h4 class="returnvalue">Return Value</h4> | |
4137 | <p class="description">1 on success, 0 on error</p> | |
4138 | <h4 class="discussion">Discussion</h4> | |
58fce51f | 4139 | <p class="discussion">Zero or more attributes are copied from the source IPP message, <code>src</code>, to the |
a2326b5b MS |
4140 | destination IPP message, <code>dst</code>. When <code>quickcopy</code> is non-zero, a "shallow" |
4141 | reference copy of the attribute is created - this should only be done as long as the | |
4142 | original source IPP message will not be freed for the life of the destination.<br> | |
4143 | <br> | |
4144 | The <code>cb</code> and <code>context</code> parameters provide a generic way to "filter" the | |
4145 | attributes that are copied - the function must return 1 to copy the attribute or | |
4146 | 0 to skip it. The function may also choose to do a partial copy of the source attribute | |
4147 | itself. | |
4148 | ||
db8b865d | 4149 | </p> |
9c0e8e5d | 4150 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="ippCreateRequestedArray">ippCreateRequestedArray</a></h3> |
db8b865d MS |
4151 | <p class="description">Create a CUPS array of attribute names from the |
4152 | given requested-attributes attribute.</p> | |
4153 | <p class="code"> | |
4154 | cups_array_t *ippCreateRequestedArray (<br> | |
4155 | <a href="#ipp_t">ipp_t</a> *request<br> | |
4156 | );</p> | |
4157 | <h4 class="parameters">Parameters</h4> | |
4158 | <dl> | |
4159 | <dt>request</dt> | |
4160 | <dd class="description">IPP request</dd> | |
4161 | </dl> | |
4162 | <h4 class="returnvalue">Return Value</h4> | |
4163 | <p class="description">CUPS array or <code>NULL</code> if all</p> | |
4164 | <h4 class="discussion">Discussion</h4> | |
4165 | <p class="discussion">This function creates a (sorted) CUPS array of attribute names matching the | |
4166 | list of "requested-attribute" values supplied in an IPP request. All IANA- | |
4167 | registered values are supported in addition to the CUPS IPP extension | |
4168 | attributes.<br> | |
4169 | <br> | |
4170 | The <code>request</code> parameter specifies the request message that was read from | |
4171 | the client. | |
4172 | ||
4173 | <code>NULL</code> is returned if all attributes should be returned. Otherwise, the | |
4174 | result is a sorted array of attribute names, where <code>cupsArrayFind(array, | |
4175 | "attribute-name")</code> will return a non-NULL pointer. The array must be freed | |
4176 | using the <code>cupsArrayDelete</code> function. | |
4177 | ||
a2326b5b | 4178 | </p> |
5a738aea MS |
4179 | <h3 class="function"><a name="ippDateToTime">ippDateToTime</a></h3> |
4180 | <p class="description">Convert from RFC 1903 Date/Time format to UNIX time | |
4181 | in seconds.</p> | |
4182 | <p class="code"> | |
4183 | time_t ippDateToTime (<br> | |
4184 | const <a href="#ipp_uchar_t">ipp_uchar_t</a> *date<br> | |
4185 | );</p> | |
4186 | <h4 class="parameters">Parameters</h4> | |
4187 | <dl> | |
4188 | <dt>date</dt> | |
4189 | <dd class="description">RFC 1903 date info</dd> | |
4190 | </dl> | |
4191 | <h4 class="returnvalue">Return Value</h4> | |
4192 | <p class="description">UNIX time value</p> | |
4193 | <h3 class="function"><a name="ippDelete">ippDelete</a></h3> | |
4194 | <p class="description">Delete an IPP message.</p> | |
4195 | <p class="code"> | |
4196 | void ippDelete (<br> | |
4197 | <a href="#ipp_t">ipp_t</a> *ipp<br> | |
4198 | );</p> | |
4199 | <h4 class="parameters">Parameters</h4> | |
4200 | <dl> | |
4201 | <dt>ipp</dt> | |
4202 | <dd class="description">IPP message</dd> | |
4203 | </dl> | |
f3c17241 | 4204 | <h3 class="function"><span class="info"> CUPS 1.1.19/OS X 10.3 </span><a name="ippDeleteAttribute">ippDeleteAttribute</a></h3> |
5a738aea MS |
4205 | <p class="description">Delete a single attribute in an IPP message.</p> |
4206 | <p class="code"> | |
4207 | void ippDeleteAttribute (<br> | |
4208 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
4209 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr<br> | |
4210 | );</p> | |
4211 | <h4 class="parameters">Parameters</h4> | |
4212 | <dl> | |
4213 | <dt>ipp</dt> | |
4214 | <dd class="description">IPP message</dd> | |
4215 | <dt>attr</dt> | |
4216 | <dd class="description">Attribute to delete</dd> | |
4217 | </dl> | |
f3c17241 | 4218 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippDeleteValues">ippDeleteValues</a></h3> |
a2326b5b MS |
4219 | <p class="description">Delete values in an attribute.</p> |
4220 | <p class="code"> | |
4221 | int ippDeleteValues (<br> | |
4222 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
3e7fe0ca | 4223 | <a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br> |
a2326b5b MS |
4224 | int element,<br> |
4225 | int count<br> | |
4226 | );</p> | |
4227 | <h4 class="parameters">Parameters</h4> | |
4228 | <dl> | |
4229 | <dt>ipp</dt> | |
4230 | <dd class="description">IPP message</dd> | |
4231 | <dt>attr</dt> | |
4232 | <dd class="description">Attribute</dd> | |
4233 | <dt>element</dt> | |
4234 | <dd class="description">Index of first value to delete (0-based)</dd> | |
4235 | <dt>count</dt> | |
4236 | <dd class="description">Number of values to delete</dd> | |
4237 | </dl> | |
4238 | <h4 class="returnvalue">Return Value</h4> | |
4239 | <p class="description">1 on success, 0 on failure</p> | |
4240 | <h4 class="discussion">Discussion</h4> | |
3e7fe0ca MS |
4241 | <p class="discussion">The <code>element</code> parameter specifies the first value to delete, starting at |
4242 | 0. It must be less than the number of values returned by <a href="#ippGetCount"><code>ippGetCount</code></a>.<br> | |
4243 | <br> | |
4244 | The <code>attr</code> parameter may be modified as a result of setting the value.<br> | |
a2326b5b MS |
4245 | <br> |
4246 | Deleting all values in an attribute deletes the attribute. | |
4247 | ||
4248 | </p> | |
4249 | <h3 class="function"><a name="ippEnumString">ippEnumString</a></h3> | |
4250 | <p class="description">Return a string corresponding to the enum value.</p> | |
4251 | <p class="code"> | |
4252 | const char *ippEnumString (<br> | |
4253 | const char *attrname,<br> | |
4254 | int enumvalue<br> | |
4255 | );</p> | |
4256 | <h4 class="parameters">Parameters</h4> | |
4257 | <dl> | |
4258 | <dt>attrname</dt> | |
4259 | <dd class="description">Attribute name</dd> | |
4260 | <dt>enumvalue</dt> | |
4261 | <dd class="description">Enum value</dd> | |
4262 | </dl> | |
4263 | <h4 class="returnvalue">Return Value</h4> | |
4264 | <p class="description">Enum string</p> | |
4265 | <h3 class="function"><a name="ippEnumValue">ippEnumValue</a></h3> | |
4266 | <p class="description">Return the value associated with a given enum string.</p> | |
4267 | <p class="code"> | |
4268 | int ippEnumValue (<br> | |
4269 | const char *attrname,<br> | |
4270 | const char *enumstring<br> | |
4271 | );</p> | |
4272 | <h4 class="parameters">Parameters</h4> | |
4273 | <dl> | |
4274 | <dt>attrname</dt> | |
4275 | <dd class="description">Attribute name</dd> | |
4276 | <dt>enumstring</dt> | |
4277 | <dd class="description">Enum string</dd> | |
4278 | </dl> | |
4279 | <h4 class="returnvalue">Return Value</h4> | |
4280 | <p class="description">Enum value or -1 if unknown</p> | |
5a738aea MS |
4281 | <h3 class="function"><a name="ippErrorString">ippErrorString</a></h3> |
4282 | <p class="description">Return a name for the given status code.</p> | |
4283 | <p class="code"> | |
4284 | const char *ippErrorString (<br> | |
4285 | ipp_status_t error<br> | |
4286 | );</p> | |
4287 | <h4 class="parameters">Parameters</h4> | |
4288 | <dl> | |
4289 | <dt>error</dt> | |
4290 | <dd class="description">Error status</dd> | |
4291 | </dl> | |
4292 | <h4 class="returnvalue">Return Value</h4> | |
4293 | <p class="description">Text string</p> | |
f3c17241 | 4294 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="ippErrorValue">ippErrorValue</a></h3> |
5a738aea MS |
4295 | <p class="description">Return a status code for the given name.</p> |
4296 | <p class="code"> | |
4297 | ipp_status_t ippErrorValue (<br> | |
4298 | const char *name<br> | |
4299 | );</p> | |
4300 | <h4 class="parameters">Parameters</h4> | |
4301 | <dl> | |
4302 | <dt>name</dt> | |
4303 | <dd class="description">Name</dd> | |
4304 | </dl> | |
4305 | <h4 class="returnvalue">Return Value</h4> | |
4306 | <p class="description">IPP status code</p> | |
4307 | <h3 class="function"><a name="ippFindAttribute">ippFindAttribute</a></h3> | |
3e7fe0ca | 4308 | <p class="description">Find a named attribute in a request.</p> |
5a738aea MS |
4309 | <p class="code"> |
4310 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippFindAttribute (<br> | |
4311 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
4312 | const char *name,<br> | |
a2326b5b | 4313 | ipp_tag_t type<br> |
5a738aea MS |
4314 | );</p> |
4315 | <h4 class="parameters">Parameters</h4> | |
4316 | <dl> | |
4317 | <dt>ipp</dt> | |
4318 | <dd class="description">IPP message</dd> | |
4319 | <dt>name</dt> | |
4320 | <dd class="description">Name of attribute</dd> | |
4321 | <dt>type</dt> | |
4322 | <dd class="description">Type of attribute</dd> | |
4323 | </dl> | |
4324 | <h4 class="returnvalue">Return Value</h4> | |
4325 | <p class="description">Matching attribute</p> | |
240214ef MS |
4326 | <h4 class="discussion">Discussion</h4> |
4327 | <p class="discussion">Starting with CUPS 2.0, the attribute name can contain a hierarchical list | |
4328 | of attribute and member names separated by slashes, for example | |
4329 | "media-col/media-size".</p> | |
5a738aea | 4330 | <h3 class="function"><a name="ippFindNextAttribute">ippFindNextAttribute</a></h3> |
3e7fe0ca | 4331 | <p class="description">Find the next named attribute in a request.</p> |
5a738aea MS |
4332 | <p class="code"> |
4333 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippFindNextAttribute (<br> | |
4334 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
4335 | const char *name,<br> | |
a2326b5b | 4336 | ipp_tag_t type<br> |
5a738aea MS |
4337 | );</p> |
4338 | <h4 class="parameters">Parameters</h4> | |
4339 | <dl> | |
4340 | <dt>ipp</dt> | |
4341 | <dd class="description">IPP message</dd> | |
4342 | <dt>name</dt> | |
4343 | <dd class="description">Name of attribute</dd> | |
4344 | <dt>type</dt> | |
4345 | <dd class="description">Type of attribute</dd> | |
4346 | </dl> | |
4347 | <h4 class="returnvalue">Return Value</h4> | |
4348 | <p class="description">Matching attribute</p> | |
240214ef MS |
4349 | <h4 class="discussion">Discussion</h4> |
4350 | <p class="discussion">Starting with CUPS 2.0, the attribute name can contain a hierarchical list | |
4351 | of attribute and member names separated by slashes, for example | |
4352 | "media-col/media-size".</p> | |
f3c17241 | 4353 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippFirstAttribute">ippFirstAttribute</a></h3> |
a2326b5b | 4354 | <p class="description">Return the first attribute in the message.</p> |
5a738aea | 4355 | <p class="code"> |
a2326b5b | 4356 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippFirstAttribute (<br> |
5a738aea MS |
4357 | <a href="#ipp_t">ipp_t</a> *ipp<br> |
4358 | );</p> | |
4359 | <h4 class="parameters">Parameters</h4> | |
4360 | <dl> | |
4361 | <dt>ipp</dt> | |
4362 | <dd class="description">IPP message</dd> | |
4363 | </dl> | |
4364 | <h4 class="returnvalue">Return Value</h4> | |
a2326b5b | 4365 | <p class="description">First attribute or <code>NULL</code> if none</p> |
f3c17241 | 4366 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippGetBoolean">ippGetBoolean</a></h3> |
a2326b5b | 4367 | <p class="description">Get a boolean value for an attribute.</p> |
5a738aea | 4368 | <p class="code"> |
a2326b5b MS |
4369 | int ippGetBoolean (<br> |
4370 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br> | |
4371 | int element<br> | |
5a738aea MS |
4372 | );</p> |
4373 | <h4 class="parameters">Parameters</h4> | |
4374 | <dl> | |
a2326b5b MS |
4375 | <dt>attr</dt> |
4376 | <dd class="description">IPP attribute</dd> | |
4377 | <dt>element</dt> | |
4378 | <dd class="description">Value number (0-based)</dd> | |
5a738aea MS |
4379 | </dl> |
4380 | <h4 class="returnvalue">Return Value</h4> | |
240214ef | 4381 | <p class="description">Boolean value or 0 on error</p> |
5a738aea | 4382 | <h4 class="discussion">Discussion</h4> |
a2326b5b MS |
4383 | <p class="discussion">The <code>element</code> parameter specifies which value to get from 0 to |
4384 | <a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a> - 1. | |
ecdc0628 | 4385 | |
5a738aea | 4386 | </p> |
f3c17241 | 4387 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippGetCollection">ippGetCollection</a></h3> |
a2326b5b | 4388 | <p class="description">Get a collection value for an attribute.</p> |
5a738aea | 4389 | <p class="code"> |
a2326b5b MS |
4390 | <a href="#ipp_t">ipp_t</a> *ippGetCollection (<br> |
4391 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br> | |
4392 | int element<br> | |
5a738aea MS |
4393 | );</p> |
4394 | <h4 class="parameters">Parameters</h4> | |
4395 | <dl> | |
a2326b5b MS |
4396 | <dt>attr</dt> |
4397 | <dd class="description">IPP attribute</dd> | |
4398 | <dt>element</dt> | |
4399 | <dd class="description">Value number (0-based)</dd> | |
5a738aea MS |
4400 | </dl> |
4401 | <h4 class="returnvalue">Return Value</h4> | |
a2326b5b MS |
4402 | <p class="description">Collection value or <code>NULL</code> on error</p> |
4403 | <h4 class="discussion">Discussion</h4> | |
4404 | <p class="discussion">The <code>element</code> parameter specifies which value to get from 0 to | |
4405 | <a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a> - 1. | |
4406 | ||
4407 | </p> | |
f3c17241 | 4408 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippGetCount">ippGetCount</a></h3> |
a2326b5b | 4409 | <p class="description">Get the number of values in an attribute.</p> |
5a738aea | 4410 | <p class="code"> |
a2326b5b MS |
4411 | int ippGetCount (<br> |
4412 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr<br> | |
5a738aea MS |
4413 | );</p> |
4414 | <h4 class="parameters">Parameters</h4> | |
4415 | <dl> | |
a2326b5b MS |
4416 | <dt>attr</dt> |
4417 | <dd class="description">IPP attribute</dd> | |
5a738aea MS |
4418 | </dl> |
4419 | <h4 class="returnvalue">Return Value</h4> | |
240214ef | 4420 | <p class="description">Number of values or 0 on error</p> |
f3c17241 | 4421 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippGetDate">ippGetDate</a></h3> |
3e7fe0ca MS |
4422 | <p class="description">Get a date value for an attribute.</p> |
4423 | <p class="code"> | |
4424 | const <a href="#ipp_uchar_t">ipp_uchar_t</a> *ippGetDate (<br> | |
4425 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br> | |
4426 | int element<br> | |
4427 | );</p> | |
4428 | <h4 class="parameters">Parameters</h4> | |
4429 | <dl> | |
4430 | <dt>attr</dt> | |
4431 | <dd class="description">IPP attribute</dd> | |
4432 | <dt>element</dt> | |
4433 | <dd class="description">Value number (0-based)</dd> | |
4434 | </dl> | |
4435 | <h4 class="returnvalue">Return Value</h4> | |
4436 | <p class="description">Date value or <code>NULL</code></p> | |
4437 | <h4 class="discussion">Discussion</h4> | |
4438 | <p class="discussion">The <code>element</code> parameter specifies which value to get from 0 to | |
4439 | <a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a> - 1. | |
4440 | ||
4441 | </p> | |
f3c17241 | 4442 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippGetGroupTag">ippGetGroupTag</a></h3> |
a2326b5b | 4443 | <p class="description">Get the group associated with an attribute.</p> |
5a738aea | 4444 | <p class="code"> |
a2326b5b MS |
4445 | ipp_tag_t ippGetGroupTag (<br> |
4446 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr<br> | |
4447 | );</p> | |
4448 | <h4 class="parameters">Parameters</h4> | |
4449 | <dl> | |
4450 | <dt>attr</dt> | |
4451 | <dd class="description">IPP attribute</dd> | |
4452 | </dl> | |
5a738aea | 4453 | <h4 class="returnvalue">Return Value</h4> |
a2326b5b | 4454 | <p class="description">Group tag or <code>IPP_TAG_ZERO</code> on error</p> |
f3c17241 | 4455 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippGetInteger">ippGetInteger</a></h3> |
a2326b5b | 4456 | <p class="description">Get the integer/enum value for an attribute.</p> |
5a738aea | 4457 | <p class="code"> |
a2326b5b MS |
4458 | int ippGetInteger (<br> |
4459 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br> | |
4460 | int element<br> | |
5a738aea MS |
4461 | );</p> |
4462 | <h4 class="parameters">Parameters</h4> | |
4463 | <dl> | |
a2326b5b MS |
4464 | <dt>attr</dt> |
4465 | <dd class="description">IPP attribute</dd> | |
4466 | <dt>element</dt> | |
4467 | <dd class="description">Value number (0-based)</dd> | |
5a738aea MS |
4468 | </dl> |
4469 | <h4 class="returnvalue">Return Value</h4> | |
240214ef | 4470 | <p class="description">Value or 0 on error</p> |
a2326b5b MS |
4471 | <h4 class="discussion">Discussion</h4> |
4472 | <p class="discussion">The <code>element</code> parameter specifies which value to get from 0 to | |
4473 | <a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a> - 1. | |
4474 | ||
4475 | </p> | |
f3c17241 | 4476 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippGetName">ippGetName</a></h3> |
a2326b5b | 4477 | <p class="description">Get the attribute name.</p> |
5a738aea | 4478 | <p class="code"> |
a2326b5b MS |
4479 | const char *ippGetName (<br> |
4480 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr<br> | |
5a738aea MS |
4481 | );</p> |
4482 | <h4 class="parameters">Parameters</h4> | |
4483 | <dl> | |
a2326b5b MS |
4484 | <dt>attr</dt> |
4485 | <dd class="description">IPP attribute</dd> | |
5a738aea MS |
4486 | </dl> |
4487 | <h4 class="returnvalue">Return Value</h4> | |
a2326b5b | 4488 | <p class="description">Attribute name or <code>NULL</code> for separators</p> |
9c0e8e5d | 4489 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="ippGetOctetString">ippGetOctetString</a></h3> |
6961465f MS |
4490 | <p class="description">Get an octetString value from an IPP attribute.</p> |
4491 | <p class="code"> | |
4492 | void *ippGetOctetString (<br> | |
4493 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br> | |
4494 | int element,<br> | |
4495 | int *datalen<br> | |
4496 | );</p> | |
4497 | <h4 class="parameters">Parameters</h4> | |
4498 | <dl> | |
4499 | <dt>attr</dt> | |
4500 | <dd class="description">IPP attribute</dd> | |
4501 | <dt>element</dt> | |
4502 | <dd class="description">Value number (0-based)</dd> | |
4503 | <dt>datalen</dt> | |
4504 | <dd class="description">Length of octetString data</dd> | |
4505 | </dl> | |
4506 | <h4 class="returnvalue">Return Value</h4> | |
4507 | <p class="description">Pointer to octetString data</p> | |
4508 | <h4 class="discussion">Discussion</h4> | |
4509 | <p class="discussion">The <code>element</code> parameter specifies which value to get from 0 to | |
4510 | <a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a> - 1. | |
4511 | ||
4512 | </p> | |
f3c17241 | 4513 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippGetOperation">ippGetOperation</a></h3> |
a2326b5b | 4514 | <p class="description">Get the operation ID in an IPP message.</p> |
5a738aea | 4515 | <p class="code"> |
a2326b5b | 4516 | ipp_op_t ippGetOperation (<br> |
5a738aea MS |
4517 | <a href="#ipp_t">ipp_t</a> *ipp<br> |
4518 | );</p> | |
4519 | <h4 class="parameters">Parameters</h4> | |
4520 | <dl> | |
5a738aea | 4521 | <dt>ipp</dt> |
a2326b5b | 4522 | <dd class="description">IPP request message</dd> |
5a738aea MS |
4523 | </dl> |
4524 | <h4 class="returnvalue">Return Value</h4> | |
240214ef | 4525 | <p class="description">Operation ID or 0 on error</p> |
f3c17241 | 4526 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippGetRange">ippGetRange</a></h3> |
3e7fe0ca MS |
4527 | <p class="description">Get a rangeOfInteger value from an attribute.</p> |
4528 | <p class="code"> | |
4529 | int ippGetRange (<br> | |
4530 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br> | |
4531 | int element,<br> | |
4532 | int *uppervalue<br> | |
4533 | );</p> | |
4534 | <h4 class="parameters">Parameters</h4> | |
4535 | <dl> | |
4536 | <dt>attr</dt> | |
4537 | <dd class="description">IPP attribute</dd> | |
4538 | <dt>element</dt> | |
4539 | <dd class="description">Value number (0-based)</dd> | |
4540 | <dt>uppervalue</dt> | |
4541 | <dd class="description">Upper value of range</dd> | |
4542 | </dl> | |
4543 | <h4 class="returnvalue">Return Value</h4> | |
240214ef | 4544 | <p class="description">Lower value of range or 0</p> |
3e7fe0ca MS |
4545 | <h4 class="discussion">Discussion</h4> |
4546 | <p class="discussion">The <code>element</code> parameter specifies which value to get from 0 to | |
4547 | <a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a> - 1. | |
4548 | ||
4549 | </p> | |
f3c17241 | 4550 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippGetRequestId">ippGetRequestId</a></h3> |
a2326b5b | 4551 | <p class="description">Get the request ID from an IPP message.</p> |
5a738aea | 4552 | <p class="code"> |
a2326b5b MS |
4553 | int ippGetRequestId (<br> |
4554 | <a href="#ipp_t">ipp_t</a> *ipp<br> | |
5a738aea MS |
4555 | );</p> |
4556 | <h4 class="parameters">Parameters</h4> | |
4557 | <dl> | |
a2326b5b MS |
4558 | <dt>ipp</dt> |
4559 | <dd class="description">IPP message</dd> | |
5a738aea | 4560 | </dl> |
a2326b5b | 4561 | <h4 class="returnvalue">Return Value</h4> |
240214ef | 4562 | <p class="description">Request ID or 0 on error</p> |
f3c17241 | 4563 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippGetResolution">ippGetResolution</a></h3> |
a2326b5b MS |
4564 | <p class="description">Get a resolution value for an attribute.</p> |
4565 | <p class="code"> | |
4566 | int ippGetResolution (<br> | |
4567 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br> | |
4568 | int element,<br> | |
4569 | int *yres,<br> | |
4570 | <a href="#ipp_res_t">ipp_res_t</a> *units<br> | |
06d4e77b MS |
4571 | );</p> |
4572 | <h4 class="parameters">Parameters</h4> | |
4573 | <dl> | |
a2326b5b MS |
4574 | <dt>attr</dt> |
4575 | <dd class="description">IPP attribute</dd> | |
4576 | <dt>element</dt> | |
4577 | <dd class="description">Value number (0-based)</dd> | |
4578 | <dt>yres</dt> | |
4579 | <dd class="description">Vertical/feed resolution</dd> | |
4580 | <dt>units</dt> | |
4581 | <dd class="description">Units for resolution</dd> | |
4582 | </dl> | |
4583 | <h4 class="returnvalue">Return Value</h4> | |
240214ef | 4584 | <p class="description">Horizontal/cross feed resolution or 0</p> |
a2326b5b MS |
4585 | <h4 class="discussion">Discussion</h4> |
4586 | <p class="discussion">The <code>element</code> parameter specifies which value to get from 0 to | |
4587 | <a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a> - 1. | |
4588 | ||
4589 | </p> | |
f3c17241 | 4590 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippGetState">ippGetState</a></h3> |
3e7fe0ca MS |
4591 | <p class="description">Get the IPP message state.</p> |
4592 | <p class="code"> | |
4593 | <a href="#ipp_state_t">ipp_state_t</a> ippGetState (<br> | |
4594 | <a href="#ipp_t">ipp_t</a> *ipp<br> | |
4595 | );</p> | |
4596 | <h4 class="parameters">Parameters</h4> | |
4597 | <dl> | |
4598 | <dt>ipp</dt> | |
4599 | <dd class="description">IPP message</dd> | |
4600 | </dl> | |
4601 | <h4 class="returnvalue">Return Value</h4> | |
4602 | <p class="description">IPP message state value</p> | |
f3c17241 | 4603 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippGetStatusCode">ippGetStatusCode</a></h3> |
a2326b5b MS |
4604 | <p class="description">Get the status code from an IPP response or event message.</p> |
4605 | <p class="code"> | |
4606 | ipp_status_t ippGetStatusCode (<br> | |
4607 | <a href="#ipp_t">ipp_t</a> *ipp<br> | |
4608 | );</p> | |
4609 | <h4 class="parameters">Parameters</h4> | |
4610 | <dl> | |
4611 | <dt>ipp</dt> | |
4612 | <dd class="description">IPP response or event message</dd> | |
4613 | </dl> | |
4614 | <h4 class="returnvalue">Return Value</h4> | |
4615 | <p class="description">Status code in IPP message</p> | |
4616 | <h3 class="function"><a name="ippGetString">ippGetString</a></h3> | |
4617 | <p class="description">Return the value...</p> | |
4618 | <p class="code"> | |
4619 | const char *ippGetString (<br> | |
4620 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br> | |
4621 | int element,<br> | |
4622 | const char **language<br> | |
4623 | );</p> | |
4624 | <h4 class="parameters">Parameters</h4> | |
4625 | <dl> | |
4626 | <dt>attr</dt> | |
4627 | <dd class="description">IPP attribute</dd> | |
4628 | <dt>element</dt> | |
4629 | <dd class="description">Value number (0-based)</dd> | |
4630 | <dt>language</dt> | |
4631 | <dd class="description">Language code (<code>NULL</code> for don't care)</dd> | |
4632 | </dl> | |
4633 | <h4 class="returnvalue">Return Value</h4> | |
4634 | <p class="description">Get the string and optionally the language code for an attribute.</p> | |
4635 | <p class="discussion">The <code>element</code> parameter specifies which value to get from 0 to | |
4636 | <a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a> - 1. | |
4637 | ||
4638 | </p> | |
f3c17241 | 4639 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippGetValueTag">ippGetValueTag</a></h3> |
a2326b5b MS |
4640 | <p class="description">Get the value tag for an attribute.</p> |
4641 | <p class="code"> | |
4642 | ipp_tag_t ippGetValueTag (<br> | |
4643 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr<br> | |
4644 | );</p> | |
4645 | <h4 class="parameters">Parameters</h4> | |
4646 | <dl> | |
4647 | <dt>attr</dt> | |
4648 | <dd class="description">IPP attribute</dd> | |
4649 | </dl> | |
4650 | <h4 class="returnvalue">Return Value</h4> | |
4651 | <p class="description">Value tag or <code>IPP_TAG_ZERO</code> on error</p> | |
f3c17241 | 4652 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippGetVersion">ippGetVersion</a></h3> |
a2326b5b MS |
4653 | <p class="description">Get the major and minor version number from an IPP message.</p> |
4654 | <p class="code"> | |
4655 | int ippGetVersion (<br> | |
4656 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
4657 | int *minor<br> | |
4658 | );</p> | |
4659 | <h4 class="parameters">Parameters</h4> | |
4660 | <dl> | |
4661 | <dt>ipp</dt> | |
4662 | <dd class="description">IPP message</dd> | |
4663 | <dt>minor</dt> | |
4664 | <dd class="description">Minor version number or <code>NULL</code></dd> | |
4665 | </dl> | |
4666 | <h4 class="returnvalue">Return Value</h4> | |
240214ef | 4667 | <p class="description">Major version number or 0 on error</p> |
a2326b5b MS |
4668 | <h3 class="function"><a name="ippLength">ippLength</a></h3> |
4669 | <p class="description">Compute the length of an IPP message.</p> | |
4670 | <p class="code"> | |
4671 | size_t ippLength (<br> | |
4672 | <a href="#ipp_t">ipp_t</a> *ipp<br> | |
4673 | );</p> | |
4674 | <h4 class="parameters">Parameters</h4> | |
4675 | <dl> | |
4676 | <dt>ipp</dt> | |
4677 | <dd class="description">IPP message</dd> | |
4678 | </dl> | |
4679 | <h4 class="returnvalue">Return Value</h4> | |
4680 | <p class="description">Size of IPP message</p> | |
4681 | <h3 class="function"><a name="ippNew">ippNew</a></h3> | |
4682 | <p class="description">Allocate a new IPP message.</p> | |
4683 | <p class="code"> | |
4684 | <a href="#ipp_t">ipp_t</a> *ippNew (void);</p> | |
4685 | <h4 class="returnvalue">Return Value</h4> | |
4686 | <p class="description">New IPP message</p> | |
f3c17241 | 4687 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="ippNewRequest">ippNewRequest</a></h3> |
a2326b5b MS |
4688 | <p class="description">Allocate a new IPP request message.</p> |
4689 | <p class="code"> | |
4690 | <a href="#ipp_t">ipp_t</a> *ippNewRequest (<br> | |
4691 | ipp_op_t op<br> | |
4692 | );</p> | |
4693 | <h4 class="parameters">Parameters</h4> | |
4694 | <dl> | |
4695 | <dt>op</dt> | |
4696 | <dd class="description">Operation code</dd> | |
4697 | </dl> | |
4698 | <h4 class="returnvalue">Return Value</h4> | |
4699 | <p class="description">IPP request message</p> | |
4700 | <h4 class="discussion">Discussion</h4> | |
4701 | <p class="discussion">The new request message is initialized with the attributes-charset and | |
4702 | attributes-natural-language attributes added. The | |
4703 | attributes-natural-language value is derived from the current locale. | |
4704 | ||
a469f8a5 | 4705 | </p> |
9c0e8e5d | 4706 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="ippNewResponse">ippNewResponse</a></h3> |
a469f8a5 MS |
4707 | <p class="description">Allocate a new IPP response message.</p> |
4708 | <p class="code"> | |
4709 | <a href="#ipp_t">ipp_t</a> *ippNewResponse (<br> | |
4710 | <a href="#ipp_t">ipp_t</a> *request<br> | |
4711 | );</p> | |
4712 | <h4 class="parameters">Parameters</h4> | |
4713 | <dl> | |
4714 | <dt>request</dt> | |
4715 | <dd class="description">IPP request message</dd> | |
4716 | </dl> | |
4717 | <h4 class="returnvalue">Return Value</h4> | |
4718 | <p class="description">IPP response message</p> | |
4719 | <h4 class="discussion">Discussion</h4> | |
4720 | <p class="discussion">The new response message is initialized with the same version-number, | |
4721 | request-id, attributes-charset, and attributes-natural-language as the | |
4722 | provided request message. If the attributes-charset or | |
4723 | attributes-natural-language attributes are missing from the request, | |
4724 | "utf-8" and a value derived from the current locale are substituted, | |
4725 | respectively. | |
4726 | ||
a2326b5b | 4727 | </p> |
f3c17241 | 4728 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippNextAttribute">ippNextAttribute</a></h3> |
a2326b5b MS |
4729 | <p class="description">Return the next attribute in the message.</p> |
4730 | <p class="code"> | |
4731 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *ippNextAttribute (<br> | |
4732 | <a href="#ipp_t">ipp_t</a> *ipp<br> | |
4733 | );</p> | |
4734 | <h4 class="parameters">Parameters</h4> | |
4735 | <dl> | |
4736 | <dt>ipp</dt> | |
4737 | <dd class="description">IPP message</dd> | |
4738 | </dl> | |
4739 | <h4 class="returnvalue">Return Value</h4> | |
4740 | <p class="description">Next attribute or <code>NULL</code> if none</p> | |
f3c17241 | 4741 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="ippOpString">ippOpString</a></h3> |
a2326b5b MS |
4742 | <p class="description">Return a name for the given operation id.</p> |
4743 | <p class="code"> | |
4744 | const char *ippOpString (<br> | |
4745 | ipp_op_t op<br> | |
4746 | );</p> | |
4747 | <h4 class="parameters">Parameters</h4> | |
4748 | <dl> | |
4749 | <dt>op</dt> | |
4750 | <dd class="description">Operation ID</dd> | |
4751 | </dl> | |
4752 | <h4 class="returnvalue">Return Value</h4> | |
4753 | <p class="description">Name</p> | |
f3c17241 | 4754 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="ippOpValue">ippOpValue</a></h3> |
a2326b5b MS |
4755 | <p class="description">Return an operation id for the given name.</p> |
4756 | <p class="code"> | |
4757 | ipp_op_t ippOpValue (<br> | |
4758 | const char *name<br> | |
4759 | );</p> | |
4760 | <h4 class="parameters">Parameters</h4> | |
4761 | <dl> | |
4762 | <dt>name</dt> | |
4763 | <dd class="description">Textual name</dd> | |
4764 | </dl> | |
4765 | <h4 class="returnvalue">Return Value</h4> | |
4766 | <p class="description">Operation ID</p> | |
4767 | <h3 class="function"><a name="ippPort">ippPort</a></h3> | |
4768 | <p class="description">Return the default IPP port number.</p> | |
4769 | <p class="code"> | |
4770 | int ippPort (void);</p> | |
4771 | <h4 class="returnvalue">Return Value</h4> | |
4772 | <p class="description">Port number</p> | |
4773 | <h3 class="function"><a name="ippRead">ippRead</a></h3> | |
4774 | <p class="description">Read data for an IPP message from a HTTP connection.</p> | |
4775 | <p class="code"> | |
4776 | <a href="#ipp_state_t">ipp_state_t</a> ippRead (<br> | |
4777 | <a href="#http_t">http_t</a> *http,<br> | |
4778 | <a href="#ipp_t">ipp_t</a> *ipp<br> | |
4779 | );</p> | |
4780 | <h4 class="parameters">Parameters</h4> | |
4781 | <dl> | |
4782 | <dt>http</dt> | |
4783 | <dd class="description">HTTP connection</dd> | |
4784 | <dt>ipp</dt> | |
4785 | <dd class="description">IPP data</dd> | |
4786 | </dl> | |
4787 | <h4 class="returnvalue">Return Value</h4> | |
4788 | <p class="description">Current state</p> | |
f3c17241 | 4789 | <h3 class="function"><span class="info"> CUPS 1.1.19/OS X 10.3 </span><a name="ippReadFile">ippReadFile</a></h3> |
a2326b5b MS |
4790 | <p class="description">Read data for an IPP message from a file.</p> |
4791 | <p class="code"> | |
4792 | <a href="#ipp_state_t">ipp_state_t</a> ippReadFile (<br> | |
4793 | int fd,<br> | |
4794 | <a href="#ipp_t">ipp_t</a> *ipp<br> | |
4795 | );</p> | |
4796 | <h4 class="parameters">Parameters</h4> | |
4797 | <dl> | |
4798 | <dt>fd</dt> | |
4799 | <dd class="description">HTTP data</dd> | |
4800 | <dt>ipp</dt> | |
4801 | <dd class="description">IPP data</dd> | |
4802 | </dl> | |
4803 | <h4 class="returnvalue">Return Value</h4> | |
4804 | <p class="description">Current state</p> | |
f3c17241 | 4805 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="ippReadIO">ippReadIO</a></h3> |
a2326b5b MS |
4806 | <p class="description">Read data for an IPP message.</p> |
4807 | <p class="code"> | |
4808 | <a href="#ipp_state_t">ipp_state_t</a> ippReadIO (<br> | |
4809 | void *src,<br> | |
4810 | <a href="#ipp_iocb_t">ipp_iocb_t</a> cb,<br> | |
4811 | int blocking,<br> | |
4812 | <a href="#ipp_t">ipp_t</a> *parent,<br> | |
4813 | <a href="#ipp_t">ipp_t</a> *ipp<br> | |
4814 | );</p> | |
4815 | <h4 class="parameters">Parameters</h4> | |
4816 | <dl> | |
4817 | <dt>src</dt> | |
4818 | <dd class="description">Data source</dd> | |
4819 | <dt>cb</dt> | |
4820 | <dd class="description">Read callback function</dd> | |
4821 | <dt>blocking</dt> | |
4822 | <dd class="description">Use blocking IO?</dd> | |
4823 | <dt>parent</dt> | |
4824 | <dd class="description">Parent request, if any</dd> | |
4825 | <dt>ipp</dt> | |
4826 | <dd class="description">IPP data</dd> | |
4827 | </dl> | |
4828 | <h4 class="returnvalue">Return Value</h4> | |
4829 | <p class="description">Current state</p> | |
f3c17241 | 4830 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippSetBoolean">ippSetBoolean</a></h3> |
a2326b5b MS |
4831 | <p class="description">Set a boolean value in an attribute.</p> |
4832 | <p class="code"> | |
4833 | int ippSetBoolean (<br> | |
4834 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
4835 | <a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br> | |
4836 | int element,<br> | |
4837 | int boolvalue<br> | |
4838 | );</p> | |
4839 | <h4 class="parameters">Parameters</h4> | |
4840 | <dl> | |
4841 | <dt>ipp</dt> | |
4842 | <dd class="description">IPP message</dd> | |
4843 | <dt>attr</dt> | |
4844 | <dd class="description">IPP attribute</dd> | |
4845 | <dt>element</dt> | |
4846 | <dd class="description">Value number (0-based)</dd> | |
4847 | <dt>boolvalue</dt> | |
4848 | <dd class="description">Boolean value</dd> | |
4849 | </dl> | |
4850 | <h4 class="returnvalue">Return Value</h4> | |
4851 | <p class="description">1 on success, 0 on failure</p> | |
4852 | <h4 class="discussion">Discussion</h4> | |
a469f8a5 MS |
4853 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
4854 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
4855 | <br> |
4856 | The <code>attr</code> parameter may be modified as a result of setting the value.<br> | |
4857 | <br> | |
4858 | The <code>element</code> parameter specifies which value to set from 0 to | |
4859 | <a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>. | |
4860 | ||
4861 | </p> | |
f3c17241 | 4862 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippSetCollection">ippSetCollection</a></h3> |
a2326b5b MS |
4863 | <p class="description">Set a collection value in an attribute.</p> |
4864 | <p class="code"> | |
4865 | int ippSetCollection (<br> | |
4866 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
4867 | <a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br> | |
4868 | int element,<br> | |
4869 | <a href="#ipp_t">ipp_t</a> *colvalue<br> | |
4870 | );</p> | |
4871 | <h4 class="parameters">Parameters</h4> | |
4872 | <dl> | |
4873 | <dt>ipp</dt> | |
4874 | <dd class="description">IPP message</dd> | |
4875 | <dt>attr</dt> | |
4876 | <dd class="description">IPP attribute</dd> | |
4877 | <dt>element</dt> | |
4878 | <dd class="description">Value number (0-based)</dd> | |
4879 | <dt>colvalue</dt> | |
4880 | <dd class="description">Collection value</dd> | |
4881 | </dl> | |
4882 | <h4 class="returnvalue">Return Value</h4> | |
4883 | <p class="description">1 on success, 0 on failure</p> | |
4884 | <h4 class="discussion">Discussion</h4> | |
a469f8a5 MS |
4885 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
4886 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
4887 | <br> |
4888 | The <code>attr</code> parameter may be modified as a result of setting the value.<br> | |
4889 | <br> | |
4890 | The <code>element</code> parameter specifies which value to set from 0 to | |
4891 | <a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>. | |
4892 | ||
3e7fe0ca | 4893 | </p> |
f3c17241 | 4894 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippSetDate">ippSetDate</a></h3> |
3e7fe0ca MS |
4895 | <p class="description">Set a date value in an attribute.</p> |
4896 | <p class="code"> | |
4897 | int ippSetDate (<br> | |
4898 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
4899 | <a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br> | |
4900 | int element,<br> | |
4901 | const <a href="#ipp_uchar_t">ipp_uchar_t</a> *datevalue<br> | |
4902 | );</p> | |
4903 | <h4 class="parameters">Parameters</h4> | |
4904 | <dl> | |
4905 | <dt>ipp</dt> | |
4906 | <dd class="description">IPP message</dd> | |
4907 | <dt>attr</dt> | |
4908 | <dd class="description">IPP attribute</dd> | |
4909 | <dt>element</dt> | |
4910 | <dd class="description">Value number (0-based)</dd> | |
4911 | <dt>datevalue</dt> | |
4912 | <dd class="description">Date value</dd> | |
4913 | </dl> | |
4914 | <h4 class="returnvalue">Return Value</h4> | |
4915 | <p class="description">1 on success, 0 on failure</p> | |
4916 | <h4 class="discussion">Discussion</h4> | |
a469f8a5 MS |
4917 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
4918 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
3e7fe0ca MS |
4919 | <br> |
4920 | The <code>attr</code> parameter may be modified as a result of setting the value.<br> | |
4921 | <br> | |
4922 | The <code>element</code> parameter specifies which value to set from 0 to | |
4923 | <a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>. | |
4924 | ||
a2326b5b | 4925 | </p> |
f3c17241 | 4926 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippSetGroupTag">ippSetGroupTag</a></h3> |
a2326b5b MS |
4927 | <p class="description">Set the group tag of an attribute.</p> |
4928 | <p class="code"> | |
4929 | int ippSetGroupTag (<br> | |
4930 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
4931 | <a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br> | |
4932 | ipp_tag_t group_tag<br> | |
4933 | );</p> | |
4934 | <h4 class="parameters">Parameters</h4> | |
4935 | <dl> | |
4936 | <dt>ipp</dt> | |
4937 | <dd class="description">IPP message</dd> | |
4938 | <dt>attr</dt> | |
4939 | <dd class="description">Attribute</dd> | |
4940 | <dt>group_tag</dt> | |
4941 | <dd class="description">Group tag</dd> | |
4942 | </dl> | |
4943 | <h4 class="returnvalue">Return Value</h4> | |
4944 | <p class="description">1 on success, 0 on failure</p> | |
4945 | <h4 class="discussion">Discussion</h4> | |
a469f8a5 MS |
4946 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
4947 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
4948 | <br> |
4949 | The <code>attr</code> parameter may be modified as a result of setting the value.<br> | |
4950 | <br> | |
4951 | The <code>group</code> parameter specifies the IPP attribute group tag: none | |
4952 | (<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>), | |
4953 | event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation | |
4954 | (<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription | |
4955 | (<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>). | |
4956 | ||
4957 | </p> | |
f3c17241 | 4958 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippSetInteger">ippSetInteger</a></h3> |
a2326b5b MS |
4959 | <p class="description">Set an integer or enum value in an attribute.</p> |
4960 | <p class="code"> | |
4961 | int ippSetInteger (<br> | |
4962 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
4963 | <a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br> | |
4964 | int element,<br> | |
4965 | int intvalue<br> | |
4966 | );</p> | |
4967 | <h4 class="parameters">Parameters</h4> | |
4968 | <dl> | |
4969 | <dt>ipp</dt> | |
4970 | <dd class="description">IPP message</dd> | |
4971 | <dt>attr</dt> | |
4972 | <dd class="description">IPP attribute</dd> | |
4973 | <dt>element</dt> | |
4974 | <dd class="description">Value number (0-based)</dd> | |
4975 | <dt>intvalue</dt> | |
4976 | <dd class="description">Integer/enum value</dd> | |
4977 | </dl> | |
4978 | <h4 class="returnvalue">Return Value</h4> | |
4979 | <p class="description">1 on success, 0 on failure</p> | |
4980 | <h4 class="discussion">Discussion</h4> | |
a469f8a5 MS |
4981 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
4982 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
4983 | <br> |
4984 | The <code>attr</code> parameter may be modified as a result of setting the value.<br> | |
4985 | <br> | |
4986 | The <code>element</code> parameter specifies which value to set from 0 to | |
4987 | <a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>. | |
4988 | ||
4989 | </p> | |
f3c17241 | 4990 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippSetName">ippSetName</a></h3> |
a2326b5b MS |
4991 | <p class="description">Set the name of an attribute.</p> |
4992 | <p class="code"> | |
4993 | int ippSetName (<br> | |
4994 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
4995 | <a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br> | |
4996 | const char *name<br> | |
4997 | );</p> | |
4998 | <h4 class="parameters">Parameters</h4> | |
4999 | <dl> | |
5000 | <dt>ipp</dt> | |
5001 | <dd class="description">IPP message</dd> | |
5002 | <dt>attr</dt> | |
5003 | <dd class="description">IPP attribute</dd> | |
5004 | <dt>name</dt> | |
5005 | <dd class="description">Attribute name</dd> | |
5006 | </dl> | |
5007 | <h4 class="returnvalue">Return Value</h4> | |
5008 | <p class="description">1 on success, 0 on failure</p> | |
5009 | <h4 class="discussion">Discussion</h4> | |
a469f8a5 MS |
5010 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
5011 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
5012 | <br> |
5013 | The <code>attr</code> parameter may be modified as a result of setting the value. | |
5014 | ||
6961465f | 5015 | </p> |
9c0e8e5d | 5016 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="ippSetOctetString">ippSetOctetString</a></h3> |
6961465f MS |
5017 | <p class="description">Set an octetString value in an IPP attribute.</p> |
5018 | <p class="code"> | |
5019 | int ippSetOctetString (<br> | |
5020 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
5021 | <a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br> | |
5022 | int element,<br> | |
5023 | const void *data,<br> | |
5024 | int datalen<br> | |
5025 | );</p> | |
5026 | <h4 class="parameters">Parameters</h4> | |
5027 | <dl> | |
5028 | <dt>ipp</dt> | |
5029 | <dd class="description">IPP message</dd> | |
5030 | <dt>attr</dt> | |
5031 | <dd class="description">IPP attribute</dd> | |
5032 | <dt>element</dt> | |
5033 | <dd class="description">Value number (0-based)</dd> | |
5034 | <dt>data</dt> | |
5035 | <dd class="description">Pointer to octetString data</dd> | |
5036 | <dt>datalen</dt> | |
5037 | <dd class="description">Length of octetString data</dd> | |
5038 | </dl> | |
5039 | <h4 class="returnvalue">Return Value</h4> | |
5040 | <p class="description">1 on success, 0 on failure</p> | |
5041 | <h4 class="discussion">Discussion</h4> | |
5042 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using | |
5043 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
5044 | <br> | |
5045 | The <code>attr</code> parameter may be modified as a result of setting the value.<br> | |
5046 | <br> | |
5047 | The <code>element</code> parameter specifies which value to set from 0 to | |
5048 | <a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>. | |
5049 | ||
a2326b5b | 5050 | </p> |
f3c17241 | 5051 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippSetOperation">ippSetOperation</a></h3> |
a2326b5b MS |
5052 | <p class="description">Set the operation ID in an IPP request message.</p> |
5053 | <p class="code"> | |
5054 | int ippSetOperation (<br> | |
5055 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
5056 | ipp_op_t op<br> | |
5057 | );</p> | |
5058 | <h4 class="parameters">Parameters</h4> | |
5059 | <dl> | |
5060 | <dt>ipp</dt> | |
5061 | <dd class="description">IPP request message</dd> | |
5062 | <dt>op</dt> | |
5063 | <dd class="description">Operation ID</dd> | |
5064 | </dl> | |
5065 | <h4 class="returnvalue">Return Value</h4> | |
5066 | <p class="description">1 on success, 0 on failure</p> | |
5067 | <h4 class="discussion">Discussion</h4> | |
a469f8a5 MS |
5068 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
5069 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions. | |
a2326b5b MS |
5070 | |
5071 | </p> | |
5072 | <h3 class="function"><a name="ippSetPort">ippSetPort</a></h3> | |
5073 | <p class="description">Set the default port number.</p> | |
5074 | <p class="code"> | |
5075 | void ippSetPort (<br> | |
5076 | int p<br> | |
5077 | );</p> | |
5078 | <h4 class="parameters">Parameters</h4> | |
5079 | <dl> | |
5080 | <dt>p</dt> | |
5081 | <dd class="description">Port number to use</dd> | |
5082 | </dl> | |
f3c17241 | 5083 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippSetRange">ippSetRange</a></h3> |
a2326b5b MS |
5084 | <p class="description">Set a rangeOfInteger value in an attribute.</p> |
5085 | <p class="code"> | |
5086 | int ippSetRange (<br> | |
5087 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
5088 | <a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br> | |
5089 | int element,<br> | |
5090 | int lowervalue,<br> | |
5091 | int uppervalue<br> | |
5092 | );</p> | |
5093 | <h4 class="parameters">Parameters</h4> | |
5094 | <dl> | |
5095 | <dt>ipp</dt> | |
5096 | <dd class="description">IPP message</dd> | |
5097 | <dt>attr</dt> | |
5098 | <dd class="description">IPP attribute</dd> | |
5099 | <dt>element</dt> | |
5100 | <dd class="description">Value number (0-based)</dd> | |
5101 | <dt>lowervalue</dt> | |
5102 | <dd class="description">Lower bound for range</dd> | |
5103 | <dt>uppervalue</dt> | |
5104 | <dd class="description">Upper bound for range</dd> | |
5105 | </dl> | |
5106 | <h4 class="returnvalue">Return Value</h4> | |
5107 | <p class="description">1 on success, 0 on failure</p> | |
5108 | <h4 class="discussion">Discussion</h4> | |
a469f8a5 MS |
5109 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
5110 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
5111 | <br> |
5112 | The <code>attr</code> parameter may be modified as a result of setting the value.<br> | |
5113 | <br> | |
5114 | The <code>element</code> parameter specifies which value to set from 0 to | |
5115 | <a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>. | |
5116 | ||
5117 | </p> | |
f3c17241 | 5118 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippSetRequestId">ippSetRequestId</a></h3> |
a2326b5b MS |
5119 | <p class="description">Set the request ID in an IPP message.</p> |
5120 | <p class="code"> | |
5121 | int ippSetRequestId (<br> | |
5122 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
5123 | int request_id<br> | |
5124 | );</p> | |
5125 | <h4 class="parameters">Parameters</h4> | |
5126 | <dl> | |
5127 | <dt>ipp</dt> | |
5128 | <dd class="description">IPP message</dd> | |
5129 | <dt>request_id</dt> | |
5130 | <dd class="description">Request ID</dd> | |
5131 | </dl> | |
5132 | <h4 class="returnvalue">Return Value</h4> | |
5133 | <p class="description">1 on success, 0 on failure</p> | |
5134 | <h4 class="discussion">Discussion</h4> | |
a469f8a5 MS |
5135 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
5136 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
5137 | <br> |
5138 | The <code>request_id</code> parameter must be greater than 0. | |
5139 | ||
5140 | </p> | |
f3c17241 | 5141 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippSetResolution">ippSetResolution</a></h3> |
a2326b5b MS |
5142 | <p class="description">Set a resolution value in an attribute.</p> |
5143 | <p class="code"> | |
5144 | int ippSetResolution (<br> | |
5145 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
5146 | <a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br> | |
5147 | int element,<br> | |
5148 | <a href="#ipp_res_t">ipp_res_t</a> unitsvalue,<br> | |
5149 | int xresvalue,<br> | |
5150 | int yresvalue<br> | |
5151 | );</p> | |
5152 | <h4 class="parameters">Parameters</h4> | |
5153 | <dl> | |
5154 | <dt>ipp</dt> | |
5155 | <dd class="description">IPP message</dd> | |
5156 | <dt>attr</dt> | |
5157 | <dd class="description">IPP attribute</dd> | |
5158 | <dt>element</dt> | |
5159 | <dd class="description">Value number (0-based)</dd> | |
5160 | <dt>unitsvalue</dt> | |
5161 | <dd class="description">Resolution units</dd> | |
5162 | <dt>xresvalue</dt> | |
5163 | <dd class="description">Horizontal/cross feed resolution</dd> | |
5164 | <dt>yresvalue</dt> | |
5165 | <dd class="description">Vertical/feed resolution</dd> | |
5166 | </dl> | |
5167 | <h4 class="returnvalue">Return Value</h4> | |
5168 | <p class="description">1 on success, 0 on failure</p> | |
5169 | <h4 class="discussion">Discussion</h4> | |
a469f8a5 MS |
5170 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
5171 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
5172 | <br> |
5173 | The <code>attr</code> parameter may be modified as a result of setting the value.<br> | |
5174 | <br> | |
5175 | The <code>element</code> parameter specifies which value to set from 0 to | |
5176 | <a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>. | |
5177 | ||
5178 | </p> | |
f3c17241 | 5179 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippSetState">ippSetState</a></h3> |
3e7fe0ca MS |
5180 | <p class="description">Set the current state of the IPP message.</p> |
5181 | <p class="code"> | |
5182 | int ippSetState (<br> | |
5183 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
5184 | <a href="#ipp_state_t">ipp_state_t</a> state<br> | |
5185 | );</p> | |
5186 | <h4 class="parameters">Parameters</h4> | |
5187 | <dl> | |
5188 | <dt>ipp</dt> | |
5189 | <dd class="description">IPP message</dd> | |
5190 | <dt>state</dt> | |
5191 | <dd class="description">IPP state value</dd> | |
5192 | </dl> | |
5193 | <h4 class="returnvalue">Return Value</h4> | |
5194 | <p class="description">1 on success, 0 on failure</p> | |
f3c17241 | 5195 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippSetStatusCode">ippSetStatusCode</a></h3> |
a2326b5b MS |
5196 | <p class="description">Set the status code in an IPP response or event message.</p> |
5197 | <p class="code"> | |
5198 | int ippSetStatusCode (<br> | |
5199 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
5200 | ipp_status_t status<br> | |
5201 | );</p> | |
5202 | <h4 class="parameters">Parameters</h4> | |
5203 | <dl> | |
5204 | <dt>ipp</dt> | |
5205 | <dd class="description">IPP response or event message</dd> | |
5206 | <dt>status</dt> | |
5207 | <dd class="description">Status code</dd> | |
5208 | </dl> | |
5209 | <h4 class="returnvalue">Return Value</h4> | |
5210 | <p class="description">1 on success, 0 on failure</p> | |
5211 | <h4 class="discussion">Discussion</h4> | |
a469f8a5 MS |
5212 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
5213 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions. | |
a2326b5b MS |
5214 | |
5215 | </p> | |
f3c17241 | 5216 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippSetString">ippSetString</a></h3> |
a2326b5b MS |
5217 | <p class="description">Set a string value in an attribute.</p> |
5218 | <p class="code"> | |
5219 | int ippSetString (<br> | |
5220 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
5221 | <a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br> | |
5222 | int element,<br> | |
5223 | const char *strvalue<br> | |
5224 | );</p> | |
5225 | <h4 class="parameters">Parameters</h4> | |
5226 | <dl> | |
5227 | <dt>ipp</dt> | |
5228 | <dd class="description">IPP message</dd> | |
5229 | <dt>attr</dt> | |
5230 | <dd class="description">IPP attribute</dd> | |
5231 | <dt>element</dt> | |
5232 | <dd class="description">Value number (0-based)</dd> | |
5233 | <dt>strvalue</dt> | |
5234 | <dd class="description">String value</dd> | |
5235 | </dl> | |
5236 | <h4 class="returnvalue">Return Value</h4> | |
5237 | <p class="description">1 on success, 0 on failure</p> | |
5238 | <h4 class="discussion">Discussion</h4> | |
a469f8a5 MS |
5239 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
5240 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
5241 | <br> |
5242 | The <code>attr</code> parameter may be modified as a result of setting the value.<br> | |
5243 | <br> | |
5244 | The <code>element</code> parameter specifies which value to set from 0 to | |
5245 | <a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>. | |
5246 | ||
a469f8a5 | 5247 | </p> |
9c0e8e5d | 5248 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="ippSetStringf">ippSetStringf</a></h3> |
a469f8a5 MS |
5249 | <p class="description">Set a formatted string value of an attribute.</p> |
5250 | <p class="code"> | |
5251 | int ippSetStringf (<br> | |
5252 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
5253 | <a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br> | |
5254 | int element,<br> | |
5255 | const char *format,<br> | |
5256 | ...<br> | |
5257 | );</p> | |
5258 | <h4 class="parameters">Parameters</h4> | |
5259 | <dl> | |
5260 | <dt>ipp</dt> | |
5261 | <dd class="description">IPP message</dd> | |
5262 | <dt>attr</dt> | |
5263 | <dd class="description">IPP attribute</dd> | |
5264 | <dt>element</dt> | |
5265 | <dd class="description">Value number (0-based)</dd> | |
5266 | <dt>format</dt> | |
5267 | <dd class="description">Printf-style format string</dd> | |
5268 | <dt>...</dt> | |
5269 | <dd class="description">Additional arguments as needed</dd> | |
5270 | </dl> | |
5271 | <h4 class="returnvalue">Return Value</h4> | |
5272 | <p class="description">1 on success, 0 on failure</p> | |
5273 | <h4 class="discussion">Discussion</h4> | |
5274 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using | |
5275 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
5276 | <br> | |
5277 | The <code>attr</code> parameter may be modified as a result of setting the value.<br> | |
5278 | <br> | |
5279 | The <code>element</code> parameter specifies which value to set from 0 to | |
5280 | <a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>.<br> | |
5281 | <br> | |
5282 | The <code>format</code> parameter uses formatting characters compatible with the | |
5283 | printf family of standard functions. Additional arguments follow it as | |
5284 | needed. The formatted string is truncated as needed to the maximum length of | |
5285 | the corresponding value type. | |
5286 | ||
5287 | </p> | |
9c0e8e5d | 5288 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="ippSetStringfv">ippSetStringfv</a></h3> |
a469f8a5 MS |
5289 | <p class="description">Set a formatted string value of an attribute.</p> |
5290 | <p class="code"> | |
5291 | int ippSetStringfv (<br> | |
5292 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
5293 | <a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br> | |
5294 | int element,<br> | |
5295 | const char *format,<br> | |
5296 | va_list ap<br> | |
5297 | );</p> | |
5298 | <h4 class="parameters">Parameters</h4> | |
5299 | <dl> | |
5300 | <dt>ipp</dt> | |
5301 | <dd class="description">IPP message</dd> | |
5302 | <dt>attr</dt> | |
5303 | <dd class="description">IPP attribute</dd> | |
5304 | <dt>element</dt> | |
5305 | <dd class="description">Value number (0-based)</dd> | |
5306 | <dt>format</dt> | |
5307 | <dd class="description">Printf-style format string</dd> | |
5308 | <dt>ap</dt> | |
5309 | <dd class="description">Pointer to additional arguments</dd> | |
5310 | </dl> | |
5311 | <h4 class="returnvalue">Return Value</h4> | |
5312 | <p class="description">1 on success, 0 on failure</p> | |
5313 | <h4 class="discussion">Discussion</h4> | |
5314 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using | |
5315 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
5316 | <br> | |
5317 | The <code>attr</code> parameter may be modified as a result of setting the value.<br> | |
5318 | <br> | |
5319 | The <code>element</code> parameter specifies which value to set from 0 to | |
5320 | <a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>.<br> | |
5321 | <br> | |
5322 | The <code>format</code> parameter uses formatting characters compatible with the | |
5323 | printf family of standard functions. Additional arguments follow it as | |
5324 | needed. The formatted string is truncated as needed to the maximum length of | |
5325 | the corresponding value type. | |
5326 | ||
a2326b5b | 5327 | </p> |
f3c17241 | 5328 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippSetValueTag">ippSetValueTag</a></h3> |
a2326b5b MS |
5329 | <p class="description">Set the value tag of an attribute.</p> |
5330 | <p class="code"> | |
5331 | int ippSetValueTag (<br> | |
5332 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
5333 | <a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br> | |
5334 | ipp_tag_t value_tag<br> | |
5335 | );</p> | |
5336 | <h4 class="parameters">Parameters</h4> | |
5337 | <dl> | |
5338 | <dt>ipp</dt> | |
5339 | <dd class="description">IPP message</dd> | |
5340 | <dt>attr</dt> | |
5341 | <dd class="description">IPP attribute</dd> | |
5342 | <dt>value_tag</dt> | |
5343 | <dd class="description">Value tag</dd> | |
5344 | </dl> | |
5345 | <h4 class="returnvalue">Return Value</h4> | |
5346 | <p class="description">1 on success, 0 on failure</p> | |
5347 | <h4 class="discussion">Discussion</h4> | |
a469f8a5 MS |
5348 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
5349 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
5350 | <br> |
5351 | The <code>attr</code> parameter may be modified as a result of setting the value.<br> | |
5352 | <br> | |
5353 | Integer (<code>IPP_TAG_INTEGER</code>) values can be promoted to rangeOfInteger | |
5354 | (<code>IPP_TAG_RANGE</code>) values, the various string tags can be promoted to name | |
5355 | (<code>IPP_TAG_NAME</code>) or nameWithLanguage (<code>IPP_TAG_NAMELANG</code>) values, text | |
5356 | (<code>IPP_TAG_TEXT</code>) values can be promoted to textWithLanguage | |
5357 | (<code>IPP_TAG_TEXTLANG</code>) values, and all values can be demoted to the various | |
5358 | out-of-band value tags such as no-value (<code>IPP_TAG_NOVALUE</code>). All other changes | |
5359 | will be rejected.<br> | |
5360 | <br> | |
5361 | Promoting a string attribute to nameWithLanguage or textWithLanguage adds the language | |
5362 | code in the "attributes-natural-language" attribute or, if not present, the language | |
5363 | code for the current locale. | |
5364 | ||
5365 | </p> | |
f3c17241 | 5366 | <h3 class="function"><span class="info"> CUPS 1.6/OS X 10.8 </span><a name="ippSetVersion">ippSetVersion</a></h3> |
a2326b5b MS |
5367 | <p class="description">Set the version number in an IPP message.</p> |
5368 | <p class="code"> | |
5369 | int ippSetVersion (<br> | |
5370 | <a href="#ipp_t">ipp_t</a> *ipp,<br> | |
5371 | int major,<br> | |
5372 | int minor<br> | |
5373 | );</p> | |
5374 | <h4 class="parameters">Parameters</h4> | |
5375 | <dl> | |
5376 | <dt>ipp</dt> | |
5377 | <dd class="description">IPP message</dd> | |
5378 | <dt>major</dt> | |
5379 | <dd class="description">Major version number (major.minor)</dd> | |
5380 | <dt>minor</dt> | |
5381 | <dd class="description">Minor version number (major.minor)</dd> | |
5382 | </dl> | |
5383 | <h4 class="returnvalue">Return Value</h4> | |
5384 | <p class="description">1 on success, 0 on failure</p> | |
5385 | <h4 class="discussion">Discussion</h4> | |
a469f8a5 MS |
5386 | <p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using |
5387 | the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br> | |
a2326b5b MS |
5388 | <br> |
5389 | The valid version numbers are currently 1.0, 1.1, 2.0, 2.1, and 2.2. | |
5390 | ||
5391 | </p> | |
e1f19878 | 5392 | <h3 class="function"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="ippStateString">ippStateString</a></h3> |
ca6b43fc MS |
5393 | <p class="description">Return the name corresponding to a state value.</p> |
5394 | <p class="code"> | |
5395 | const char *ippStateString (<br> | |
5396 | <a href="#ipp_state_t">ipp_state_t</a> state<br> | |
5397 | );</p> | |
5398 | <h4 class="parameters">Parameters</h4> | |
5399 | <dl> | |
5400 | <dt>state</dt> | |
5401 | <dd class="description">State value</dd> | |
5402 | </dl> | |
5403 | <h4 class="returnvalue">Return Value</h4> | |
5404 | <p class="description">State name</p> | |
f3c17241 | 5405 | <h3 class="function"><span class="info"> CUPS 1.4/OS X 10.6 </span><a name="ippTagString">ippTagString</a></h3> |
a2326b5b MS |
5406 | <p class="description">Return the tag name corresponding to a tag value.</p> |
5407 | <p class="code"> | |
5408 | const char *ippTagString (<br> | |
5409 | ipp_tag_t tag<br> | |
5410 | );</p> | |
5411 | <h4 class="parameters">Parameters</h4> | |
5412 | <dl> | |
5413 | <dt>tag</dt> | |
5414 | <dd class="description">Tag value</dd> | |
5415 | </dl> | |
06d4e77b MS |
5416 | <h4 class="returnvalue">Return Value</h4> |
5417 | <p class="description">Tag name</p> | |
5418 | <h4 class="discussion">Discussion</h4> | |
5419 | <p class="discussion">The returned names are defined in RFC 2911 and 3382. | |
5420 | ||
5421 | </p> | |
f3c17241 | 5422 | <h3 class="function"><span class="info"> CUPS 1.4/OS X 10.6 </span><a name="ippTagValue">ippTagValue</a></h3> |
06d4e77b MS |
5423 | <p class="description">Return the tag value corresponding to a tag name.</p> |
5424 | <p class="code"> | |
a2326b5b | 5425 | ipp_tag_t ippTagValue (<br> |
06d4e77b MS |
5426 | const char *name<br> |
5427 | );</p> | |
5428 | <h4 class="parameters">Parameters</h4> | |
5429 | <dl> | |
5430 | <dt>name</dt> | |
5431 | <dd class="description">Tag name</dd> | |
5432 | </dl> | |
5433 | <h4 class="returnvalue">Return Value</h4> | |
5434 | <p class="description">Tag value</p> | |
5435 | <h4 class="discussion">Discussion</h4> | |
5436 | <p class="discussion">The tag names are defined in RFC 2911 and 3382. | |
5437 | ||
5438 | </p> | |
5a738aea MS |
5439 | <h3 class="function"><a name="ippTimeToDate">ippTimeToDate</a></h3> |
5440 | <p class="description">Convert from UNIX time to RFC 1903 format.</p> | |
5441 | <p class="code"> | |
5442 | const <a href="#ipp_uchar_t">ipp_uchar_t</a> *ippTimeToDate (<br> | |
5443 | time_t t<br> | |
5444 | );</p> | |
5445 | <h4 class="parameters">Parameters</h4> | |
5446 | <dl> | |
5447 | <dt>t</dt> | |
5448 | <dd class="description">UNIX time value</dd> | |
5449 | </dl> | |
5450 | <h4 class="returnvalue">Return Value</h4> | |
5451 | <p class="description">RFC-1903 date/time data</p> | |
9c0e8e5d | 5452 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="ippValidateAttribute">ippValidateAttribute</a></h3> |
db8b865d MS |
5453 | <p class="description">Validate the contents of an attribute.</p> |
5454 | <p class="code"> | |
5455 | int ippValidateAttribute (<br> | |
5456 | <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr<br> | |
5457 | );</p> | |
5458 | <h4 class="parameters">Parameters</h4> | |
5459 | <dl> | |
5460 | <dt>attr</dt> | |
5461 | <dd class="description">Attribute</dd> | |
5462 | </dl> | |
5463 | <h4 class="returnvalue">Return Value</h4> | |
5464 | <p class="description">1 if valid, 0 otherwise</p> | |
5465 | <h4 class="discussion">Discussion</h4> | |
5466 | <p class="discussion">This function validates the contents of an attribute based on the name and | |
5467 | value tag. 1 is returned if the attribute is valid, 0 otherwise. On | |
5468 | failure, cupsLastErrorString() is set to a human-readable message. | |
5469 | ||
5470 | </p> | |
9c0e8e5d | 5471 | <h3 class="function"><span class="info"> CUPS 1.7/OS X 10.9 </span><a name="ippValidateAttributes">ippValidateAttributes</a></h3> |
db8b865d MS |
5472 | <p class="description">Validate all attributes in an IPP message.</p> |
5473 | <p class="code"> | |
5474 | int ippValidateAttributes (<br> | |
5475 | <a href="#ipp_t">ipp_t</a> *ipp<br> | |
5476 | );</p> | |
5477 | <h4 class="parameters">Parameters</h4> | |
5478 | <dl> | |
5479 | <dt>ipp</dt> | |
5480 | <dd class="description">IPP message</dd> | |
5481 | </dl> | |
5482 | <h4 class="returnvalue">Return Value</h4> | |
5483 | <p class="description">1 if valid, 0 otherwise</p> | |
5484 | <h4 class="discussion">Discussion</h4> | |
5485 | <p class="discussion">This function validates the contents of the IPP message, including each | |
5486 | attribute. Like <a href="#ippValidateAttribute"><code>ippValidateAttribute</code></a>, cupsLastErrorString() is set | |
5487 | to a human-readable message on failure. | |
5488 | ||
5489 | </p> | |
5a738aea MS |
5490 | <h3 class="function"><a name="ippWrite">ippWrite</a></h3> |
5491 | <p class="description">Write data for an IPP message to a HTTP connection.</p> | |
5492 | <p class="code"> | |
79e1d494 | 5493 | <a href="#ipp_state_t">ipp_state_t</a> ippWrite (<br> |
5a738aea MS |
5494 | <a href="#http_t">http_t</a> *http,<br> |
5495 | <a href="#ipp_t">ipp_t</a> *ipp<br> | |
5496 | );</p> | |
5497 | <h4 class="parameters">Parameters</h4> | |
5498 | <dl> | |
5499 | <dt>http</dt> | |
5500 | <dd class="description">HTTP connection</dd> | |
5501 | <dt>ipp</dt> | |
5502 | <dd class="description">IPP data</dd> | |
5503 | </dl> | |
5504 | <h4 class="returnvalue">Return Value</h4> | |
5505 | <p class="description">Current state</p> | |
f3c17241 | 5506 | <h3 class="function"><span class="info"> CUPS 1.1.19/OS X 10.3 </span><a name="ippWriteFile">ippWriteFile</a></h3> |
5a738aea MS |
5507 | <p class="description">Write data for an IPP message to a file.</p> |
5508 | <p class="code"> | |
79e1d494 | 5509 | <a href="#ipp_state_t">ipp_state_t</a> ippWriteFile (<br> |
5a738aea MS |
5510 | int fd,<br> |
5511 | <a href="#ipp_t">ipp_t</a> *ipp<br> | |
5512 | );</p> | |
5513 | <h4 class="parameters">Parameters</h4> | |
5514 | <dl> | |
5515 | <dt>fd</dt> | |
5516 | <dd class="description">HTTP data</dd> | |
5517 | <dt>ipp</dt> | |
5518 | <dd class="description">IPP data</dd> | |
5519 | </dl> | |
5520 | <h4 class="returnvalue">Return Value</h4> | |
5521 | <p class="description">Current state</p> | |
f3c17241 | 5522 | <h3 class="function"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="ippWriteIO">ippWriteIO</a></h3> |
5a738aea MS |
5523 | <p class="description">Write data for an IPP message.</p> |
5524 | <p class="code"> | |
79e1d494 | 5525 | <a href="#ipp_state_t">ipp_state_t</a> ippWriteIO (<br> |
5a738aea MS |
5526 | void *dst,<br> |
5527 | <a href="#ipp_iocb_t">ipp_iocb_t</a> cb,<br> | |
5528 | int blocking,<br> | |
5529 | <a href="#ipp_t">ipp_t</a> *parent,<br> | |
5530 | <a href="#ipp_t">ipp_t</a> *ipp<br> | |
5531 | );</p> | |
5532 | <h4 class="parameters">Parameters</h4> | |
5533 | <dl> | |
5534 | <dt>dst</dt> | |
5535 | <dd class="description">Destination</dd> | |
5536 | <dt>cb</dt> | |
5537 | <dd class="description">Write callback function</dd> | |
5538 | <dt>blocking</dt> | |
5539 | <dd class="description">Use blocking IO?</dd> | |
5540 | <dt>parent</dt> | |
5541 | <dd class="description">Parent IPP message</dd> | |
5542 | <dt>ipp</dt> | |
5543 | <dd class="description">IPP data</dd> | |
5544 | </dl> | |
5545 | <h4 class="returnvalue">Return Value</h4> | |
5546 | <p class="description">Current state</p> | |
5547 | <h2 class="title"><a name="TYPES">Data Types</a></h2> | |
eac3a0a0 MS |
5548 | <h3 class="typedef"><a name="gss_auth_identity_desc">gss_auth_identity_desc</a></h3> |
5549 | <p class="description">Local functions...</p> | |
5550 | <p class="code"> | |
5551 | typedef struct <a href="#gss_auth_identity">gss_auth_identity</a> gss_auth_identity_desc; | |
5552 | </p> | |
f3c17241 | 5553 | <h3 class="typedef"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="http_addr_t">http_addr_t</a></h3> |
f11a948a MS |
5554 | <p class="description">Socket address union, which |
5555 | makes using IPv6 and other | |
5556 | address types easier and | |
5557 | more portable. </p> | |
5558 | <p class="code"> | |
5559 | typedef union _http_addr_u / http_addr_t; | |
5560 | </p> | |
f3c17241 | 5561 | <h3 class="typedef"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="http_addrlist_t">http_addrlist_t</a></h3> |
5a738aea | 5562 | <p class="description">Socket address list, which is |
ef416fc2 | 5563 | used to enumerate all of the |
5564 | addresses that are associated | |
5a738aea MS |
5565 | with a hostname. </p> |
5566 | <p class="code"> | |
5567 | typedef struct <a href="#http_addrlist_s">http_addrlist_s</a> / http_addrlist_t; | |
5568 | </p> | |
5569 | <h3 class="typedef"><a name="http_auth_t">http_auth_t</a></h3> | |
5570 | <p class="description">HTTP authentication types</p> | |
5571 | <p class="code"> | |
5572 | typedef enum <a href="#http_auth_e">http_auth_e</a> http_auth_t; | |
5573 | </p> | |
f3c17241 | 5574 | <h3 class="typedef"><span class="info"> CUPS 1.5/OS X 10.7 </span><a name="http_credential_t">http_credential_t</a></h3> |
f228370c | 5575 | <p class="description">HTTP credential data </p> |
10d09e33 MS |
5576 | <p class="code"> |
5577 | typedef struct <a href="#http_credential_s">http_credential_s</a> http_credential_t; | |
5578 | </p> | |
5a738aea MS |
5579 | <h3 class="typedef"><a name="http_encoding_t">http_encoding_t</a></h3> |
5580 | <p class="description">HTTP transfer encoding values</p> | |
5581 | <p class="code"> | |
5582 | typedef enum <a href="#http_encoding_e">http_encoding_e</a> http_encoding_t; | |
5583 | </p> | |
5584 | <h3 class="typedef"><a name="http_encryption_t">http_encryption_t</a></h3> | |
5585 | <p class="description">HTTP encryption values</p> | |
5586 | <p class="code"> | |
5587 | typedef enum <a href="#http_encryption_e">http_encryption_e</a> http_encryption_t; | |
5588 | </p> | |
79e1d494 MS |
5589 | <h3 class="typedef"><a name="http_field_t">http_field_t</a></h3> |
5590 | <p class="description">HTTP field names</p> | |
5591 | <p class="code"> | |
5592 | typedef enum <a href="#http_field_e">http_field_e</a> http_field_t; | |
5593 | </p> | |
5594 | <h3 class="typedef"><a name="http_keepalive_t">http_keepalive_t</a></h3> | |
f11a948a | 5595 | <p class="description">HTTP keep-alive values</p> |
79e1d494 MS |
5596 | <p class="code"> |
5597 | typedef enum <a href="#http_keepalive_e">http_keepalive_e</a> http_keepalive_t; | |
5598 | </p> | |
f11a948a MS |
5599 | <h3 class="typedef"><a name="http_state_t">http_state_t</a></h3> |
5600 | <p class="description">HTTP state values; states | |
5601 | are server-oriented...</p> | |
5602 | <p class="code"> | |
a469f8a5 | 5603 | typedef enum <a href="#http_state_e">http_state_e</a> http_state_t; |
79e1d494 | 5604 | </p> |
5a738aea MS |
5605 | <h3 class="typedef"><a name="http_t">http_t</a></h3> |
5606 | <p class="description">HTTP connection type</p> | |
5607 | <p class="code"> | |
ecdc0628 | 5608 | typedef struct _http_s http_t; |
5a738aea | 5609 | </p> |
f3c17241 | 5610 | <h3 class="typedef"><span class="info"> CUPS 1.5/OS X 10.7 </span><a name="http_timeout_cb_t">http_timeout_cb_t</a></h3> |
f228370c MS |
5611 | <p class="description">HTTP timeout callback </p> |
5612 | <p class="code"> | |
5613 | typedef int (*http_timeout_cb_t)(<a href="#http_t">http_t</a> *http, void *user_data); | |
5614 | </p> | |
e1f19878 | 5615 | <h3 class="typedef"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="http_trust_t">http_trust_t</a></h3> |
240214ef MS |
5616 | <p class="description">Level of trust for credentials </p> |
5617 | <p class="code"> | |
5618 | typedef enum <a href="#http_trust_e">http_trust_e</a> http_trust_t; | |
5619 | </p> | |
79e1d494 | 5620 | <h3 class="typedef"><a name="http_uri_coding_t">http_uri_coding_t</a></h3> |
f11a948a | 5621 | <p class="description">URI en/decode flags</p> |
79e1d494 MS |
5622 | <p class="code"> |
5623 | typedef enum <a href="#http_uri_coding_e">http_uri_coding_e</a> http_uri_coding_t; | |
5624 | </p> | |
10d09e33 | 5625 | <h3 class="typedef"><span class="info"> CUPS 1.2 </span><a name="http_uri_status_t">http_uri_status_t</a></h3> |
f11a948a | 5626 | <p class="description">URI separation status </p> |
79e1d494 MS |
5627 | <p class="code"> |
5628 | typedef enum <a href="#http_uri_status_e">http_uri_status_e</a> http_uri_status_t; | |
5629 | </p> | |
f11a948a MS |
5630 | <h3 class="typedef"><a name="http_version_t">http_version_t</a></h3> |
5631 | <p class="description">HTTP version numbers</p> | |
79e1d494 MS |
5632 | <p class="code"> |
5633 | typedef enum <a href="#http_version_e">http_version_e</a> http_version_t; | |
5634 | </p> | |
5a738aea | 5635 | <h3 class="typedef"><a name="ipp_attribute_t">ipp_attribute_t</a></h3> |
a2326b5b | 5636 | <p class="description">IPP attribute</p> |
5a738aea | 5637 | <p class="code"> |
a2326b5b MS |
5638 | typedef struct _ipp_attribute_s ipp_attribute_t; |
5639 | </p> | |
5640 | <h3 class="typedef"><a name="ipp_copycb_t">ipp_copycb_t</a></h3> | |
f3c17241 MS |
5641 | <p class="description">The following structures are PRIVATE starting with CUPS 1.6/OS X 10.8. |
5642 | Please use the new accessor functions available in CUPS 1.6 and later, as | |
5643 | these definitions will be moved to a private header file in a future release.</p> | |
a2326b5b MS |
5644 | <p class="code"> |
5645 | typedef int (*ipp_copycb_t)(void *context, <a href="#ipp_t">ipp_t</a> *dst, <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr); | |
5646 | </p> | |
5647 | <h3 class="typedef"><a name="ipp_dstate_t">ipp_dstate_t</a></h3> | |
5648 | <p class="description">Document states</p> | |
5649 | <p class="code"> | |
5650 | typedef enum <a href="#ipp_dstate_e">ipp_dstate_e</a> ipp_dstate_t; | |
5a738aea | 5651 | </p> |
79e1d494 | 5652 | <h3 class="typedef"><a name="ipp_finish_t">ipp_finish_t</a></h3> |
a469f8a5 | 5653 | <p class="description">Job collation types</p> |
79e1d494 | 5654 | <p class="code"> |
a469f8a5 | 5655 | typedef enum <a href="#ipp_finishings_e">ipp_finishings_e</a> ipp_finish_t; |
79e1d494 | 5656 | </p> |
f3c17241 | 5657 | <h3 class="typedef"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="ipp_iocb_t">ipp_iocb_t</a></h3> |
5a738aea MS |
5658 | <p class="description">IPP IO Callback Function </p> |
5659 | <p class="code"> | |
a2326b5b | 5660 | typedef ssize_t (*ipp_iocb_t)(void *context, <a href="#ipp_uchar_t">ipp_uchar_t</a> *buffer, size_t bytes); |
5a738aea | 5661 | </p> |
a2326b5b MS |
5662 | <h3 class="typedef"><a name="ipp_jcollate_t">ipp_jcollate_t</a></h3> |
5663 | <p class="description">Job collation types</p> | |
79e1d494 | 5664 | <p class="code"> |
a2326b5b | 5665 | typedef enum <a href="#ipp_jcollate_e">ipp_jcollate_e</a> ipp_jcollate_t; |
79e1d494 MS |
5666 | </p> |
5667 | <h3 class="typedef"><a name="ipp_orient_t">ipp_orient_t</a></h3> | |
aaf19ab0 | 5668 | <p class="description">Orientation values</p> |
79e1d494 MS |
5669 | <p class="code"> |
5670 | typedef enum <a href="#ipp_orient_e">ipp_orient_e</a> ipp_orient_t; | |
5671 | </p> | |
5672 | <h3 class="typedef"><a name="ipp_pstate_t">ipp_pstate_t</a></h3> | |
aaf19ab0 | 5673 | <p class="description">Printer states</p> |
79e1d494 MS |
5674 | <p class="code"> |
5675 | typedef enum <a href="#ipp_pstate_e">ipp_pstate_e</a> ipp_pstate_t; | |
5676 | </p> | |
5677 | <h3 class="typedef"><a name="ipp_quality_t">ipp_quality_t</a></h3> | |
aaf19ab0 | 5678 | <p class="description">Qualities</p> |
79e1d494 MS |
5679 | <p class="code"> |
5680 | typedef enum <a href="#ipp_quality_e">ipp_quality_e</a> ipp_quality_t; | |
5681 | </p> | |
79e1d494 | 5682 | <h3 class="typedef"><a name="ipp_res_t">ipp_res_t</a></h3> |
aaf19ab0 | 5683 | <p class="description">Resolution units</p> |
79e1d494 MS |
5684 | <p class="code"> |
5685 | typedef enum <a href="#ipp_res_e">ipp_res_e</a> ipp_res_t; | |
5686 | </p> | |
5687 | <h3 class="typedef"><a name="ipp_state_t">ipp_state_t</a></h3> | |
aaf19ab0 | 5688 | <p class="description">IPP states</p> |
79e1d494 MS |
5689 | <p class="code"> |
5690 | typedef enum <a href="#ipp_state_e">ipp_state_e</a> ipp_state_t; | |
5691 | </p> | |
5a738aea | 5692 | <h3 class="typedef"><a name="ipp_t">ipp_t</a></h3> |
a2326b5b | 5693 | <p class="description">IPP request/response data</p> |
5a738aea | 5694 | <p class="code"> |
a2326b5b | 5695 | typedef struct _ipp_s ipp_t; |
5a738aea MS |
5696 | </p> |
5697 | <h3 class="typedef"><a name="ipp_uchar_t">ipp_uchar_t</a></h3> | |
a2326b5b | 5698 | <p class="description">Unsigned 8-bit integer/character</p> |
5a738aea | 5699 | <p class="code"> |
a2326b5b | 5700 | typedef unsigned char ipp_uchar_t; |
5a738aea MS |
5701 | </p> |
5702 | <h2 class="title"><a name="STRUCTURES">Structures</a></h2> | |
eac3a0a0 MS |
5703 | <h3 class="struct"><a name="gss_auth_identity">gss_auth_identity</a></h3> |
5704 | <p class="description">Local functions...</p> | |
5705 | <p class="code">struct gss_auth_identity {<br> | |
5706 | gss_buffer_t *credentialsRef;<br> | |
5707 | uint32_t flags;<br> | |
5708 | char *password;<br> | |
5709 | char *realm;<br> | |
5710 | uint32_t type;<br> | |
5711 | char *username;<br> | |
5712 | };</p> | |
5713 | <h4 class="members">Members</h4> | |
5714 | <dl> | |
5715 | <dt>credentialsRef </dt> | |
5716 | <dt>flags </dt> | |
5717 | <dt>password </dt> | |
5718 | <dt>realm </dt> | |
5719 | <dt>type </dt> | |
5720 | <dt>username </dt> | |
5721 | </dl> | |
f3c17241 | 5722 | <h3 class="struct"><span class="info"> CUPS 1.2/OS X 10.5 </span><a name="http_addrlist_s">http_addrlist_s</a></h3> |
5a738aea MS |
5723 | <p class="description">Socket address list, which is |
5724 | used to enumerate all of the | |
5725 | addresses that are associated | |
5726 | with a hostname. </p> | |
5727 | <p class="code">struct http_addrlist_s {<br> | |
5728 | <a href="#http_addr_t">http_addr_t</a> addr;<br> | |
5729 | struct <a href="#http_addrlist_s">http_addrlist_s</a> *next;<br> | |
5730 | };</p> | |
5731 | <h4 class="members">Members</h4> | |
5732 | <dl> | |
5733 | <dt>addr </dt> | |
5734 | <dd class="description">Address</dd> | |
5735 | <dt>next </dt> | |
5736 | <dd class="description">Pointer to next address in list</dd> | |
5737 | </dl> | |
f3c17241 | 5738 | <h3 class="struct"><span class="info"> CUPS 1.5/OS X 10.7 </span><a name="http_credential_s">http_credential_s</a></h3> |
f228370c | 5739 | <p class="description">HTTP credential data </p> |
10d09e33 MS |
5740 | <p class="code">struct http_credential_s {<br> |
5741 | void *data;<br> | |
5742 | size_t datalen;<br> | |
5743 | };</p> | |
5744 | <h4 class="members">Members</h4> | |
5745 | <dl> | |
5746 | <dt>data </dt> | |
5747 | <dd class="description">Pointer to credential data</dd> | |
5748 | <dt>datalen </dt> | |
5749 | <dd class="description">Credential length</dd> | |
5750 | </dl> | |
f3c17241 MS |
5751 | <h3 class="struct"><a name="pollfd">pollfd</a></h3> |
5752 | <p class="description">User data (unused)</p> | |
5753 | <p class="code">struct pollfd *pollfds, unsigned int num_pollfds, int timeout, void *context) {<br> | |
5754 | void) context;<br> | |
5755 | void) timeout;<br> | |
5756 | };</p> | |
5757 | <h4 class="members">Members</h4> | |
5758 | <dl> | |
5759 | <dt>context </dt> | |
5760 | <dt>timeout </dt> | |
5761 | </dl> | |
5a738aea MS |
5762 | <h2 class="title"><a name="ENUMERATIONS">Constants</a></h2> |
5763 | <h3 class="enumeration"><a name="http_auth_e">http_auth_e</a></h3> | |
5764 | <p class="description">HTTP authentication types</p> | |
5765 | <h4 class="constants">Constants</h4> | |
5766 | <dl> | |
5767 | <dt>HTTP_AUTH_BASIC </dt> | |
5768 | <dd class="description">Basic authentication in use</dd> | |
5769 | <dt>HTTP_AUTH_MD5 </dt> | |
5770 | <dd class="description">Digest authentication in use</dd> | |
5771 | <dt>HTTP_AUTH_MD5_INT </dt> | |
5772 | <dd class="description">Digest authentication in use for body</dd> | |
5773 | <dt>HTTP_AUTH_MD5_SESS </dt> | |
5774 | <dd class="description">MD5-session authentication in use</dd> | |
5775 | <dt>HTTP_AUTH_MD5_SESS_INT </dt> | |
5776 | <dd class="description">MD5-session authentication in use for body</dd> | |
f3c17241 | 5777 | <dt>HTTP_AUTH_NEGOTIATE <span class="info"> CUPS 1.3/OS X 10.5 </span></dt> |
5a738aea MS |
5778 | <dd class="description">GSSAPI authentication in use </dd> |
5779 | <dt>HTTP_AUTH_NONE </dt> | |
5780 | <dd class="description">No authentication in use</dd> | |
5781 | </dl> | |
5782 | <h3 class="enumeration"><a name="http_encoding_e">http_encoding_e</a></h3> | |
5783 | <p class="description">HTTP transfer encoding values</p> | |
5784 | <h4 class="constants">Constants</h4> | |
5785 | <dl> | |
a469f8a5 | 5786 | <dt>HTTP_ENCODING_CHUNKED </dt> |
5a738aea | 5787 | <dd class="description">Data is chunked</dd> |
a469f8a5 | 5788 | <dt>HTTP_ENCODING_FIELDS </dt> |
5a738aea | 5789 | <dd class="description">Sending HTTP fields</dd> |
a469f8a5 | 5790 | <dt>HTTP_ENCODING_LENGTH </dt> |
5a738aea MS |
5791 | <dd class="description">Data is sent with Content-Length</dd> |
5792 | </dl> | |
5793 | <h3 class="enumeration"><a name="http_encryption_e">http_encryption_e</a></h3> | |
5794 | <p class="description">HTTP encryption values</p> | |
5795 | <h4 class="constants">Constants</h4> | |
5796 | <dl> | |
a469f8a5 | 5797 | <dt>HTTP_ENCRYPTION_ALWAYS </dt> |
5a738aea | 5798 | <dd class="description">Always encrypt (SSL)</dd> |
a469f8a5 | 5799 | <dt>HTTP_ENCRYPTION_IF_REQUESTED </dt> |
5a738aea | 5800 | <dd class="description">Encrypt if requested (TLS upgrade)</dd> |
a469f8a5 | 5801 | <dt>HTTP_ENCRYPTION_NEVER </dt> |
5a738aea | 5802 | <dd class="description">Never encrypt</dd> |
a469f8a5 | 5803 | <dt>HTTP_ENCRYPTION_REQUIRED </dt> |
5a738aea MS |
5804 | <dd class="description">Encryption is required (TLS upgrade)</dd> |
5805 | </dl> | |
5806 | <h3 class="enumeration"><a name="http_field_e">http_field_e</a></h3> | |
5807 | <p class="description">HTTP field names</p> | |
5808 | <h4 class="constants">Constants</h4> | |
5809 | <dl> | |
9c0e8e5d | 5810 | <dt>HTTP_FIELD_ACCEPT_ENCODING <span class="info"> CUPS 1.7/OS X 10.9 </span></dt> |
a469f8a5 | 5811 | <dd class="description">Accepting-Encoding field </dd> |
5a738aea MS |
5812 | <dt>HTTP_FIELD_ACCEPT_LANGUAGE </dt> |
5813 | <dd class="description">Accept-Language field</dd> | |
5814 | <dt>HTTP_FIELD_ACCEPT_RANGES </dt> | |
5815 | <dd class="description">Accept-Ranges field</dd> | |
9c0e8e5d | 5816 | <dt>HTTP_FIELD_ALLOW <span class="info"> CUPS 1.7/OS X 10.9 </span></dt> |
a469f8a5 | 5817 | <dd class="description">Allow field </dd> |
5a738aea MS |
5818 | <dt>HTTP_FIELD_AUTHORIZATION </dt> |
5819 | <dd class="description">Authorization field</dd> | |
5820 | <dt>HTTP_FIELD_CONNECTION </dt> | |
5821 | <dd class="description">Connection field</dd> | |
5822 | <dt>HTTP_FIELD_CONTENT_ENCODING </dt> | |
5823 | <dd class="description">Content-Encoding field</dd> | |
5824 | <dt>HTTP_FIELD_CONTENT_LANGUAGE </dt> | |
5825 | <dd class="description">Content-Language field</dd> | |
5826 | <dt>HTTP_FIELD_CONTENT_LENGTH </dt> | |
5827 | <dd class="description">Content-Length field</dd> | |
5828 | <dt>HTTP_FIELD_CONTENT_LOCATION </dt> | |
5829 | <dd class="description">Content-Location field</dd> | |
5830 | <dt>HTTP_FIELD_CONTENT_MD5 </dt> | |
5831 | <dd class="description">Content-MD5 field</dd> | |
5832 | <dt>HTTP_FIELD_CONTENT_RANGE </dt> | |
5833 | <dd class="description">Content-Range field</dd> | |
5834 | <dt>HTTP_FIELD_CONTENT_TYPE </dt> | |
5835 | <dd class="description">Content-Type field</dd> | |
5836 | <dt>HTTP_FIELD_CONTENT_VERSION </dt> | |
5837 | <dd class="description">Content-Version field</dd> | |
5838 | <dt>HTTP_FIELD_DATE </dt> | |
5839 | <dd class="description">Date field</dd> | |
5840 | <dt>HTTP_FIELD_HOST </dt> | |
5841 | <dd class="description">Host field</dd> | |
5842 | <dt>HTTP_FIELD_IF_MODIFIED_SINCE </dt> | |
5843 | <dd class="description">If-Modified-Since field</dd> | |
5844 | <dt>HTTP_FIELD_IF_UNMODIFIED_SINCE </dt> | |
5845 | <dd class="description">If-Unmodified-Since field</dd> | |
5846 | <dt>HTTP_FIELD_KEEP_ALIVE </dt> | |
5847 | <dd class="description">Keep-Alive field</dd> | |
5848 | <dt>HTTP_FIELD_LAST_MODIFIED </dt> | |
5849 | <dd class="description">Last-Modified field</dd> | |
5850 | <dt>HTTP_FIELD_LINK </dt> | |
5851 | <dd class="description">Link field</dd> | |
5852 | <dt>HTTP_FIELD_LOCATION </dt> | |
5853 | <dd class="description">Location field</dd> | |
5854 | <dt>HTTP_FIELD_MAX </dt> | |
5855 | <dd class="description">Maximum field index</dd> | |
5856 | <dt>HTTP_FIELD_RANGE </dt> | |
5857 | <dd class="description">Range field</dd> | |
5858 | <dt>HTTP_FIELD_REFERER </dt> | |
5859 | <dd class="description">Referer field</dd> | |
5860 | <dt>HTTP_FIELD_RETRY_AFTER </dt> | |
5861 | <dd class="description">Retry-After field</dd> | |
9c0e8e5d | 5862 | <dt>HTTP_FIELD_SERVER <span class="info"> CUPS 1.7/OS X 10.9 </span></dt> |
a469f8a5 | 5863 | <dd class="description">Server field </dd> |
5a738aea MS |
5864 | <dt>HTTP_FIELD_TRANSFER_ENCODING </dt> |
5865 | <dd class="description">Transfer-Encoding field</dd> | |
5866 | <dt>HTTP_FIELD_UNKNOWN </dt> | |
5867 | <dd class="description">Unknown field</dd> | |
5868 | <dt>HTTP_FIELD_UPGRADE </dt> | |
5869 | <dd class="description">Upgrade field</dd> | |
5870 | <dt>HTTP_FIELD_USER_AGENT </dt> | |
5871 | <dd class="description">User-Agent field</dd> | |
5872 | <dt>HTTP_FIELD_WWW_AUTHENTICATE </dt> | |
5873 | <dd class="description">WWW-Authenticate field</dd> | |
5874 | </dl> | |
5875 | <h3 class="enumeration"><a name="http_keepalive_e">http_keepalive_e</a></h3> | |
f11a948a | 5876 | <p class="description">HTTP keep-alive values</p> |
5a738aea MS |
5877 | <h4 class="constants">Constants</h4> |
5878 | <dl> | |
5879 | <dt>HTTP_KEEPALIVE_OFF </dt> | |
5880 | <dd class="description">No keep alive support</dd> | |
5881 | <dt>HTTP_KEEPALIVE_ON </dt> | |
5882 | <dd class="description">Use keep alive</dd> | |
5883 | </dl> | |
5884 | <h3 class="enumeration"><a name="http_state_e">http_state_e</a></h3> | |
f11a948a MS |
5885 | <p class="description">HTTP state values; states |
5886 | are server-oriented...</p> | |
5a738aea MS |
5887 | <h4 class="constants">Constants</h4> |
5888 | <dl> | |
a469f8a5 MS |
5889 | <dt>HTTP_STATE_CONNECT </dt> |
5890 | <dd class="description">CONNECT command, waiting for blank line</dd> | |
5891 | <dt>HTTP_STATE_DELETE </dt> | |
5a738aea | 5892 | <dd class="description">DELETE command, waiting for blank line</dd> |
a469f8a5 MS |
5893 | <dt>HTTP_STATE_ERROR </dt> |
5894 | <dd class="description">Error on socket</dd> | |
5895 | <dt>HTTP_STATE_GET </dt> | |
5a738aea | 5896 | <dd class="description">GET command, waiting for blank line</dd> |
a469f8a5 | 5897 | <dt>HTTP_STATE_GET_SEND </dt> |
5a738aea | 5898 | <dd class="description">GET command, sending data</dd> |
a469f8a5 | 5899 | <dt>HTTP_STATE_HEAD </dt> |
5a738aea | 5900 | <dd class="description">HEAD command, waiting for blank line</dd> |
a469f8a5 | 5901 | <dt>HTTP_STATE_OPTIONS </dt> |
5a738aea | 5902 | <dd class="description">OPTIONS command, waiting for blank line</dd> |
a469f8a5 | 5903 | <dt>HTTP_STATE_POST </dt> |
5a738aea | 5904 | <dd class="description">POST command, waiting for blank line</dd> |
a469f8a5 | 5905 | <dt>HTTP_STATE_POST_RECV </dt> |
5a738aea | 5906 | <dd class="description">POST command, receiving data</dd> |
a469f8a5 | 5907 | <dt>HTTP_STATE_POST_SEND </dt> |
5a738aea | 5908 | <dd class="description">POST command, sending data</dd> |
a469f8a5 | 5909 | <dt>HTTP_STATE_PUT </dt> |
5a738aea | 5910 | <dd class="description">PUT command, waiting for blank line</dd> |
a469f8a5 | 5911 | <dt>HTTP_STATE_PUT_RECV </dt> |
5a738aea | 5912 | <dd class="description">PUT command, receiving data</dd> |
a469f8a5 | 5913 | <dt>HTTP_STATE_STATUS </dt> |
5a738aea | 5914 | <dd class="description">Command complete, sending status</dd> |
a469f8a5 | 5915 | <dt>HTTP_STATE_TRACE </dt> |
5a738aea | 5916 | <dd class="description">TRACE command, waiting for blank line</dd> |
9c0e8e5d | 5917 | <dt>HTTP_STATE_UNKNOWN_METHOD <span class="info"> CUPS 1.7/OS X 10.9 </span></dt> |
a469f8a5 | 5918 | <dd class="description">Unknown request method, waiting for blank line </dd> |
9c0e8e5d | 5919 | <dt>HTTP_STATE_UNKNOWN_VERSION <span class="info"> CUPS 1.7/OS X 10.9 </span></dt> |
a469f8a5 MS |
5920 | <dd class="description">Unknown request method, waiting for blank line </dd> |
5921 | <dt>HTTP_STATE_WAITING </dt> | |
5a738aea MS |
5922 | <dd class="description">Waiting for command</dd> |
5923 | </dl> | |
5924 | <h3 class="enumeration"><a name="http_status_e">http_status_e</a></h3> | |
5925 | <p class="description">HTTP status codes</p> | |
5926 | <h4 class="constants">Constants</h4> | |
5927 | <dl> | |
a469f8a5 MS |
5928 | <dt>HTTP_STATUS_ACCEPTED </dt> |
5929 | <dd class="description">DELETE command was successful</dd> | |
5930 | <dt>HTTP_STATUS_BAD_GATEWAY </dt> | |
5a738aea | 5931 | <dd class="description">Bad gateway</dd> |
a469f8a5 | 5932 | <dt>HTTP_STATUS_BAD_REQUEST </dt> |
5a738aea | 5933 | <dd class="description">Bad request</dd> |
a469f8a5 | 5934 | <dt>HTTP_STATUS_CONFLICT </dt> |
5a738aea | 5935 | <dd class="description">Request is self-conflicting</dd> |
a469f8a5 | 5936 | <dt>HTTP_STATUS_CONTINUE </dt> |
5a738aea | 5937 | <dd class="description">Everything OK, keep going...</dd> |
a469f8a5 | 5938 | <dt>HTTP_STATUS_CREATED </dt> |
5a738aea | 5939 | <dd class="description">PUT command was successful</dd> |
6961465f MS |
5940 | <dt>HTTP_STATUS_CUPS_AUTHORIZATION_CANCELED <span class="info"> CUPS 1.4 </span></dt> |
5941 | <dd class="description">User canceled authorization </dd> | |
5942 | <dt>HTTP_STATUS_CUPS_PKI_ERROR <span class="info"> CUPS 1.5/OS X 10.7 </span></dt> | |
5943 | <dd class="description">Error negotiating a secure connection </dd> | |
a469f8a5 | 5944 | <dt>HTTP_STATUS_ERROR </dt> |
5a738aea | 5945 | <dd class="description">An error response from httpXxxx()</dd> |
a469f8a5 | 5946 | <dt>HTTP_STATUS_EXPECTATION_FAILED </dt> |
5a738aea | 5947 | <dd class="description">The expectation given in an Expect header field was not met</dd> |
a469f8a5 | 5948 | <dt>HTTP_STATUS_FORBIDDEN </dt> |
5a738aea | 5949 | <dd class="description">Forbidden to access this URI</dd> |
a469f8a5 | 5950 | <dt>HTTP_STATUS_GATEWAY_TIMEOUT </dt> |
5a738aea | 5951 | <dd class="description">Gateway connection timed out</dd> |
a469f8a5 | 5952 | <dt>HTTP_STATUS_GONE </dt> |
5a738aea | 5953 | <dd class="description">Server has gone away</dd> |
a469f8a5 | 5954 | <dt>HTTP_STATUS_LENGTH_REQUIRED </dt> |
5a738aea | 5955 | <dd class="description">A content length or encoding is required</dd> |
a469f8a5 | 5956 | <dt>HTTP_STATUS_METHOD_NOT_ALLOWED </dt> |
5a738aea | 5957 | <dd class="description">Method is not allowed</dd> |
a469f8a5 | 5958 | <dt>HTTP_STATUS_MOVED_PERMANENTLY </dt> |
5a738aea | 5959 | <dd class="description">Document has moved permanently</dd> |
a469f8a5 | 5960 | <dt>HTTP_STATUS_MOVED_TEMPORARILY </dt> |
5a738aea | 5961 | <dd class="description">Document has moved temporarily</dd> |
a469f8a5 | 5962 | <dt>HTTP_STATUS_MULTIPLE_CHOICES </dt> |
5a738aea | 5963 | <dd class="description">Multiple files match request</dd> |
9c0e8e5d | 5964 | <dt>HTTP_STATUS_NONE <span class="info"> CUPS 1.7/OS X 10.9 </span></dt> |
a469f8a5 MS |
5965 | <dd class="description">No Expect value </dd> |
5966 | <dt>HTTP_STATUS_NOT_ACCEPTABLE </dt> | |
5a738aea | 5967 | <dd class="description">Not Acceptable</dd> |
a469f8a5 | 5968 | <dt>HTTP_STATUS_NOT_AUTHORITATIVE </dt> |
5a738aea | 5969 | <dd class="description">Information isn't authoritative</dd> |
a469f8a5 | 5970 | <dt>HTTP_STATUS_NOT_FOUND </dt> |
5a738aea | 5971 | <dd class="description">URI was not found</dd> |
a469f8a5 | 5972 | <dt>HTTP_STATUS_NOT_IMPLEMENTED </dt> |
5a738aea | 5973 | <dd class="description">Feature not implemented</dd> |
a469f8a5 | 5974 | <dt>HTTP_STATUS_NOT_MODIFIED </dt> |
5a738aea | 5975 | <dd class="description">File not modified</dd> |
a469f8a5 | 5976 | <dt>HTTP_STATUS_NOT_SUPPORTED </dt> |
5a738aea | 5977 | <dd class="description">HTTP version not supported</dd> |
a469f8a5 | 5978 | <dt>HTTP_STATUS_NO_CONTENT </dt> |
5a738aea | 5979 | <dd class="description">Successful command, no new data</dd> |
a469f8a5 | 5980 | <dt>HTTP_STATUS_OK </dt> |
5a738aea | 5981 | <dd class="description">OPTIONS/GET/HEAD/POST/TRACE command was successful</dd> |
a469f8a5 | 5982 | <dt>HTTP_STATUS_PARTIAL_CONTENT </dt> |
dd3fdd2c | 5983 | <dd class="description">Only a partial file was received/sent</dd> |
a469f8a5 | 5984 | <dt>HTTP_STATUS_PAYMENT_REQUIRED </dt> |
5a738aea | 5985 | <dd class="description">Payment required</dd> |
a469f8a5 | 5986 | <dt>HTTP_STATUS_PRECONDITION </dt> |
5a738aea | 5987 | <dd class="description">Precondition failed</dd> |
a469f8a5 | 5988 | <dt>HTTP_STATUS_PROXY_AUTHENTICATION </dt> |
5a738aea | 5989 | <dd class="description">Proxy Authentication is Required</dd> |
a469f8a5 | 5990 | <dt>HTTP_STATUS_REQUESTED_RANGE </dt> |
5a738aea | 5991 | <dd class="description">The requested range is not satisfiable</dd> |
a469f8a5 | 5992 | <dt>HTTP_STATUS_REQUEST_TIMEOUT </dt> |
5a738aea | 5993 | <dd class="description">Request timed out</dd> |
a469f8a5 | 5994 | <dt>HTTP_STATUS_REQUEST_TOO_LARGE </dt> |
5a738aea | 5995 | <dd class="description">Request entity too large</dd> |
a469f8a5 | 5996 | <dt>HTTP_STATUS_RESET_CONTENT </dt> |
5a738aea | 5997 | <dd class="description">Content was reset/recreated</dd> |
a469f8a5 | 5998 | <dt>HTTP_STATUS_SEE_OTHER </dt> |
5a738aea | 5999 | <dd class="description">See this other link...</dd> |
a469f8a5 | 6000 | <dt>HTTP_STATUS_SERVER_ERROR </dt> |
5a738aea | 6001 | <dd class="description">Internal server error</dd> |
a469f8a5 | 6002 | <dt>HTTP_STATUS_SERVICE_UNAVAILABLE </dt> |
5a738aea | 6003 | <dd class="description">Service is unavailable</dd> |
a469f8a5 | 6004 | <dt>HTTP_STATUS_SWITCHING_PROTOCOLS </dt> |
5a738aea | 6005 | <dd class="description">HTTP upgrade to TLS/SSL</dd> |
a469f8a5 | 6006 | <dt>HTTP_STATUS_UNAUTHORIZED </dt> |
5a738aea | 6007 | <dd class="description">Unauthorized to access host</dd> |
a469f8a5 | 6008 | <dt>HTTP_STATUS_UNSUPPORTED_MEDIATYPE </dt> |
5a738aea | 6009 | <dd class="description">The requested media type is unsupported</dd> |
a469f8a5 | 6010 | <dt>HTTP_STATUS_UPGRADE_REQUIRED </dt> |
5a738aea | 6011 | <dd class="description">Upgrade to SSL/TLS required</dd> |
a469f8a5 | 6012 | <dt>HTTP_STATUS_URI_TOO_LONG </dt> |
5a738aea | 6013 | <dd class="description">URI too long</dd> |
a469f8a5 | 6014 | <dt>HTTP_STATUS_USE_PROXY </dt> |
5a738aea MS |
6015 | <dd class="description">Must use a proxy to access this URI</dd> |
6016 | </dl> | |
e1f19878 | 6017 | <h3 class="enumeration"><span class="info"> CUPS 2.0/OS 10.10 </span><a name="http_trust_e">http_trust_e</a></h3> |
240214ef MS |
6018 | <p class="description">Level of trust for credentials </p> |
6019 | <h4 class="constants">Constants</h4> | |
6020 | <dl> | |
6021 | <dt>HTTP_TRUST_CHANGED </dt> | |
6022 | <dd class="description">Credentials have changed</dd> | |
6023 | <dt>HTTP_TRUST_EXPIRED </dt> | |
6024 | <dd class="description">Credentials are expired</dd> | |
6025 | <dt>HTTP_TRUST_INVALID </dt> | |
6026 | <dd class="description">Credentials are invalid</dd> | |
6027 | <dt>HTTP_TRUST_OK </dt> | |
6028 | <dd class="description">Credentials are OK/trusted</dd> | |
6029 | <dt>HTTP_TRUST_RENEWED </dt> | |
6030 | <dd class="description">Credentials have been renewed</dd> | |
6031 | <dt>HTTP_TRUST_UNKNOWN </dt> | |
6032 | <dd class="description">Credentials are unknown/new</dd> | |
6033 | </dl> | |
5a738aea | 6034 | <h3 class="enumeration"><a name="http_uri_coding_e">http_uri_coding_e</a></h3> |
f11a948a | 6035 | <p class="description">URI en/decode flags</p> |
5a738aea MS |
6036 | <h4 class="constants">Constants</h4> |
6037 | <dl> | |
6038 | <dt>HTTP_URI_CODING_ALL </dt> | |
6039 | <dd class="description">En/decode everything</dd> | |
6040 | <dt>HTTP_URI_CODING_HOSTNAME </dt> | |
6041 | <dd class="description">En/decode the hostname portion</dd> | |
6042 | <dt>HTTP_URI_CODING_MOST </dt> | |
6043 | <dd class="description">En/decode all but the query</dd> | |
6044 | <dt>HTTP_URI_CODING_NONE </dt> | |
6045 | <dd class="description">Don't en/decode anything</dd> | |
6046 | <dt>HTTP_URI_CODING_QUERY </dt> | |
6047 | <dd class="description">En/decode the query portion</dd> | |
6048 | <dt>HTTP_URI_CODING_RESOURCE </dt> | |
6049 | <dd class="description">En/decode the resource portion</dd> | |
9c0e8e5d MS |
6050 | <dt>HTTP_URI_CODING_RFC6874 </dt> |
6051 | <dd class="description">Use RFC 6874 address format</dd> | |
5a738aea MS |
6052 | <dt>HTTP_URI_CODING_USERNAME </dt> |
6053 | <dd class="description">En/decode the username portion</dd> | |
6054 | </dl> | |
10d09e33 | 6055 | <h3 class="enumeration"><span class="info"> CUPS 1.2 </span><a name="http_uri_status_e">http_uri_status_e</a></h3> |
f11a948a | 6056 | <p class="description">URI separation status </p> |
5a738aea MS |
6057 | <h4 class="constants">Constants</h4> |
6058 | <dl> | |
a469f8a5 | 6059 | <dt>HTTP_URI_STATUS_BAD_ARGUMENTS </dt> |
5a738aea | 6060 | <dd class="description">Bad arguments to function (error)</dd> |
a469f8a5 | 6061 | <dt>HTTP_URI_STATUS_BAD_HOSTNAME </dt> |
5a738aea | 6062 | <dd class="description">Bad hostname in URI (error)</dd> |
a469f8a5 | 6063 | <dt>HTTP_URI_STATUS_BAD_PORT </dt> |
5a738aea | 6064 | <dd class="description">Bad port number in URI (error)</dd> |
a469f8a5 | 6065 | <dt>HTTP_URI_STATUS_BAD_RESOURCE </dt> |
5a738aea | 6066 | <dd class="description">Bad resource in URI (error)</dd> |
a469f8a5 | 6067 | <dt>HTTP_URI_STATUS_BAD_SCHEME </dt> |
5a738aea | 6068 | <dd class="description">Bad scheme in URI (error)</dd> |
a469f8a5 | 6069 | <dt>HTTP_URI_STATUS_BAD_URI </dt> |
5a738aea | 6070 | <dd class="description">Bad/empty URI (error)</dd> |
a469f8a5 | 6071 | <dt>HTTP_URI_STATUS_BAD_USERNAME </dt> |
5a738aea | 6072 | <dd class="description">Bad username in URI (error)</dd> |
a469f8a5 | 6073 | <dt>HTTP_URI_STATUS_MISSING_RESOURCE </dt> |
5a738aea | 6074 | <dd class="description">Missing resource in URI (warning)</dd> |
a469f8a5 | 6075 | <dt>HTTP_URI_STATUS_MISSING_SCHEME </dt> |
5a738aea | 6076 | <dd class="description">Missing scheme in URI (warning)</dd> |
a469f8a5 | 6077 | <dt>HTTP_URI_STATUS_OK </dt> |
5a738aea | 6078 | <dd class="description">URI decoded OK</dd> |
a469f8a5 | 6079 | <dt>HTTP_URI_STATUS_OVERFLOW </dt> |
5a738aea | 6080 | <dd class="description">URI buffer for httpAssembleURI is too small</dd> |
a469f8a5 | 6081 | <dt>HTTP_URI_STATUS_UNKNOWN_SCHEME </dt> |
5a738aea MS |
6082 | <dd class="description">Unknown scheme in URI (warning)</dd> |
6083 | </dl> | |
6084 | <h3 class="enumeration"><a name="http_version_e">http_version_e</a></h3> | |
f11a948a | 6085 | <p class="description">HTTP version numbers</p> |
5a738aea MS |
6086 | <h4 class="constants">Constants</h4> |
6087 | <dl> | |
a469f8a5 | 6088 | <dt>HTTP_VERSION_0_9 </dt> |
5a738aea | 6089 | <dd class="description">HTTP/0.9</dd> |
a469f8a5 | 6090 | <dt>HTTP_VERSION_1_0 </dt> |
5a738aea | 6091 | <dd class="description">HTTP/1.0</dd> |
a469f8a5 | 6092 | <dt>HTTP_VERSION_1_1 </dt> |
5a738aea MS |
6093 | <dd class="description">HTTP/1.1</dd> |
6094 | </dl> | |
a2326b5b MS |
6095 | <h3 class="enumeration"><a name="ipp_dstate_e">ipp_dstate_e</a></h3> |
6096 | <p class="description">Document states</p> | |
6097 | <h4 class="constants">Constants</h4> | |
6098 | <dl> | |
6099 | <dt>IPP_DOCUMENT_ABORTED </dt> | |
a469f8a5 | 6100 | <dd class="description">Document is aborted</dd> |
a2326b5b | 6101 | <dt>IPP_DOCUMENT_CANCELED </dt> |
a469f8a5 | 6102 | <dd class="description">Document is canceled</dd> |
a2326b5b | 6103 | <dt>IPP_DOCUMENT_COMPLETED </dt> |
a469f8a5 | 6104 | <dd class="description">Document is completed</dd> |
a2326b5b | 6105 | <dt>IPP_DOCUMENT_PENDING </dt> |
a469f8a5 | 6106 | <dd class="description">Document is pending</dd> |
a2326b5b | 6107 | <dt>IPP_DOCUMENT_PROCESSING </dt> |
a469f8a5 | 6108 | <dd class="description">Document is processing</dd> |
a2326b5b | 6109 | </dl> |
a469f8a5 | 6110 | <h3 class="enumeration"><a name="ipp_finishings_e">ipp_finishings_e</a></h3> |
aaf19ab0 | 6111 | <p class="description">Finishings</p> |
5a738aea MS |
6112 | <h4 class="constants">Constants</h4> |
6113 | <dl> | |
6114 | <dt>IPP_FINISHINGS_BALE </dt> | |
6115 | <dd class="description">Bale (any type)</dd> | |
6116 | <dt>IPP_FINISHINGS_BIND </dt> | |
6117 | <dd class="description">Bind</dd> | |
6118 | <dt>IPP_FINISHINGS_BIND_BOTTOM </dt> | |
6119 | <dd class="description">Bind on bottom</dd> | |
6120 | <dt>IPP_FINISHINGS_BIND_LEFT </dt> | |
6121 | <dd class="description">Bind on left</dd> | |
6122 | <dt>IPP_FINISHINGS_BIND_RIGHT </dt> | |
6123 | <dd class="description">Bind on right</dd> | |
6124 | <dt>IPP_FINISHINGS_BIND_TOP </dt> | |
6125 | <dd class="description">Bind on top</dd> | |
6126 | <dt>IPP_FINISHINGS_BOOKLET_MAKER </dt> | |
6127 | <dd class="description">Fold to make booklet</dd> | |
ca6b43fc MS |
6128 | <dt>IPP_FINISHINGS_COAT </dt> |
6129 | <dd class="description">Apply protective liquid or powder coating</dd> | |
5a738aea MS |
6130 | <dt>IPP_FINISHINGS_COVER </dt> |
6131 | <dd class="description">Add cover</dd> | |
6961465f MS |
6132 | <dt>IPP_FINISHINGS_CUPS_FOLD_ACCORDIAN </dt> |
6133 | <dd class="description">Accordian-fold the paper vertically into four sections</dd> | |
6134 | <dt>IPP_FINISHINGS_CUPS_FOLD_DOUBLE_GATE </dt> | |
6135 | <dd class="description">Fold the top and bottom quarters of the paper towards the midline, then fold in half vertically</dd> | |
6136 | <dt>IPP_FINISHINGS_CUPS_FOLD_GATE </dt> | |
6137 | <dd class="description">Fold the top and bottom quarters of the paper towards the midline</dd> | |
6138 | <dt>IPP_FINISHINGS_CUPS_FOLD_HALF </dt> | |
6139 | <dd class="description">Fold the paper in half vertically</dd> | |
6140 | <dt>IPP_FINISHINGS_CUPS_FOLD_HALF_Z </dt> | |
6141 | <dd class="description">Fold the paper in half horizontally, then Z-fold the paper vertically</dd> | |
6142 | <dt>IPP_FINISHINGS_CUPS_FOLD_LEFT_GATE </dt> | |
6143 | <dd class="description">Fold the top quarter of the paper towards the midline</dd> | |
6144 | <dt>IPP_FINISHINGS_CUPS_FOLD_LETTER </dt> | |
6145 | <dd class="description">Fold the paper into three sections vertically; sometimes also known as a C fold</dd> | |
6146 | <dt>IPP_FINISHINGS_CUPS_FOLD_PARALLEL </dt> | |
6147 | <dd class="description">Fold the paper in half vertically two times, yielding four sections</dd> | |
6148 | <dt>IPP_FINISHINGS_CUPS_FOLD_POSTER </dt> | |
6149 | <dd class="description">Fold the paper in half horizontally and vertically; sometimes also called a cross fold</dd> | |
6150 | <dt>IPP_FINISHINGS_CUPS_FOLD_RIGHT_GATE </dt> | |
6151 | <dd class="description">Fold the bottom quarter of the paper towards the midline</dd> | |
6152 | <dt>IPP_FINISHINGS_CUPS_FOLD_Z </dt> | |
6153 | <dd class="description">Fold the paper vertically into three sections, forming a Z</dd> | |
a469f8a5 MS |
6154 | <dt>IPP_FINISHINGS_CUPS_PUNCH_BOTTOM_LEFT </dt> |
6155 | <dd class="description">Punch 1 hole bottom left</dd> | |
6156 | <dt>IPP_FINISHINGS_CUPS_PUNCH_BOTTOM_RIGHT </dt> | |
6157 | <dd class="description">Punch 1 hole bottom right</dd> | |
6158 | <dt>IPP_FINISHINGS_CUPS_PUNCH_DUAL_BOTTOM </dt> | |
6159 | <dd class="description">Punch 2 holes bottom edge</dd> | |
6160 | <dt>IPP_FINISHINGS_CUPS_PUNCH_DUAL_LEFT </dt> | |
6161 | <dd class="description">Punch 2 holes left side</dd> | |
6162 | <dt>IPP_FINISHINGS_CUPS_PUNCH_DUAL_RIGHT </dt> | |
6163 | <dd class="description">Punch 2 holes right side</dd> | |
6164 | <dt>IPP_FINISHINGS_CUPS_PUNCH_DUAL_TOP </dt> | |
6165 | <dd class="description">Punch 2 holes top edge</dd> | |
6166 | <dt>IPP_FINISHINGS_CUPS_PUNCH_QUAD_BOTTOM </dt> | |
6167 | <dd class="description">Punch 4 holes bottom edge</dd> | |
6168 | <dt>IPP_FINISHINGS_CUPS_PUNCH_QUAD_LEFT </dt> | |
6169 | <dd class="description">Punch 4 holes left side</dd> | |
6170 | <dt>IPP_FINISHINGS_CUPS_PUNCH_QUAD_RIGHT </dt> | |
6171 | <dd class="description">Punch 4 holes right side</dd> | |
6172 | <dt>IPP_FINISHINGS_CUPS_PUNCH_QUAD_TOP </dt> | |
6173 | <dd class="description">Punch 4 holes top edge</dd> | |
6174 | <dt>IPP_FINISHINGS_CUPS_PUNCH_TOP_LEFT </dt> | |
6175 | <dd class="description">Punch 1 hole top left</dd> | |
6176 | <dt>IPP_FINISHINGS_CUPS_PUNCH_TOP_RIGHT </dt> | |
6177 | <dd class="description">Punch 1 hole top right</dd> | |
6178 | <dt>IPP_FINISHINGS_CUPS_PUNCH_TRIPLE_BOTTOM </dt> | |
6179 | <dd class="description">Punch 3 holes bottom edge</dd> | |
6180 | <dt>IPP_FINISHINGS_CUPS_PUNCH_TRIPLE_LEFT </dt> | |
6181 | <dd class="description">Punch 3 holes left side</dd> | |
6182 | <dt>IPP_FINISHINGS_CUPS_PUNCH_TRIPLE_RIGHT </dt> | |
6183 | <dd class="description">Punch 3 holes right side</dd> | |
6184 | <dt>IPP_FINISHINGS_CUPS_PUNCH_TRIPLE_TOP </dt> | |
6185 | <dd class="description">Punch 3 holes top edge</dd> | |
5a738aea MS |
6186 | <dt>IPP_FINISHINGS_EDGE_STITCH </dt> |
6187 | <dd class="description">Stitch along any side</dd> | |
6188 | <dt>IPP_FINISHINGS_EDGE_STITCH_BOTTOM </dt> | |
6189 | <dd class="description">Stitch along bottom edge</dd> | |
6190 | <dt>IPP_FINISHINGS_EDGE_STITCH_LEFT </dt> | |
6191 | <dd class="description">Stitch along left side</dd> | |
6192 | <dt>IPP_FINISHINGS_EDGE_STITCH_RIGHT </dt> | |
6193 | <dd class="description">Stitch along right side</dd> | |
6194 | <dt>IPP_FINISHINGS_EDGE_STITCH_TOP </dt> | |
6195 | <dd class="description">Stitch along top edge</dd> | |
6196 | <dt>IPP_FINISHINGS_FOLD </dt> | |
6197 | <dd class="description">Fold (any type)</dd> | |
9c0e8e5d MS |
6198 | <dt>IPP_FINISHINGS_FOLD_ACCORDIAN </dt> |
6199 | <dd class="description">Accordian-fold the paper vertically into four sections</dd> | |
6200 | <dt>IPP_FINISHINGS_FOLD_DOUBLE_GATE </dt> | |
6201 | <dd class="description">Fold the top and bottom quarters of the paper towards the midline, then fold in half vertically</dd> | |
6202 | <dt>IPP_FINISHINGS_FOLD_GATE </dt> | |
6203 | <dd class="description">Fold the top and bottom quarters of the paper towards the midline</dd> | |
6204 | <dt>IPP_FINISHINGS_FOLD_HALF </dt> | |
6205 | <dd class="description">Fold the paper in half vertically</dd> | |
6206 | <dt>IPP_FINISHINGS_FOLD_HALF_Z </dt> | |
6207 | <dd class="description">Fold the paper in half horizontally, then Z-fold the paper vertically</dd> | |
6208 | <dt>IPP_FINISHINGS_FOLD_LEFT_GATE </dt> | |
6209 | <dd class="description">Fold the top quarter of the paper towards the midline</dd> | |
6210 | <dt>IPP_FINISHINGS_FOLD_LETTER </dt> | |
6211 | <dd class="description">Fold the paper into three sections vertically; sometimes also known as a C fold</dd> | |
6212 | <dt>IPP_FINISHINGS_FOLD_PARALLEL </dt> | |
6213 | <dd class="description">Fold the paper in half vertically two times, yielding four sections</dd> | |
6214 | <dt>IPP_FINISHINGS_FOLD_POSTER </dt> | |
6215 | <dd class="description">Fold the paper in half horizontally and vertically; sometimes also called a cross fold</dd> | |
6216 | <dt>IPP_FINISHINGS_FOLD_RIGHT_GATE </dt> | |
6217 | <dd class="description">Fold the bottom quarter of the paper towards the midline</dd> | |
6218 | <dt>IPP_FINISHINGS_FOLD_Z </dt> | |
6219 | <dd class="description">Fold the paper vertically into three sections, forming a Z</dd> | |
6961465f | 6220 | <dt>IPP_FINISHINGS_JOG_OFFSET </dt> |
5a738aea | 6221 | <dd class="description">Offset for binding (any type)</dd> |
ca6b43fc MS |
6222 | <dt>IPP_FINISHINGS_LAMINATE </dt> |
6223 | <dd class="description">Apply protective (solid) material</dd> | |
5a738aea MS |
6224 | <dt>IPP_FINISHINGS_NONE </dt> |
6225 | <dd class="description">No finishing</dd> | |
6226 | <dt>IPP_FINISHINGS_PUNCH </dt> | |
6227 | <dd class="description">Punch (any location/count)</dd> | |
9c0e8e5d MS |
6228 | <dt>IPP_FINISHINGS_PUNCH_BOTTOM_LEFT </dt> |
6229 | <dd class="description">Punch 1 hole bottom left</dd> | |
6230 | <dt>IPP_FINISHINGS_PUNCH_BOTTOM_RIGHT </dt> | |
6231 | <dd class="description">Punch 1 hole bottom right</dd> | |
6232 | <dt>IPP_FINISHINGS_PUNCH_DUAL_BOTTOM </dt> | |
6233 | <dd class="description">Punch 2 holes bottom edge</dd> | |
6234 | <dt>IPP_FINISHINGS_PUNCH_DUAL_LEFT </dt> | |
6235 | <dd class="description">Punch 2 holes left side</dd> | |
6236 | <dt>IPP_FINISHINGS_PUNCH_DUAL_RIGHT </dt> | |
6237 | <dd class="description">Punch 2 holes right side</dd> | |
6238 | <dt>IPP_FINISHINGS_PUNCH_DUAL_TOP </dt> | |
6239 | <dd class="description">Punch 2 holes top edge</dd> | |
6240 | <dt>IPP_FINISHINGS_PUNCH_QUAD_BOTTOM </dt> | |
6241 | <dd class="description">Punch 4 holes bottom edge</dd> | |
6242 | <dt>IPP_FINISHINGS_PUNCH_QUAD_LEFT </dt> | |
6243 | <dd class="description">Punch 4 holes left side</dd> | |
6244 | <dt>IPP_FINISHINGS_PUNCH_QUAD_RIGHT </dt> | |
6245 | <dd class="description">Punch 4 holes right side</dd> | |
6246 | <dt>IPP_FINISHINGS_PUNCH_QUAD_TOP </dt> | |
6247 | <dd class="description">Punch 4 holes top edge</dd> | |
6248 | <dt>IPP_FINISHINGS_PUNCH_TOP_LEFT </dt> | |
6249 | <dd class="description">Punch 1 hole top left</dd> | |
6250 | <dt>IPP_FINISHINGS_PUNCH_TOP_RIGHT </dt> | |
6251 | <dd class="description">Punch 1 hole top right</dd> | |
6252 | <dt>IPP_FINISHINGS_PUNCH_TRIPLE_BOTTOM </dt> | |
6253 | <dd class="description">Punch 3 holes bottom edge</dd> | |
6254 | <dt>IPP_FINISHINGS_PUNCH_TRIPLE_LEFT </dt> | |
6255 | <dd class="description">Punch 3 holes left side</dd> | |
6256 | <dt>IPP_FINISHINGS_PUNCH_TRIPLE_RIGHT </dt> | |
6257 | <dd class="description">Punch 3 holes right side</dd> | |
6258 | <dt>IPP_FINISHINGS_PUNCH_TRIPLE_TOP </dt> | |
6259 | <dd class="description">Punch 3 holes top edge</dd> | |
5a738aea MS |
6260 | <dt>IPP_FINISHINGS_SADDLE_STITCH </dt> |
6261 | <dd class="description">Staple interior</dd> | |
6262 | <dt>IPP_FINISHINGS_STAPLE </dt> | |
6263 | <dd class="description">Staple (any location)</dd> | |
6264 | <dt>IPP_FINISHINGS_STAPLE_BOTTOM_LEFT </dt> | |
6265 | <dd class="description">Staple bottom left corner</dd> | |
6266 | <dt>IPP_FINISHINGS_STAPLE_BOTTOM_RIGHT </dt> | |
6267 | <dd class="description">Staple bottom right corner</dd> | |
6268 | <dt>IPP_FINISHINGS_STAPLE_DUAL_BOTTOM </dt> | |
6269 | <dd class="description">Two staples on bottom</dd> | |
6270 | <dt>IPP_FINISHINGS_STAPLE_DUAL_LEFT </dt> | |
6271 | <dd class="description">Two staples on left</dd> | |
6272 | <dt>IPP_FINISHINGS_STAPLE_DUAL_RIGHT </dt> | |
6273 | <dd class="description">Two staples on right</dd> | |
6274 | <dt>IPP_FINISHINGS_STAPLE_DUAL_TOP </dt> | |
6275 | <dd class="description">Two staples on top</dd> | |
6276 | <dt>IPP_FINISHINGS_STAPLE_TOP_LEFT </dt> | |
6277 | <dd class="description">Staple top left corner</dd> | |
6278 | <dt>IPP_FINISHINGS_STAPLE_TOP_RIGHT </dt> | |
6279 | <dd class="description">Staple top right corner</dd> | |
ca6b43fc MS |
6280 | <dt>IPP_FINISHINGS_STAPLE_TRIPLE_BOTTOM </dt> |
6281 | <dd class="description">Three staples on bottom</dd> | |
6282 | <dt>IPP_FINISHINGS_STAPLE_TRIPLE_LEFT </dt> | |
6283 | <dd class="description">Three staples on left</dd> | |
6284 | <dt>IPP_FINISHINGS_STAPLE_TRIPLE_RIGHT </dt> | |
6285 | <dd class="description">Three staples on right</dd> | |
6286 | <dt>IPP_FINISHINGS_STAPLE_TRIPLE_TOP </dt> | |
6287 | <dd class="description">Three staples on top</dd> | |
5a738aea MS |
6288 | <dt>IPP_FINISHINGS_TRIM </dt> |
6289 | <dd class="description">Trim (any type)</dd> | |
a2326b5b MS |
6290 | <dt>IPP_FINISHINGS_TRIM_AFTER_COPIES </dt> |
6291 | <dd class="description">Trim output after each copy</dd> | |
6292 | <dt>IPP_FINISHINGS_TRIM_AFTER_DOCUMENTS </dt> | |
6293 | <dd class="description">Trim output after each document</dd> | |
6294 | <dt>IPP_FINISHINGS_TRIM_AFTER_JOB </dt> | |
6295 | <dd class="description">Trim output after job</dd> | |
6296 | <dt>IPP_FINISHINGS_TRIM_AFTER_PAGES </dt> | |
6297 | <dd class="description">Trim output after each page</dd> | |
6298 | </dl> | |
6299 | <h3 class="enumeration"><a name="ipp_jcollate_e">ipp_jcollate_e</a></h3> | |
6300 | <p class="description">Job collation types</p> | |
6301 | <h4 class="constants">Constants</h4> | |
6302 | <dl> | |
a469f8a5 MS |
6303 | <dt>IPP_JCOLLATE_COLLATED_DOCUMENTS </dt> |
6304 | <dt>IPP_JCOLLATE_UNCOLLATED_DOCUMENTS </dt> | |
6305 | <dt>IPP_JCOLLATE_UNCOLLATED_SHEETS </dt> | |
5a738aea MS |
6306 | </dl> |
6307 | <h3 class="enumeration"><a name="ipp_jstate_e">ipp_jstate_e</a></h3> | |
aaf19ab0 | 6308 | <p class="description">Job states</p> |
5a738aea MS |
6309 | <h4 class="constants">Constants</h4> |
6310 | <dl> | |
a469f8a5 | 6311 | <dt>IPP_JSTATE_ABORTED </dt> |
5a738aea | 6312 | <dd class="description">Job has aborted due to error</dd> |
a469f8a5 | 6313 | <dt>IPP_JSTATE_CANCELED </dt> |
5a738aea | 6314 | <dd class="description">Job has been canceled</dd> |
a469f8a5 | 6315 | <dt>IPP_JSTATE_COMPLETED </dt> |
5a738aea | 6316 | <dd class="description">Job has completed successfully</dd> |
a469f8a5 | 6317 | <dt>IPP_JSTATE_HELD </dt> |
5a738aea | 6318 | <dd class="description">Job is held for printing</dd> |
a469f8a5 | 6319 | <dt>IPP_JSTATE_PENDING </dt> |
5a738aea | 6320 | <dd class="description">Job is waiting to be printed</dd> |
a469f8a5 | 6321 | <dt>IPP_JSTATE_PROCESSING </dt> |
5a738aea | 6322 | <dd class="description">Job is currently printing</dd> |
a469f8a5 | 6323 | <dt>IPP_JSTATE_STOPPED </dt> |
5a738aea MS |
6324 | <dd class="description">Job has been stopped</dd> |
6325 | </dl> | |
6326 | <h3 class="enumeration"><a name="ipp_op_e">ipp_op_e</a></h3> | |
aaf19ab0 | 6327 | <p class="description">IPP operations</p> |
5a738aea MS |
6328 | <h4 class="constants">Constants</h4> |
6329 | <dl> | |
c59e07c6 MS |
6330 | <dt>IPP_OP_ACKNOWLEDGE_DOCUMENT </dt> |
6331 | <dd class="description">Acknowledge-Document</dd> | |
6332 | <dt>IPP_OP_ACKNOWLEDGE_IDENTIFY_PRINTER </dt> | |
6333 | <dd class="description">Acknowledge-Identify-Printer</dd> | |
6334 | <dt>IPP_OP_ACKNOWLEDGE_JOB </dt> | |
6335 | <dd class="description">Acknowledge-Job</dd> | |
6336 | <dt>IPP_OP_ACTIVATE_PRINTER </dt> | |
6337 | <dd class="description">Start a printer</dd> | |
6338 | <dt>IPP_OP_CANCEL_CURRENT_JOB </dt> | |
6339 | <dd class="description">Cancel the current job</dd> | |
6340 | <dt>IPP_OP_CANCEL_DOCUMENT </dt> | |
6341 | <dd class="description">Cancel-Document</dd> | |
a469f8a5 MS |
6342 | <dt>IPP_OP_CANCEL_JOB </dt> |
6343 | <dd class="description">Cancel a job</dd> | |
6344 | <dt>IPP_OP_CANCEL_JOBS </dt> | |
6345 | <dd class="description">Cancel-Jobs</dd> | |
6346 | <dt>IPP_OP_CANCEL_MY_JOBS </dt> | |
6347 | <dd class="description">Cancel-My-Jobs</dd> | |
6348 | <dt>IPP_OP_CANCEL_SUBSCRIPTION <span class="info"> CUPS 1.2/OS X 10.5 </span></dt> | |
6349 | <dd class="description">Cancel a subscription </dd> | |
6350 | <dt>IPP_OP_CLOSE_JOB </dt> | |
6351 | <dd class="description">Close-Job</dd> | |
6352 | <dt>IPP_OP_CREATE_JOB </dt> | |
6353 | <dd class="description">Create an empty print job</dd> | |
ca6b43fc MS |
6354 | <dt>IPP_OP_CREATE_JOB_SUBSCRIPTIONS <span class="info"> CUPS 1.2/OS X 10.5 </span></dt> |
6355 | <dd class="description">Create one of more job subscriptions </dd> | |
6356 | <dt>IPP_OP_CREATE_PRINTER_SUBSCRIPTIONS <span class="info"> CUPS 1.2/OS X 10.5 </span></dt> | |
6357 | <dd class="description">Create one or more printer subscriptions </dd> | |
a469f8a5 | 6358 | <dt>IPP_OP_CUPS_ACCEPT_JOBS </dt> |
5a738aea | 6359 | <dd class="description">Accept new jobs on a printer</dd> |
a469f8a5 | 6360 | <dt>IPP_OP_CUPS_ADD_MODIFY_CLASS </dt> |
5a738aea | 6361 | <dd class="description">Add or modify a class</dd> |
a469f8a5 | 6362 | <dt>IPP_OP_CUPS_ADD_MODIFY_PRINTER </dt> |
5a738aea | 6363 | <dd class="description">Add or modify a printer</dd> |
a469f8a5 | 6364 | <dt>IPP_OP_CUPS_AUTHENTICATE_JOB <span class="info"> CUPS 1.2/OS X 10.5 </span></dt> |
5a738aea | 6365 | <dd class="description">Authenticate a job </dd> |
503b54c9 MS |
6366 | <dt>IPP_OP_CUPS_CREATE_LOCAL_PRINTER <span class="info"> CUPS 2.2 </span></dt> |
6367 | <dd class="description">Create a local (temporary) printer <dt>IPP_OP_CUPS_DELETE_CLASS </dt> | |
5a738aea | 6368 | <dd class="description">Delete a class</dd> |
a469f8a5 | 6369 | <dt>IPP_OP_CUPS_DELETE_PRINTER </dt> |
5a738aea | 6370 | <dd class="description">Delete a printer</dd> |
a469f8a5 | 6371 | <dt>IPP_OP_CUPS_GET_CLASSES <span class="info"> DEPRECATED </span></dt> |
5a738aea | 6372 | <dd class="description">Get a list of classes </dd> |
a469f8a5 | 6373 | <dt>IPP_OP_CUPS_GET_DEFAULT </dt> |
5a738aea | 6374 | <dd class="description">Get the default printer</dd> |
503b54c9 MS |
6375 | <dt>IPP_OP_CUPS_GET_DEVICES <span class="info"> DEPRECATED </span></dt> |
6376 | <dd class="description">Get a list of supported devices </dd> | |
a469f8a5 | 6377 | <dt>IPP_OP_CUPS_GET_DOCUMENT <span class="info"> CUPS 1.4/OS X 10.6 </span></dt> |
5a738aea | 6378 | <dd class="description">Get a document file </dd> |
503b54c9 | 6379 | <dt>IPP_OP_CUPS_GET_PPD <span class="info"> DEPRECATED </span></dt> |
5a738aea | 6380 | <dd class="description">Get a PPD file </dd> |
503b54c9 MS |
6381 | <dt>IPP_OP_CUPS_GET_PPDS <span class="info"> DEPRECATED </span></dt> |
6382 | <dd class="description">Get a list of supported drivers </dd> | |
a469f8a5 | 6383 | <dt>IPP_OP_CUPS_GET_PRINTERS </dt> |
5a738aea | 6384 | <dd class="description">Get a list of printers and/or classes</dd> |
a469f8a5 MS |
6385 | <dt>IPP_OP_CUPS_INVALID </dt> |
6386 | <dd class="description">Invalid operation name for <a href="#ippOpValue"><code>ippOpValue</code></a></dd> | |
6387 | <dt>IPP_OP_CUPS_MOVE_JOB </dt> | |
5a738aea | 6388 | <dd class="description">Move a job to a different printer</dd> |
a469f8a5 | 6389 | <dt>IPP_OP_CUPS_REJECT_JOBS </dt> |
5a738aea | 6390 | <dd class="description">Reject new jobs on a printer</dd> |
a469f8a5 | 6391 | <dt>IPP_OP_CUPS_SET_DEFAULT </dt> |
5a738aea | 6392 | <dd class="description">Set the default printer</dd> |
c59e07c6 MS |
6393 | <dt>IPP_OP_DEACTIVATE_PRINTER </dt> |
6394 | <dd class="description">Stop a printer</dd> | |
6395 | <dt>IPP_OP_DELETE_DOCUMENT </dt> | |
6396 | <dd class="description">Delete-Document</dd> | |
6397 | <dt>IPP_OP_DEREGISTER_OUTPUT_DEVICE </dt> | |
6398 | <dd class="description">Deregister-Output-Device</dd> | |
a469f8a5 | 6399 | <dt>IPP_OP_DISABLE_PRINTER </dt> |
5a738aea | 6400 | <dd class="description">Stop a printer</dd> |
a469f8a5 | 6401 | <dt>IPP_OP_ENABLE_PRINTER </dt> |
5a738aea | 6402 | <dd class="description">Start a printer</dd> |
c59e07c6 MS |
6403 | <dt>IPP_OP_FETCH_DOCUMENT </dt> |
6404 | <dd class="description">Fetch-Document</dd> | |
6405 | <dt>IPP_OP_FETCH_JOB </dt> | |
6406 | <dd class="description">Fetch-Job</dd> | |
6407 | <dt>IPP_OP_GET_DOCUMENTS </dt> | |
6408 | <dd class="description">Get-Documents</dd> | |
6409 | <dt>IPP_OP_GET_DOCUMENT_ATTRIBUTES </dt> | |
6410 | <dd class="description">Get-Document-Attributes</dd> | |
a469f8a5 | 6411 | <dt>IPP_OP_GET_JOBS </dt> |
5a738aea | 6412 | <dd class="description">Get a list of jobs</dd> |
a469f8a5 | 6413 | <dt>IPP_OP_GET_JOB_ATTRIBUTES </dt> |
5a738aea | 6414 | <dd class="description">Get job attributes</dd> |
c59e07c6 MS |
6415 | <dt>IPP_OP_GET_NEXT_DOCUMENT_DATA </dt> |
6416 | <dd class="description">Get-Next-Document-Data</dd> | |
a469f8a5 | 6417 | <dt>IPP_OP_GET_NOTIFICATIONS <span class="info"> CUPS 1.2/OS X 10.5 </span></dt> |
5a738aea | 6418 | <dd class="description">Get notification events </dd> |
c59e07c6 MS |
6419 | <dt>IPP_OP_GET_OUTPUT_DEVICE_ATTRIBUTES </dt> |
6420 | <dd class="description">Get-Output-Device-Attributes</dd> | |
a469f8a5 | 6421 | <dt>IPP_OP_GET_PRINTER_ATTRIBUTES </dt> |
5a738aea | 6422 | <dd class="description">Get printer attributes</dd> |
a469f8a5 | 6423 | <dt>IPP_OP_GET_PRINTER_SUPPORTED_VALUES </dt> |
5a738aea | 6424 | <dd class="description">Get supported attribute values</dd> |
a469f8a5 | 6425 | <dt>IPP_OP_GET_SUBSCRIPTIONS <span class="info"> CUPS 1.2/OS X 10.5 </span></dt> |
5a738aea | 6426 | <dd class="description">Get list of subscriptions </dd> |
a469f8a5 | 6427 | <dt>IPP_OP_GET_SUBSCRIPTION_ATTRIBUTES <span class="info"> CUPS 1.2/OS X 10.5 </span></dt> |
5a738aea | 6428 | <dd class="description">Get subscription attributes </dd> |
a469f8a5 | 6429 | <dt>IPP_OP_HOLD_JOB </dt> |
5a738aea | 6430 | <dd class="description">Hold a job for printing</dd> |
c59e07c6 MS |
6431 | <dt>IPP_OP_HOLD_NEW_JOBS </dt> |
6432 | <dd class="description">Hold new jobs</dd> | |
6433 | <dt>IPP_OP_IDENTIFY_PRINTER </dt> | |
6434 | <dd class="description">Identify-Printer</dd> | |
a469f8a5 | 6435 | <dt>IPP_OP_PAUSE_PRINTER </dt> |
5a738aea | 6436 | <dd class="description">Stop a printer</dd> |
c59e07c6 MS |
6437 | <dt>IPP_OP_PAUSE_PRINTER_AFTER_CURRENT_JOB </dt> |
6438 | <dd class="description">Stop printer after the current job</dd> | |
a469f8a5 | 6439 | <dt>IPP_OP_PRINT_JOB </dt> |
5a738aea | 6440 | <dd class="description">Print a single file</dd> |
c59e07c6 MS |
6441 | <dt>IPP_OP_PRINT_URI </dt> |
6442 | <dd class="description">Print a single URL</dd> | |
6443 | <dt>IPP_OP_PROMOTE_JOB </dt> | |
6444 | <dd class="description">Promote a job to print sooner</dd> | |
a469f8a5 | 6445 | <dt>IPP_OP_PURGE_JOBS </dt> |
5a738aea | 6446 | <dd class="description">Cancel all jobs</dd> |
c59e07c6 MS |
6447 | <dt>IPP_OP_RELEASE_HELD_NEW_JOBS </dt> |
6448 | <dd class="description">Release new jobs</dd> | |
a469f8a5 | 6449 | <dt>IPP_OP_RELEASE_JOB </dt> |
5a738aea | 6450 | <dd class="description">Release a job for printing</dd> |
a469f8a5 | 6451 | <dt>IPP_OP_RENEW_SUBSCRIPTION <span class="info"> CUPS 1.2/OS X 10.5 </span></dt> |
5a738aea | 6452 | <dd class="description">Renew a printer subscription </dd> |
c59e07c6 MS |
6453 | <dt>IPP_OP_REPROCESS_JOB </dt> |
6454 | <dd class="description">Reprint a job</dd> | |
a469f8a5 | 6455 | <dt>IPP_OP_RESTART_JOB </dt> |
5a738aea | 6456 | <dd class="description">Reprint a job</dd> |
c59e07c6 MS |
6457 | <dt>IPP_OP_RESTART_PRINTER </dt> |
6458 | <dd class="description">Restart a printer</dd> | |
a469f8a5 | 6459 | <dt>IPP_OP_RESUBMIT_JOB </dt> |
aaf19ab0 | 6460 | <dd class="description">Resubmit-Job</dd> |
c59e07c6 MS |
6461 | <dt>IPP_OP_RESUME_JOB </dt> |
6462 | <dd class="description">Resume the current job</dd> | |
a469f8a5 | 6463 | <dt>IPP_OP_RESUME_PRINTER </dt> |
5a738aea | 6464 | <dd class="description">Start a printer</dd> |
c59e07c6 MS |
6465 | <dt>IPP_OP_SCHEDULE_JOB_AFTER </dt> |
6466 | <dd class="description">Schedule a job to print after another</dd> | |
a469f8a5 | 6467 | <dt>IPP_OP_SEND_DOCUMENT </dt> |
5a738aea | 6468 | <dd class="description">Add a file to a job</dd> |
c59e07c6 MS |
6469 | <dt>IPP_OP_SEND_HARDCOPY_DOCUMENT </dt> |
6470 | <dd class="description">Send-Hardcopy-Document</dd> | |
6471 | <dt>IPP_OP_SEND_URI </dt> | |
6472 | <dd class="description">Add a URL to a job</dd> | |
6473 | <dt>IPP_OP_SET_DOCUMENT_ATTRIBUTES </dt> | |
6474 | <dd class="description">Set-Document-Attributes</dd> | |
a469f8a5 | 6475 | <dt>IPP_OP_SET_JOB_ATTRIBUTES </dt> |
5a738aea | 6476 | <dd class="description">Set job attributes</dd> |
c59e07c6 MS |
6477 | <dt>IPP_OP_SET_PRINTER_ATTRIBUTES </dt> |
6478 | <dd class="description">Set printer attributes</dd> | |
6479 | <dt>IPP_OP_SHUTDOWN_PRINTER </dt> | |
6480 | <dd class="description">Turn a printer off</dd> | |
6481 | <dt>IPP_OP_STARTUP_PRINTER </dt> | |
6482 | <dd class="description">Turn a printer on</dd> | |
6483 | <dt>IPP_OP_SUSPEND_CURRENT_JOB </dt> | |
6484 | <dd class="description">Suspend the current job</dd> | |
6485 | <dt>IPP_OP_UPDATE_ACTIVE_JOBS </dt> | |
6486 | <dd class="description">Update-Active-Jobs</dd> | |
6487 | <dt>IPP_OP_UPDATE_DOCUMENT_STATUS </dt> | |
6488 | <dd class="description">Update-Document-Status</dd> | |
6489 | <dt>IPP_OP_UPDATE_JOB_STATUS </dt> | |
6490 | <dd class="description">Update-Job-Status</dd> | |
6491 | <dt>IPP_OP_UPDATE_OUTPUT_DEVICE_ATTRIBUTES </dt> | |
6492 | <dd class="description">Update-Output-Device-Attributes</dd> | |
6493 | <dt>IPP_OP_VALIDATE_DOCUMENT </dt> | |
6494 | <dd class="description">Validate-Document</dd> | |
a469f8a5 | 6495 | <dt>IPP_OP_VALIDATE_JOB </dt> |
5a738aea MS |
6496 | <dd class="description">Validate job options</dd> |
6497 | </dl> | |
6498 | <h3 class="enumeration"><a name="ipp_orient_e">ipp_orient_e</a></h3> | |
aaf19ab0 | 6499 | <p class="description">Orientation values</p> |
5a738aea MS |
6500 | <h4 class="constants">Constants</h4> |
6501 | <dl> | |
a469f8a5 | 6502 | <dt>IPP_ORIENT_LANDSCAPE </dt> |
5a738aea | 6503 | <dd class="description">90 degrees counter-clockwise</dd> |
ca6b43fc MS |
6504 | <dt>IPP_ORIENT_NONE </dt> |
6505 | <dd class="description">No rotation</dd> | |
a469f8a5 | 6506 | <dt>IPP_ORIENT_PORTRAIT </dt> |
5a738aea | 6507 | <dd class="description">No rotation</dd> |
a469f8a5 | 6508 | <dt>IPP_ORIENT_REVERSE_LANDSCAPE </dt> |
5a738aea | 6509 | <dd class="description">90 degrees clockwise</dd> |
a469f8a5 | 6510 | <dt>IPP_ORIENT_REVERSE_PORTRAIT </dt> |
5a738aea MS |
6511 | <dd class="description">180 degrees</dd> |
6512 | </dl> | |
6513 | <h3 class="enumeration"><a name="ipp_pstate_e">ipp_pstate_e</a></h3> | |
aaf19ab0 | 6514 | <p class="description">Printer states</p> |
5a738aea MS |
6515 | <h4 class="constants">Constants</h4> |
6516 | <dl> | |
a469f8a5 | 6517 | <dt>IPP_PSTATE_IDLE </dt> |
5a738aea | 6518 | <dd class="description">Printer is idle</dd> |
a469f8a5 | 6519 | <dt>IPP_PSTATE_PROCESSING </dt> |
5a738aea | 6520 | <dd class="description">Printer is working</dd> |
a469f8a5 | 6521 | <dt>IPP_PSTATE_STOPPED </dt> |
5a738aea MS |
6522 | <dd class="description">Printer is stopped</dd> |
6523 | </dl> | |
6524 | <h3 class="enumeration"><a name="ipp_quality_e">ipp_quality_e</a></h3> | |
aaf19ab0 | 6525 | <p class="description">Qualities</p> |
5a738aea MS |
6526 | <h4 class="constants">Constants</h4> |
6527 | <dl> | |
6528 | <dt>IPP_QUALITY_DRAFT </dt> | |
6529 | <dd class="description">Draft quality</dd> | |
6530 | <dt>IPP_QUALITY_HIGH </dt> | |
6531 | <dd class="description">High quality</dd> | |
6532 | <dt>IPP_QUALITY_NORMAL </dt> | |
6533 | <dd class="description">Normal quality</dd> | |
6534 | </dl> | |
6535 | <h3 class="enumeration"><a name="ipp_res_e">ipp_res_e</a></h3> | |
aaf19ab0 | 6536 | <p class="description">Resolution units</p> |
5a738aea MS |
6537 | <h4 class="constants">Constants</h4> |
6538 | <dl> | |
6539 | <dt>IPP_RES_PER_CM </dt> | |
6540 | <dd class="description">Pixels per centimeter</dd> | |
6541 | <dt>IPP_RES_PER_INCH </dt> | |
6542 | <dd class="description">Pixels per inch</dd> | |
6543 | </dl> | |
6544 | <h3 class="enumeration"><a name="ipp_state_e">ipp_state_e</a></h3> | |
aaf19ab0 | 6545 | <p class="description">IPP states</p> |
5a738aea MS |
6546 | <h4 class="constants">Constants</h4> |
6547 | <dl> | |
a469f8a5 | 6548 | <dt>IPP_STATE_ATTRIBUTE </dt> |
5a738aea | 6549 | <dd class="description">One or more attributes need to be sent/received</dd> |
a469f8a5 | 6550 | <dt>IPP_STATE_DATA </dt> |
5a738aea | 6551 | <dd class="description">IPP request data needs to be sent/received</dd> |
a469f8a5 | 6552 | <dt>IPP_STATE_ERROR </dt> |
5a738aea | 6553 | <dd class="description">An error occurred</dd> |
a469f8a5 | 6554 | <dt>IPP_STATE_HEADER </dt> |
5a738aea | 6555 | <dd class="description">The request header needs to be sent/received</dd> |
a469f8a5 | 6556 | <dt>IPP_STATE_IDLE </dt> |
5a738aea MS |
6557 | <dd class="description">Nothing is happening/request completed</dd> |
6558 | </dl> | |
6559 | <h3 class="enumeration"><a name="ipp_status_e">ipp_status_e</a></h3> | |
aaf19ab0 | 6560 | <p class="description">IPP status codes</p> |
5a738aea MS |
6561 | <h4 class="constants">Constants</h4> |
6562 | <dl> | |
a469f8a5 MS |
6563 | <dt>IPP_STATUS_CUPS_INVALID </dt> |
6564 | <dd class="description">Invalid status name for <a href="#ippErrorValue"><code>ippErrorValue</code></a></dd> | |
6565 | <dt>IPP_STATUS_CUPS_SEE_OTHER </dt> | |
5a738aea | 6566 | <dd class="description">cups-see-other</dd> |
240214ef MS |
6567 | <dt>IPP_STATUS_ERROR_ACCOUNT_AUTHORIZATION_FAILED </dt> |
6568 | <dd class="description">client-error-account-authorization-failed</dd> | |
6569 | <dt>IPP_STATUS_ERROR_ACCOUNT_CLOSED </dt> | |
6570 | <dd class="description">client-error-account-closed</dd> | |
6571 | <dt>IPP_STATUS_ERROR_ACCOUNT_INFO_NEEDED </dt> | |
6572 | <dd class="description">client-error-account-info-needed</dd> | |
6573 | <dt>IPP_STATUS_ERROR_ACCOUNT_LIMIT_REACHED </dt> | |
6574 | <dd class="description">client-error-account-limit-reached</dd> | |
a469f8a5 | 6575 | <dt>IPP_STATUS_ERROR_ATTRIBUTES_NOT_SETTABLE </dt> |
5a738aea | 6576 | <dd class="description">client-error-attributes-not-settable</dd> |
a469f8a5 MS |
6577 | <dt>IPP_STATUS_ERROR_ATTRIBUTES_OR_VALUES </dt> |
6578 | <dd class="description">client-error-attributes-or-values-not-supported</dd> | |
6579 | <dt>IPP_STATUS_ERROR_BAD_REQUEST </dt> | |
5a738aea | 6580 | <dd class="description">client-error-bad-request</dd> |
a469f8a5 MS |
6581 | <dt>IPP_STATUS_ERROR_BUSY </dt> |
6582 | <dd class="description">server-error-busy</dd> | |
6583 | <dt>IPP_STATUS_ERROR_CHARSET </dt> | |
5a738aea | 6584 | <dd class="description">client-error-charset-not-supported</dd> |
a469f8a5 | 6585 | <dt>IPP_STATUS_ERROR_COMPRESSION_ERROR </dt> |
5a738aea | 6586 | <dd class="description">client-error-compression-error</dd> |
a469f8a5 | 6587 | <dt>IPP_STATUS_ERROR_COMPRESSION_NOT_SUPPORTED </dt> |
5a738aea | 6588 | <dd class="description">client-error-compression-not-supported</dd> |
a469f8a5 | 6589 | <dt>IPP_STATUS_ERROR_CONFLICTING </dt> |
5a738aea | 6590 | <dd class="description">client-error-conflicting-attributes</dd> |
240214ef | 6591 | <dt>IPP_STATUS_ERROR_CUPS_ACCOUNT_AUTHORIZATION_FAILED <span class="info"> DEPRECATED </span></dt> |
a469f8a5 | 6592 | <dd class="description">cups-error-account-authorization-failed </dd> |
240214ef MS |
6593 | <dt>IPP_STATUS_ERROR_CUPS_ACCOUNT_CLOSED </dt> |
6594 | <dd class="description">cups-error-account-closed @deprecate@</dd> | |
6595 | <dt>IPP_STATUS_ERROR_CUPS_ACCOUNT_INFO_NEEDED <span class="info"> DEPRECATED </span></dt> | |
a469f8a5 | 6596 | <dd class="description">cups-error-account-info-needed </dd> |
240214ef | 6597 | <dt>IPP_STATUS_ERROR_CUPS_ACCOUNT_LIMIT_REACHED <span class="info"> DEPRECATED </span></dt> |
a469f8a5 MS |
6598 | <dd class="description">cups-error-account-limit-reached </dd> |
6599 | <dt>IPP_STATUS_ERROR_CUPS_AUTHENTICATION_CANCELED <span class="info"> CUPS 1.5/OS X 10.7 </span></dt> | |
6600 | <dd class="description">cups-authentication-canceled - Authentication canceled by user </dd> | |
6601 | <dt>IPP_STATUS_ERROR_CUPS_PKI <span class="info"> CUPS 1.5/OS X 10.7 </span></dt> | |
6602 | <dd class="description">cups-pki-error - Error negotiating a secure connection </dd> | |
6603 | <dt>IPP_STATUS_ERROR_CUPS_UPGRADE_REQUIRED </dt> | |
6604 | <dd class="description">cups-upgrade-required - TLS upgrade required</dd> | |
6605 | <dt>IPP_STATUS_ERROR_DEVICE </dt> | |
5a738aea | 6606 | <dd class="description">server-error-device-error</dd> |
a469f8a5 | 6607 | <dt>IPP_STATUS_ERROR_DOCUMENT_ACCESS </dt> |
5a738aea | 6608 | <dd class="description">client-error-document-access-error</dd> |
a469f8a5 | 6609 | <dt>IPP_STATUS_ERROR_DOCUMENT_FORMAT_ERROR </dt> |
5a738aea | 6610 | <dd class="description">client-error-document-format-error</dd> |
a469f8a5 MS |
6611 | <dt>IPP_STATUS_ERROR_DOCUMENT_FORMAT_NOT_SUPPORTED </dt> |
6612 | <dd class="description">client-error-document-format-not-supported</dd> | |
6613 | <dt>IPP_STATUS_ERROR_DOCUMENT_PASSWORD </dt> | |
a2326b5b | 6614 | <dd class="description">client-error-document-password-error</dd> |
a469f8a5 | 6615 | <dt>IPP_STATUS_ERROR_DOCUMENT_PERMISSION </dt> |
a2326b5b | 6616 | <dd class="description">client-error-document-permission-error</dd> |
a469f8a5 | 6617 | <dt>IPP_STATUS_ERROR_DOCUMENT_SECURITY </dt> |
a2326b5b | 6618 | <dd class="description">client-error-document-security-error</dd> |
a469f8a5 | 6619 | <dt>IPP_STATUS_ERROR_DOCUMENT_UNPRINTABLE </dt> |
a2326b5b | 6620 | <dd class="description">client-error-document-unprintable-error</dd> |
a469f8a5 | 6621 | <dt>IPP_STATUS_ERROR_FORBIDDEN </dt> |
5a738aea | 6622 | <dd class="description">client-error-forbidden</dd> |
a469f8a5 | 6623 | <dt>IPP_STATUS_ERROR_GONE </dt> |
5a738aea | 6624 | <dd class="description">client-error-gone</dd> |
a469f8a5 | 6625 | <dt>IPP_STATUS_ERROR_IGNORED_ALL_SUBSCRIPTIONS </dt> |
5a738aea | 6626 | <dd class="description">client-error-ignored-all-subscriptions</dd> |
a469f8a5 | 6627 | <dt>IPP_STATUS_ERROR_INTERNAL </dt> |
5a738aea | 6628 | <dd class="description">server-error-internal-error</dd> |
a469f8a5 MS |
6629 | <dt>IPP_STATUS_ERROR_JOB_CANCELED </dt> |
6630 | <dd class="description">server-error-job-canceled</dd> | |
6631 | <dt>IPP_STATUS_ERROR_MULTIPLE_JOBS_NOT_SUPPORTED </dt> | |
5a738aea | 6632 | <dd class="description">server-error-multiple-document-jobs-not-supported</dd> |
a469f8a5 | 6633 | <dt>IPP_STATUS_ERROR_NOT_ACCEPTING_JOBS </dt> |
5a738aea | 6634 | <dd class="description">server-error-not-accepting-jobs</dd> |
a469f8a5 | 6635 | <dt>IPP_STATUS_ERROR_NOT_AUTHENTICATED </dt> |
5a738aea | 6636 | <dd class="description">client-error-not-authenticated</dd> |
a469f8a5 | 6637 | <dt>IPP_STATUS_ERROR_NOT_AUTHORIZED </dt> |
5a738aea | 6638 | <dd class="description">client-error-not-authorized</dd> |
6e5a57e8 MS |
6639 | <dt>IPP_STATUS_ERROR_NOT_FETCHABLE </dt> |
6640 | <dd class="description">client-error-not-fetchable</dd> | |
a469f8a5 | 6641 | <dt>IPP_STATUS_ERROR_NOT_FOUND </dt> |
5a738aea | 6642 | <dd class="description">client-error-not-found</dd> |
a469f8a5 | 6643 | <dt>IPP_STATUS_ERROR_NOT_POSSIBLE </dt> |
5a738aea | 6644 | <dd class="description">client-error-not-possible</dd> |
a469f8a5 | 6645 | <dt>IPP_STATUS_ERROR_OPERATION_NOT_SUPPORTED </dt> |
5a738aea | 6646 | <dd class="description">server-error-operation-not-supported</dd> |
a469f8a5 | 6647 | <dt>IPP_STATUS_ERROR_PRINTER_IS_DEACTIVATED </dt> |
5a738aea | 6648 | <dd class="description">server-error-printer-is-deactivated</dd> |
a469f8a5 | 6649 | <dt>IPP_STATUS_ERROR_REQUEST_ENTITY </dt> |
5a738aea | 6650 | <dd class="description">client-error-request-entity-too-large</dd> |
a469f8a5 | 6651 | <dt>IPP_STATUS_ERROR_REQUEST_VALUE </dt> |
5a738aea | 6652 | <dd class="description">client-error-request-value-too-long</dd> |
a469f8a5 | 6653 | <dt>IPP_STATUS_ERROR_SERVICE_UNAVAILABLE </dt> |
5a738aea | 6654 | <dd class="description">server-error-service-unavailable</dd> |
a469f8a5 | 6655 | <dt>IPP_STATUS_ERROR_TEMPORARY </dt> |
5a738aea | 6656 | <dd class="description">server-error-temporary-error</dd> |
a469f8a5 | 6657 | <dt>IPP_STATUS_ERROR_TIMEOUT </dt> |
5a738aea | 6658 | <dd class="description">client-error-timeout</dd> |
a469f8a5 | 6659 | <dt>IPP_STATUS_ERROR_TOO_MANY_DOCUMENTS </dt> |
3e7fe0ca | 6660 | <dd class="description">server-error-too-many-documents</dd> |
a469f8a5 | 6661 | <dt>IPP_STATUS_ERROR_TOO_MANY_JOBS </dt> |
3e7fe0ca | 6662 | <dd class="description">server-error-too-many-jobs</dd> |
a469f8a5 | 6663 | <dt>IPP_STATUS_ERROR_TOO_MANY_SUBSCRIPTIONS </dt> |
5a738aea | 6664 | <dd class="description">client-error-too-many-subscriptions</dd> |
a469f8a5 | 6665 | <dt>IPP_STATUS_ERROR_URI_SCHEME </dt> |
5a738aea | 6666 | <dd class="description">client-error-uri-scheme-not-supported</dd> |
a469f8a5 | 6667 | <dt>IPP_STATUS_ERROR_VERSION_NOT_SUPPORTED </dt> |
5a738aea | 6668 | <dd class="description">server-error-version-not-supported</dd> |
a469f8a5 MS |
6669 | <dt>IPP_STATUS_OK </dt> |
6670 | <dd class="description">successful-ok</dd> | |
6671 | <dt>IPP_STATUS_OK_CONFLICTING </dt> | |
6672 | <dd class="description">successful-ok-conflicting-attributes</dd> | |
6673 | <dt>IPP_STATUS_OK_EVENTS_COMPLETE </dt> | |
6674 | <dd class="description">successful-ok-events-complete</dd> | |
6675 | <dt>IPP_STATUS_OK_IGNORED_OR_SUBSTITUTED </dt> | |
6676 | <dd class="description">successful-ok-ignored-or-substituted-attributes</dd> | |
6677 | <dt>IPP_STATUS_OK_IGNORED_SUBSCRIPTIONS </dt> | |
6678 | <dd class="description">successful-ok-ignored-subscriptions</dd> | |
6679 | <dt>IPP_STATUS_OK_TOO_MANY_EVENTS </dt> | |
6680 | <dd class="description">successful-ok-too-many-events</dd> | |
5a738aea MS |
6681 | </dl> |
6682 | <h3 class="enumeration"><a name="ipp_tag_e">ipp_tag_e</a></h3> | |
aaf19ab0 | 6683 | <p class="description">Format tags for attributes</p> |
5a738aea MS |
6684 | <h4 class="constants">Constants</h4> |
6685 | <dl> | |
6686 | <dt>IPP_TAG_ADMINDEFINE </dt> | |
6687 | <dd class="description">Admin-defined value</dd> | |
6688 | <dt>IPP_TAG_BEGIN_COLLECTION </dt> | |
6689 | <dd class="description">Beginning of collection value</dd> | |
6690 | <dt>IPP_TAG_BOOLEAN </dt> | |
6691 | <dd class="description">Boolean value</dd> | |
6692 | <dt>IPP_TAG_CHARSET </dt> | |
6693 | <dd class="description">Character set value</dd> | |
3e7fe0ca MS |
6694 | <dt>IPP_TAG_CUPS_INVALID </dt> |
6695 | <dd class="description">Invalid tag name for <a href="#ippTagValue"><code>ippTagValue</code></a></dd> | |
5a738aea MS |
6696 | <dt>IPP_TAG_DATE </dt> |
6697 | <dd class="description">Date/time value</dd> | |
6698 | <dt>IPP_TAG_DEFAULT </dt> | |
6699 | <dd class="description">Default value</dd> | |
6700 | <dt>IPP_TAG_DELETEATTR </dt> | |
6701 | <dd class="description">Delete-attribute value</dd> | |
a2326b5b MS |
6702 | <dt>IPP_TAG_DOCUMENT </dt> |
6703 | <dd class="description">Document group</dd> | |
5a738aea MS |
6704 | <dt>IPP_TAG_END </dt> |
6705 | <dd class="description">End-of-attributes</dd> | |
6706 | <dt>IPP_TAG_END_COLLECTION </dt> | |
6707 | <dd class="description">End of collection value</dd> | |
6708 | <dt>IPP_TAG_ENUM </dt> | |
6709 | <dd class="description">Enumeration value</dd> | |
6710 | <dt>IPP_TAG_EVENT_NOTIFICATION </dt> | |
6711 | <dd class="description">Event group</dd> | |
a2326b5b MS |
6712 | <dt>IPP_TAG_EXTENSION </dt> |
6713 | <dd class="description">Extension point for 32-bit tags</dd> | |
5a738aea MS |
6714 | <dt>IPP_TAG_INTEGER </dt> |
6715 | <dd class="description">Integer value</dd> | |
6716 | <dt>IPP_TAG_JOB </dt> | |
6717 | <dd class="description">Job group</dd> | |
6718 | <dt>IPP_TAG_KEYWORD </dt> | |
6719 | <dd class="description">Keyword value</dd> | |
6720 | <dt>IPP_TAG_LANGUAGE </dt> | |
6721 | <dd class="description">Language value</dd> | |
5a738aea MS |
6722 | <dt>IPP_TAG_MEMBERNAME </dt> |
6723 | <dd class="description">Collection member name value</dd> | |
6724 | <dt>IPP_TAG_MIMETYPE </dt> | |
6725 | <dd class="description">MIME media type value</dd> | |
6726 | <dt>IPP_TAG_NAME </dt> | |
6727 | <dd class="description">Name value</dd> | |
6728 | <dt>IPP_TAG_NAMELANG </dt> | |
6729 | <dd class="description">Name-with-language value</dd> | |
6730 | <dt>IPP_TAG_NOTSETTABLE </dt> | |
6731 | <dd class="description">Not-settable value</dd> | |
6732 | <dt>IPP_TAG_NOVALUE </dt> | |
6733 | <dd class="description">No-value value</dd> | |
6734 | <dt>IPP_TAG_OPERATION </dt> | |
6735 | <dd class="description">Operation group</dd> | |
6736 | <dt>IPP_TAG_PRINTER </dt> | |
6737 | <dd class="description">Printer group</dd> | |
6738 | <dt>IPP_TAG_RANGE </dt> | |
6739 | <dd class="description">Range value</dd> | |
6740 | <dt>IPP_TAG_RESOLUTION </dt> | |
6741 | <dd class="description">Resolution value</dd> | |
6742 | <dt>IPP_TAG_STRING </dt> | |
6743 | <dd class="description">Octet string value</dd> | |
6744 | <dt>IPP_TAG_SUBSCRIPTION </dt> | |
6745 | <dd class="description">Subscription group</dd> | |
6746 | <dt>IPP_TAG_TEXT </dt> | |
6747 | <dd class="description">Text value</dd> | |
6748 | <dt>IPP_TAG_TEXTLANG </dt> | |
6749 | <dd class="description">Text-with-language value</dd> | |
6750 | <dt>IPP_TAG_UNKNOWN </dt> | |
6751 | <dd class="description">Unknown value</dd> | |
6752 | <dt>IPP_TAG_UNSUPPORTED_GROUP </dt> | |
6753 | <dd class="description">Unsupported attributes group</dd> | |
6754 | <dt>IPP_TAG_UNSUPPORTED_VALUE </dt> | |
6755 | <dd class="description">Unsupported value</dd> | |
6756 | <dt>IPP_TAG_URI </dt> | |
6757 | <dd class="description">URI value</dd> | |
6758 | <dt>IPP_TAG_URISCHEME </dt> | |
6759 | <dd class="description">URI scheme value</dd> | |
6760 | <dt>IPP_TAG_ZERO </dt> | |
6761 | <dd class="description">Zero tag - used for separators</dd> | |
6762 | </dl> | |
6763 | </div> | |
ef416fc2 | 6764 | </body> |
6765 | </html> |