1 <!DOCTYPE HTML PUBLIC
"-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
3 <!-- SECTION: Programming -->
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">
8 <meta name=
"creator" content=
"Mini-XML v2.7">
9 <style type=
"text/css"><!--
11 font-family: lucida grande, geneva, helvetica, arial, sans-serif;
14 H1, H2, H3, H4, H5, H6, P, TD, TH {
15 font-family: lucida grande, geneva, helvetica, arial, sans-serif;
19 font-family: monaco, courier, monospace;
24 font-family: monaco, courier, monospace;
28 border: dotted thin #7f7f7f;
44 border: dotted thin #999999;
49 PRE.command EM, PRE.example EM {
50 font-family: lucida grande, geneva, helvetica, arial, sans-serif;
54 font-family: monaco, courier, monospace;
65 border: solid thin #999999;
76 -moz-border-radius: 10px;
81 text-decoration: none;
84 A:link:hover, A:visited:hover, A:active {
85 text-decoration: underline;
92 TR.data, TD.data, TR.data TD {
95 border-bottom: solid 1pt #999999;
99 border-bottom: solid 1pt #999999;
106 border: solid thin #999999;
107 border-collapse: collapse;
123 border: solid thin #cccccc;
130 border-bottom: solid thin #999999;
139 caption-side: bottom;
163 border: thin solid black;
171 H2 SPAN.info, H3 SPAN.info, H4 SPAN.info {
180 border-bottom: solid 2pt #000000;
183 DIV.indent, TABLE.indent {
191 border-collapse: collapse;
194 TABLE.indent TD, TABLE.indent TH {
199 border-collapse: collapse;
207 border-bottom: solid thin #cccccc;
212 vertical-align: bottom;
221 border-bottom: solid thin #eeeeee;
226 TABLE.list TR:nth-child(even) {
230 TABLE.list TR:nth-child(odd) {
249 font-family: monaco, courier, monospace;
253 border: solid thin #999999;
254 border-collapse: collapse;
259 DIV.summary TABLE TD, DIV.summary TABLE TH {
260 border: solid thin #999999;
266 DIV.summary TABLE THEAD TH {
270 /* API documentation styles... */
277 div.body h3, div.body h4, div.body h5 {
278 margin-bottom: 0.5em;
281 .class, .enumeration, .function, .struct, .typedef, .union {
282 border-bottom: solid thin #999999;
289 code, p.code, pre, ul.code li {
290 font-family: monaco, courier, monospace;
293 ul.code, ul.contents, ul.subcontents {
294 list-style-type: none;
304 ul.contents li ul.code, ul.contents li ul.subcontents {
317 margin-bottom: 0.5em;
320 /* This is just for the HTML files generated with the framedhelp target */
323 border: solid thin black;
332 div.contents ul.contents {
335 div.contents ul.subcontents li {
346 HTTP and IPP API header for CUPS.
348 Copyright 2007-2011 by Apple Inc.
349 Copyright 1997-2006 by Easy Software Products, all rights reserved.
351 These coded instructions, statements, and computer programs are the
352 property of Apple Inc. and are protected by Federal copyright
353 law. Distribution and use rights are outlined in the file "LICENSE.txt"
354 which should have been included with this file. If this file is
355 file is missing or damaged, see the license at "http://www.cups.org/".
358 <h1 class='title'
>HTTP and IPP APIs
</h1>
360 <div class='summary'
><table summary='General Information'
>
374 <td>Programming:
<a href='api-overview.html'
>Introduction to CUPS Programming
</a><br>
375 Programming:
<a href='api-cups.html'
>CUPS API
</a><br>
376 References:
<a href='spec-ipp.html'
>CUPS Implementation of IPP
</a></td>
380 <h2 class=
"title">Contents
</h2>
381 <ul class=
"contents">
382 <li><a href=
"#OVERVIEW">Overview
</a><ul class=
"subcontents">
383 <li><a href=
"#CREATING_URI_STRINGS">Creating URI Strings
</a></li>
384 <li><a href=
"#SENDING_REQUESTS_WITH_FILES">Sending Requests with Files
</a></li>
385 <li><a href=
"#ASYNCHRONOUS_REQUEST_PROCESSING">Asynchronous Request Processing
</a></li>
387 <li><a href=
"#FUNCTIONS">Functions
</a><ul class=
"code">
388 <li><a href=
"#cupsDoAuthentication" title=
"Authenticate a request.">cupsDoAuthentication
</a></li>
389 <li><a href=
"#cupsDoFileRequest" title=
"Do an IPP request with a file.">cupsDoFileRequest
</a></li>
390 <li><a href=
"#cupsDoIORequest" title=
"Do an IPP request with file descriptors.">cupsDoIORequest
</a></li>
391 <li><a href=
"#cupsDoRequest" title=
"Do an IPP request.">cupsDoRequest
</a></li>
392 <li><a href=
"#cupsEncodeOptions" title=
"Encode printer options into IPP attributes.">cupsEncodeOptions
</a></li>
393 <li><a href=
"#cupsEncodeOptions2" title=
"Encode printer options into IPP attributes for a group.">cupsEncodeOptions2
</a></li>
394 <li><a href=
"#cupsGetDevices" title=
"Get available printer devices.">cupsGetDevices
</a></li>
395 <li><a href=
"#cupsGetFd" title=
"Get a file from the server.">cupsGetFd
</a></li>
396 <li><a href=
"#cupsGetFile" title=
"Get a file from the server.">cupsGetFile
</a></li>
397 <li><a href=
"#cupsGetResponse" title=
"Get a response to an IPP request.">cupsGetResponse
</a></li>
398 <li><a href=
"#cupsLastError" title=
"Return the last IPP status code.">cupsLastError
</a></li>
399 <li><a href=
"#cupsLastErrorString" title=
"Return the last IPP status-message.">cupsLastErrorString
</a></li>
400 <li><a href=
"#cupsPutFd" title=
"Put a file on the server.">cupsPutFd
</a></li>
401 <li><a href=
"#cupsPutFile" title=
"Put a file on the server.">cupsPutFile
</a></li>
402 <li><a href=
"#cupsReadResponseData" title=
"Read additional data after the IPP response.">cupsReadResponseData
</a></li>
403 <li><a href=
"#cupsSendRequest" title=
"Send an IPP request.">cupsSendRequest
</a></li>
404 <li><a href=
"#cupsWriteRequestData" title=
"Write additional data after an IPP request.">cupsWriteRequestData
</a></li>
405 <li><a href=
"#httpAddCredential" title=
"Allocates and adds a single credential to an array.">httpAddCredential
</a></li>
406 <li><a href=
"#httpAddrAny" title=
"Check for the "any" address.">httpAddrAny
</a></li>
407 <li><a href=
"#httpAddrEqual" title=
"Compare two addresses.">httpAddrEqual
</a></li>
408 <li><a href=
"#httpAddrLength" title=
"Return the length of the address in bytes.">httpAddrLength
</a></li>
409 <li><a href=
"#httpAddrLocalhost" title=
"Check for the local loopback address.">httpAddrLocalhost
</a></li>
410 <li><a href=
"#httpAddrLookup" title=
"Lookup the hostname associated with the address.">httpAddrLookup
</a></li>
411 <li><a href=
"#httpAddrString" title=
"Convert an address to a numeric string.">httpAddrString
</a></li>
412 <li><a href=
"#httpAssembleURI" title=
"Assemble a uniform resource identifier from its
413 components.">httpAssembleURI
</a></li>
414 <li><a href=
"#httpAssembleURIf" title=
"Assemble a uniform resource identifier from its
415 components with a formatted resource.">httpAssembleURIf
</a></li>
416 <li><a href=
"#httpBlocking" title=
"Set blocking/non-blocking behavior on a connection.">httpBlocking
</a></li>
417 <li><a href=
"#httpCheck" title=
"Check to see if there is a pending response from the server.">httpCheck
</a></li>
418 <li><a href=
"#httpClearCookie" title=
"Clear the cookie value(s).">httpClearCookie
</a></li>
419 <li><a href=
"#httpClearFields" title=
"Clear HTTP request fields.">httpClearFields
</a></li>
420 <li><a href=
"#httpClose" title=
"Close an HTTP connection.">httpClose
</a></li>
421 <li><a href=
"#httpConnect" title=
"Connect to a HTTP server.">httpConnect
</a></li>
422 <li><a href=
"#httpConnectEncrypt" title=
"Connect to a HTTP server using encryption.">httpConnectEncrypt
</a></li>
423 <li><a href=
"#httpCopyCredentials" title=
"Copy the credentials associated with an encrypted
424 connection.">httpCopyCredentials
</a></li>
425 <li><a href=
"#httpDecode64" title=
"Base64-decode a string.">httpDecode64
</a></li>
426 <li><a href=
"#httpDecode64_2" title=
"Base64-decode a string.">httpDecode64_2
</a></li>
427 <li><a href=
"#httpDelete" title=
"Send a DELETE request to the server.">httpDelete
</a></li>
428 <li><a href=
"#httpEncode64" title=
"Base64-encode a string.">httpEncode64
</a></li>
429 <li><a href=
"#httpEncode64_2" title=
"Base64-encode a string.">httpEncode64_2
</a></li>
430 <li><a href=
"#httpEncryption" title=
"Set the required encryption on the link.">httpEncryption
</a></li>
431 <li><a href=
"#httpError" title=
"Get the last error on a connection.">httpError
</a></li>
432 <li><a href=
"#httpFlush" title=
"Flush data from a HTTP connection.">httpFlush
</a></li>
433 <li><a href=
"#httpFlushWrite" title=
"Flush data in write buffer.">httpFlushWrite
</a></li>
434 <li><a href=
"#httpFreeCredentials" title=
"Free an array of credentials.">httpFreeCredentials
</a></li>
435 <li><a href=
"#httpGet" title=
"Send a GET request to the server.">httpGet
</a></li>
436 <li><a href=
"#httpGetAuthString" title=
"Get the current authorization string.">httpGetAuthString
</a></li>
437 <li><a href=
"#httpGetBlocking" title=
"Get the blocking/non-block state of a connection.">httpGetBlocking
</a></li>
438 <li><a href=
"#httpGetCookie" title=
"Get any cookie data from the response.">httpGetCookie
</a></li>
439 <li><a href=
"#httpGetDateString" title=
"Get a formatted date/time string from a time value.">httpGetDateString
</a></li>
440 <li><a href=
"#httpGetDateString2" title=
"Get a formatted date/time string from a time value.">httpGetDateString2
</a></li>
441 <li><a href=
"#httpGetDateTime" title=
"Get a time value from a formatted date/time string.">httpGetDateTime
</a></li>
442 <li><a href=
"#httpGetFd" title=
"Get the file descriptor associated with a connection.">httpGetFd
</a></li>
443 <li><a href=
"#httpGetField" title=
"Get a field value from a request/response.">httpGetField
</a></li>
444 <li><a href=
"#httpGetHostByName" title=
"Lookup a hostname or IPv4 address, and return
445 address records for the specified name.">httpGetHostByName
</a></li>
446 <li><a href=
"#httpGetHostname" title=
"Get the FQDN for the connection or local system.">httpGetHostname
</a></li>
447 <li><a href=
"#httpGetLength" title=
"Get the amount of data remaining from the
448 content-length or transfer-encoding fields.">httpGetLength
</a></li>
449 <li><a href=
"#httpGetLength2" title=
"Get the amount of data remaining from the
450 content-length or transfer-encoding fields.">httpGetLength2
</a></li>
451 <li><a href=
"#httpGetStatus" title=
"Get the status of the last HTTP request.">httpGetStatus
</a></li>
452 <li><a href=
"#httpGetSubField" title=
"Get a sub-field value.">httpGetSubField
</a></li>
453 <li><a href=
"#httpGetSubField2" title=
"Get a sub-field value.">httpGetSubField2
</a></li>
454 <li><a href=
"#httpGets" title=
"Get a line of text from a HTTP connection.">httpGets
</a></li>
455 <li><a href=
"#httpHead" title=
"Send a HEAD request to the server.">httpHead
</a></li>
456 <li><a href=
"#httpInitialize" title=
"Initialize the HTTP interface library and set the
457 default HTTP proxy (if any).">httpInitialize
</a></li>
458 <li><a href=
"#httpMD5" title=
"Compute the MD5 sum of the username:group:password.">httpMD5
</a></li>
459 <li><a href=
"#httpMD5Final" title=
"Combine the MD5 sum of the username, group, and password
460 with the server-supplied nonce value, method, and
461 request-uri.">httpMD5Final
</a></li>
462 <li><a href=
"#httpMD5String" title=
"Convert an MD5 sum to a character string.">httpMD5String
</a></li>
463 <li><a href=
"#httpOptions" title=
"Send an OPTIONS request to the server.">httpOptions
</a></li>
464 <li><a href=
"#httpPost" title=
"Send a POST request to the server.">httpPost
</a></li>
465 <li><a href=
"#httpPut" title=
"Send a PUT request to the server.">httpPut
</a></li>
466 <li><a href=
"#httpRead" title=
"Read data from a HTTP connection.">httpRead
</a></li>
467 <li><a href=
"#httpRead2" title=
"Read data from a HTTP connection.">httpRead2
</a></li>
468 <li><a href=
"#httpReconnect" title=
"Reconnect to a HTTP server.">httpReconnect
</a></li>
469 <li><a href=
"#httpSeparate" title=
"Separate a Universal Resource Identifier into its
470 components.">httpSeparate
</a></li>
471 <li><a href=
"#httpSeparate2" title=
"Separate a Universal Resource Identifier into its
472 components.">httpSeparate2
</a></li>
473 <li><a href=
"#httpSeparateURI" title=
"Separate a Universal Resource Identifier into its
474 components.">httpSeparateURI
</a></li>
475 <li><a href=
"#httpSetAuthString" title=
"Set the current authorization string.">httpSetAuthString
</a></li>
476 <li><a href=
"#httpSetCookie" title=
"Set the cookie value(s).">httpSetCookie
</a></li>
477 <li><a href=
"#httpSetCredentials" title=
"Set the credentials associated with an encrypted
478 connection.">httpSetCredentials
</a></li>
479 <li><a href=
"#httpSetExpect" title=
"Set the Expect: header in a request.">httpSetExpect
</a></li>
480 <li><a href=
"#httpSetField" title=
"Set the value of an HTTP header.">httpSetField
</a></li>
481 <li><a href=
"#httpSetLength" title=
"Set the content-length and content-encoding.">httpSetLength
</a></li>
482 <li><a href=
"#httpStatus" title=
"Return a short string describing a HTTP status code.">httpStatus
</a></li>
483 <li><a href=
"#httpTrace" title=
"Send an TRACE request to the server.">httpTrace
</a></li>
484 <li><a href=
"#httpUpdate" title=
"Update the current HTTP state for incoming data.">httpUpdate
</a></li>
485 <li><a href=
"#httpWait" title=
"Wait for data available on a connection.">httpWait
</a></li>
486 <li><a href=
"#httpWrite" title=
"Write data to a HTTP connection.">httpWrite
</a></li>
487 <li><a href=
"#httpWrite2" title=
"Write data to a HTTP connection.">httpWrite2
</a></li>
488 <li><a href=
"#ippAddBoolean" title=
"Add a boolean attribute to an IPP message.">ippAddBoolean
</a></li>
489 <li><a href=
"#ippAddBooleans" title=
"Add an array of boolean values.">ippAddBooleans
</a></li>
490 <li><a href=
"#ippAddCollection" title=
"Add a collection value.">ippAddCollection
</a></li>
491 <li><a href=
"#ippAddCollections" title=
"Add an array of collection values.">ippAddCollections
</a></li>
492 <li><a href=
"#ippAddDate" title=
"Add a date attribute to an IPP message.">ippAddDate
</a></li>
493 <li><a href=
"#ippAddInteger" title=
"Add a integer attribute to an IPP message.">ippAddInteger
</a></li>
494 <li><a href=
"#ippAddIntegers" title=
"Add an array of integer values.">ippAddIntegers
</a></li>
495 <li><a href=
"#ippAddOctetString" title=
"Add an octetString value to an IPP message.">ippAddOctetString
</a></li>
496 <li><a href=
"#ippAddRange" title=
"Add a range of values to an IPP message.">ippAddRange
</a></li>
497 <li><a href=
"#ippAddRanges" title=
"Add ranges of values to an IPP message.">ippAddRanges
</a></li>
498 <li><a href=
"#ippAddResolution" title=
"Add a resolution value to an IPP message.">ippAddResolution
</a></li>
499 <li><a href=
"#ippAddResolutions" title=
"Add resolution values to an IPP message.">ippAddResolutions
</a></li>
500 <li><a href=
"#ippAddSeparator" title=
"Add a group separator to an IPP message.">ippAddSeparator
</a></li>
501 <li><a href=
"#ippAddString" title=
"Add a language-encoded string to an IPP message.">ippAddString
</a></li>
502 <li><a href=
"#ippAddStrings" title=
"Add language-encoded strings to an IPP message.">ippAddStrings
</a></li>
503 <li><a href=
"#ippDateToTime" title=
"Convert from RFC 1903 Date/Time format to UNIX time
504 in seconds.">ippDateToTime
</a></li>
505 <li><a href=
"#ippDelete" title=
"Delete an IPP message.">ippDelete
</a></li>
506 <li><a href=
"#ippDeleteAttribute" title=
"Delete a single attribute in an IPP message.">ippDeleteAttribute
</a></li>
507 <li><a href=
"#ippErrorString" title=
"Return a name for the given status code.">ippErrorString
</a></li>
508 <li><a href=
"#ippErrorValue" title=
"Return a status code for the given name.">ippErrorValue
</a></li>
509 <li><a href=
"#ippFindAttribute" title=
"Find a named attribute in a request...">ippFindAttribute
</a></li>
510 <li><a href=
"#ippFindNextAttribute" title=
"Find the next named attribute in a request...">ippFindNextAttribute
</a></li>
511 <li><a href=
"#ippLength" title=
"Compute the length of an IPP message.">ippLength
</a></li>
512 <li><a href=
"#ippNew" title=
"Allocate a new IPP message.">ippNew
</a></li>
513 <li><a href=
"#ippNewRequest" title=
"Allocate a new IPP request message.">ippNewRequest
</a></li>
514 <li><a href=
"#ippOpString" title=
"Return a name for the given operation id.">ippOpString
</a></li>
515 <li><a href=
"#ippOpValue" title=
"Return an operation id for the given name.">ippOpValue
</a></li>
516 <li><a href=
"#ippPort" title=
"Return the default IPP port number.">ippPort
</a></li>
517 <li><a href=
"#ippRead" title=
"Read data for an IPP message from a HTTP connection.">ippRead
</a></li>
518 <li><a href=
"#ippReadFile" title=
"Read data for an IPP message from a file.">ippReadFile
</a></li>
519 <li><a href=
"#ippReadIO" title=
"Read data for an IPP message.">ippReadIO
</a></li>
520 <li><a href=
"#ippSetPort" title=
"Set the default port number.">ippSetPort
</a></li>
521 <li><a href=
"#ippTagString" title=
"Return the tag name corresponding to a tag value.">ippTagString
</a></li>
522 <li><a href=
"#ippTagValue" title=
"Return the tag value corresponding to a tag name.">ippTagValue
</a></li>
523 <li><a href=
"#ippTimeToDate" title=
"Convert from UNIX time to RFC 1903 format.">ippTimeToDate
</a></li>
524 <li><a href=
"#ippWrite" title=
"Write data for an IPP message to a HTTP connection.">ippWrite
</a></li>
525 <li><a href=
"#ippWriteFile" title=
"Write data for an IPP message to a file.">ippWriteFile
</a></li>
526 <li><a href=
"#ippWriteIO" title=
"Write data for an IPP message.">ippWriteIO
</a></li>
528 <li><a href=
"#TYPES">Data Types
</a><ul class=
"code">
529 <li><a href=
"#gss_auth_identity_desc" title=
"Local functions...">gss_auth_identity_desc
</a></li>
530 <li><a href=
"#http_addr_t" title=
"Socket address union, which
531 makes using IPv6 and other
532 address types easier and
533 more portable. ">http_addr_t
</a></li>
534 <li><a href=
"#http_addrlist_t" title=
"Socket address list, which is
535 used to enumerate all of the
536 addresses that are associated
537 with a hostname. ">http_addrlist_t
</a></li>
538 <li><a href=
"#http_auth_t" title=
"HTTP authentication types">http_auth_t
</a></li>
539 <li><a href=
"#http_credential_t" title=
"Credential data ">http_credential_t
</a></li>
540 <li><a href=
"#http_encoding_t" title=
"HTTP transfer encoding values">http_encoding_t
</a></li>
541 <li><a href=
"#http_encryption_t" title=
"HTTP encryption values">http_encryption_t
</a></li>
542 <li><a href=
"#http_field_t" title=
"HTTP field names">http_field_t
</a></li>
543 <li><a href=
"#http_keepalive_t" title=
"HTTP keep-alive values">http_keepalive_t
</a></li>
544 <li><a href=
"#http_state_t" title=
"HTTP state values; states
545 are server-oriented...">http_state_t
</a></li>
546 <li><a href=
"#http_status_t" title=
"HTTP status codes">http_status_t
</a></li>
547 <li><a href=
"#http_t" title=
"HTTP connection type">http_t
</a></li>
548 <li><a href=
"#http_uri_coding_t" title=
"URI en/decode flags">http_uri_coding_t
</a></li>
549 <li><a href=
"#http_uri_status_t" title=
"URI separation status ">http_uri_status_t
</a></li>
550 <li><a href=
"#http_version_t" title=
"HTTP version numbers">http_version_t
</a></li>
551 <li><a href=
"#ipp_attribute_t" title=
"Attribute">ipp_attribute_t
</a></li>
552 <li><a href=
"#ipp_finish_t" title=
"Finishings">ipp_finish_t
</a></li>
553 <li><a href=
"#ipp_iocb_t" title=
"IPP IO Callback Function ">ipp_iocb_t
</a></li>
554 <li><a href=
"#ipp_jstate_t" title=
"Job states">ipp_jstate_t
</a></li>
555 <li><a href=
"#ipp_op_t" title=
"IPP operations">ipp_op_t
</a></li>
556 <li><a href=
"#ipp_orient_t" title=
"Orientation values">ipp_orient_t
</a></li>
557 <li><a href=
"#ipp_pstate_t" title=
"Printer states">ipp_pstate_t
</a></li>
558 <li><a href=
"#ipp_quality_t" title=
"Qualities">ipp_quality_t
</a></li>
559 <li><a href=
"#ipp_request_t" title=
"Request Header">ipp_request_t
</a></li>
560 <li><a href=
"#ipp_res_t" title=
"Resolution units">ipp_res_t
</a></li>
561 <li><a href=
"#ipp_state_t" title=
"IPP states">ipp_state_t
</a></li>
562 <li><a href=
"#ipp_t" title=
"Attribute Value">ipp_t
</a></li>
563 <li><a href=
"#ipp_uchar_t" title=
"IPP status codes">ipp_uchar_t
</a></li>
564 <li><a href=
"#ipp_tag_t" title=
"Format tags for attributes">ipp_tag_t
</a></li>
565 <li><a href=
"#ipp_value_t" title=
"Attribute Value">ipp_value_t
</a></li>
567 <li><a href=
"#STRUCTURES">Structures
</a><ul class=
"code">
568 <li><a href=
"#gss_auth_identity" title=
"Local functions...">gss_auth_identity
</a></li>
569 <li><a href=
"#http_addrlist_s" title=
"Socket address list, which is
570 used to enumerate all of the
571 addresses that are associated
572 with a hostname. ">http_addrlist_s
</a></li>
573 <li><a href=
"#http_credential_s" title=
"Credential data ">http_credential_s
</a></li>
574 <li><a href=
"#ipp_attribute_s" title=
"Attribute">ipp_attribute_s
</a></li>
575 <li><a href=
"#ipp_s" title=
"IPP Request/Response/Notification">ipp_s
</a></li>
577 <li><a href=
"#UNIONS">Unions
</a><ul class=
"code">
578 <li><a href=
"#ipp_request_u" title=
"Request Header">ipp_request_u
</a></li>
579 <li><a href=
"#ipp_value_u" title=
"Attribute Value">ipp_value_u
</a></li>
581 <li><a href=
"#ENUMERATIONS">Constants
</a><ul class=
"code">
582 <li><a href=
"#http_auth_e" title=
"HTTP authentication types">http_auth_e
</a></li>
583 <li><a href=
"#http_encoding_e" title=
"HTTP transfer encoding values">http_encoding_e
</a></li>
584 <li><a href=
"#http_encryption_e" title=
"HTTP encryption values">http_encryption_e
</a></li>
585 <li><a href=
"#http_field_e" title=
"HTTP field names">http_field_e
</a></li>
586 <li><a href=
"#http_keepalive_e" title=
"HTTP keep-alive values">http_keepalive_e
</a></li>
587 <li><a href=
"#http_state_e" title=
"HTTP state values; states
588 are server-oriented...">http_state_e
</a></li>
589 <li><a href=
"#http_status_e" title=
"HTTP status codes">http_status_e
</a></li>
590 <li><a href=
"#http_uri_coding_e" title=
"URI en/decode flags">http_uri_coding_e
</a></li>
591 <li><a href=
"#http_uri_status_e" title=
"URI separation status ">http_uri_status_e
</a></li>
592 <li><a href=
"#http_version_e" title=
"HTTP version numbers">http_version_e
</a></li>
593 <li><a href=
"#ipp_finish_e" title=
"Finishings">ipp_finish_e
</a></li>
594 <li><a href=
"#ipp_jstate_e" title=
"Job states">ipp_jstate_e
</a></li>
595 <li><a href=
"#ipp_op_e" title=
"IPP operations">ipp_op_e
</a></li>
596 <li><a href=
"#ipp_orient_e" title=
"Orientation values">ipp_orient_e
</a></li>
597 <li><a href=
"#ipp_pstate_e" title=
"Printer states">ipp_pstate_e
</a></li>
598 <li><a href=
"#ipp_quality_e" title=
"Qualities">ipp_quality_e
</a></li>
599 <li><a href=
"#ipp_res_e" title=
"Resolution units">ipp_res_e
</a></li>
600 <li><a href=
"#ipp_state_e" title=
"IPP states">ipp_state_e
</a></li>
601 <li><a href=
"#ipp_status_e" title=
"IPP status codes">ipp_status_e
</a></li>
602 <li><a href=
"#ipp_tag_e" title=
"Format tags for attributes">ipp_tag_e
</a></li>
608 HTTP and IPP API introduction for CUPS.
610 Copyright 2007-2011 by Apple Inc.
611 Copyright 1997-2006 by Easy Software Products, all rights reserved.
613 These coded instructions, statements, and computer programs are the
614 property of Apple Inc. and are protected by Federal copyright
615 law. Distribution and use rights are outlined in the file "LICENSE.txt"
616 which should have been included with this file. If this file is
617 file is missing or damaged, see the license at "http://www.cups.org/".
620 <h2 class='title'
><a name='OVERVIEW'
>Overview
</a></h2>
622 <p>The CUPS HTTP and IPP APIs provide low-level access to the HTTP and IPP
623 protocols and CUPS scheduler. They are typically used by monitoring and
624 administration programs to perform specific functions not supported by the
625 high-level CUPS API functions.
</p>
627 <p>The HTTP APIs use an opaque structure called
628 <a href='#http_t'
><code>http_t
</code></a> to manage connections to
629 a particular HTTP or IPP server. The
630 <a href='#httpConnectEncrypt'
><code>httpConnectEncrypt
</code></a> function is
631 used to create an instance of this structure for a particular server.
632 The constant
<code>CUPS_HTTP_DEFAULT
</code> can be used with all of the
633 <code>cups
</code> functions to refer to the default CUPS server - the functions
634 create a per-thread
<a href='#http_t'
><code>http_t
</code></a> as needed.
</p>
636 <p>The IPP APIs use two structures for requests (messages sent to the CUPS
637 scheduler) and responses (messages sent back to your application from the
638 scheduler). The
<a href='#ipp_t'
><code>ipp_t
</code></a> structure holds a
639 complete request or response and is allocated using the
640 <a href='#ippNew'
><code>ippNew
</code></a> or
641 <a href='#ippNewRequest'
><code>ippNewRequest
</code></a> functions and
642 freed using the
<a href='#ippDelete'
><code>ippDelete
</code></a> function.
</p>
644 <p>The second structure is called
645 <a href='#ipp_attribute_t'
><code>ipp_attribute_t
</code></a> and holds a
646 single IPP attribute which consists of a group tag (
<code>group_tag
</code>), a
647 value type tag (
<code>value_tag
</code>), the attribute name (
<code>name
</code>),
648 and
1 or more values (
<code>values[]
</code>). Attributes are added to an
649 <a href='#ipp_t'
><code>ipp_t
</code></a> structure using one of the
650 <code>ippAdd
</code> functions. For example, use
651 <a href='#ippAddString'
><code>ippAddString
</code></a> to add a
652 "requesting-user-name" string attribute to a request:
</p>
654 <pre class='example'
>
655 <a href='#ipp_t'
>ipp_t
</a> *request =
<a href='#ippNewRequest'
>ippNewRequest
</a>(IPP_GET_JOBS);
657 <a href='#ippAddString'
>ippAddString
</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME,
"requesting-user-name",
661 <p>Once you have created an IPP request, use the
<code>cups
</code>
662 functions to send the request to and read the response from the server.
663 For example, the
<a href='#cupsDoRequest'
><code>cupsDoRequest
</code></a>
664 function can be used for simple query operations that do not involve files:
</p>
666 <pre class='example'
>
667 #include
<cups/cups.h
>
670 <a href='#ipp_t'
>ipp_t
</a> *
<a name='get_jobs'
>get_jobs
</a>(void)
672 <a href='#ipp_t'
>ipp_t
</a> *request =
<a href='#ippNewRequest'
>ippNewRequest
</a>(IPP_GET_JOBS);
674 <a href='#ippAddString'
>ippAddString
</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME,
"requesting-user-name",
677 return (
<a href='#cupsDoRequest'
>cupsDoRequest
</a>(CUPS_HTTP_DEFAULT, request,
"/"));
681 <p>The
<a href='#cupsDoRequest'
><code>cupsDoRequest
</code></a> function frees
682 the request structure and returns an IPP response structure or NULL pointer if
683 the request could not be sent to the server. Once you have a response from
684 the server, you can either use the
685 <a href='#ippFindAttribute'
><code>ippFindAttribute
</code></a> and
686 <a href='#ippFindNextAttribute'
><code>ippFindNextAttribute
</code></a> functions
687 to find specific attributes, for example:
</p>
689 <pre class='example'
>
690 <a href='#ipp_t'
>ipp_t
</a> *response;
691 <a href='#ipp_attribute_t'
>ipp_attribute_t
</a> *attr;
693 attr =
<a href='#ippFindAttribute'
>ippFindAttribute
</a>(response,
"printer-state", IPP_TAG_ENUM);
696 <p>You can also walk the list of attributes with a simple
<code>for
</code> loop
699 <pre class='example'
>
700 <a href='#ipp_t'
>ipp_t
</a> *response;
701 <a href='#ipp_attribute_t'
>ipp_attribute_t
</a> *attr;
703 for (attr = response-
>attrs; attr != NULL; attr = attr-
>next)
704 if (attr-
>name == NULL)
705 puts(
"--SEPARATOR--");
710 <p>The
<code>for
</code> loop approach is normally used when collecting
711 attributes for multiple objects (jobs, printers, etc.) in a response. Attributes
712 with
<code>NULL
</code> names indicate a separator between the attributes of
713 each object. For example, the following code will list the jobs returned from
714 our previous
<a href='#get_jobs'
><code>get_jobs
</code></a> example code:
</p>
716 <pre class='example'
>
717 <a href='#ipp_t'
>ipp_t
</a> *response =
<a href='#get_jobs'
>get_jobs
</a>();
719 if (response != NULL)
721 <a href='#ipp_attribute_t'
>ipp_attribute_t
</a> *attr;
723 char *job_name = NULL;
724 char *job_originating_user_name = NULL;
726 puts(
"Job ID Owner Title");
727 puts(
"------ ---------------- ---------------------------------");
729 for (attr = response-
>attrs; attr != NULL; attr = attr-
>next)
731 /* Attributes without names are separators between jobs */
732 if (attr-
>name == NULL)
734 if (job_id
> 0 && job_name != NULL
&& job_originating_user_name != NULL)
735 printf(
"%5d %-16s %s\n", job_id, job_originating_user_name, job_name);
739 job_originating_user_name = NULL;
742 else if (!strcmp(attr-
>name,
"job-id")
&& attr-
>value_tag == IPP_TAG_INTEGER)
743 job_id = attr-
>values[
0].integer;
744 else if (!strcmp(attr-
>name,
"job-name")
&& attr-
>value_tag == IPP_TAG_NAME)
745 job_name = attr-
>values[
0].string.text;
746 else if (!strcmp(attr-
>name,
"job-originating-user-name")
&&
747 attr-
>value_tag == IPP_TAG_NAME)
748 job_originating_user_name = attr-
>values[
0].string.text;
751 if (job_id
> 0 && job_name != NULL
&& job_originating_user_name != NULL)
752 printf(
"%5d %-16s %s\n", job_id, job_originating_user_name, job_name);
756 <h3><a name='CREATING_URI_STRINGS'
>Creating URI Strings
</a></h3>
758 <p>To ensure proper encoding, the
759 <a href='#httpAssembleURIf'
><code>httpAssembleURIf
</code></a> function must be
760 used to format a
"printer-uri" string for all printer-based requests:
</p>
762 <pre class='example'
>
763 const char *name =
"Foo";
765 <a href='#ipp_t'
>ipp_t
</a> *request;
767 <a href='#httpAssembleURIf'
>httpAssembleURIf
</a>(HTTP_URI_CODING_ALL, uri, sizeof(uri),
"ipp", NULL, cupsServer(),
768 ippPort(),
"/printers/%s", name);
769 <a href='#ippAddString'
>ippAddString
</a>(request, IPP_TAG_OPERATION, IPP_TAG_URI,
"printer-uri", NULL, uri);
772 <h3><a name='SENDING_REQUESTS_WITH_FILES'
>Sending Requests with Files
</a></h3>
774 <p>The
<a href='#cupsDoFileRequest'
><code>cupsDoFileRequest
</code></a> and
775 <a href='#cupsDoIORequest'
><code>cupsDoIORequest
</code></a> functions are
776 used for requests involving files. The
777 <a href='#cupsDoFileRequest'
><code>cupsDoFileRequest
</code></a> function
778 attaches the named file to a request and is typically used when sending a print
779 file or changing a printer's PPD file:
</p>
781 <pre class='example'
>
782 const char *filename =
"/usr/share/cups/data/testprint.ps";
783 const char *name =
"Foo";
786 <a href='#ipp_t'
>ipp_t
</a> *request =
<a href='#ippNewRequest'
>ippNewRequest
</a>(IPP_PRINT_JOB);
787 <a href='#ipp_t'
>ipp_t
</a> *response;
789 /* Use httpAssembleURIf for the printer-uri string */
790 <a href='#httpAssembleURIf'
>httpAssembleURIf
</a>(HTTP_URI_CODING_ALL, uri, sizeof(uri),
"ipp", NULL, cupsServer(),
791 ippPort(),
"/printers/%s", name);
792 <a href='#ippAddString'
>ippAddString
</a>(request, IPP_TAG_OPERATION, IPP_TAG_URI,
"printer-uri", NULL, uri);
793 <a href='#ippAddString'
>ippAddString
</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME,
"requesting-user-name",
795 <a href='#ippAddString'
>ippAddString
</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME,
"job-name",
796 NULL,
"testprint.ps");
798 /* Use snprintf for the resource path */
799 snprintf(resource, sizeof(resource),
"/printers/%s", name);
801 response =
<a href='#cupsDoFileRequest'
>cupsDoFileRequest
</a>(CUPS_HTTP_DEFAULT, request, resource, filename);
804 <p>The
<a href='#cupsDoIORequest'
><code>cupsDoIORequest
</code></a> function
805 optionally attaches a file to the request and optionally saves a file in the
806 response from the server. It is used when using a pipe for the request
807 attachment or when using a request that returns a file, currently only
808 <code>CUPS_GET_DOCUMENT
</code> and
<code>CUPS_GET_PPD
</code>. For example,
809 the following code will download the PPD file for the sample HP LaserJet
812 <pre class='example'
>
815 <a href='#ipp_t'
>ipp_t
</a> *request =
<a href='#ippNewRequest'
>ippNewRequest
</a>(CUPS_GET_PPD);
816 <a href='#ipp_t'
>ipp_t
</a> *response;
818 <a href='#ippAddString'
>ippAddString
</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME,
"ppd-name",
819 NULL,
"laserjet.ppd");
821 tempfd = cupsTempFd(tempfile, sizeof(tempfile));
823 response =
<a href='#cupsDoIORequest'
>cupsDoIORequest
</a>(CUPS_HTTP_DEFAULT, request,
"/", -
1, tempfd);
826 <p>The example passes
<code>-
1</code> for the input file descriptor to specify
827 that no file is to be attached to the request. The PPD file attached to the
828 response is written to the temporary file descriptor we created using the
829 <code>cupsTempFd
</code> function.
</p>
831 <h3><a name='ASYNCHRONOUS_REQUEST_PROCESSING'
>Asynchronous Request Processing
</a></h3>
833 <p>The
<a href='#cupsSendRequest'
><code>cupsSendRequest
</code></a> and
834 <a href='#cupsGetResponse'
><code>cupsGetResponse
</code></a> support
835 asynchronous communications with the server. Unlike the other request
836 functions, the IPP request is not automatically freed, so remember to
837 free your request with the
<a href='#ippDelete'
><code>ippDelete
</code></a>
840 <p>File data is attached to the request using the
841 <a href='#cupsWriteRequestData'
><code>cupsWriteRequestData
</code></a>
842 function, while file data returned from the server is read using the
843 <a href='#cupsReadResponseData'
><code>cupsReadResponseData
</code></a>
844 function. We can rewrite the previous
<code>CUPS_GET_PPD
</code> example
845 to use the asynchronous functions quite easily:
</p>
847 <pre class='example'
>
850 <a href='#ipp_t'
>ipp_t
</a> *request =
<a href='#ippNewRequest'
>ippNewRequest
</a>(CUPS_GET_PPD);
851 <a href='#ipp_t'
>ipp_t
</a> *response;
853 <a href='#ippAddString'
>ippAddString
</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME,
"ppd-name",
854 NULL,
"laserjet.ppd");
856 tempfd = cupsTempFd(tempfile, sizeof(tempfile));
858 if (
<a href='#cupsSendRequest'
>cupsSendRequest
</a>(CUPS_HTTP_DEFAULT, request,
"/") == HTTP_CONTINUE)
860 response =
<a href='#cupsGetResponse'
>cupsGetResponse
</a>(CUPS_HTTP_DEFAULT,
"/");
862 if (response != NULL)
867 while ((bytes =
<a href='#cupsReadResponseData'
>cupsReadResponseData
</a>(CUPS_HTTP_DEFAULT, buffer, sizeof(buffer)))
> 0)
868 write(tempfd, buffer, bytes);
872 /* Free the request! */
873 <a href='#ippDelete'
>ippDelete
</a>(request);
876 <p>The
<a href='#cupsSendRequest'
><code>cupsSendRequest
</code></a> function
877 returns the initial HTTP request status, typically either
878 <code>HTTP_CONTINUE
</code> or
<code>HTTP_UNAUTHORIZED
</code>. The latter status
879 is returned when the request requires authentication of some sort. The
880 <a href='#cupsDoAuthentication'
><code>cupsDoAuthentication
</code></a> function
881 must be called when your see
<code>HTTP_UNAUTHORIZED
</code> and the request
882 re-sent. We can add authentication support to our example code by using a
883 <code>do ... while
</code> loop:
</p>
885 <pre class='example'
>
888 <a href='#ipp_t'
>ipp_t
</a> *request =
<a href='#ippNewRequest'
>ippNewRequest
</a>(CUPS_GET_PPD);
889 <a href='#ipp_t'
>ipp_t
</a> *response;
890 http_status_t status;
892 <a href='#ippAddString'
>ippAddString
</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME,
"ppd-name",
893 NULL,
"laserjet.ppd");
895 tempfd = cupsTempFd(tempfile, sizeof(tempfile));
897 /* Loop for authentication */
900 status =
<a href='#cupsSendRequest'
>cupsSendRequest
</a>(CUPS_HTTP_DEFAULT, request,
"/");
902 if (status == HTTP_UNAUTHORIZED)
904 /* Try to authenticate, break out of the loop if that fails */
905 if (
<a href='#cupsDoAuthentication'
>cupsDoAuthentication
</a>(CUPS_HTTP_DEFAULT,
"POST",
"/"))
909 while (status != HTTP_CONTINUE
&& status != HTTP_UNAUTHORIZED);
911 if (status == HTTP_CONTINUE)
913 response =
<a href='#cupsGetResponse'
>cupsGetResponse
</a>(CUPS_HTTP_DEFAULT,
"/");
915 if (response != NULL)
920 while ((bytes =
<a href='#cupsReadResponseData'
>cupsReadResponseData
</a>(CUPS_HTTP_DEFAULT, buffer, sizeof(buffer)))
> 0)
921 write(tempfd, buffer, bytes);
925 /* Free the request! */
926 <a href='#ippDelete'
>ippDelete
</a>(request);
928 <h2 class=
"title"><a name=
"FUNCTIONS">Functions
</a></h2>
929 <h3 class=
"function"><span class=
"info"> CUPS
1.1.20/Mac OS X
10.4 </span><a name=
"cupsDoAuthentication">cupsDoAuthentication
</a></h3>
930 <p class=
"description">Authenticate a request.
</p>
932 int cupsDoAuthentication (
<br>
933 <a href=
"#http_t">http_t
</a> *http,
<br>
934 const char *method,
<br>
935 const char *resource
<br>
937 <h4 class=
"parameters">Parameters
</h4>
940 <dd class=
"description">Connection to server or
<code>CUPS_HTTP_DEFAULT
</code></dd>
942 <dd class=
"description">Request method (
"GET
",
"POST
",
"PUT
")
</dd>
944 <dd class=
"description">Resource path
</dd>
946 <h4 class=
"returnvalue">Return Value
</h4>
947 <p class=
"description">0 on success, -
1 on error
</p>
948 <h4 class=
"discussion">Discussion
</h4>
949 <p class=
"discussion">This function should be called in response to a
<code>HTTP_UNAUTHORIZED
</code>
950 status, prior to resubmitting your request.
953 <h3 class=
"function"><a name=
"cupsDoFileRequest">cupsDoFileRequest
</a></h3>
954 <p class=
"description">Do an IPP request with a file.
</p>
956 <a href=
"#ipp_t">ipp_t
</a> *cupsDoFileRequest (
<br>
957 <a href=
"#http_t">http_t
</a> *http,
<br>
958 <a href=
"#ipp_t">ipp_t
</a> *request,
<br>
959 const char *resource,
<br>
960 const char *filename
<br>
962 <h4 class=
"parameters">Parameters
</h4>
965 <dd class=
"description">Connection to server or
<code>CUPS_HTTP_DEFAULT
</code></dd>
967 <dd class=
"description">IPP request
</dd>
969 <dd class=
"description">HTTP resource for POST
</dd>
971 <dd class=
"description">File to send or
<code>NULL
</code> for none
</dd>
973 <h4 class=
"returnvalue">Return Value
</h4>
974 <p class=
"description">Response data
</p>
975 <h4 class=
"discussion">Discussion
</h4>
976 <p class=
"discussion">This function sends the IPP request to the specified server, retrying
977 and authenticating as necessary. The request is freed with
<a href=
"#ippDelete"><code>ippDelete
</code></a>
978 after receiving a valid IPP response.
</p>
979 <h3 class=
"function"><span class=
"info"> CUPS
1.3/Mac OS X
10.5 </span><a name=
"cupsDoIORequest">cupsDoIORequest
</a></h3>
980 <p class=
"description">Do an IPP request with file descriptors.
</p>
982 <a href=
"#ipp_t">ipp_t
</a> *cupsDoIORequest (
<br>
983 <a href=
"#http_t">http_t
</a> *http,
<br>
984 <a href=
"#ipp_t">ipp_t
</a> *request,
<br>
985 const char *resource,
<br>
986 int infile,
<br>
987 int outfile
<br>
989 <h4 class=
"parameters">Parameters
</h4>
992 <dd class=
"description">Connection to server or
<code>CUPS_HTTP_DEFAULT
</code></dd>
994 <dd class=
"description">IPP request
</dd>
996 <dd class=
"description">HTTP resource for POST
</dd>
998 <dd class=
"description">File to read from or -
1 for none
</dd>
1000 <dd class=
"description">File to write to or -
1 for none
</dd>
1002 <h4 class=
"returnvalue">Return Value
</h4>
1003 <p class=
"description">Response data
</p>
1004 <h4 class=
"discussion">Discussion
</h4>
1005 <p class=
"discussion">This function sends the IPP request to the specified server, retrying
1006 and authenticating as necessary. The request is freed with ippDelete()
1007 after receiving a valid IPP response.
<br>
1009 If
"infile
" is a valid file descriptor, cupsDoIORequest() copies
1010 all of the data from the file after the IPP request message.
<br>
1012 If
"outfile
" is a valid file descriptor, cupsDoIORequest() copies
1013 all of the data after the IPP response message to the file.
1016 <h3 class=
"function"><a name=
"cupsDoRequest">cupsDoRequest
</a></h3>
1017 <p class=
"description">Do an IPP request.
</p>
1019 <a href=
"#ipp_t">ipp_t
</a> *cupsDoRequest (
<br>
1020 <a href=
"#http_t">http_t
</a> *http,
<br>
1021 <a href=
"#ipp_t">ipp_t
</a> *request,
<br>
1022 const char *resource
<br>
1024 <h4 class=
"parameters">Parameters
</h4>
1027 <dd class=
"description">Connection to server or
<code>CUPS_HTTP_DEFAULT
</code></dd>
1029 <dd class=
"description">IPP request
</dd>
1031 <dd class=
"description">HTTP resource for POST
</dd>
1033 <h4 class=
"returnvalue">Return Value
</h4>
1034 <p class=
"description">Response data
</p>
1035 <h4 class=
"discussion">Discussion
</h4>
1036 <p class=
"discussion">This function sends the IPP request to the specified server, retrying
1037 and authenticating as necessary. The request is freed with ippDelete()
1038 after receiving a valid IPP response.
</p>
1039 <h3 class=
"function"><a name=
"cupsEncodeOptions">cupsEncodeOptions
</a></h3>
1040 <p class=
"description">Encode printer options into IPP attributes.
</p>
1042 void cupsEncodeOptions (
<br>
1043 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
1044 int num_options,
<br>
1045 cups_option_t *options
<br>
1047 <h4 class=
"parameters">Parameters
</h4>
1050 <dd class=
"description">Request to add to
</dd>
1051 <dt>num_options
</dt>
1052 <dd class=
"description">Number of options
</dd>
1054 <dd class=
"description">Options
</dd>
1056 <h4 class=
"discussion">Discussion
</h4>
1057 <p class=
"discussion">This function adds operation, job, and then subscription attributes,
1058 in that order. Use the cupsEncodeOptions2() function to add attributes
1059 for a single group.
</p>
1060 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"cupsEncodeOptions2">cupsEncodeOptions2
</a></h3>
1061 <p class=
"description">Encode printer options into IPP attributes for a group.
</p>
1063 void cupsEncodeOptions2 (
<br>
1064 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
1065 int num_options,
<br>
1066 cups_option_t *options,
<br>
1067 <a href=
"#ipp_tag_t">ipp_tag_t
</a> group_tag
<br>
1069 <h4 class=
"parameters">Parameters
</h4>
1072 <dd class=
"description">Request to add to
</dd>
1073 <dt>num_options
</dt>
1074 <dd class=
"description">Number of options
</dd>
1076 <dd class=
"description">Options
</dd>
1078 <dd class=
"description">Group to encode
</dd>
1080 <h4 class=
"discussion">Discussion
</h4>
1081 <p class=
"discussion">This function only adds attributes for a single group. Call this
1082 function multiple times for each group, or use cupsEncodeOptions()
1083 to add the standard groups.
1086 <h3 class=
"function"><span class=
"info"> CUPS
1.4/Mac OS X
10.6 </span><a name=
"cupsGetDevices">cupsGetDevices
</a></h3>
1087 <p class=
"description">Get available printer devices.
</p>
1089 ipp_status_t cupsGetDevices (
<br>
1090 <a href=
"#http_t">http_t
</a> *http,
<br>
1091 int timeout,
<br>
1092 const char *include_schemes,
<br>
1093 const char *exclude_schemes,
<br>
1094 cups_device_cb_t callback,
<br>
1095 void *user_data
<br>
1097 <h4 class=
"parameters">Parameters
</h4>
1100 <dd class=
"description">Connection to server or
<code>CUPS_HTTP_DEFAULT
</code></dd>
1102 <dd class=
"description">Timeout in seconds or
<code>CUPS_TIMEOUT_DEFAULT
</code></dd>
1103 <dt>include_schemes
</dt>
1104 <dd class=
"description">Comma-separated URI schemes to include or
<code>CUPS_INCLUDE_ALL
</code></dd>
1105 <dt>exclude_schemes
</dt>
1106 <dd class=
"description">Comma-separated URI schemes to exclude or
<code>CUPS_EXCLUDE_NONE
</code></dd>
1108 <dd class=
"description">Callback function
</dd>
1110 <dd class=
"description">User data pointer
</dd>
1112 <h4 class=
"returnvalue">Return Value
</h4>
1113 <p class=
"description">Request status -
<code>IPP_OK
</code> on success.
</p>
1114 <h4 class=
"discussion">Discussion
</h4>
1115 <p class=
"discussion">This function sends a CUPS-Get-Devices request and streams the discovered
1116 devices to the specified callback function. The
"timeout
" parameter controls
1117 how long the request lasts, while the
"include_schemes
" and
"exclude_schemes
"
1118 parameters provide comma-delimited lists of backends to include or omit from
1119 the request respectively.
1122 <h3 class=
"function"><span class=
"info"> CUPS
1.1.20/Mac OS X
10.4 </span><a name=
"cupsGetFd">cupsGetFd
</a></h3>
1123 <p class=
"description">Get a file from the server.
</p>
1125 <a href=
"#http_status_t">http_status_t
</a> cupsGetFd (
<br>
1126 <a href=
"#http_t">http_t
</a> *http,
<br>
1127 const char *resource,
<br>
1128 int fd
<br>
1130 <h4 class=
"parameters">Parameters
</h4>
1133 <dd class=
"description">Connection to server or
<code>CUPS_HTTP_DEFAULT
</code></dd>
1135 <dd class=
"description">Resource name
</dd>
1137 <dd class=
"description">File descriptor
</dd>
1139 <h4 class=
"returnvalue">Return Value
</h4>
1140 <p class=
"description">HTTP status
</p>
1141 <h4 class=
"discussion">Discussion
</h4>
1142 <p class=
"discussion">This function returns
<code>HTTP_OK
</code> when the file is successfully retrieved.
1145 <h3 class=
"function"><span class=
"info"> CUPS
1.1.20/Mac OS X
10.4 </span><a name=
"cupsGetFile">cupsGetFile
</a></h3>
1146 <p class=
"description">Get a file from the server.
</p>
1148 <a href=
"#http_status_t">http_status_t
</a> cupsGetFile (
<br>
1149 <a href=
"#http_t">http_t
</a> *http,
<br>
1150 const char *resource,
<br>
1151 const char *filename
<br>
1153 <h4 class=
"parameters">Parameters
</h4>
1156 <dd class=
"description">Connection to server or
<code>CUPS_HTTP_DEFAULT
</code></dd>
1158 <dd class=
"description">Resource name
</dd>
1160 <dd class=
"description">Filename
</dd>
1162 <h4 class=
"returnvalue">Return Value
</h4>
1163 <p class=
"description">HTTP status
</p>
1164 <h4 class=
"discussion">Discussion
</h4>
1165 <p class=
"discussion">This function returns
<code>HTTP_OK
</code> when the file is successfully retrieved.
1168 <h3 class=
"function"><span class=
"info"> CUPS
1.4/Mac OS X
10.6 </span><a name=
"cupsGetResponse">cupsGetResponse
</a></h3>
1169 <p class=
"description">Get a response to an IPP request.
</p>
1171 <a href=
"#ipp_t">ipp_t
</a> *cupsGetResponse (
<br>
1172 <a href=
"#http_t">http_t
</a> *http,
<br>
1173 const char *resource
<br>
1175 <h4 class=
"parameters">Parameters
</h4>
1178 <dd class=
"description">Connection to server or
<code>CUPS_HTTP_DEFAULT
</code></dd>
1180 <dd class=
"description">HTTP resource for POST
</dd>
1182 <h4 class=
"returnvalue">Return Value
</h4>
1183 <p class=
"description">Response or
<code>NULL
</code> on HTTP error
</p>
1184 <h4 class=
"discussion">Discussion
</h4>
1185 <p class=
"discussion">Use this function to get the response for an IPP request sent using
1186 cupsSendDocument() or cupsSendRequest(). For requests that return
1187 additional data, use httpRead() after getting a successful response.
1190 <h3 class=
"function"><a name=
"cupsLastError">cupsLastError
</a></h3>
1191 <p class=
"description">Return the last IPP status code.
</p>
1193 ipp_status_t cupsLastError (void);
</p>
1194 <h4 class=
"returnvalue">Return Value
</h4>
1195 <p class=
"description">IPP status code from last request
</p>
1196 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"cupsLastErrorString">cupsLastErrorString
</a></h3>
1197 <p class=
"description">Return the last IPP status-message.
</p>
1199 const char *cupsLastErrorString (void);
</p>
1200 <h4 class=
"returnvalue">Return Value
</h4>
1201 <p class=
"description">status-message text from last request
</p>
1202 <h3 class=
"function"><span class=
"info"> CUPS
1.1.20/Mac OS X
10.4 </span><a name=
"cupsPutFd">cupsPutFd
</a></h3>
1203 <p class=
"description">Put a file on the server.
</p>
1205 <a href=
"#http_status_t">http_status_t
</a> cupsPutFd (
<br>
1206 <a href=
"#http_t">http_t
</a> *http,
<br>
1207 const char *resource,
<br>
1208 int fd
<br>
1210 <h4 class=
"parameters">Parameters
</h4>
1213 <dd class=
"description">Connection to server or
<code>CUPS_HTTP_DEFAULT
</code></dd>
1215 <dd class=
"description">Resource name
</dd>
1217 <dd class=
"description">File descriptor
</dd>
1219 <h4 class=
"returnvalue">Return Value
</h4>
1220 <p class=
"description">HTTP status
</p>
1221 <h4 class=
"discussion">Discussion
</h4>
1222 <p class=
"discussion">This function returns
<code>HTTP_CREATED
</code> when the file is stored
1226 <h3 class=
"function"><span class=
"info"> CUPS
1.1.20/Mac OS X
10.4 </span><a name=
"cupsPutFile">cupsPutFile
</a></h3>
1227 <p class=
"description">Put a file on the server.
</p>
1229 <a href=
"#http_status_t">http_status_t
</a> cupsPutFile (
<br>
1230 <a href=
"#http_t">http_t
</a> *http,
<br>
1231 const char *resource,
<br>
1232 const char *filename
<br>
1234 <h4 class=
"parameters">Parameters
</h4>
1237 <dd class=
"description">Connection to server or
<code>CUPS_HTTP_DEFAULT
</code></dd>
1239 <dd class=
"description">Resource name
</dd>
1241 <dd class=
"description">Filename
</dd>
1243 <h4 class=
"returnvalue">Return Value
</h4>
1244 <p class=
"description">HTTP status
</p>
1245 <h4 class=
"discussion">Discussion
</h4>
1246 <p class=
"discussion">This function returns
<code>HTTP_CREATED
</code> when the file is stored
1250 <h3 class=
"function"><span class=
"info"> CUPS
1.4/Mac OS X
10.6 </span><a name=
"cupsReadResponseData">cupsReadResponseData
</a></h3>
1251 <p class=
"description">Read additional data after the IPP response.
</p>
1253 ssize_t cupsReadResponseData (
<br>
1254 <a href=
"#http_t">http_t
</a> *http,
<br>
1255 char *buffer,
<br>
1256 size_t length
<br>
1258 <h4 class=
"parameters">Parameters
</h4>
1261 <dd class=
"description">Connection to server or
<code>CUPS_HTTP_DEFAULT
</code></dd>
1263 <dd class=
"description">Buffer to use
</dd>
1265 <dd class=
"description">Number of bytes to read
</dd>
1267 <h4 class=
"returnvalue">Return Value
</h4>
1268 <p class=
"description">Bytes read,
0 on EOF, -
1 on error
</p>
1269 <h4 class=
"discussion">Discussion
</h4>
1270 <p class=
"discussion">This function is used after cupsGetResponse() to read the PPD or document
1271 files for CUPS_GET_PPD and CUPS_GET_DOCUMENT requests, respectively.
1274 <h3 class=
"function"><span class=
"info"> CUPS
1.4/Mac OS X
10.6 </span><a name=
"cupsSendRequest">cupsSendRequest
</a></h3>
1275 <p class=
"description">Send an IPP request.
</p>
1277 <a href=
"#http_status_t">http_status_t
</a> cupsSendRequest (
<br>
1278 <a href=
"#http_t">http_t
</a> *http,
<br>
1279 <a href=
"#ipp_t">ipp_t
</a> *request,
<br>
1280 const char *resource,
<br>
1281 size_t length
<br>
1283 <h4 class=
"parameters">Parameters
</h4>
1286 <dd class=
"description">Connection to server or
<code>CUPS_HTTP_DEFAULT
</code></dd>
1288 <dd class=
"description">IPP request
</dd>
1290 <dd class=
"description">Resource path
</dd>
1292 <dd class=
"description">Length of data to follow or
<code>CUPS_LENGTH_VARIABLE
</code></dd>
1294 <h4 class=
"returnvalue">Return Value
</h4>
1295 <p class=
"description">Initial HTTP status
</p>
1296 <h4 class=
"discussion">Discussion
</h4>
1297 <p class=
"discussion">Use httpWrite() to write any additional data (document, PPD file, etc.)
1298 for the request, cupsGetResponse() to get the IPP response, and httpRead()
1299 to read any additional data following the response. Only one request can be
1300 sent/queued at a time.
<br>
1302 Unlike cupsDoFileRequest(), cupsDoIORequest(), and cupsDoRequest(), the
1303 request is not freed.
1306 <h3 class=
"function"><span class=
"info"> CUPS
1.4/Mac OS X
10.6 </span><a name=
"cupsWriteRequestData">cupsWriteRequestData
</a></h3>
1307 <p class=
"description">Write additional data after an IPP request.
</p>
1309 <a href=
"#http_status_t">http_status_t
</a> cupsWriteRequestData (
<br>
1310 <a href=
"#http_t">http_t
</a> *http,
<br>
1311 const char *buffer,
<br>
1312 size_t length
<br>
1314 <h4 class=
"parameters">Parameters
</h4>
1317 <dd class=
"description">Connection to server or
<code>CUPS_HTTP_DEFAULT
</code></dd>
1319 <dd class=
"description">Bytes to write
</dd>
1321 <dd class=
"description">Number of bytes to write
</dd>
1323 <h4 class=
"returnvalue">Return Value
</h4>
1324 <p class=
"description"><code>HTTP_CONTINUE
</code> if OK or HTTP status on error
</p>
1325 <h4 class=
"discussion">Discussion
</h4>
1326 <p class=
"discussion">This function is used after
<a href=
"#cupsSendRequest"><code>cupsSendRequest
</code></a> to provide a PPD and
1327 after
<a href=
"#cupsStartDocument"><code>cupsStartDocument
</code></a> to provide a document file.
1330 <h3 class=
"function"><span class=
"info"> CUPS
1.5/Mac OS X
10.7 </span><a name=
"httpAddCredential">httpAddCredential
</a></h3>
1331 <p class=
"description">Allocates and adds a single credential to an array.
</p>
1333 int httpAddCredential (
<br>
1334 cups_array_t *credentials,
<br>
1335 const void *data,
<br>
1336 size_t datalen
<br>
1338 <h4 class=
"parameters">Parameters
</h4>
1340 <dt>credentials
</dt>
1341 <dd class=
"description">Credentials array
</dd>
1343 <dd class=
"description">PEM-encoded X
.509 data
</dd>
1345 <dd class=
"description">Length of data
</dd>
1347 <h4 class=
"returnvalue">Return Value
</h4>
1348 <p class=
"description">0 on success, -
1 on error
</p>
1349 <h4 class=
"discussion">Discussion
</h4>
1350 <p class=
"discussion">Use
<code>cupsArrayNew(NULL, NULL)
</code> to create a credentials array.
1353 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpAddrAny">httpAddrAny
</a></h3>
1354 <p class=
"description">Check for the
"any
" address.
</p>
1356 int httpAddrAny (
<br>
1357 const
<a href=
"#http_addr_t">http_addr_t
</a> *addr
<br>
1359 <h4 class=
"parameters">Parameters
</h4>
1362 <dd class=
"description">Address to check
</dd>
1364 <h4 class=
"returnvalue">Return Value
</h4>
1365 <p class=
"description">1 if
"any
",
0 otherwise
</p>
1366 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpAddrEqual">httpAddrEqual
</a></h3>
1367 <p class=
"description">Compare two addresses.
</p>
1369 int httpAddrEqual (
<br>
1370 const
<a href=
"#http_addr_t">http_addr_t
</a> *addr1,
<br>
1371 const
<a href=
"#http_addr_t">http_addr_t
</a> *addr2
<br>
1373 <h4 class=
"parameters">Parameters
</h4>
1376 <dd class=
"description">First address
</dd>
1378 <dd class=
"description">Second address
</dd>
1380 <h4 class=
"returnvalue">Return Value
</h4>
1381 <p class=
"description">1 if equal,
0 if not
</p>
1382 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpAddrLength">httpAddrLength
</a></h3>
1383 <p class=
"description">Return the length of the address in bytes.
</p>
1385 int httpAddrLength (
<br>
1386 const
<a href=
"#http_addr_t">http_addr_t
</a> *addr
<br>
1388 <h4 class=
"parameters">Parameters
</h4>
1391 <dd class=
"description">Address
</dd>
1393 <h4 class=
"returnvalue">Return Value
</h4>
1394 <p class=
"description">Length in bytes
</p>
1395 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpAddrLocalhost">httpAddrLocalhost
</a></h3>
1396 <p class=
"description">Check for the local loopback address.
</p>
1398 int httpAddrLocalhost (
<br>
1399 const
<a href=
"#http_addr_t">http_addr_t
</a> *addr
<br>
1401 <h4 class=
"parameters">Parameters
</h4>
1404 <dd class=
"description">Address to check
</dd>
1406 <h4 class=
"returnvalue">Return Value
</h4>
1407 <p class=
"description">1 if local host,
0 otherwise
</p>
1408 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpAddrLookup">httpAddrLookup
</a></h3>
1409 <p class=
"description">Lookup the hostname associated with the address.
</p>
1411 char *httpAddrLookup (
<br>
1412 const
<a href=
"#http_addr_t">http_addr_t
</a> *addr,
<br>
1413 char *name,
<br>
1414 int namelen
<br>
1416 <h4 class=
"parameters">Parameters
</h4>
1419 <dd class=
"description">Address to lookup
</dd>
1421 <dd class=
"description">Host name buffer
</dd>
1423 <dd class=
"description">Size of name buffer
</dd>
1425 <h4 class=
"returnvalue">Return Value
</h4>
1426 <p class=
"description">Host name
</p>
1427 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpAddrString">httpAddrString
</a></h3>
1428 <p class=
"description">Convert an address to a numeric string.
</p>
1430 char *httpAddrString (
<br>
1431 const
<a href=
"#http_addr_t">http_addr_t
</a> *addr,
<br>
1432 char *s,
<br>
1433 int slen
<br>
1435 <h4 class=
"parameters">Parameters
</h4>
1438 <dd class=
"description">Address to convert
</dd>
1440 <dd class=
"description">String buffer
</dd>
1442 <dd class=
"description">Length of string
</dd>
1444 <h4 class=
"returnvalue">Return Value
</h4>
1445 <p class=
"description">Numeric address string
</p>
1446 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpAssembleURI">httpAssembleURI
</a></h3>
1447 <p class=
"description">Assemble a uniform resource identifier from its
1450 <a href=
"#http_uri_status_t">http_uri_status_t
</a> httpAssembleURI (
<br>
1451 <a href=
"#http_uri_coding_t">http_uri_coding_t
</a> encoding,
<br>
1452 char *uri,
<br>
1453 int urilen,
<br>
1454 const char *scheme,
<br>
1455 const char *username,
<br>
1456 const char *host,
<br>
1457 int port,
<br>
1458 const char *resource
<br>
1460 <h4 class=
"parameters">Parameters
</h4>
1463 <dd class=
"description">Encoding flags
</dd>
1465 <dd class=
"description">URI buffer
</dd>
1467 <dd class=
"description">Size of URI buffer
</dd>
1469 <dd class=
"description">Scheme name
</dd>
1471 <dd class=
"description">Username
</dd>
1473 <dd class=
"description">Hostname or address
</dd>
1475 <dd class=
"description">Port number
</dd>
1477 <dd class=
"description">Resource
</dd>
1479 <h4 class=
"returnvalue">Return Value
</h4>
1480 <p class=
"description">URI status
</p>
1481 <h4 class=
"discussion">Discussion
</h4>
1482 <p class=
"discussion">This function escapes reserved characters in the URI depending on the
1483 value of the
"encoding
" argument. You should use this function in
1484 place of traditional string functions whenever you need to create a
1488 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpAssembleURIf">httpAssembleURIf
</a></h3>
1489 <p class=
"description">Assemble a uniform resource identifier from its
1490 components with a formatted resource.
</p>
1492 <a href=
"#http_uri_status_t">http_uri_status_t
</a> httpAssembleURIf (
<br>
1493 <a href=
"#http_uri_coding_t">http_uri_coding_t
</a> encoding,
<br>
1494 char *uri,
<br>
1495 int urilen,
<br>
1496 const char *scheme,
<br>
1497 const char *username,
<br>
1498 const char *host,
<br>
1499 int port,
<br>
1500 const char *resourcef,
<br>
1501 ...
<br>
1503 <h4 class=
"parameters">Parameters
</h4>
1506 <dd class=
"description">Encoding flags
</dd>
1508 <dd class=
"description">URI buffer
</dd>
1510 <dd class=
"description">Size of URI buffer
</dd>
1512 <dd class=
"description">Scheme name
</dd>
1514 <dd class=
"description">Username
</dd>
1516 <dd class=
"description">Hostname or address
</dd>
1518 <dd class=
"description">Port number
</dd>
1520 <dd class=
"description">Printf-style resource
</dd>
1522 <dd class=
"description">Additional arguments as needed
</dd>
1524 <h4 class=
"returnvalue">Return Value
</h4>
1525 <p class=
"description">URI status
</p>
1526 <h4 class=
"discussion">Discussion
</h4>
1527 <p class=
"discussion">This function creates a formatted version of the resource string
1528 argument
"resourcef
" and escapes reserved characters in the URI
1529 depending on the value of the
"encoding
" argument. You should use
1530 this function in place of traditional string functions whenever
1531 you need to create a URI string.
1534 <h3 class=
"function"><a name=
"httpBlocking">httpBlocking
</a></h3>
1535 <p class=
"description">Set blocking/non-blocking behavior on a connection.
</p>
1537 void httpBlocking (
<br>
1538 <a href=
"#http_t">http_t
</a> *http,
<br>
1539 int b
<br>
1541 <h4 class=
"parameters">Parameters
</h4>
1544 <dd class=
"description">Connection to server
</dd>
1546 <dd class=
"description">1 = blocking,
0 = non-blocking
</dd>
1548 <h3 class=
"function"><a name=
"httpCheck">httpCheck
</a></h3>
1549 <p class=
"description">Check to see if there is a pending response from the server.
</p>
1552 <a href=
"#http_t">http_t
</a> *http
<br>
1554 <h4 class=
"parameters">Parameters
</h4>
1557 <dd class=
"description">Connection to server
</dd>
1559 <h4 class=
"returnvalue">Return Value
</h4>
1560 <p class=
"description">0 = no data,
1 = data available
</p>
1561 <h3 class=
"function"><span class=
"info"> CUPS
1.1.19/Mac OS X
10.3 </span><a name=
"httpClearCookie">httpClearCookie
</a></h3>
1562 <p class=
"description">Clear the cookie value(s).
</p>
1564 void httpClearCookie (
<br>
1565 <a href=
"#http_t">http_t
</a> *http
<br>
1567 <h4 class=
"parameters">Parameters
</h4>
1570 <dd class=
"description">Connection to server
</dd>
1572 <h3 class=
"function"><a name=
"httpClearFields">httpClearFields
</a></h3>
1573 <p class=
"description">Clear HTTP request fields.
</p>
1575 void httpClearFields (
<br>
1576 <a href=
"#http_t">http_t
</a> *http
<br>
1578 <h4 class=
"parameters">Parameters
</h4>
1581 <dd class=
"description">Connection to server
</dd>
1583 <h3 class=
"function"><a name=
"httpClose">httpClose
</a></h3>
1584 <p class=
"description">Close an HTTP connection.
</p>
1586 void httpClose (
<br>
1587 <a href=
"#http_t">http_t
</a> *http
<br>
1589 <h4 class=
"parameters">Parameters
</h4>
1592 <dd class=
"description">Connection to server
</dd>
1594 <h3 class=
"function"><span class=
"info"> DEPRECATED
</span><a name=
"httpConnect">httpConnect
</a></h3>
1595 <p class=
"description">Connect to a HTTP server.
</p>
1597 <a href=
"#http_t">http_t
</a> *httpConnect (
<br>
1598 const char *host,
<br>
1599 int port
<br>
1601 <h4 class=
"parameters">Parameters
</h4>
1604 <dd class=
"description">Host to connect to
</dd>
1606 <dd class=
"description">Port number
</dd>
1608 <h4 class=
"returnvalue">Return Value
</h4>
1609 <p class=
"description">New HTTP connection
</p>
1610 <h4 class=
"discussion">Discussion
</h4>
1611 <p class=
"discussion">This function is deprecated - use
<a href=
"#httpConnectEncrypt"><code>httpConnectEncrypt
</code></a> instead.
1614 <h3 class=
"function"><a name=
"httpConnectEncrypt">httpConnectEncrypt
</a></h3>
1615 <p class=
"description">Connect to a HTTP server using encryption.
</p>
1617 <a href=
"#http_t">http_t
</a> *httpConnectEncrypt (
<br>
1618 const char *host,
<br>
1619 int port,
<br>
1620 <a href=
"#http_encryption_t">http_encryption_t
</a> encryption
<br>
1622 <h4 class=
"parameters">Parameters
</h4>
1625 <dd class=
"description">Host to connect to
</dd>
1627 <dd class=
"description">Port number
</dd>
1629 <dd class=
"description">Type of encryption to use
</dd>
1631 <h4 class=
"returnvalue">Return Value
</h4>
1632 <p class=
"description">New HTTP connection
</p>
1633 <h3 class=
"function"><span class=
"info"> CUPS
1.5/Mac OS X
10.7 </span><a name=
"httpCopyCredentials">httpCopyCredentials
</a></h3>
1634 <p class=
"description">Copy the credentials associated with an encrypted
1637 int httpCopyCredentials (
<br>
1638 <a href=
"#http_t">http_t
</a> *http,
<br>
1639 cups_array_t **credentials
<br>
1641 <h4 class=
"parameters">Parameters
</h4>
1644 <dd class=
"description">Connection to server
</dd>
1645 <dt>credentials
</dt>
1646 <dd class=
"description">Array of credentials
</dd>
1648 <h4 class=
"returnvalue">Return Value
</h4>
1649 <p class=
"description">Status of call (
0 = success)
</p>
1650 <h3 class=
"function"><span class=
"info"> DEPRECATED
</span><a name=
"httpDecode64">httpDecode64
</a></h3>
1651 <p class=
"description">Base64-decode a string.
</p>
1653 char *httpDecode64 (
<br>
1654 char *out,
<br>
1655 const char *in
<br>
1657 <h4 class=
"parameters">Parameters
</h4>
1660 <dd class=
"description">String to write to
</dd>
1662 <dd class=
"description">String to read from
</dd>
1664 <h4 class=
"returnvalue">Return Value
</h4>
1665 <p class=
"description">Decoded string
</p>
1666 <h4 class=
"discussion">Discussion
</h4>
1667 <p class=
"discussion">This function is deprecated. Use the httpDecode64_2() function instead
1668 which provides buffer length arguments.
1671 <h3 class=
"function"><span class=
"info"> CUPS
1.1.21/Mac OS X
10.4 </span><a name=
"httpDecode64_2">httpDecode64_2
</a></h3>
1672 <p class=
"description">Base64-decode a string.
</p>
1674 char *httpDecode64_2 (
<br>
1675 char *out,
<br>
1676 int *outlen,
<br>
1677 const char *in
<br>
1679 <h4 class=
"parameters">Parameters
</h4>
1682 <dd class=
"description">String to write to
</dd>
1684 <dd class=
"description">Size of output string
</dd>
1686 <dd class=
"description">String to read from
</dd>
1688 <h4 class=
"returnvalue">Return Value
</h4>
1689 <p class=
"description">Decoded string
</p>
1690 <h3 class=
"function"><a name=
"httpDelete">httpDelete
</a></h3>
1691 <p class=
"description">Send a DELETE request to the server.
</p>
1693 int httpDelete (
<br>
1694 <a href=
"#http_t">http_t
</a> *http,
<br>
1695 const char *uri
<br>
1697 <h4 class=
"parameters">Parameters
</h4>
1700 <dd class=
"description">Connection to server
</dd>
1702 <dd class=
"description">URI to delete
</dd>
1704 <h4 class=
"returnvalue">Return Value
</h4>
1705 <p class=
"description">Status of call (
0 = success)
</p>
1706 <h3 class=
"function"><span class=
"info"> DEPRECATED
</span><a name=
"httpEncode64">httpEncode64
</a></h3>
1707 <p class=
"description">Base64-encode a string.
</p>
1709 char *httpEncode64 (
<br>
1710 char *out,
<br>
1711 const char *in
<br>
1713 <h4 class=
"parameters">Parameters
</h4>
1716 <dd class=
"description">String to write to
</dd>
1718 <dd class=
"description">String to read from
</dd>
1720 <h4 class=
"returnvalue">Return Value
</h4>
1721 <p class=
"description">Encoded string
</p>
1722 <h4 class=
"discussion">Discussion
</h4>
1723 <p class=
"discussion">This function is deprecated. Use the httpEncode64_2() function instead
1724 which provides buffer length arguments.
1727 <h3 class=
"function"><span class=
"info"> CUPS
1.1.21/Mac OS X
10.4 </span><a name=
"httpEncode64_2">httpEncode64_2
</a></h3>
1728 <p class=
"description">Base64-encode a string.
</p>
1730 char *httpEncode64_2 (
<br>
1731 char *out,
<br>
1732 int outlen,
<br>
1733 const char *in,
<br>
1734 int inlen
<br>
1736 <h4 class=
"parameters">Parameters
</h4>
1739 <dd class=
"description">String to write to
</dd>
1741 <dd class=
"description">Size of output string
</dd>
1743 <dd class=
"description">String to read from
</dd>
1745 <dd class=
"description">Size of input string
</dd>
1747 <h4 class=
"returnvalue">Return Value
</h4>
1748 <p class=
"description">Encoded string
</p>
1749 <h3 class=
"function"><a name=
"httpEncryption">httpEncryption
</a></h3>
1750 <p class=
"description">Set the required encryption on the link.
</p>
1752 int httpEncryption (
<br>
1753 <a href=
"#http_t">http_t
</a> *http,
<br>
1754 <a href=
"#http_encryption_t">http_encryption_t
</a> e
<br>
1756 <h4 class=
"parameters">Parameters
</h4>
1759 <dd class=
"description">Connection to server
</dd>
1761 <dd class=
"description">New encryption preference
</dd>
1763 <h4 class=
"returnvalue">Return Value
</h4>
1764 <p class=
"description">-
1 on error,
0 on success
</p>
1765 <h3 class=
"function"><a name=
"httpError">httpError
</a></h3>
1766 <p class=
"description">Get the last error on a connection.
</p>
1769 <a href=
"#http_t">http_t
</a> *http
<br>
1771 <h4 class=
"parameters">Parameters
</h4>
1774 <dd class=
"description">Connection to server
</dd>
1776 <h4 class=
"returnvalue">Return Value
</h4>
1777 <p class=
"description">Error code (errno) value
</p>
1778 <h3 class=
"function"><a name=
"httpFlush">httpFlush
</a></h3>
1779 <p class=
"description">Flush data from a HTTP connection.
</p>
1781 void httpFlush (
<br>
1782 <a href=
"#http_t">http_t
</a> *http
<br>
1784 <h4 class=
"parameters">Parameters
</h4>
1787 <dd class=
"description">Connection to server
</dd>
1789 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpFlushWrite">httpFlushWrite
</a></h3>
1790 <p class=
"description">Flush data in write buffer.
</p>
1792 int httpFlushWrite (
<br>
1793 <a href=
"#http_t">http_t
</a> *http
<br>
1795 <h4 class=
"parameters">Parameters
</h4>
1798 <dd class=
"description">Connection to server
</dd>
1800 <h4 class=
"returnvalue">Return Value
</h4>
1801 <p class=
"description">Bytes written or -
1 on error
</p>
1802 <h3 class=
"function"><a name=
"httpFreeCredentials">httpFreeCredentials
</a></h3>
1803 <p class=
"description">Free an array of credentials.
</p>
1805 void httpFreeCredentials (
<br>
1806 cups_array_t *credentials
<br>
1808 <h4 class=
"parameters">Parameters
</h4>
1810 <dt>credentials
</dt>
1811 <dd class=
"description">Array of credentials
</dd>
1813 <h3 class=
"function"><a name=
"httpGet">httpGet
</a></h3>
1814 <p class=
"description">Send a GET request to the server.
</p>
1817 <a href=
"#http_t">http_t
</a> *http,
<br>
1818 const char *uri
<br>
1820 <h4 class=
"parameters">Parameters
</h4>
1823 <dd class=
"description">Connection to server
</dd>
1825 <dd class=
"description">URI to get
</dd>
1827 <h4 class=
"returnvalue">Return Value
</h4>
1828 <p class=
"description">Status of call (
0 = success)
</p>
1829 <h3 class=
"function"><span class=
"info"> CUPS
1.3/Mac OS X
10.5 </span><a name=
"httpGetAuthString">httpGetAuthString
</a></h3>
1830 <p class=
"description">Get the current authorization string.
</p>
1832 char *httpGetAuthString (
<br>
1833 <a href=
"#http_t">http_t
</a> *http
<br>
1835 <h4 class=
"parameters">Parameters
</h4>
1838 <dd class=
"description">Connection to server
</dd>
1840 <h4 class=
"returnvalue">Return Value
</h4>
1841 <p class=
"description">Authorization string
</p>
1842 <h4 class=
"discussion">Discussion
</h4>
1843 <p class=
"discussion">The authorization string is set by cupsDoAuthentication() and
1844 httpSetAuthString(). Use httpGetAuthString() to retrieve the
1845 string to use with httpSetField() for the HTTP_FIELD_AUTHORIZATION
1849 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpGetBlocking">httpGetBlocking
</a></h3>
1850 <p class=
"description">Get the blocking/non-block state of a connection.
</p>
1852 int httpGetBlocking (
<br>
1853 <a href=
"#http_t">http_t
</a> *http
<br>
1855 <h4 class=
"parameters">Parameters
</h4>
1858 <dd class=
"description">Connection to server
</dd>
1860 <h4 class=
"returnvalue">Return Value
</h4>
1861 <p class=
"description">1 if blocking,
0 if non-blocking
</p>
1862 <h3 class=
"function"><span class=
"info"> CUPS
1.1.19/Mac OS X
10.3 </span><a name=
"httpGetCookie">httpGetCookie
</a></h3>
1863 <p class=
"description">Get any cookie data from the response.
</p>
1865 const char *httpGetCookie (
<br>
1866 <a href=
"#http_t">http_t
</a> *http
<br>
1868 <h4 class=
"parameters">Parameters
</h4>
1871 <dd class=
"description">HTTP connecion
</dd>
1873 <h4 class=
"returnvalue">Return Value
</h4>
1874 <p class=
"description">Cookie data or NULL
</p>
1875 <h3 class=
"function"><span class=
"info"> DEPRECATED
</span><a name=
"httpGetDateString">httpGetDateString
</a></h3>
1876 <p class=
"description">Get a formatted date/time string from a time value.
</p>
1878 const char *httpGetDateString (
<br>
1879 time_t t
<br>
1881 <h4 class=
"parameters">Parameters
</h4>
1884 <dd class=
"description">UNIX time
</dd>
1886 <h4 class=
"returnvalue">Return Value
</h4>
1887 <p class=
"description">Date/time string
</p>
1888 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpGetDateString2">httpGetDateString2
</a></h3>
1889 <p class=
"description">Get a formatted date/time string from a time value.
</p>
1891 const char *httpGetDateString2 (
<br>
1892 time_t t,
<br>
1893 char *s,
<br>
1894 int slen
<br>
1896 <h4 class=
"parameters">Parameters
</h4>
1899 <dd class=
"description">UNIX time
</dd>
1901 <dd class=
"description">String buffer
</dd>
1903 <dd class=
"description">Size of string buffer
</dd>
1905 <h4 class=
"returnvalue">Return Value
</h4>
1906 <p class=
"description">Date/time string
</p>
1907 <h3 class=
"function"><a name=
"httpGetDateTime">httpGetDateTime
</a></h3>
1908 <p class=
"description">Get a time value from a formatted date/time string.
</p>
1910 time_t httpGetDateTime (
<br>
1911 const char *s
<br>
1913 <h4 class=
"parameters">Parameters
</h4>
1916 <dd class=
"description">Date/time string
</dd>
1918 <h4 class=
"returnvalue">Return Value
</h4>
1919 <p class=
"description">UNIX time
</p>
1920 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpGetFd">httpGetFd
</a></h3>
1921 <p class=
"description">Get the file descriptor associated with a connection.
</p>
1924 <a href=
"#http_t">http_t
</a> *http
<br>
1926 <h4 class=
"parameters">Parameters
</h4>
1929 <dd class=
"description">Connection to server
</dd>
1931 <h4 class=
"returnvalue">Return Value
</h4>
1932 <p class=
"description">File descriptor or -
1 if none
</p>
1933 <h3 class=
"function"><a name=
"httpGetField">httpGetField
</a></h3>
1934 <p class=
"description">Get a field value from a request/response.
</p>
1936 const char *httpGetField (
<br>
1937 <a href=
"#http_t">http_t
</a> *http,
<br>
1938 <a href=
"#http_field_t">http_field_t
</a> field
<br>
1940 <h4 class=
"parameters">Parameters
</h4>
1943 <dd class=
"description">Connection to server
</dd>
1945 <dd class=
"description">Field to get
</dd>
1947 <h4 class=
"returnvalue">Return Value
</h4>
1948 <p class=
"description">Field value
</p>
1949 <h3 class=
"function"><span class=
"info"> DEPRECATED
</span><a name=
"httpGetHostByName">httpGetHostByName
</a></h3>
1950 <p class=
"description">Lookup a hostname or IPv4 address, and return
1951 address records for the specified name.
</p>
1953 struct hostent *httpGetHostByName (
<br>
1954 const char *name
<br>
1956 <h4 class=
"parameters">Parameters
</h4>
1959 <dd class=
"description">Hostname or IP address
</dd>
1961 <h4 class=
"returnvalue">Return Value
</h4>
1962 <p class=
"description">Host entry
</p>
1963 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpGetHostname">httpGetHostname
</a></h3>
1964 <p class=
"description">Get the FQDN for the connection or local system.
</p>
1966 const char *httpGetHostname (
<br>
1967 <a href=
"#http_t">http_t
</a> *http,
<br>
1968 char *s,
<br>
1969 int slen
<br>
1971 <h4 class=
"parameters">Parameters
</h4>
1974 <dd class=
"description">HTTP connection or NULL
</dd>
1976 <dd class=
"description">String buffer for name
</dd>
1978 <dd class=
"description">Size of buffer
</dd>
1980 <h4 class=
"returnvalue">Return Value
</h4>
1981 <p class=
"description">FQDN for connection or system
</p>
1982 <h4 class=
"discussion">Discussion
</h4>
1983 <p class=
"discussion">When
"http
" points to a connected socket, return the hostname or
1984 address that was used in the call to httpConnect() or httpConnectEncrypt().
1985 Otherwise, return the FQDN for the local system using both gethostname()
1986 and gethostbyname() to get the local hostname with domain.
1989 <h3 class=
"function"><span class=
"info"> DEPRECATED
</span><a name=
"httpGetLength">httpGetLength
</a></h3>
1990 <p class=
"description">Get the amount of data remaining from the
1991 content-length or transfer-encoding fields.
</p>
1993 int httpGetLength (
<br>
1994 <a href=
"#http_t">http_t
</a> *http
<br>
1996 <h4 class=
"parameters">Parameters
</h4>
1999 <dd class=
"description">Connection to server
</dd>
2001 <h4 class=
"returnvalue">Return Value
</h4>
2002 <p class=
"description">Content length
</p>
2003 <h4 class=
"discussion">Discussion
</h4>
2004 <p class=
"discussion">This function is deprecated and will not return lengths larger than
2005 2^
31 -
1; use httpGetLength2() instead.
2008 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpGetLength2">httpGetLength2
</a></h3>
2009 <p class=
"description">Get the amount of data remaining from the
2010 content-length or transfer-encoding fields.
</p>
2012 off_t httpGetLength2 (
<br>
2013 <a href=
"#http_t">http_t
</a> *http
<br>
2015 <h4 class=
"parameters">Parameters
</h4>
2018 <dd class=
"description">Connection to server
</dd>
2020 <h4 class=
"returnvalue">Return Value
</h4>
2021 <p class=
"description">Content length
</p>
2022 <h4 class=
"discussion">Discussion
</h4>
2023 <p class=
"discussion">This function returns the complete content length, even for
2024 content larger than
2^
31 -
1.
2027 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpGetStatus">httpGetStatus
</a></h3>
2028 <p class=
"description">Get the status of the last HTTP request.
</p>
2030 <a href=
"#http_status_t">http_status_t
</a> httpGetStatus (
<br>
2031 <a href=
"#http_t">http_t
</a> *http
<br>
2033 <h4 class=
"parameters">Parameters
</h4>
2036 <dd class=
"description">Connection to server
</dd>
2038 <h4 class=
"returnvalue">Return Value
</h4>
2039 <p class=
"description">HTTP status
</p>
2040 <h3 class=
"function"><span class=
"info"> DEPRECATED
</span><a name=
"httpGetSubField">httpGetSubField
</a></h3>
2041 <p class=
"description">Get a sub-field value.
</p>
2043 char *httpGetSubField (
<br>
2044 <a href=
"#http_t">http_t
</a> *http,
<br>
2045 <a href=
"#http_field_t">http_field_t
</a> field,
<br>
2046 const char *name,
<br>
2047 char *value
<br>
2049 <h4 class=
"parameters">Parameters
</h4>
2052 <dd class=
"description">Connection to server
</dd>
2054 <dd class=
"description">Field index
</dd>
2056 <dd class=
"description">Name of sub-field
</dd>
2058 <dd class=
"description">Value string
</dd>
2060 <h4 class=
"returnvalue">Return Value
</h4>
2061 <p class=
"description">Value or NULL
</p>
2062 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpGetSubField2">httpGetSubField2
</a></h3>
2063 <p class=
"description">Get a sub-field value.
</p>
2065 char *httpGetSubField2 (
<br>
2066 <a href=
"#http_t">http_t
</a> *http,
<br>
2067 <a href=
"#http_field_t">http_field_t
</a> field,
<br>
2068 const char *name,
<br>
2069 char *value,
<br>
2070 int valuelen
<br>
2072 <h4 class=
"parameters">Parameters
</h4>
2075 <dd class=
"description">Connection to server
</dd>
2077 <dd class=
"description">Field index
</dd>
2079 <dd class=
"description">Name of sub-field
</dd>
2081 <dd class=
"description">Value string
</dd>
2083 <dd class=
"description">Size of value buffer
</dd>
2085 <h4 class=
"returnvalue">Return Value
</h4>
2086 <p class=
"description">Value or NULL
</p>
2087 <h3 class=
"function"><a name=
"httpGets">httpGets
</a></h3>
2088 <p class=
"description">Get a line of text from a HTTP connection.
</p>
2090 char *httpGets (
<br>
2091 char *line,
<br>
2092 int length,
<br>
2093 <a href=
"#http_t">http_t
</a> *http
<br>
2095 <h4 class=
"parameters">Parameters
</h4>
2098 <dd class=
"description">Line to read into
</dd>
2100 <dd class=
"description">Max length of buffer
</dd>
2102 <dd class=
"description">Connection to server
</dd>
2104 <h4 class=
"returnvalue">Return Value
</h4>
2105 <p class=
"description">Line or NULL
</p>
2106 <h3 class=
"function"><a name=
"httpHead">httpHead
</a></h3>
2107 <p class=
"description">Send a HEAD request to the server.
</p>
2110 <a href=
"#http_t">http_t
</a> *http,
<br>
2111 const char *uri
<br>
2113 <h4 class=
"parameters">Parameters
</h4>
2116 <dd class=
"description">Connection to server
</dd>
2118 <dd class=
"description">URI for head
</dd>
2120 <h4 class=
"returnvalue">Return Value
</h4>
2121 <p class=
"description">Status of call (
0 = success)
</p>
2122 <h3 class=
"function"><a name=
"httpInitialize">httpInitialize
</a></h3>
2123 <p class=
"description">Initialize the HTTP interface library and set the
2124 default HTTP proxy (if any).
</p>
2126 void httpInitialize (void);
</p>
2127 <h3 class=
"function"><a name=
"httpMD5">httpMD5
</a></h3>
2128 <p class=
"description">Compute the MD5 sum of the username:group:password.
</p>
2131 const char *username,
<br>
2132 const char *realm,
<br>
2133 const char *passwd,
<br>
2134 char md5[
33]
<br>
2136 <h4 class=
"parameters">Parameters
</h4>
2139 <dd class=
"description">User name
</dd>
2141 <dd class=
"description">Realm name
</dd>
2143 <dd class=
"description">Password string
</dd>
2145 <dd class=
"description">MD5 string
</dd>
2147 <h4 class=
"returnvalue">Return Value
</h4>
2148 <p class=
"description">MD5 sum
</p>
2149 <h3 class=
"function"><a name=
"httpMD5Final">httpMD5Final
</a></h3>
2150 <p class=
"description">Combine the MD5 sum of the username, group, and password
2151 with the server-supplied nonce value, method, and
2154 char *httpMD5Final (
<br>
2155 const char *nonce,
<br>
2156 const char *method,
<br>
2157 const char *resource,
<br>
2158 char md5[
33]
<br>
2160 <h4 class=
"parameters">Parameters
</h4>
2163 <dd class=
"description">Server nonce value
</dd>
2165 <dd class=
"description">METHOD (GET, POST, etc.)
</dd>
2167 <dd class=
"description">Resource path
</dd>
2169 <dd class=
"description">MD5 sum
</dd>
2171 <h4 class=
"returnvalue">Return Value
</h4>
2172 <p class=
"description">New sum
</p>
2173 <h3 class=
"function"><a name=
"httpMD5String">httpMD5String
</a></h3>
2174 <p class=
"description">Convert an MD5 sum to a character string.
</p>
2176 char *httpMD5String (
<br>
2177 const unsigned char *sum,
<br>
2178 char md5[
33]
<br>
2180 <h4 class=
"parameters">Parameters
</h4>
2183 <dd class=
"description">MD5 sum data
</dd>
2185 <dd class=
"description">MD5 sum in hex
</dd>
2187 <h4 class=
"returnvalue">Return Value
</h4>
2188 <p class=
"description">MD5 sum in hex
</p>
2189 <h3 class=
"function"><a name=
"httpOptions">httpOptions
</a></h3>
2190 <p class=
"description">Send an OPTIONS request to the server.
</p>
2192 int httpOptions (
<br>
2193 <a href=
"#http_t">http_t
</a> *http,
<br>
2194 const char *uri
<br>
2196 <h4 class=
"parameters">Parameters
</h4>
2199 <dd class=
"description">Connection to server
</dd>
2201 <dd class=
"description">URI for options
</dd>
2203 <h4 class=
"returnvalue">Return Value
</h4>
2204 <p class=
"description">Status of call (
0 = success)
</p>
2205 <h3 class=
"function"><a name=
"httpPost">httpPost
</a></h3>
2206 <p class=
"description">Send a POST request to the server.
</p>
2209 <a href=
"#http_t">http_t
</a> *http,
<br>
2210 const char *uri
<br>
2212 <h4 class=
"parameters">Parameters
</h4>
2215 <dd class=
"description">Connection to server
</dd>
2217 <dd class=
"description">URI for post
</dd>
2219 <h4 class=
"returnvalue">Return Value
</h4>
2220 <p class=
"description">Status of call (
0 = success)
</p>
2221 <h3 class=
"function"><a name=
"httpPut">httpPut
</a></h3>
2222 <p class=
"description">Send a PUT request to the server.
</p>
2225 <a href=
"#http_t">http_t
</a> *http,
<br>
2226 const char *uri
<br>
2228 <h4 class=
"parameters">Parameters
</h4>
2231 <dd class=
"description">Connection to server
</dd>
2233 <dd class=
"description">URI to put
</dd>
2235 <h4 class=
"returnvalue">Return Value
</h4>
2236 <p class=
"description">Status of call (
0 = success)
</p>
2237 <h3 class=
"function"><span class=
"info"> DEPRECATED
</span><a name=
"httpRead">httpRead
</a></h3>
2238 <p class=
"description">Read data from a HTTP connection.
</p>
2241 <a href=
"#http_t">http_t
</a> *http,
<br>
2242 char *buffer,
<br>
2243 int length
<br>
2245 <h4 class=
"parameters">Parameters
</h4>
2248 <dd class=
"description">Connection to server
</dd>
2250 <dd class=
"description">Buffer for data
</dd>
2252 <dd class=
"description">Maximum number of bytes
</dd>
2254 <h4 class=
"returnvalue">Return Value
</h4>
2255 <p class=
"description">Number of bytes read
</p>
2256 <h4 class=
"discussion">Discussion
</h4>
2257 <p class=
"discussion">This function is deprecated. Use the httpRead2() function which can
2258 read more than
2GB of data.
2261 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpRead2">httpRead2
</a></h3>
2262 <p class=
"description">Read data from a HTTP connection.
</p>
2264 ssize_t httpRead2 (
<br>
2265 <a href=
"#http_t">http_t
</a> *http,
<br>
2266 char *buffer,
<br>
2267 size_t length
<br>
2269 <h4 class=
"parameters">Parameters
</h4>
2272 <dd class=
"description">Connection to server
</dd>
2274 <dd class=
"description">Buffer for data
</dd>
2276 <dd class=
"description">Maximum number of bytes
</dd>
2278 <h4 class=
"returnvalue">Return Value
</h4>
2279 <p class=
"description">Number of bytes read
</p>
2280 <h3 class=
"function"><a name=
"httpReconnect">httpReconnect
</a></h3>
2281 <p class=
"description">Reconnect to a HTTP server.
</p>
2283 int httpReconnect (
<br>
2284 <a href=
"#http_t">http_t
</a> *http
<br>
2286 <h4 class=
"parameters">Parameters
</h4>
2289 <dd class=
"description">Connection to server
</dd>
2291 <h4 class=
"returnvalue">Return Value
</h4>
2292 <p class=
"description">0 on success, non-zero on failure
</p>
2293 <h3 class=
"function"><span class=
"info"> DEPRECATED
</span><a name=
"httpSeparate">httpSeparate
</a></h3>
2294 <p class=
"description">Separate a Universal Resource Identifier into its
2297 void httpSeparate (
<br>
2298 const char *uri,
<br>
2299 char *scheme,
<br>
2300 char *username,
<br>
2301 char *host,
<br>
2302 int *port,
<br>
2303 char *resource
<br>
2305 <h4 class=
"parameters">Parameters
</h4>
2308 <dd class=
"description">Universal Resource Identifier
</dd>
2310 <dd class=
"description">Scheme [
32] (http, https, etc.)
</dd>
2312 <dd class=
"description">Username [
1024]
</dd>
2314 <dd class=
"description">Hostname [
1024]
</dd>
2316 <dd class=
"description">Port number to use
</dd>
2318 <dd class=
"description">Resource/filename [
1024]
</dd>
2320 <h4 class=
"discussion">Discussion
</h4>
2321 <p class=
"discussion">This function is deprecated; use the httpSeparateURI() function instead.
2324 <h3 class=
"function"><span class=
"info"> CUPS
1.1.21/Mac OS X
10.4 </span><a name=
"httpSeparate2">httpSeparate2
</a></h3>
2325 <p class=
"description">Separate a Universal Resource Identifier into its
2328 void httpSeparate2 (
<br>
2329 const char *uri,
<br>
2330 char *scheme,
<br>
2331 int schemelen,
<br>
2332 char *username,
<br>
2333 int usernamelen,
<br>
2334 char *host,
<br>
2335 int hostlen,
<br>
2336 int *port,
<br>
2337 char *resource,
<br>
2338 int resourcelen
<br>
2340 <h4 class=
"parameters">Parameters
</h4>
2343 <dd class=
"description">Universal Resource Identifier
</dd>
2345 <dd class=
"description">Scheme (http, https, etc.)
</dd>
2347 <dd class=
"description">Size of scheme buffer
</dd>
2349 <dd class=
"description">Username
</dd>
2350 <dt>usernamelen
</dt>
2351 <dd class=
"description">Size of username buffer
</dd>
2353 <dd class=
"description">Hostname
</dd>
2355 <dd class=
"description">Size of hostname buffer
</dd>
2357 <dd class=
"description">Port number to use
</dd>
2359 <dd class=
"description">Resource/filename
</dd>
2360 <dt>resourcelen
</dt>
2361 <dd class=
"description">Size of resource buffer
</dd>
2363 <h4 class=
"discussion">Discussion
</h4>
2364 <p class=
"discussion">This function is deprecated; use the httpSeparateURI() function instead.
2368 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpSeparateURI">httpSeparateURI
</a></h3>
2369 <p class=
"description">Separate a Universal Resource Identifier into its
2372 <a href=
"#http_uri_status_t">http_uri_status_t
</a> httpSeparateURI (
<br>
2373 <a href=
"#http_uri_coding_t">http_uri_coding_t
</a> decoding,
<br>
2374 const char *uri,
<br>
2375 char *scheme,
<br>
2376 int schemelen,
<br>
2377 char *username,
<br>
2378 int usernamelen,
<br>
2379 char *host,
<br>
2380 int hostlen,
<br>
2381 int *port,
<br>
2382 char *resource,
<br>
2383 int resourcelen
<br>
2385 <h4 class=
"parameters">Parameters
</h4>
2388 <dd class=
"description">Decoding flags
</dd>
2390 <dd class=
"description">Universal Resource Identifier
</dd>
2392 <dd class=
"description">Scheme (http, https, etc.)
</dd>
2394 <dd class=
"description">Size of scheme buffer
</dd>
2396 <dd class=
"description">Username
</dd>
2397 <dt>usernamelen
</dt>
2398 <dd class=
"description">Size of username buffer
</dd>
2400 <dd class=
"description">Hostname
</dd>
2402 <dd class=
"description">Size of hostname buffer
</dd>
2404 <dd class=
"description">Port number to use
</dd>
2406 <dd class=
"description">Resource/filename
</dd>
2407 <dt>resourcelen
</dt>
2408 <dd class=
"description">Size of resource buffer
</dd>
2410 <h4 class=
"returnvalue">Return Value
</h4>
2411 <p class=
"description">Result of separation
</p>
2412 <h3 class=
"function"><span class=
"info"> CUPS
1.3/Mac OS X
10.5 </span><a name=
"httpSetAuthString">httpSetAuthString
</a></h3>
2413 <p class=
"description">Set the current authorization string.
</p>
2415 void httpSetAuthString (
<br>
2416 <a href=
"#http_t">http_t
</a> *http,
<br>
2417 const char *scheme,
<br>
2418 const char *data
<br>
2420 <h4 class=
"parameters">Parameters
</h4>
2423 <dd class=
"description">Connection to server
</dd>
2425 <dd class=
"description">Auth scheme (NULL to clear it)
</dd>
2427 <dd class=
"description">Auth data (NULL for none)
</dd>
2429 <h4 class=
"discussion">Discussion
</h4>
2430 <p class=
"discussion">This function just stores a copy of the current authorization string in
2431 the HTTP connection object. You must still call httpSetField() to set
2432 HTTP_FIELD_AUTHORIZATION prior to issuing a HTTP request using httpGet(),
2433 httpHead(), httpOptions(), httpPost, or httpPut().
2436 <h3 class=
"function"><span class=
"info"> CUPS
1.1.19/Mac OS X
10.3 </span><a name=
"httpSetCookie">httpSetCookie
</a></h3>
2437 <p class=
"description">Set the cookie value(s).
</p>
2439 void httpSetCookie (
<br>
2440 <a href=
"#http_t">http_t
</a> *http,
<br>
2441 const char *cookie
<br>
2443 <h4 class=
"parameters">Parameters
</h4>
2446 <dd class=
"description">Connection
</dd>
2448 <dd class=
"description">Cookie string
</dd>
2450 <h3 class=
"function"><span class=
"info"> CUPS
1.5/Mac OS X
10.7 </span><a name=
"httpSetCredentials">httpSetCredentials
</a></h3>
2451 <p class=
"description">Set the credentials associated with an encrypted
2454 int httpSetCredentials (
<br>
2455 <a href=
"#http_t">http_t
</a> *http,
<br>
2456 cups_array_t *credentials
<br>
2458 <h4 class=
"parameters">Parameters
</h4>
2461 <dd class=
"description">Connection to server
</dd>
2462 <dt>credentials
</dt>
2463 <dd class=
"description">Array of credentials
</dd>
2465 <h4 class=
"returnvalue">Return Value
</h4>
2466 <p class=
"description">Status of call (
0 = success)
</p>
2467 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpSetExpect">httpSetExpect
</a></h3>
2468 <p class=
"description">Set the Expect: header in a request.
</p>
2470 void httpSetExpect (
<br>
2471 <a href=
"#http_t">http_t
</a> *http,
<br>
2472 <a href=
"#http_status_t">http_status_t
</a> expect
<br>
2474 <h4 class=
"parameters">Parameters
</h4>
2477 <dd class=
"description">Connection to server
</dd>
2479 <dd class=
"description">HTTP status to expect (HTTP_CONTINUE)
</dd>
2481 <h4 class=
"discussion">Discussion
</h4>
2482 <p class=
"discussion">Currently only HTTP_CONTINUE is supported for the
"expect
" argument.
2485 <h3 class=
"function"><a name=
"httpSetField">httpSetField
</a></h3>
2486 <p class=
"description">Set the value of an HTTP header.
</p>
2488 void httpSetField (
<br>
2489 <a href=
"#http_t">http_t
</a> *http,
<br>
2490 <a href=
"#http_field_t">http_field_t
</a> field,
<br>
2491 const char *value
<br>
2493 <h4 class=
"parameters">Parameters
</h4>
2496 <dd class=
"description">Connection to server
</dd>
2498 <dd class=
"description">Field index
</dd>
2500 <dd class=
"description">Value
</dd>
2502 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpSetLength">httpSetLength
</a></h3>
2503 <p class=
"description">Set the content-length and content-encoding.
</p>
2505 void httpSetLength (
<br>
2506 <a href=
"#http_t">http_t
</a> *http,
<br>
2507 size_t length
<br>
2509 <h4 class=
"parameters">Parameters
</h4>
2512 <dd class=
"description">Connection to server
</dd>
2514 <dd class=
"description">Length (
0 for chunked)
</dd>
2516 <h3 class=
"function"><a name=
"httpStatus">httpStatus
</a></h3>
2517 <p class=
"description">Return a short string describing a HTTP status code.
</p>
2519 const char *httpStatus (
<br>
2520 <a href=
"#http_status_t">http_status_t
</a> status
<br>
2522 <h4 class=
"parameters">Parameters
</h4>
2525 <dd class=
"description">HTTP status code
</dd>
2527 <h4 class=
"returnvalue">Return Value
</h4>
2528 <p class=
"description">Localized status string
</p>
2529 <h4 class=
"discussion">Discussion
</h4>
2530 <p class=
"discussion">The returned string is localized to the current POSIX locale and is based
2531 on the status strings defined in RFC
2616.
</p>
2532 <h3 class=
"function"><a name=
"httpTrace">httpTrace
</a></h3>
2533 <p class=
"description">Send an TRACE request to the server.
</p>
2536 <a href=
"#http_t">http_t
</a> *http,
<br>
2537 const char *uri
<br>
2539 <h4 class=
"parameters">Parameters
</h4>
2542 <dd class=
"description">Connection to server
</dd>
2544 <dd class=
"description">URI for trace
</dd>
2546 <h4 class=
"returnvalue">Return Value
</h4>
2547 <p class=
"description">Status of call (
0 = success)
</p>
2548 <h3 class=
"function"><a name=
"httpUpdate">httpUpdate
</a></h3>
2549 <p class=
"description">Update the current HTTP state for incoming data.
</p>
2551 <a href=
"#http_status_t">http_status_t
</a> httpUpdate (
<br>
2552 <a href=
"#http_t">http_t
</a> *http
<br>
2554 <h4 class=
"parameters">Parameters
</h4>
2557 <dd class=
"description">Connection to server
</dd>
2559 <h4 class=
"returnvalue">Return Value
</h4>
2560 <p class=
"description">HTTP status
</p>
2561 <h3 class=
"function"><span class=
"info"> CUPS
1.1.19/Mac OS X
10.3 </span><a name=
"httpWait">httpWait
</a></h3>
2562 <p class=
"description">Wait for data available on a connection.
</p>
2565 <a href=
"#http_t">http_t
</a> *http,
<br>
2566 int msec
<br>
2568 <h4 class=
"parameters">Parameters
</h4>
2571 <dd class=
"description">Connection to server
</dd>
2573 <dd class=
"description">Milliseconds to wait
</dd>
2575 <h4 class=
"returnvalue">Return Value
</h4>
2576 <p class=
"description">1 if data is available,
0 otherwise
</p>
2577 <h3 class=
"function"><span class=
"info"> DEPRECATED
</span><a name=
"httpWrite">httpWrite
</a></h3>
2578 <p class=
"description">Write data to a HTTP connection.
</p>
2581 <a href=
"#http_t">http_t
</a> *http,
<br>
2582 const char *buffer,
<br>
2583 int length
<br>
2585 <h4 class=
"parameters">Parameters
</h4>
2588 <dd class=
"description">Connection to server
</dd>
2590 <dd class=
"description">Buffer for data
</dd>
2592 <dd class=
"description">Number of bytes to write
</dd>
2594 <h4 class=
"returnvalue">Return Value
</h4>
2595 <p class=
"description">Number of bytes written
</p>
2596 <h4 class=
"discussion">Discussion
</h4>
2597 <p class=
"discussion">This function is deprecated. Use the httpWrite2() function which can
2598 write more than
2GB of data.
2601 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"httpWrite2">httpWrite2
</a></h3>
2602 <p class=
"description">Write data to a HTTP connection.
</p>
2604 ssize_t httpWrite2 (
<br>
2605 <a href=
"#http_t">http_t
</a> *http,
<br>
2606 const char *buffer,
<br>
2607 size_t length
<br>
2609 <h4 class=
"parameters">Parameters
</h4>
2612 <dd class=
"description">Connection to server
</dd>
2614 <dd class=
"description">Buffer for data
</dd>
2616 <dd class=
"description">Number of bytes to write
</dd>
2618 <h4 class=
"returnvalue">Return Value
</h4>
2619 <p class=
"description">Number of bytes written
</p>
2620 <h3 class=
"function"><a name=
"ippAddBoolean">ippAddBoolean
</a></h3>
2621 <p class=
"description">Add a boolean attribute to an IPP message.
</p>
2623 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *ippAddBoolean (
<br>
2624 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
2625 <a href=
"#ipp_tag_t">ipp_tag_t
</a> group,
<br>
2626 const char *name,
<br>
2627 char value
<br>
2629 <h4 class=
"parameters">Parameters
</h4>
2632 <dd class=
"description">IPP message
</dd>
2634 <dd class=
"description">IPP group
</dd>
2636 <dd class=
"description">Name of attribute
</dd>
2638 <dd class=
"description">Value of attribute
</dd>
2640 <h4 class=
"returnvalue">Return Value
</h4>
2641 <p class=
"description">New attribute
</p>
2642 <h3 class=
"function"><a name=
"ippAddBooleans">ippAddBooleans
</a></h3>
2643 <p class=
"description">Add an array of boolean values.
</p>
2645 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *ippAddBooleans (
<br>
2646 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
2647 <a href=
"#ipp_tag_t">ipp_tag_t
</a> group,
<br>
2648 const char *name,
<br>
2649 int num_values,
<br>
2650 const char *values
<br>
2652 <h4 class=
"parameters">Parameters
</h4>
2655 <dd class=
"description">IPP message
</dd>
2657 <dd class=
"description">IPP group
</dd>
2659 <dd class=
"description">Name of attribute
</dd>
2661 <dd class=
"description">Number of values
</dd>
2663 <dd class=
"description">Values
</dd>
2665 <h4 class=
"returnvalue">Return Value
</h4>
2666 <p class=
"description">New attribute
</p>
2667 <h3 class=
"function"><span class=
"info"> CUPS
1.1.19/Mac OS X
10.3 </span><a name=
"ippAddCollection">ippAddCollection
</a></h3>
2668 <p class=
"description">Add a collection value.
</p>
2670 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *ippAddCollection (
<br>
2671 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
2672 <a href=
"#ipp_tag_t">ipp_tag_t
</a> group,
<br>
2673 const char *name,
<br>
2674 <a href=
"#ipp_t">ipp_t
</a> *value
<br>
2676 <h4 class=
"parameters">Parameters
</h4>
2679 <dd class=
"description">IPP message
</dd>
2681 <dd class=
"description">IPP group
</dd>
2683 <dd class=
"description">Name of attribute
</dd>
2685 <dd class=
"description">Value
</dd>
2687 <h4 class=
"returnvalue">Return Value
</h4>
2688 <p class=
"description">New attribute
</p>
2689 <h3 class=
"function"><span class=
"info"> CUPS
1.1.19/Mac OS X
10.3 </span><a name=
"ippAddCollections">ippAddCollections
</a></h3>
2690 <p class=
"description">Add an array of collection values.
</p>
2692 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *ippAddCollections (
<br>
2693 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
2694 <a href=
"#ipp_tag_t">ipp_tag_t
</a> group,
<br>
2695 const char *name,
<br>
2696 int num_values,
<br>
2697 const
<a href=
"#ipp_t">ipp_t
</a> **values
<br>
2699 <h4 class=
"parameters">Parameters
</h4>
2702 <dd class=
"description">IPP message
</dd>
2704 <dd class=
"description">IPP group
</dd>
2706 <dd class=
"description">Name of attribute
</dd>
2708 <dd class=
"description">Number of values
</dd>
2710 <dd class=
"description">Values
</dd>
2712 <h4 class=
"returnvalue">Return Value
</h4>
2713 <p class=
"description">New attribute
</p>
2714 <h3 class=
"function"><a name=
"ippAddDate">ippAddDate
</a></h3>
2715 <p class=
"description">Add a date attribute to an IPP message.
</p>
2717 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *ippAddDate (
<br>
2718 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
2719 <a href=
"#ipp_tag_t">ipp_tag_t
</a> group,
<br>
2720 const char *name,
<br>
2721 const
<a href=
"#ipp_uchar_t">ipp_uchar_t
</a> *value
<br>
2723 <h4 class=
"parameters">Parameters
</h4>
2726 <dd class=
"description">IPP message
</dd>
2728 <dd class=
"description">IPP group
</dd>
2730 <dd class=
"description">Name of attribute
</dd>
2732 <dd class=
"description">Value
</dd>
2734 <h4 class=
"returnvalue">Return Value
</h4>
2735 <p class=
"description">New attribute
</p>
2736 <h3 class=
"function"><a name=
"ippAddInteger">ippAddInteger
</a></h3>
2737 <p class=
"description">Add a integer attribute to an IPP message.
</p>
2739 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *ippAddInteger (
<br>
2740 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
2741 <a href=
"#ipp_tag_t">ipp_tag_t
</a> group,
<br>
2742 <a href=
"#ipp_tag_t">ipp_tag_t
</a> type,
<br>
2743 const char *name,
<br>
2744 int value
<br>
2746 <h4 class=
"parameters">Parameters
</h4>
2749 <dd class=
"description">IPP message
</dd>
2751 <dd class=
"description">IPP group
</dd>
2753 <dd class=
"description">Type of attribute
</dd>
2755 <dd class=
"description">Name of attribute
</dd>
2757 <dd class=
"description">Value of attribute
</dd>
2759 <h4 class=
"returnvalue">Return Value
</h4>
2760 <p class=
"description">New attribute
</p>
2761 <h3 class=
"function"><a name=
"ippAddIntegers">ippAddIntegers
</a></h3>
2762 <p class=
"description">Add an array of integer values.
</p>
2764 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *ippAddIntegers (
<br>
2765 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
2766 <a href=
"#ipp_tag_t">ipp_tag_t
</a> group,
<br>
2767 <a href=
"#ipp_tag_t">ipp_tag_t
</a> type,
<br>
2768 const char *name,
<br>
2769 int num_values,
<br>
2770 const int *values
<br>
2772 <h4 class=
"parameters">Parameters
</h4>
2775 <dd class=
"description">IPP message
</dd>
2777 <dd class=
"description">IPP group
</dd>
2779 <dd class=
"description">Type of attribute
</dd>
2781 <dd class=
"description">Name of attribute
</dd>
2783 <dd class=
"description">Number of values
</dd>
2785 <dd class=
"description">Values
</dd>
2787 <h4 class=
"returnvalue">Return Value
</h4>
2788 <p class=
"description">New attribute
</p>
2789 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"ippAddOctetString">ippAddOctetString
</a></h3>
2790 <p class=
"description">Add an octetString value to an IPP message.
</p>
2792 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *ippAddOctetString (
<br>
2793 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
2794 <a href=
"#ipp_tag_t">ipp_tag_t
</a> group,
<br>
2795 const char *name,
<br>
2796 const void *data,
<br>
2797 int datalen
<br>
2799 <h4 class=
"parameters">Parameters
</h4>
2802 <dd class=
"description">IPP message
</dd>
2804 <dd class=
"description">IPP group
</dd>
2806 <dd class=
"description">Name of attribute
</dd>
2808 <dd class=
"description">octetString data
</dd>
2810 <dd class=
"description">Length of data in bytes
</dd>
2812 <h4 class=
"returnvalue">Return Value
</h4>
2813 <p class=
"description">New attribute
</p>
2814 <h3 class=
"function"><a name=
"ippAddRange">ippAddRange
</a></h3>
2815 <p class=
"description">Add a range of values to an IPP message.
</p>
2817 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *ippAddRange (
<br>
2818 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
2819 <a href=
"#ipp_tag_t">ipp_tag_t
</a> group,
<br>
2820 const char *name,
<br>
2821 int lower,
<br>
2822 int upper
<br>
2824 <h4 class=
"parameters">Parameters
</h4>
2827 <dd class=
"description">IPP message
</dd>
2829 <dd class=
"description">IPP group
</dd>
2831 <dd class=
"description">Name of attribute
</dd>
2833 <dd class=
"description">Lower value
</dd>
2835 <dd class=
"description">Upper value
</dd>
2837 <h4 class=
"returnvalue">Return Value
</h4>
2838 <p class=
"description">New attribute
</p>
2839 <h3 class=
"function"><a name=
"ippAddRanges">ippAddRanges
</a></h3>
2840 <p class=
"description">Add ranges of values to an IPP message.
</p>
2842 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *ippAddRanges (
<br>
2843 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
2844 <a href=
"#ipp_tag_t">ipp_tag_t
</a> group,
<br>
2845 const char *name,
<br>
2846 int num_values,
<br>
2847 const int *lower,
<br>
2848 const int *upper
<br>
2850 <h4 class=
"parameters">Parameters
</h4>
2853 <dd class=
"description">IPP message
</dd>
2855 <dd class=
"description">IPP group
</dd>
2857 <dd class=
"description">Name of attribute
</dd>
2859 <dd class=
"description">Number of values
</dd>
2861 <dd class=
"description">Lower values
</dd>
2863 <dd class=
"description">Upper values
</dd>
2865 <h4 class=
"returnvalue">Return Value
</h4>
2866 <p class=
"description">New attribute
</p>
2867 <h3 class=
"function"><a name=
"ippAddResolution">ippAddResolution
</a></h3>
2868 <p class=
"description">Add a resolution value to an IPP message.
</p>
2870 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *ippAddResolution (
<br>
2871 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
2872 <a href=
"#ipp_tag_t">ipp_tag_t
</a> group,
<br>
2873 const char *name,
<br>
2874 <a href=
"#ipp_res_t">ipp_res_t
</a> units,
<br>
2875 int xres,
<br>
2876 int yres
<br>
2878 <h4 class=
"parameters">Parameters
</h4>
2881 <dd class=
"description">IPP message
</dd>
2883 <dd class=
"description">IPP group
</dd>
2885 <dd class=
"description">Name of attribute
</dd>
2887 <dd class=
"description">Units for resolution
</dd>
2889 <dd class=
"description">X resolution
</dd>
2891 <dd class=
"description">Y resolution
</dd>
2893 <h4 class=
"returnvalue">Return Value
</h4>
2894 <p class=
"description">New attribute
</p>
2895 <h3 class=
"function"><a name=
"ippAddResolutions">ippAddResolutions
</a></h3>
2896 <p class=
"description">Add resolution values to an IPP message.
</p>
2898 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *ippAddResolutions (
<br>
2899 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
2900 <a href=
"#ipp_tag_t">ipp_tag_t
</a> group,
<br>
2901 const char *name,
<br>
2902 int num_values,
<br>
2903 <a href=
"#ipp_res_t">ipp_res_t
</a> units,
<br>
2904 const int *xres,
<br>
2905 const int *yres
<br>
2907 <h4 class=
"parameters">Parameters
</h4>
2910 <dd class=
"description">IPP message
</dd>
2912 <dd class=
"description">IPP group
</dd>
2914 <dd class=
"description">Name of attribute
</dd>
2916 <dd class=
"description">Number of values
</dd>
2918 <dd class=
"description">Units for resolution
</dd>
2920 <dd class=
"description">X resolutions
</dd>
2922 <dd class=
"description">Y resolutions
</dd>
2924 <h4 class=
"returnvalue">Return Value
</h4>
2925 <p class=
"description">New attribute
</p>
2926 <h3 class=
"function"><a name=
"ippAddSeparator">ippAddSeparator
</a></h3>
2927 <p class=
"description">Add a group separator to an IPP message.
</p>
2929 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *ippAddSeparator (
<br>
2930 <a href=
"#ipp_t">ipp_t
</a> *ipp
<br>
2932 <h4 class=
"parameters">Parameters
</h4>
2935 <dd class=
"description">IPP message
</dd>
2937 <h4 class=
"returnvalue">Return Value
</h4>
2938 <p class=
"description">New attribute
</p>
2939 <h3 class=
"function"><a name=
"ippAddString">ippAddString
</a></h3>
2940 <p class=
"description">Add a language-encoded string to an IPP message.
</p>
2942 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *ippAddString (
<br>
2943 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
2944 <a href=
"#ipp_tag_t">ipp_tag_t
</a> group,
<br>
2945 <a href=
"#ipp_tag_t">ipp_tag_t
</a> type,
<br>
2946 const char *name,
<br>
2947 const char *charset,
<br>
2948 const char *value
<br>
2950 <h4 class=
"parameters">Parameters
</h4>
2953 <dd class=
"description">IPP message
</dd>
2955 <dd class=
"description">IPP group
</dd>
2957 <dd class=
"description">Type of attribute
</dd>
2959 <dd class=
"description">Name of attribute
</dd>
2961 <dd class=
"description">Character set
</dd>
2963 <dd class=
"description">Value
</dd>
2965 <h4 class=
"returnvalue">Return Value
</h4>
2966 <p class=
"description">New attribute
</p>
2967 <h3 class=
"function"><a name=
"ippAddStrings">ippAddStrings
</a></h3>
2968 <p class=
"description">Add language-encoded strings to an IPP message.
</p>
2970 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *ippAddStrings (
<br>
2971 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
2972 <a href=
"#ipp_tag_t">ipp_tag_t
</a> group,
<br>
2973 <a href=
"#ipp_tag_t">ipp_tag_t
</a> type,
<br>
2974 const char *name,
<br>
2975 int num_values,
<br>
2976 const char *charset,
<br>
2977 const char *const *values
<br>
2979 <h4 class=
"parameters">Parameters
</h4>
2982 <dd class=
"description">IPP message
</dd>
2984 <dd class=
"description">IPP group
</dd>
2986 <dd class=
"description">Type of attribute
</dd>
2988 <dd class=
"description">Name of attribute
</dd>
2990 <dd class=
"description">Number of values
</dd>
2992 <dd class=
"description">Character set
</dd>
2994 <dd class=
"description">Values
</dd>
2996 <h4 class=
"returnvalue">Return Value
</h4>
2997 <p class=
"description">New attribute
</p>
2998 <h3 class=
"function"><a name=
"ippDateToTime">ippDateToTime
</a></h3>
2999 <p class=
"description">Convert from RFC
1903 Date/Time format to UNIX time
3002 time_t ippDateToTime (
<br>
3003 const
<a href=
"#ipp_uchar_t">ipp_uchar_t
</a> *date
<br>
3005 <h4 class=
"parameters">Parameters
</h4>
3008 <dd class=
"description">RFC
1903 date info
</dd>
3010 <h4 class=
"returnvalue">Return Value
</h4>
3011 <p class=
"description">UNIX time value
</p>
3012 <h3 class=
"function"><a name=
"ippDelete">ippDelete
</a></h3>
3013 <p class=
"description">Delete an IPP message.
</p>
3015 void ippDelete (
<br>
3016 <a href=
"#ipp_t">ipp_t
</a> *ipp
<br>
3018 <h4 class=
"parameters">Parameters
</h4>
3021 <dd class=
"description">IPP message
</dd>
3023 <h3 class=
"function"><span class=
"info"> CUPS
1.1.19/Mac OS X
10.3 </span><a name=
"ippDeleteAttribute">ippDeleteAttribute
</a></h3>
3024 <p class=
"description">Delete a single attribute in an IPP message.
</p>
3026 void ippDeleteAttribute (
<br>
3027 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
3028 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *attr
<br>
3030 <h4 class=
"parameters">Parameters
</h4>
3033 <dd class=
"description">IPP message
</dd>
3035 <dd class=
"description">Attribute to delete
</dd>
3037 <h3 class=
"function"><a name=
"ippErrorString">ippErrorString
</a></h3>
3038 <p class=
"description">Return a name for the given status code.
</p>
3040 const char *ippErrorString (
<br>
3041 ipp_status_t error
<br>
3043 <h4 class=
"parameters">Parameters
</h4>
3046 <dd class=
"description">Error status
</dd>
3048 <h4 class=
"returnvalue">Return Value
</h4>
3049 <p class=
"description">Text string
</p>
3050 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"ippErrorValue">ippErrorValue
</a></h3>
3051 <p class=
"description">Return a status code for the given name.
</p>
3053 ipp_status_t ippErrorValue (
<br>
3054 const char *name
<br>
3056 <h4 class=
"parameters">Parameters
</h4>
3059 <dd class=
"description">Name
</dd>
3061 <h4 class=
"returnvalue">Return Value
</h4>
3062 <p class=
"description">IPP status code
</p>
3063 <h3 class=
"function"><a name=
"ippFindAttribute">ippFindAttribute
</a></h3>
3064 <p class=
"description">Find a named attribute in a request...
</p>
3066 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *ippFindAttribute (
<br>
3067 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
3068 const char *name,
<br>
3069 <a href=
"#ipp_tag_t">ipp_tag_t
</a> type
<br>
3071 <h4 class=
"parameters">Parameters
</h4>
3074 <dd class=
"description">IPP message
</dd>
3076 <dd class=
"description">Name of attribute
</dd>
3078 <dd class=
"description">Type of attribute
</dd>
3080 <h4 class=
"returnvalue">Return Value
</h4>
3081 <p class=
"description">Matching attribute
</p>
3082 <h3 class=
"function"><a name=
"ippFindNextAttribute">ippFindNextAttribute
</a></h3>
3083 <p class=
"description">Find the next named attribute in a request...
</p>
3085 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *ippFindNextAttribute (
<br>
3086 <a href=
"#ipp_t">ipp_t
</a> *ipp,
<br>
3087 const char *name,
<br>
3088 <a href=
"#ipp_tag_t">ipp_tag_t
</a> type
<br>
3090 <h4 class=
"parameters">Parameters
</h4>
3093 <dd class=
"description">IPP message
</dd>
3095 <dd class=
"description">Name of attribute
</dd>
3097 <dd class=
"description">Type of attribute
</dd>
3099 <h4 class=
"returnvalue">Return Value
</h4>
3100 <p class=
"description">Matching attribute
</p>
3101 <h3 class=
"function"><a name=
"ippLength">ippLength
</a></h3>
3102 <p class=
"description">Compute the length of an IPP message.
</p>
3104 size_t ippLength (
<br>
3105 <a href=
"#ipp_t">ipp_t
</a> *ipp
<br>
3107 <h4 class=
"parameters">Parameters
</h4>
3110 <dd class=
"description">IPP message
</dd>
3112 <h4 class=
"returnvalue">Return Value
</h4>
3113 <p class=
"description">Size of IPP message
</p>
3114 <h3 class=
"function"><a name=
"ippNew">ippNew
</a></h3>
3115 <p class=
"description">Allocate a new IPP message.
</p>
3117 <a href=
"#ipp_t">ipp_t
</a> *ippNew (void);
</p>
3118 <h4 class=
"returnvalue">Return Value
</h4>
3119 <p class=
"description">New IPP message
</p>
3120 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"ippNewRequest">ippNewRequest
</a></h3>
3121 <p class=
"description">Allocate a new IPP request message.
</p>
3123 <a href=
"#ipp_t">ipp_t
</a> *ippNewRequest (
<br>
3124 <a href=
"#ipp_op_t">ipp_op_t
</a> op
<br>
3126 <h4 class=
"parameters">Parameters
</h4>
3129 <dd class=
"description">Operation code
</dd>
3131 <h4 class=
"returnvalue">Return Value
</h4>
3132 <p class=
"description">IPP request message
</p>
3133 <h4 class=
"discussion">Discussion
</h4>
3134 <p class=
"discussion">The new request message is initialized with the attributes-charset and
3135 attributes-natural-language attributes added. The
3136 attributes-natural-language value is derived from the current locale.
3139 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"ippOpString">ippOpString
</a></h3>
3140 <p class=
"description">Return a name for the given operation id.
</p>
3142 const char *ippOpString (
<br>
3143 <a href=
"#ipp_op_t">ipp_op_t
</a> op
<br>
3145 <h4 class=
"parameters">Parameters
</h4>
3148 <dd class=
"description">Operation ID
</dd>
3150 <h4 class=
"returnvalue">Return Value
</h4>
3151 <p class=
"description">Name
</p>
3152 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"ippOpValue">ippOpValue
</a></h3>
3153 <p class=
"description">Return an operation id for the given name.
</p>
3155 <a href=
"#ipp_op_t">ipp_op_t
</a> ippOpValue (
<br>
3156 const char *name
<br>
3158 <h4 class=
"parameters">Parameters
</h4>
3161 <dd class=
"description">Textual name
</dd>
3163 <h4 class=
"returnvalue">Return Value
</h4>
3164 <p class=
"description">Operation ID
</p>
3165 <h3 class=
"function"><a name=
"ippPort">ippPort
</a></h3>
3166 <p class=
"description">Return the default IPP port number.
</p>
3168 int ippPort (void);
</p>
3169 <h4 class=
"returnvalue">Return Value
</h4>
3170 <p class=
"description">Port number
</p>
3171 <h3 class=
"function"><a name=
"ippRead">ippRead
</a></h3>
3172 <p class=
"description">Read data for an IPP message from a HTTP connection.
</p>
3174 <a href=
"#ipp_state_t">ipp_state_t
</a> ippRead (
<br>
3175 <a href=
"#http_t">http_t
</a> *http,
<br>
3176 <a href=
"#ipp_t">ipp_t
</a> *ipp
<br>
3178 <h4 class=
"parameters">Parameters
</h4>
3181 <dd class=
"description">HTTP connection
</dd>
3183 <dd class=
"description">IPP data
</dd>
3185 <h4 class=
"returnvalue">Return Value
</h4>
3186 <p class=
"description">Current state
</p>
3187 <h3 class=
"function"><span class=
"info"> CUPS
1.1.19/Mac OS X
10.3 </span><a name=
"ippReadFile">ippReadFile
</a></h3>
3188 <p class=
"description">Read data for an IPP message from a file.
</p>
3190 <a href=
"#ipp_state_t">ipp_state_t
</a> ippReadFile (
<br>
3191 int fd,
<br>
3192 <a href=
"#ipp_t">ipp_t
</a> *ipp
<br>
3194 <h4 class=
"parameters">Parameters
</h4>
3197 <dd class=
"description">HTTP data
</dd>
3199 <dd class=
"description">IPP data
</dd>
3201 <h4 class=
"returnvalue">Return Value
</h4>
3202 <p class=
"description">Current state
</p>
3203 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"ippReadIO">ippReadIO
</a></h3>
3204 <p class=
"description">Read data for an IPP message.
</p>
3206 <a href=
"#ipp_state_t">ipp_state_t
</a> ippReadIO (
<br>
3207 void *src,
<br>
3208 <a href=
"#ipp_iocb_t">ipp_iocb_t
</a> cb,
<br>
3209 int blocking,
<br>
3210 <a href=
"#ipp_t">ipp_t
</a> *parent,
<br>
3211 <a href=
"#ipp_t">ipp_t
</a> *ipp
<br>
3213 <h4 class=
"parameters">Parameters
</h4>
3216 <dd class=
"description">Data source
</dd>
3218 <dd class=
"description">Read callback function
</dd>
3220 <dd class=
"description">Use blocking IO?
</dd>
3222 <dd class=
"description">Parent request, if any
</dd>
3224 <dd class=
"description">IPP data
</dd>
3226 <h4 class=
"returnvalue">Return Value
</h4>
3227 <p class=
"description">Current state
</p>
3228 <h3 class=
"function"><a name=
"ippSetPort">ippSetPort
</a></h3>
3229 <p class=
"description">Set the default port number.
</p>
3231 void ippSetPort (
<br>
3232 int p
<br>
3234 <h4 class=
"parameters">Parameters
</h4>
3237 <dd class=
"description">Port number to use
</dd>
3239 <h3 class=
"function"><span class=
"info"> CUPS
1.4/Mac OS X
10.6 </span><a name=
"ippTagString">ippTagString
</a></h3>
3240 <p class=
"description">Return the tag name corresponding to a tag value.
</p>
3242 const char *ippTagString (
<br>
3243 <a href=
"#ipp_tag_t">ipp_tag_t
</a> tag
<br>
3245 <h4 class=
"parameters">Parameters
</h4>
3248 <dd class=
"description">Tag value
</dd>
3250 <h4 class=
"returnvalue">Return Value
</h4>
3251 <p class=
"description">Tag name
</p>
3252 <h4 class=
"discussion">Discussion
</h4>
3253 <p class=
"discussion">The returned names are defined in RFC
2911 and
3382.
3256 <h3 class=
"function"><span class=
"info"> CUPS
1.4/Mac OS X
10.6 </span><a name=
"ippTagValue">ippTagValue
</a></h3>
3257 <p class=
"description">Return the tag value corresponding to a tag name.
</p>
3259 <a href=
"#ipp_tag_t">ipp_tag_t
</a> ippTagValue (
<br>
3260 const char *name
<br>
3262 <h4 class=
"parameters">Parameters
</h4>
3265 <dd class=
"description">Tag name
</dd>
3267 <h4 class=
"returnvalue">Return Value
</h4>
3268 <p class=
"description">Tag value
</p>
3269 <h4 class=
"discussion">Discussion
</h4>
3270 <p class=
"discussion">The tag names are defined in RFC
2911 and
3382.
3273 <h3 class=
"function"><a name=
"ippTimeToDate">ippTimeToDate
</a></h3>
3274 <p class=
"description">Convert from UNIX time to RFC
1903 format.
</p>
3276 const
<a href=
"#ipp_uchar_t">ipp_uchar_t
</a> *ippTimeToDate (
<br>
3277 time_t t
<br>
3279 <h4 class=
"parameters">Parameters
</h4>
3282 <dd class=
"description">UNIX time value
</dd>
3284 <h4 class=
"returnvalue">Return Value
</h4>
3285 <p class=
"description">RFC-
1903 date/time data
</p>
3286 <h3 class=
"function"><a name=
"ippWrite">ippWrite
</a></h3>
3287 <p class=
"description">Write data for an IPP message to a HTTP connection.
</p>
3289 <a href=
"#ipp_state_t">ipp_state_t
</a> ippWrite (
<br>
3290 <a href=
"#http_t">http_t
</a> *http,
<br>
3291 <a href=
"#ipp_t">ipp_t
</a> *ipp
<br>
3293 <h4 class=
"parameters">Parameters
</h4>
3296 <dd class=
"description">HTTP connection
</dd>
3298 <dd class=
"description">IPP data
</dd>
3300 <h4 class=
"returnvalue">Return Value
</h4>
3301 <p class=
"description">Current state
</p>
3302 <h3 class=
"function"><span class=
"info"> CUPS
1.1.19/Mac OS X
10.3 </span><a name=
"ippWriteFile">ippWriteFile
</a></h3>
3303 <p class=
"description">Write data for an IPP message to a file.
</p>
3305 <a href=
"#ipp_state_t">ipp_state_t
</a> ippWriteFile (
<br>
3306 int fd,
<br>
3307 <a href=
"#ipp_t">ipp_t
</a> *ipp
<br>
3309 <h4 class=
"parameters">Parameters
</h4>
3312 <dd class=
"description">HTTP data
</dd>
3314 <dd class=
"description">IPP data
</dd>
3316 <h4 class=
"returnvalue">Return Value
</h4>
3317 <p class=
"description">Current state
</p>
3318 <h3 class=
"function"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"ippWriteIO">ippWriteIO
</a></h3>
3319 <p class=
"description">Write data for an IPP message.
</p>
3321 <a href=
"#ipp_state_t">ipp_state_t
</a> ippWriteIO (
<br>
3322 void *dst,
<br>
3323 <a href=
"#ipp_iocb_t">ipp_iocb_t
</a> cb,
<br>
3324 int blocking,
<br>
3325 <a href=
"#ipp_t">ipp_t
</a> *parent,
<br>
3326 <a href=
"#ipp_t">ipp_t
</a> *ipp
<br>
3328 <h4 class=
"parameters">Parameters
</h4>
3331 <dd class=
"description">Destination
</dd>
3333 <dd class=
"description">Write callback function
</dd>
3335 <dd class=
"description">Use blocking IO?
</dd>
3337 <dd class=
"description">Parent IPP message
</dd>
3339 <dd class=
"description">IPP data
</dd>
3341 <h4 class=
"returnvalue">Return Value
</h4>
3342 <p class=
"description">Current state
</p>
3343 <h2 class=
"title"><a name=
"TYPES">Data Types
</a></h2>
3344 <h3 class=
"typedef"><a name=
"gss_auth_identity_desc">gss_auth_identity_desc
</a></h3>
3345 <p class=
"description">Local functions...
</p>
3347 typedef struct
<a href=
"#gss_auth_identity">gss_auth_identity
</a> gss_auth_identity_desc;
3349 <h3 class=
"typedef"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"http_addr_t">http_addr_t
</a></h3>
3350 <p class=
"description">Socket address union, which
3351 makes using IPv6 and other
3352 address types easier and
3355 typedef union _http_addr_u / http_addr_t;
3357 <h3 class=
"typedef"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"http_addrlist_t">http_addrlist_t
</a></h3>
3358 <p class=
"description">Socket address list, which is
3359 used to enumerate all of the
3360 addresses that are associated
3361 with a hostname.
</p>
3363 typedef struct
<a href=
"#http_addrlist_s">http_addrlist_s
</a> / http_addrlist_t;
3365 <h3 class=
"typedef"><a name=
"http_auth_t">http_auth_t
</a></h3>
3366 <p class=
"description">HTTP authentication types
</p>
3368 typedef enum
<a href=
"#http_auth_e">http_auth_e
</a> http_auth_t;
3370 <h3 class=
"typedef"><span class=
"info"> CUPS
1.5/Mac OS X
10.7 </span><a name=
"http_credential_t">http_credential_t
</a></h3>
3371 <p class=
"description">Credential data
</p>
3373 typedef struct
<a href=
"#http_credential_s">http_credential_s
</a> http_credential_t;
3375 <h3 class=
"typedef"><a name=
"http_encoding_t">http_encoding_t
</a></h3>
3376 <p class=
"description">HTTP transfer encoding values
</p>
3378 typedef enum
<a href=
"#http_encoding_e">http_encoding_e
</a> http_encoding_t;
3380 <h3 class=
"typedef"><a name=
"http_encryption_t">http_encryption_t
</a></h3>
3381 <p class=
"description">HTTP encryption values
</p>
3383 typedef enum
<a href=
"#http_encryption_e">http_encryption_e
</a> http_encryption_t;
3385 <h3 class=
"typedef"><a name=
"http_field_t">http_field_t
</a></h3>
3386 <p class=
"description">HTTP field names
</p>
3388 typedef enum
<a href=
"#http_field_e">http_field_e
</a> http_field_t;
3390 <h3 class=
"typedef"><a name=
"http_keepalive_t">http_keepalive_t
</a></h3>
3391 <p class=
"description">HTTP keep-alive values
</p>
3393 typedef enum
<a href=
"#http_keepalive_e">http_keepalive_e
</a> http_keepalive_t;
3395 <h3 class=
"typedef"><a name=
"http_state_t">http_state_t
</a></h3>
3396 <p class=
"description">HTTP state values; states
3397 are server-oriented...
</p>
3399 typedef enum
<a href=
"#http_state_e">http_state_e
</a> / http_state_t;
3401 <h3 class=
"typedef"><a name=
"http_status_t">http_status_t
</a></h3>
3402 <p class=
"description">HTTP status codes
</p>
3404 typedef enum
<a href=
"#http_status_e">http_status_e
</a> http_status_t;
3406 <h3 class=
"typedef"><a name=
"http_t">http_t
</a></h3>
3407 <p class=
"description">HTTP connection type
</p>
3409 typedef struct _http_s http_t;
3411 <h3 class=
"typedef"><a name=
"http_uri_coding_t">http_uri_coding_t
</a></h3>
3412 <p class=
"description">URI en/decode flags
</p>
3414 typedef enum
<a href=
"#http_uri_coding_e">http_uri_coding_e
</a> http_uri_coding_t;
3416 <h3 class=
"typedef"><span class=
"info"> CUPS
1.2 </span><a name=
"http_uri_status_t">http_uri_status_t
</a></h3>
3417 <p class=
"description">URI separation status
</p>
3419 typedef enum
<a href=
"#http_uri_status_e">http_uri_status_e
</a> http_uri_status_t;
3421 <h3 class=
"typedef"><a name=
"http_version_t">http_version_t
</a></h3>
3422 <p class=
"description">HTTP version numbers
</p>
3424 typedef enum
<a href=
"#http_version_e">http_version_e
</a> http_version_t;
3426 <h3 class=
"typedef"><a name=
"ipp_attribute_t">ipp_attribute_t
</a></h3>
3427 <p class=
"description">Attribute
</p>
3429 typedef struct
<a href=
"#ipp_attribute_s">ipp_attribute_s
</a> ipp_attribute_t;
3431 <h3 class=
"typedef"><a name=
"ipp_finish_t">ipp_finish_t
</a></h3>
3432 <p class=
"description">Finishings
</p>
3434 typedef enum
<a href=
"#ipp_finish_e">ipp_finish_e
</a> ipp_finish_t;
3436 <h3 class=
"typedef"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"ipp_iocb_t">ipp_iocb_t
</a></h3>
3437 <p class=
"description">IPP IO Callback Function
</p>
3439 typedef ssize_t (*ipp_iocb_t)(void *,
<a href=
"#ipp_uchar_t">ipp_uchar_t
</a> *, size_t);
3441 <h3 class=
"typedef"><a name=
"ipp_jstate_t">ipp_jstate_t
</a></h3>
3442 <p class=
"description">Job states
</p>
3444 typedef enum
<a href=
"#ipp_jstate_e">ipp_jstate_e
</a> ipp_jstate_t;
3446 <h3 class=
"typedef"><a name=
"ipp_op_t">ipp_op_t
</a></h3>
3447 <p class=
"description">IPP operations
</p>
3449 typedef enum
<a href=
"#ipp_op_e">ipp_op_e
</a> ipp_op_t;
3451 <h3 class=
"typedef"><a name=
"ipp_orient_t">ipp_orient_t
</a></h3>
3452 <p class=
"description">Orientation values
</p>
3454 typedef enum
<a href=
"#ipp_orient_e">ipp_orient_e
</a> ipp_orient_t;
3456 <h3 class=
"typedef"><a name=
"ipp_pstate_t">ipp_pstate_t
</a></h3>
3457 <p class=
"description">Printer states
</p>
3459 typedef enum
<a href=
"#ipp_pstate_e">ipp_pstate_e
</a> ipp_pstate_t;
3461 <h3 class=
"typedef"><a name=
"ipp_quality_t">ipp_quality_t
</a></h3>
3462 <p class=
"description">Qualities
</p>
3464 typedef enum
<a href=
"#ipp_quality_e">ipp_quality_e
</a> ipp_quality_t;
3466 <h3 class=
"typedef"><a name=
"ipp_request_t">ipp_request_t
</a></h3>
3467 <p class=
"description">Request Header
</p>
3469 typedef union
<a href=
"#ipp_request_u">ipp_request_u
</a> ipp_request_t;
3471 <h3 class=
"typedef"><a name=
"ipp_res_t">ipp_res_t
</a></h3>
3472 <p class=
"description">Resolution units
</p>
3474 typedef enum
<a href=
"#ipp_res_e">ipp_res_e
</a> ipp_res_t;
3476 <h3 class=
"typedef"><a name=
"ipp_state_t">ipp_state_t
</a></h3>
3477 <p class=
"description">IPP states
</p>
3479 typedef enum
<a href=
"#ipp_state_e">ipp_state_e
</a> ipp_state_t;
3481 <h3 class=
"typedef"><a name=
"ipp_t">ipp_t
</a></h3>
3482 <p class=
"description">Attribute Value
</p>
3484 typedef struct
<a href=
"#ipp_s">ipp_s
</a> ipp_t;
3486 <h3 class=
"typedef"><a name=
"ipp_uchar_t">ipp_uchar_t
</a></h3>
3487 <p class=
"description">IPP status codes
</p>
3489 typedef typedef unsigned char ipp_uchar_t;
3491 <h3 class=
"typedef"><a name=
"ipp_tag_t">ipp_tag_t
</a></h3>
3492 <p class=
"description">Format tags for attributes
</p>
3494 typedef enum
<a href=
"#ipp_tag_e">ipp_tag_e
</a> ipp_tag_t;
3496 <h3 class=
"typedef"><a name=
"ipp_value_t">ipp_value_t
</a></h3>
3497 <p class=
"description">Attribute Value
</p>
3499 typedef union
<a href=
"#ipp_value_u">ipp_value_u
</a> ipp_value_t;
3501 <h2 class=
"title"><a name=
"STRUCTURES">Structures
</a></h2>
3502 <h3 class=
"struct"><a name=
"gss_auth_identity">gss_auth_identity
</a></h3>
3503 <p class=
"description">Local functions...
</p>
3504 <p class=
"code">struct gss_auth_identity {
<br>
3505 gss_buffer_t *credentialsRef;
<br>
3506 uint32_t flags;
<br>
3507 char *password;
<br>
3508 char *realm;
<br>
3509 uint32_t type;
<br>
3510 char *username;
<br>
3512 <h4 class=
"members">Members
</h4>
3514 <dt>credentialsRef
</dt>
3521 <h3 class=
"struct"><span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span><a name=
"http_addrlist_s">http_addrlist_s
</a></h3>
3522 <p class=
"description">Socket address list, which is
3523 used to enumerate all of the
3524 addresses that are associated
3525 with a hostname.
</p>
3526 <p class=
"code">struct http_addrlist_s {
<br>
3527 <a href=
"#http_addr_t">http_addr_t
</a> addr;
<br>
3528 struct
<a href=
"#http_addrlist_s">http_addrlist_s
</a> *next;
<br>
3530 <h4 class=
"members">Members
</h4>
3533 <dd class=
"description">Address
</dd>
3535 <dd class=
"description">Pointer to next address in list
</dd>
3537 <h3 class=
"struct"><span class=
"info"> CUPS
1.5/Mac OS X
10.7 </span><a name=
"http_credential_s">http_credential_s
</a></h3>
3538 <p class=
"description">Credential data
</p>
3539 <p class=
"code">struct http_credential_s {
<br>
3540 void *data;
<br>
3541 size_t datalen;
<br>
3543 <h4 class=
"members">Members
</h4>
3546 <dd class=
"description">Pointer to credential data
</dd>
3548 <dd class=
"description">Credential length
</dd>
3550 <h3 class=
"struct"><a name=
"ipp_attribute_s">ipp_attribute_s
</a></h3>
3551 <p class=
"description">Attribute
</p>
3552 <p class=
"code">struct ipp_attribute_s {
<br>
3553 char *name;
<br>
3554 struct
<a href=
"#ipp_attribute_s">ipp_attribute_s
</a> *next;
<br>
3555 int num_values;
<br>
3556 <a href=
"#ipp_tag_t">ipp_tag_t
</a> group_tag, value_tag;
<br>
3557 <a href=
"#ipp_value_t">ipp_value_t
</a> values[
1];
<br>
3559 <h4 class=
"members">Members
</h4>
3562 <dd class=
"description">Name of attribute
</dd>
3564 <dd class=
"description">Next attribute in list
</dd>
3565 <dt>num_values
</dt>
3566 <dd class=
"description">Number of values
</dd>
3568 <dd class=
"description">What type of value is it?
</dd>
3570 <dd class=
"description">Values
</dd>
3572 <h3 class=
"struct"><a name=
"ipp_s">ipp_s
</a></h3>
3573 <p class=
"description">IPP Request/Response/Notification
</p>
3574 <p class=
"code">struct ipp_s {
<br>
3575 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *attrs;
<br>
3576 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *current;
<br>
3577 <a href=
"#ipp_tag_t">ipp_tag_t
</a> curtag;
<br>
3578 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *last;
<br>
3579 <a href=
"#ipp_attribute_t">ipp_attribute_t
</a> *prev;
<br>
3580 <a href=
"#ipp_request_t">ipp_request_t
</a> request;
<br>
3581 <a href=
"#ipp_state_t">ipp_state_t
</a> state;
<br>
3582 int use;
<br>
3584 <h4 class=
"members">Members
</h4>
3587 <dd class=
"description">Attributes
</dd>
3589 <dd class=
"description">Current attribute (for read/write)
</dd>
3591 <dd class=
"description">Current attribute group tag
</dd>
3593 <dd class=
"description">Last attribute in list
</dd>
3594 <dt>prev
<span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span></dt>
3595 <dd class=
"description">Previous attribute (for read)
</dd>
3597 <dd class=
"description">Request header
</dd>
3599 <dd class=
"description">State of request
</dd>
3600 <dt>use
<span class=
"info"> CUPS
1.4.4/Mac OS X
10.6.?
</span></dt>
3601 <dd class=
"description">Use count
</dd>
3603 <h2 class=
"title"><a name=
"UNIONS">Unions
</a></h2>
3604 <h3 class=
"union"><a name=
"ipp_request_u">ipp_request_u
</a></h3>
3605 <p class=
"description">Request Header
</p>
3606 <p class=
"code">union ipp_request_u {
<br>
3608 <h4 class=
"members">Members
</h4>
3611 <h3 class=
"union"><a name=
"ipp_value_u">ipp_value_u
</a></h3>
3612 <p class=
"description">Attribute Value
</p>
3613 <p class=
"code">union ipp_value_u {
<br>
3614 char boolean;
<br>
3615 <a href=
"#ipp_t">ipp_t
</a> *collection;
<br>
3616 <a href=
"#ipp_uchar_t">ipp_uchar_t
</a> date[
11];
<br>
3617 int integer;
<br>
3619 <h4 class=
"members">Members
</h4>
3622 <dd class=
"description">Boolean value
</dd>
3623 <dt>collection
<span class=
"info"> CUPS
1.1.19/Mac OS X
10.3 </span></dt>
3624 <dd class=
"description">Collection value
</dd>
3626 <dd class=
"description">Date/time value
</dd>
3628 <dd class=
"description">Integer/enumerated value
</dd>
3630 <h2 class=
"title"><a name=
"ENUMERATIONS">Constants
</a></h2>
3631 <h3 class=
"enumeration"><a name=
"http_auth_e">http_auth_e
</a></h3>
3632 <p class=
"description">HTTP authentication types
</p>
3633 <h4 class=
"constants">Constants
</h4>
3635 <dt>HTTP_AUTH_BASIC
</dt>
3636 <dd class=
"description">Basic authentication in use
</dd>
3637 <dt>HTTP_AUTH_MD5
</dt>
3638 <dd class=
"description">Digest authentication in use
</dd>
3639 <dt>HTTP_AUTH_MD5_INT
</dt>
3640 <dd class=
"description">Digest authentication in use for body
</dd>
3641 <dt>HTTP_AUTH_MD5_SESS
</dt>
3642 <dd class=
"description">MD5-session authentication in use
</dd>
3643 <dt>HTTP_AUTH_MD5_SESS_INT
</dt>
3644 <dd class=
"description">MD5-session authentication in use for body
</dd>
3645 <dt>HTTP_AUTH_NEGOTIATE
<span class=
"info"> CUPS
1.3/Mac OS X
10.5 </span></dt>
3646 <dd class=
"description">GSSAPI authentication in use
</dd>
3647 <dt>HTTP_AUTH_NONE
</dt>
3648 <dd class=
"description">No authentication in use
</dd>
3650 <h3 class=
"enumeration"><a name=
"http_encoding_e">http_encoding_e
</a></h3>
3651 <p class=
"description">HTTP transfer encoding values
</p>
3652 <h4 class=
"constants">Constants
</h4>
3654 <dt>HTTP_ENCODE_CHUNKED
</dt>
3655 <dd class=
"description">Data is chunked
</dd>
3656 <dt>HTTP_ENCODE_FIELDS
</dt>
3657 <dd class=
"description">Sending HTTP fields
</dd>
3658 <dt>HTTP_ENCODE_LENGTH
</dt>
3659 <dd class=
"description">Data is sent with Content-Length
</dd>
3661 <h3 class=
"enumeration"><a name=
"http_encryption_e">http_encryption_e
</a></h3>
3662 <p class=
"description">HTTP encryption values
</p>
3663 <h4 class=
"constants">Constants
</h4>
3665 <dt>HTTP_ENCRYPT_ALWAYS
</dt>
3666 <dd class=
"description">Always encrypt (SSL)
</dd>
3667 <dt>HTTP_ENCRYPT_IF_REQUESTED
</dt>
3668 <dd class=
"description">Encrypt if requested (TLS upgrade)
</dd>
3669 <dt>HTTP_ENCRYPT_NEVER
</dt>
3670 <dd class=
"description">Never encrypt
</dd>
3671 <dt>HTTP_ENCRYPT_REQUIRED
</dt>
3672 <dd class=
"description">Encryption is required (TLS upgrade)
</dd>
3674 <h3 class=
"enumeration"><a name=
"http_field_e">http_field_e
</a></h3>
3675 <p class=
"description">HTTP field names
</p>
3676 <h4 class=
"constants">Constants
</h4>
3678 <dt>HTTP_FIELD_ACCEPT_LANGUAGE
</dt>
3679 <dd class=
"description">Accept-Language field
</dd>
3680 <dt>HTTP_FIELD_ACCEPT_RANGES
</dt>
3681 <dd class=
"description">Accept-Ranges field
</dd>
3682 <dt>HTTP_FIELD_AUTHORIZATION
</dt>
3683 <dd class=
"description">Authorization field
</dd>
3684 <dt>HTTP_FIELD_CONNECTION
</dt>
3685 <dd class=
"description">Connection field
</dd>
3686 <dt>HTTP_FIELD_CONTENT_ENCODING
</dt>
3687 <dd class=
"description">Content-Encoding field
</dd>
3688 <dt>HTTP_FIELD_CONTENT_LANGUAGE
</dt>
3689 <dd class=
"description">Content-Language field
</dd>
3690 <dt>HTTP_FIELD_CONTENT_LENGTH
</dt>
3691 <dd class=
"description">Content-Length field
</dd>
3692 <dt>HTTP_FIELD_CONTENT_LOCATION
</dt>
3693 <dd class=
"description">Content-Location field
</dd>
3694 <dt>HTTP_FIELD_CONTENT_MD5
</dt>
3695 <dd class=
"description">Content-MD5 field
</dd>
3696 <dt>HTTP_FIELD_CONTENT_RANGE
</dt>
3697 <dd class=
"description">Content-Range field
</dd>
3698 <dt>HTTP_FIELD_CONTENT_TYPE
</dt>
3699 <dd class=
"description">Content-Type field
</dd>
3700 <dt>HTTP_FIELD_CONTENT_VERSION
</dt>
3701 <dd class=
"description">Content-Version field
</dd>
3702 <dt>HTTP_FIELD_DATE
</dt>
3703 <dd class=
"description">Date field
</dd>
3704 <dt>HTTP_FIELD_HOST
</dt>
3705 <dd class=
"description">Host field
</dd>
3706 <dt>HTTP_FIELD_IF_MODIFIED_SINCE
</dt>
3707 <dd class=
"description">If-Modified-Since field
</dd>
3708 <dt>HTTP_FIELD_IF_UNMODIFIED_SINCE
</dt>
3709 <dd class=
"description">If-Unmodified-Since field
</dd>
3710 <dt>HTTP_FIELD_KEEP_ALIVE
</dt>
3711 <dd class=
"description">Keep-Alive field
</dd>
3712 <dt>HTTP_FIELD_LAST_MODIFIED
</dt>
3713 <dd class=
"description">Last-Modified field
</dd>
3714 <dt>HTTP_FIELD_LINK
</dt>
3715 <dd class=
"description">Link field
</dd>
3716 <dt>HTTP_FIELD_LOCATION
</dt>
3717 <dd class=
"description">Location field
</dd>
3718 <dt>HTTP_FIELD_MAX
</dt>
3719 <dd class=
"description">Maximum field index
</dd>
3720 <dt>HTTP_FIELD_RANGE
</dt>
3721 <dd class=
"description">Range field
</dd>
3722 <dt>HTTP_FIELD_REFERER
</dt>
3723 <dd class=
"description">Referer field
</dd>
3724 <dt>HTTP_FIELD_RETRY_AFTER
</dt>
3725 <dd class=
"description">Retry-After field
</dd>
3726 <dt>HTTP_FIELD_TRANSFER_ENCODING
</dt>
3727 <dd class=
"description">Transfer-Encoding field
</dd>
3728 <dt>HTTP_FIELD_UNKNOWN
</dt>
3729 <dd class=
"description">Unknown field
</dd>
3730 <dt>HTTP_FIELD_UPGRADE
</dt>
3731 <dd class=
"description">Upgrade field
</dd>
3732 <dt>HTTP_FIELD_USER_AGENT
</dt>
3733 <dd class=
"description">User-Agent field
</dd>
3734 <dt>HTTP_FIELD_WWW_AUTHENTICATE
</dt>
3735 <dd class=
"description">WWW-Authenticate field
</dd>
3737 <h3 class=
"enumeration"><a name=
"http_keepalive_e">http_keepalive_e
</a></h3>
3738 <p class=
"description">HTTP keep-alive values
</p>
3739 <h4 class=
"constants">Constants
</h4>
3741 <dt>HTTP_KEEPALIVE_OFF
</dt>
3742 <dd class=
"description">No keep alive support
</dd>
3743 <dt>HTTP_KEEPALIVE_ON
</dt>
3744 <dd class=
"description">Use keep alive
</dd>
3746 <h3 class=
"enumeration"><a name=
"http_state_e">http_state_e
</a></h3>
3747 <p class=
"description">HTTP state values; states
3748 are server-oriented...
</p>
3749 <h4 class=
"constants">Constants
</h4>
3751 <dt>HTTP_CLOSE
</dt>
3752 <dd class=
"description">CLOSE command, waiting for blank line
</dd>
3753 <dt>HTTP_DELETE
</dt>
3754 <dd class=
"description">DELETE command, waiting for blank line
</dd>
3756 <dd class=
"description">GET command, waiting for blank line
</dd>
3757 <dt>HTTP_GET_SEND
</dt>
3758 <dd class=
"description">GET command, sending data
</dd>
3760 <dd class=
"description">HEAD command, waiting for blank line
</dd>
3761 <dt>HTTP_OPTIONS
</dt>
3762 <dd class=
"description">OPTIONS command, waiting for blank line
</dd>
3764 <dd class=
"description">POST command, waiting for blank line
</dd>
3765 <dt>HTTP_POST_RECV
</dt>
3766 <dd class=
"description">POST command, receiving data
</dd>
3767 <dt>HTTP_POST_SEND
</dt>
3768 <dd class=
"description">POST command, sending data
</dd>
3770 <dd class=
"description">PUT command, waiting for blank line
</dd>
3771 <dt>HTTP_PUT_RECV
</dt>
3772 <dd class=
"description">PUT command, receiving data
</dd>
3773 <dt>HTTP_STATUS
</dt>
3774 <dd class=
"description">Command complete, sending status
</dd>
3775 <dt>HTTP_TRACE
</dt>
3776 <dd class=
"description">TRACE command, waiting for blank line
</dd>
3777 <dt>HTTP_WAITING
</dt>
3778 <dd class=
"description">Waiting for command
</dd>
3780 <h3 class=
"enumeration"><a name=
"http_status_e">http_status_e
</a></h3>
3781 <p class=
"description">HTTP status codes
</p>
3782 <h4 class=
"constants">Constants
</h4>
3784 <dt>HTTP_ACCEPTED
</dt>
3785 <dd class=
"description">DELETE command was successful
</dd>
3786 <dt>HTTP_AUTHORIZATION_CANCELED
<span class=
"info"> CUPS
1.4 </span></dt>
3787 <dd class=
"description">User canceled authorization
</dd>
3788 <dt>HTTP_BAD_GATEWAY
</dt>
3789 <dd class=
"description">Bad gateway
</dd>
3790 <dt>HTTP_BAD_REQUEST
</dt>
3791 <dd class=
"description">Bad request
</dd>
3792 <dt>HTTP_CONFLICT
</dt>
3793 <dd class=
"description">Request is self-conflicting
</dd>
3794 <dt>HTTP_CONTINUE
</dt>
3795 <dd class=
"description">Everything OK, keep going...
</dd>
3796 <dt>HTTP_CREATED
</dt>
3797 <dd class=
"description">PUT command was successful
</dd>
3798 <dt>HTTP_ERROR
</dt>
3799 <dd class=
"description">An error response from httpXxxx()
</dd>
3800 <dt>HTTP_EXPECTATION_FAILED
</dt>
3801 <dd class=
"description">The expectation given in an Expect header field was not met
</dd>
3802 <dt>HTTP_FORBIDDEN
</dt>
3803 <dd class=
"description">Forbidden to access this URI
</dd>
3804 <dt>HTTP_GATEWAY_TIMEOUT
</dt>
3805 <dd class=
"description">Gateway connection timed out
</dd>
3807 <dd class=
"description">Server has gone away
</dd>
3808 <dt>HTTP_LENGTH_REQUIRED
</dt>
3809 <dd class=
"description">A content length or encoding is required
</dd>
3810 <dt>HTTP_METHOD_NOT_ALLOWED
</dt>
3811 <dd class=
"description">Method is not allowed
</dd>
3812 <dt>HTTP_MOVED_PERMANENTLY
</dt>
3813 <dd class=
"description">Document has moved permanently
</dd>
3814 <dt>HTTP_MOVED_TEMPORARILY
</dt>
3815 <dd class=
"description">Document has moved temporarily
</dd>
3816 <dt>HTTP_MULTIPLE_CHOICES
</dt>
3817 <dd class=
"description">Multiple files match request
</dd>
3818 <dt>HTTP_NOT_ACCEPTABLE
</dt>
3819 <dd class=
"description">Not Acceptable
</dd>
3820 <dt>HTTP_NOT_AUTHORITATIVE
</dt>
3821 <dd class=
"description">Information isn't authoritative
</dd>
3822 <dt>HTTP_NOT_FOUND
</dt>
3823 <dd class=
"description">URI was not found
</dd>
3824 <dt>HTTP_NOT_IMPLEMENTED
</dt>
3825 <dd class=
"description">Feature not implemented
</dd>
3826 <dt>HTTP_NOT_MODIFIED
</dt>
3827 <dd class=
"description">File not modified
</dd>
3828 <dt>HTTP_NOT_SUPPORTED
</dt>
3829 <dd class=
"description">HTTP version not supported
</dd>
3830 <dt>HTTP_NO_CONTENT
</dt>
3831 <dd class=
"description">Successful command, no new data
</dd>
3833 <dd class=
"description">OPTIONS/GET/HEAD/POST/TRACE command was successful
</dd>
3834 <dt>HTTP_PARTIAL_CONTENT
</dt>
3835 <dd class=
"description">Only a partial file was recieved/sent
</dd>
3836 <dt>HTTP_PAYMENT_REQUIRED
</dt>
3837 <dd class=
"description">Payment required
</dd>
3838 <dt>HTTP_PKI_ERROR
<span class=
"info"> CUPS
1.5/Mac OS X
10.7 </span></dt>
3839 <dd class=
"description">Error negotiating a secure connection
</dd>
3840 <dt>HTTP_PRECONDITION
</dt>
3841 <dd class=
"description">Precondition failed
</dd>
3842 <dt>HTTP_PROXY_AUTHENTICATION
</dt>
3843 <dd class=
"description">Proxy Authentication is Required
</dd>
3844 <dt>HTTP_REQUESTED_RANGE
</dt>
3845 <dd class=
"description">The requested range is not satisfiable
</dd>
3846 <dt>HTTP_REQUEST_TIMEOUT
</dt>
3847 <dd class=
"description">Request timed out
</dd>
3848 <dt>HTTP_REQUEST_TOO_LARGE
</dt>
3849 <dd class=
"description">Request entity too large
</dd>
3850 <dt>HTTP_RESET_CONTENT
</dt>
3851 <dd class=
"description">Content was reset/recreated
</dd>
3852 <dt>HTTP_SEE_OTHER
</dt>
3853 <dd class=
"description">See this other link...
</dd>
3854 <dt>HTTP_SERVER_ERROR
</dt>
3855 <dd class=
"description">Internal server error
</dd>
3856 <dt>HTTP_SERVICE_UNAVAILABLE
</dt>
3857 <dd class=
"description">Service is unavailable
</dd>
3858 <dt>HTTP_SWITCHING_PROTOCOLS
</dt>
3859 <dd class=
"description">HTTP upgrade to TLS/SSL
</dd>
3860 <dt>HTTP_UNAUTHORIZED
</dt>
3861 <dd class=
"description">Unauthorized to access host
</dd>
3862 <dt>HTTP_UNSUPPORTED_MEDIATYPE
</dt>
3863 <dd class=
"description">The requested media type is unsupported
</dd>
3864 <dt>HTTP_UPGRADE_REQUIRED
</dt>
3865 <dd class=
"description">Upgrade to SSL/TLS required
</dd>
3866 <dt>HTTP_URI_TOO_LONG
</dt>
3867 <dd class=
"description">URI too long
</dd>
3868 <dt>HTTP_USE_PROXY
</dt>
3869 <dd class=
"description">Must use a proxy to access this URI
</dd>
3871 <h3 class=
"enumeration"><a name=
"http_uri_coding_e">http_uri_coding_e
</a></h3>
3872 <p class=
"description">URI en/decode flags
</p>
3873 <h4 class=
"constants">Constants
</h4>
3875 <dt>HTTP_URI_CODING_ALL
</dt>
3876 <dd class=
"description">En/decode everything
</dd>
3877 <dt>HTTP_URI_CODING_HOSTNAME
</dt>
3878 <dd class=
"description">En/decode the hostname portion
</dd>
3879 <dt>HTTP_URI_CODING_MOST
</dt>
3880 <dd class=
"description">En/decode all but the query
</dd>
3881 <dt>HTTP_URI_CODING_NONE
</dt>
3882 <dd class=
"description">Don't en/decode anything
</dd>
3883 <dt>HTTP_URI_CODING_QUERY
</dt>
3884 <dd class=
"description">En/decode the query portion
</dd>
3885 <dt>HTTP_URI_CODING_RESOURCE
</dt>
3886 <dd class=
"description">En/decode the resource portion
</dd>
3887 <dt>HTTP_URI_CODING_USERNAME
</dt>
3888 <dd class=
"description">En/decode the username portion
</dd>
3890 <h3 class=
"enumeration"><span class=
"info"> CUPS
1.2 </span><a name=
"http_uri_status_e">http_uri_status_e
</a></h3>
3891 <p class=
"description">URI separation status
</p>
3892 <h4 class=
"constants">Constants
</h4>
3894 <dt>HTTP_URI_BAD_ARGUMENTS
</dt>
3895 <dd class=
"description">Bad arguments to function (error)
</dd>
3896 <dt>HTTP_URI_BAD_HOSTNAME
</dt>
3897 <dd class=
"description">Bad hostname in URI (error)
</dd>
3898 <dt>HTTP_URI_BAD_PORT
</dt>
3899 <dd class=
"description">Bad port number in URI (error)
</dd>
3900 <dt>HTTP_URI_BAD_RESOURCE
</dt>
3901 <dd class=
"description">Bad resource in URI (error)
</dd>
3902 <dt>HTTP_URI_BAD_SCHEME
</dt>
3903 <dd class=
"description">Bad scheme in URI (error)
</dd>
3904 <dt>HTTP_URI_BAD_URI
</dt>
3905 <dd class=
"description">Bad/empty URI (error)
</dd>
3906 <dt>HTTP_URI_BAD_USERNAME
</dt>
3907 <dd class=
"description">Bad username in URI (error)
</dd>
3908 <dt>HTTP_URI_MISSING_RESOURCE
</dt>
3909 <dd class=
"description">Missing resource in URI (warning)
</dd>
3910 <dt>HTTP_URI_MISSING_SCHEME
</dt>
3911 <dd class=
"description">Missing scheme in URI (warning)
</dd>
3912 <dt>HTTP_URI_OK
</dt>
3913 <dd class=
"description">URI decoded OK
</dd>
3914 <dt>HTTP_URI_OVERFLOW
</dt>
3915 <dd class=
"description">URI buffer for httpAssembleURI is too small
</dd>
3916 <dt>HTTP_URI_UNKNOWN_SCHEME
</dt>
3917 <dd class=
"description">Unknown scheme in URI (warning)
</dd>
3919 <h3 class=
"enumeration"><a name=
"http_version_e">http_version_e
</a></h3>
3920 <p class=
"description">HTTP version numbers
</p>
3921 <h4 class=
"constants">Constants
</h4>
3924 <dd class=
"description">HTTP/
0.9</dd>
3926 <dd class=
"description">HTTP/
1.0</dd>
3928 <dd class=
"description">HTTP/
1.1</dd>
3930 <h3 class=
"enumeration"><a name=
"ipp_finish_e">ipp_finish_e
</a></h3>
3931 <p class=
"description">Finishings
</p>
3932 <h4 class=
"constants">Constants
</h4>
3934 <dt>IPP_FINISHINGS_BALE
</dt>
3935 <dd class=
"description">Bale (any type)
</dd>
3936 <dt>IPP_FINISHINGS_BIND
</dt>
3937 <dd class=
"description">Bind
</dd>
3938 <dt>IPP_FINISHINGS_BIND_BOTTOM
</dt>
3939 <dd class=
"description">Bind on bottom
</dd>
3940 <dt>IPP_FINISHINGS_BIND_LEFT
</dt>
3941 <dd class=
"description">Bind on left
</dd>
3942 <dt>IPP_FINISHINGS_BIND_RIGHT
</dt>
3943 <dd class=
"description">Bind on right
</dd>
3944 <dt>IPP_FINISHINGS_BIND_TOP
</dt>
3945 <dd class=
"description">Bind on top
</dd>
3946 <dt>IPP_FINISHINGS_BOOKLET_MAKER
</dt>
3947 <dd class=
"description">Fold to make booklet
</dd>
3948 <dt>IPP_FINISHINGS_COVER
</dt>
3949 <dd class=
"description">Add cover
</dd>
3950 <dt>IPP_FINISHINGS_EDGE_STITCH
</dt>
3951 <dd class=
"description">Stitch along any side
</dd>
3952 <dt>IPP_FINISHINGS_EDGE_STITCH_BOTTOM
</dt>
3953 <dd class=
"description">Stitch along bottom edge
</dd>
3954 <dt>IPP_FINISHINGS_EDGE_STITCH_LEFT
</dt>
3955 <dd class=
"description">Stitch along left side
</dd>
3956 <dt>IPP_FINISHINGS_EDGE_STITCH_RIGHT
</dt>
3957 <dd class=
"description">Stitch along right side
</dd>
3958 <dt>IPP_FINISHINGS_EDGE_STITCH_TOP
</dt>
3959 <dd class=
"description">Stitch along top edge
</dd>
3960 <dt>IPP_FINISHINGS_FOLD
</dt>
3961 <dd class=
"description">Fold (any type)
</dd>
3962 <dt>IPP_FINISHINGS_JOB_OFFSET
</dt>
3963 <dd class=
"description">Offset for binding (any type)
</dd>
3964 <dt>IPP_FINISHINGS_NONE
</dt>
3965 <dd class=
"description">No finishing
</dd>
3966 <dt>IPP_FINISHINGS_PUNCH
</dt>
3967 <dd class=
"description">Punch (any location/count)
</dd>
3968 <dt>IPP_FINISHINGS_SADDLE_STITCH
</dt>
3969 <dd class=
"description">Staple interior
</dd>
3970 <dt>IPP_FINISHINGS_STAPLE
</dt>
3971 <dd class=
"description">Staple (any location)
</dd>
3972 <dt>IPP_FINISHINGS_STAPLE_BOTTOM_LEFT
</dt>
3973 <dd class=
"description">Staple bottom left corner
</dd>
3974 <dt>IPP_FINISHINGS_STAPLE_BOTTOM_RIGHT
</dt>
3975 <dd class=
"description">Staple bottom right corner
</dd>
3976 <dt>IPP_FINISHINGS_STAPLE_DUAL_BOTTOM
</dt>
3977 <dd class=
"description">Two staples on bottom
</dd>
3978 <dt>IPP_FINISHINGS_STAPLE_DUAL_LEFT
</dt>
3979 <dd class=
"description">Two staples on left
</dd>
3980 <dt>IPP_FINISHINGS_STAPLE_DUAL_RIGHT
</dt>
3981 <dd class=
"description">Two staples on right
</dd>
3982 <dt>IPP_FINISHINGS_STAPLE_DUAL_TOP
</dt>
3983 <dd class=
"description">Two staples on top
</dd>
3984 <dt>IPP_FINISHINGS_STAPLE_TOP_LEFT
</dt>
3985 <dd class=
"description">Staple top left corner
</dd>
3986 <dt>IPP_FINISHINGS_STAPLE_TOP_RIGHT
</dt>
3987 <dd class=
"description">Staple top right corner
</dd>
3988 <dt>IPP_FINISHINGS_TRIM
</dt>
3989 <dd class=
"description">Trim (any type)
</dd>
3991 <h3 class=
"enumeration"><a name=
"ipp_jstate_e">ipp_jstate_e
</a></h3>
3992 <p class=
"description">Job states
</p>
3993 <h4 class=
"constants">Constants
</h4>
3995 <dt>IPP_JOB_ABORTED
</dt>
3996 <dd class=
"description">Job has aborted due to error
</dd>
3997 <dt>IPP_JOB_CANCELED
</dt>
3998 <dd class=
"description">Job has been canceled
</dd>
3999 <dt>IPP_JOB_COMPLETED
</dt>
4000 <dd class=
"description">Job has completed successfully
</dd>
4001 <dt>IPP_JOB_HELD
</dt>
4002 <dd class=
"description">Job is held for printing
</dd>
4003 <dt>IPP_JOB_PENDING
</dt>
4004 <dd class=
"description">Job is waiting to be printed
</dd>
4005 <dt>IPP_JOB_PROCESSING
</dt>
4006 <dd class=
"description">Job is currently printing
</dd>
4007 <dt>IPP_JOB_STOPPED
</dt>
4008 <dd class=
"description">Job has been stopped
</dd>
4010 <h3 class=
"enumeration"><a name=
"ipp_op_e">ipp_op_e
</a></h3>
4011 <p class=
"description">IPP operations
</p>
4012 <h4 class=
"constants">Constants
</h4>
4014 <dt>CUPS_ACCEPT_JOBS
</dt>
4015 <dd class=
"description">Accept new jobs on a printer
</dd>
4016 <dt>CUPS_ADD_MODIFY_CLASS
</dt>
4017 <dd class=
"description">Add or modify a class
</dd>
4018 <dt>CUPS_ADD_MODIFY_PRINTER
</dt>
4019 <dd class=
"description">Add or modify a printer
</dd>
4020 <dt>CUPS_AUTHENTICATE_JOB
<span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span></dt>
4021 <dd class=
"description">Authenticate a job
</dd>
4022 <dt>CUPS_DELETE_CLASS
</dt>
4023 <dd class=
"description">Delete a class
</dd>
4024 <dt>CUPS_DELETE_PRINTER
</dt>
4025 <dd class=
"description">Delete a printer
</dd>
4026 <dt>CUPS_GET_CLASSES
<span class=
"info"> DEPRECATED
</span></dt>
4027 <dd class=
"description">Get a list of classes
</dd>
4028 <dt>CUPS_GET_DEFAULT
</dt>
4029 <dd class=
"description">Get the default printer
</dd>
4030 <dt>CUPS_GET_DEVICES
</dt>
4031 <dd class=
"description">Get a list of supported devices
</dd>
4032 <dt>CUPS_GET_DOCUMENT
<span class=
"info"> CUPS
1.4/Mac OS X
10.6 </span></dt>
4033 <dd class=
"description">Get a document file
</dd>
4034 <dt>CUPS_GET_PPD
<span class=
"info"> CUPS
1.3/Mac OS X
10.5 </span></dt>
4035 <dd class=
"description">Get a PPD file
</dd>
4036 <dt>CUPS_GET_PPDS
</dt>
4037 <dd class=
"description">Get a list of supported drivers
</dd>
4038 <dt>CUPS_GET_PRINTERS
</dt>
4039 <dd class=
"description">Get a list of printers and/or classes
</dd>
4040 <dt>CUPS_MOVE_JOB
</dt>
4041 <dd class=
"description">Move a job to a different printer
</dd>
4042 <dt>CUPS_REJECT_JOBS
</dt>
4043 <dd class=
"description">Reject new jobs on a printer
</dd>
4044 <dt>CUPS_SET_DEFAULT
</dt>
4045 <dd class=
"description">Set the default printer
</dd>
4046 <dt>IPP_CANCEL_JOB
</dt>
4047 <dd class=
"description">Cancel a job
</dd>
4048 <dt>IPP_CANCEL_JOBS
</dt>
4049 <dd class=
"description">Cancel-Jobs
</dd>
4050 <dt>IPP_CANCEL_MY_JOBS
</dt>
4051 <dd class=
"description">Cancel-My-Jobs
</dd>
4052 <dt>IPP_CANCEL_SUBSCRIPTION
<span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span></dt>
4053 <dd class=
"description">Cancel a subscription
</dd>
4054 <dt>IPP_CLOSE_JOB
</dt>
4055 <dd class=
"description">Close-Job
</dd>
4056 <dt>IPP_CREATE_JOB
</dt>
4057 <dd class=
"description">Create an empty print job
</dd>
4058 <dt>IPP_CREATE_JOB_SUBSCRIPTION
<span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span></dt>
4059 <dd class=
"description">Create a job subscription
</dd>
4060 <dt>IPP_CREATE_PRINTER_SUBSCRIPTION
<span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span></dt>
4061 <dd class=
"description">Create a printer subscription
</dd>
4062 <dt>IPP_DISABLE_PRINTER
</dt>
4063 <dd class=
"description">Stop a printer
</dd>
4064 <dt>IPP_ENABLE_PRINTER
</dt>
4065 <dd class=
"description">Start a printer
</dd>
4066 <dt>IPP_GET_JOBS
</dt>
4067 <dd class=
"description">Get a list of jobs
</dd>
4068 <dt>IPP_GET_JOB_ATTRIBUTES
</dt>
4069 <dd class=
"description">Get job attributes
</dd>
4070 <dt>IPP_GET_NOTIFICATIONS
<span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span></dt>
4071 <dd class=
"description">Get notification events
</dd>
4072 <dt>IPP_GET_PRINTER_ATTRIBUTES
</dt>
4073 <dd class=
"description">Get printer attributes
</dd>
4074 <dt>IPP_GET_PRINTER_SUPPORTED_VALUES
</dt>
4075 <dd class=
"description">Get supported attribute values
</dd>
4076 <dt>IPP_GET_SUBSCRIPTIONS
<span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span></dt>
4077 <dd class=
"description">Get list of subscriptions
</dd>
4078 <dt>IPP_GET_SUBSCRIPTION_ATTRIBUTES
<span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span></dt>
4079 <dd class=
"description">Get subscription attributes
</dd>
4080 <dt>IPP_HOLD_JOB
</dt>
4081 <dd class=
"description">Hold a job for printing
</dd>
4082 <dt>IPP_PAUSE_PRINTER
</dt>
4083 <dd class=
"description">Stop a printer
</dd>
4084 <dt>IPP_PRINT_JOB
</dt>
4085 <dd class=
"description">Print a single file
</dd>
4086 <dt>IPP_PURGE_JOBS
</dt>
4087 <dd class=
"description">Cancel all jobs
</dd>
4088 <dt>IPP_RELEASE_JOB
</dt>
4089 <dd class=
"description">Release a job for printing
</dd>
4090 <dt>IPP_RENEW_SUBSCRIPTION
<span class=
"info"> CUPS
1.2/Mac OS X
10.5 </span></dt>
4091 <dd class=
"description">Renew a printer subscription
</dd>
4092 <dt>IPP_RESTART_JOB
</dt>
4093 <dd class=
"description">Reprint a job
</dd>
4094 <dt>IPP_RESUBMIT_JOB
</dt>
4095 <dd class=
"description">Resubmit-Job
</dd>
4096 <dt>IPP_RESUME_PRINTER
</dt>
4097 <dd class=
"description">Start a printer
</dd>
4098 <dt>IPP_SEND_DOCUMENT
</dt>
4099 <dd class=
"description">Add a file to a job
</dd>
4100 <dt>IPP_SET_JOB_ATTRIBUTES
</dt>
4101 <dd class=
"description">Set job attributes
</dd>
4102 <dt>IPP_VALIDATE_JOB
</dt>
4103 <dd class=
"description">Validate job options
</dd>
4105 <h3 class=
"enumeration"><a name=
"ipp_orient_e">ipp_orient_e
</a></h3>
4106 <p class=
"description">Orientation values
</p>
4107 <h4 class=
"constants">Constants
</h4>
4109 <dt>IPP_LANDSCAPE
</dt>
4110 <dd class=
"description">90 degrees counter-clockwise
</dd>
4111 <dt>IPP_PORTRAIT
</dt>
4112 <dd class=
"description">No rotation
</dd>
4113 <dt>IPP_REVERSE_LANDSCAPE
</dt>
4114 <dd class=
"description">90 degrees clockwise
</dd>
4115 <dt>IPP_REVERSE_PORTRAIT
</dt>
4116 <dd class=
"description">180 degrees
</dd>
4118 <h3 class=
"enumeration"><a name=
"ipp_pstate_e">ipp_pstate_e
</a></h3>
4119 <p class=
"description">Printer states
</p>
4120 <h4 class=
"constants">Constants
</h4>
4122 <dt>IPP_PRINTER_IDLE
</dt>
4123 <dd class=
"description">Printer is idle
</dd>
4124 <dt>IPP_PRINTER_PROCESSING
</dt>
4125 <dd class=
"description">Printer is working
</dd>
4126 <dt>IPP_PRINTER_STOPPED
</dt>
4127 <dd class=
"description">Printer is stopped
</dd>
4129 <h3 class=
"enumeration"><a name=
"ipp_quality_e">ipp_quality_e
</a></h3>
4130 <p class=
"description">Qualities
</p>
4131 <h4 class=
"constants">Constants
</h4>
4133 <dt>IPP_QUALITY_DRAFT
</dt>
4134 <dd class=
"description">Draft quality
</dd>
4135 <dt>IPP_QUALITY_HIGH
</dt>
4136 <dd class=
"description">High quality
</dd>
4137 <dt>IPP_QUALITY_NORMAL
</dt>
4138 <dd class=
"description">Normal quality
</dd>
4140 <h3 class=
"enumeration"><a name=
"ipp_res_e">ipp_res_e
</a></h3>
4141 <p class=
"description">Resolution units
</p>
4142 <h4 class=
"constants">Constants
</h4>
4144 <dt>IPP_RES_PER_CM
</dt>
4145 <dd class=
"description">Pixels per centimeter
</dd>
4146 <dt>IPP_RES_PER_INCH
</dt>
4147 <dd class=
"description">Pixels per inch
</dd>
4149 <h3 class=
"enumeration"><a name=
"ipp_state_e">ipp_state_e
</a></h3>
4150 <p class=
"description">IPP states
</p>
4151 <h4 class=
"constants">Constants
</h4>
4153 <dt>IPP_ATTRIBUTE
</dt>
4154 <dd class=
"description">One or more attributes need to be sent/received
</dd>
4156 <dd class=
"description">IPP request data needs to be sent/received
</dd>
4158 <dd class=
"description">An error occurred
</dd>
4159 <dt>IPP_HEADER
</dt>
4160 <dd class=
"description">The request header needs to be sent/received
</dd>
4162 <dd class=
"description">Nothing is happening/request completed
</dd>
4164 <h3 class=
"enumeration"><a name=
"ipp_status_e">ipp_status_e
</a></h3>
4165 <p class=
"description">IPP status codes
</p>
4166 <h4 class=
"constants">Constants
</h4>
4168 <dt>CUPS_SEE_OTHER
</dt>
4169 <dd class=
"description">cups-see-other
</dd>
4170 <dt>IPP_ATTRIBUTES
</dt>
4171 <dd class=
"description">client-error-attributes-or-values-not-supported
</dd>
4172 <dt>IPP_ATTRIBUTES_NOT_SETTABLE
</dt>
4173 <dd class=
"description">client-error-attributes-not-settable
</dd>
4174 <dt>IPP_AUTHENTICATION_CANCELED
<span class=
"info"> CUPS
1.5/Mac OS X
10.7 </span></dt>
4175 <dd class=
"description">Authentication canceled by user
</dd>
4176 <dt>IPP_BAD_REQUEST
</dt>
4177 <dd class=
"description">client-error-bad-request
</dd>
4178 <dt>IPP_CHARSET
</dt>
4179 <dd class=
"description">client-error-charset-not-supported
</dd>
4180 <dt>IPP_COMPRESSION_ERROR
</dt>
4181 <dd class=
"description">client-error-compression-error
</dd>
4182 <dt>IPP_COMPRESSION_NOT_SUPPORTED
</dt>
4183 <dd class=
"description">client-error-compression-not-supported
</dd>
4184 <dt>IPP_CONFLICT
</dt>
4185 <dd class=
"description">client-error-conflicting-attributes
</dd>
4186 <dt>IPP_DEVICE_ERROR
</dt>
4187 <dd class=
"description">server-error-device-error
</dd>
4188 <dt>IPP_DOCUMENT_ACCESS_ERROR
</dt>
4189 <dd class=
"description">client-error-document-access-error
</dd>
4190 <dt>IPP_DOCUMENT_FORMAT
</dt>
4191 <dd class=
"description">client-error-document-format-not-supported
</dd>
4192 <dt>IPP_DOCUMENT_FORMAT_ERROR
</dt>
4193 <dd class=
"description">client-error-document-format-error
</dd>
4194 <dt>IPP_ERROR_JOB_CANCELED
</dt>
4195 <dd class=
"description">server-error-job-canceled
</dd>
4196 <dt>IPP_FORBIDDEN
</dt>
4197 <dd class=
"description">client-error-forbidden
</dd>
4199 <dd class=
"description">client-error-gone
</dd>
4200 <dt>IPP_IGNORED_ALL_NOTIFICATIONS
</dt>
4201 <dd class=
"description">client-error-ignored-all-notifications
</dd>
4202 <dt>IPP_IGNORED_ALL_SUBSCRIPTIONS
</dt>
4203 <dd class=
"description">client-error-ignored-all-subscriptions
</dd>
4204 <dt>IPP_INTERNAL_ERROR
</dt>
4205 <dd class=
"description">server-error-internal-error
</dd>
4206 <dt>IPP_MULTIPLE_JOBS_NOT_SUPPORTED
</dt>
4207 <dd class=
"description">server-error-multiple-document-jobs-not-supported
</dd>
4208 <dt>IPP_NOT_ACCEPTING
</dt>
4209 <dd class=
"description">server-error-not-accepting-jobs
</dd>
4210 <dt>IPP_NOT_AUTHENTICATED
</dt>
4211 <dd class=
"description">client-error-not-authenticated
</dd>
4212 <dt>IPP_NOT_AUTHORIZED
</dt>
4213 <dd class=
"description">client-error-not-authorized
</dd>
4214 <dt>IPP_NOT_FOUND
</dt>
4215 <dd class=
"description">client-error-not-found
</dd>
4216 <dt>IPP_NOT_POSSIBLE
</dt>
4217 <dd class=
"description">client-error-not-possible
</dd>
4219 <dd class=
"description">successful-ok
</dd>
4220 <dt>IPP_OK_BUT_CANCEL_SUBSCRIPTION
</dt>
4221 <dd class=
"description">successful-ok-but-cancel-subscription
</dd>
4222 <dt>IPP_OK_CONFLICT
</dt>
4223 <dd class=
"description">successful-ok-conflicting-attributes
</dd>
4224 <dt>IPP_OK_EVENTS_COMPLETE
</dt>
4225 <dd class=
"description">successful-ok-events-complete
</dd>
4226 <dt>IPP_OK_IGNORED_NOTIFICATIONS
</dt>
4227 <dd class=
"description">successful-ok-ignored-notifications
</dd>
4228 <dt>IPP_OK_IGNORED_SUBSCRIPTIONS
</dt>
4229 <dd class=
"description">successful-ok-ignored-subscriptions
</dd>
4230 <dt>IPP_OK_SUBST
</dt>
4231 <dd class=
"description">successful-ok-ignored-or-substituted-attributes
</dd>
4232 <dt>IPP_OK_TOO_MANY_EVENTS
</dt>
4233 <dd class=
"description">successful-ok-too-many-events
</dd>
4234 <dt>IPP_OPERATION_NOT_SUPPORTED
</dt>
4235 <dd class=
"description">server-error-operation-not-supported
</dd>
4236 <dt>IPP_PKI_ERROR
<span class=
"info"> CUPS
1.5/Mac OS X
10.7 </span></dt>
4237 <dd class=
"description">Error negotiating a secure connection
</dd>
4238 <dt>IPP_PRINTER_BUSY
</dt>
4239 <dd class=
"description">server-error-busy
</dd>
4240 <dt>IPP_PRINTER_IS_DEACTIVATED
</dt>
4241 <dd class=
"description">server-error-printer-is-deactivated
</dd>
4242 <dt>IPP_PRINT_SUPPORT_FILE_NOT_FOUND
</dt>
4243 <dd class=
"description">client-error-print-support-file-not-found
</dd>
4244 <dt>IPP_REQUEST_ENTITY
</dt>
4245 <dd class=
"description">client-error-request-entity-too-large
</dd>
4246 <dt>IPP_REQUEST_VALUE
</dt>
4247 <dd class=
"description">client-error-request-value-too-long
</dd>
4248 <dt>IPP_SERVICE_UNAVAILABLE
</dt>
4249 <dd class=
"description">server-error-service-unavailable
</dd>
4250 <dt>IPP_TEMPORARY_ERROR
</dt>
4251 <dd class=
"description">server-error-temporary-error
</dd>
4252 <dt>IPP_TIMEOUT
</dt>
4253 <dd class=
"description">client-error-timeout
</dd>
4254 <dt>IPP_TOO_MANY_SUBSCRIPTIONS
</dt>
4255 <dd class=
"description">client-error-too-many-subscriptions
</dd>
4256 <dt>IPP_UPGRADE_REQUIRED
</dt>
4257 <dd class=
"description">TLS upgrade required
</dd>
4258 <dt>IPP_URI_SCHEME
</dt>
4259 <dd class=
"description">client-error-uri-scheme-not-supported
</dd>
4260 <dt>IPP_VERSION_NOT_SUPPORTED
</dt>
4261 <dd class=
"description">server-error-version-not-supported
</dd>
4263 <h3 class=
"enumeration"><a name=
"ipp_tag_e">ipp_tag_e
</a></h3>
4264 <p class=
"description">Format tags for attributes
</p>
4265 <h4 class=
"constants">Constants
</h4>
4267 <dt>IPP_TAG_ADMINDEFINE
</dt>
4268 <dd class=
"description">Admin-defined value
</dd>
4269 <dt>IPP_TAG_BEGIN_COLLECTION
</dt>
4270 <dd class=
"description">Beginning of collection value
</dd>
4271 <dt>IPP_TAG_BOOLEAN
</dt>
4272 <dd class=
"description">Boolean value
</dd>
4273 <dt>IPP_TAG_CHARSET
</dt>
4274 <dd class=
"description">Character set value
</dd>
4275 <dt>IPP_TAG_COPY
</dt>
4276 <dd class=
"description">Bitflag for copied attribute values
</dd>
4277 <dt>IPP_TAG_DATE
</dt>
4278 <dd class=
"description">Date/time value
</dd>
4279 <dt>IPP_TAG_DEFAULT
</dt>
4280 <dd class=
"description">Default value
</dd>
4281 <dt>IPP_TAG_DELETEATTR
</dt>
4282 <dd class=
"description">Delete-attribute value
</dd>
4283 <dt>IPP_TAG_END
</dt>
4284 <dd class=
"description">End-of-attributes
</dd>
4285 <dt>IPP_TAG_END_COLLECTION
</dt>
4286 <dd class=
"description">End of collection value
</dd>
4287 <dt>IPP_TAG_ENUM
</dt>
4288 <dd class=
"description">Enumeration value
</dd>
4289 <dt>IPP_TAG_EVENT_NOTIFICATION
</dt>
4290 <dd class=
"description">Event group
</dd>
4291 <dt>IPP_TAG_INTEGER
</dt>
4292 <dd class=
"description">Integer value
</dd>
4293 <dt>IPP_TAG_JOB
</dt>
4294 <dd class=
"description">Job group
</dd>
4295 <dt>IPP_TAG_KEYWORD
</dt>
4296 <dd class=
"description">Keyword value
</dd>
4297 <dt>IPP_TAG_LANGUAGE
</dt>
4298 <dd class=
"description">Language value
</dd>
4299 <dt>IPP_TAG_MASK
</dt>
4300 <dd class=
"description">Mask for copied attribute values
</dd>
4301 <dt>IPP_TAG_MEMBERNAME
</dt>
4302 <dd class=
"description">Collection member name value
</dd>
4303 <dt>IPP_TAG_MIMETYPE
</dt>
4304 <dd class=
"description">MIME media type value
</dd>
4305 <dt>IPP_TAG_NAME
</dt>
4306 <dd class=
"description">Name value
</dd>
4307 <dt>IPP_TAG_NAMELANG
</dt>
4308 <dd class=
"description">Name-with-language value
</dd>
4309 <dt>IPP_TAG_NOTSETTABLE
</dt>
4310 <dd class=
"description">Not-settable value
</dd>
4311 <dt>IPP_TAG_NOVALUE
</dt>
4312 <dd class=
"description">No-value value
</dd>
4313 <dt>IPP_TAG_OPERATION
</dt>
4314 <dd class=
"description">Operation group
</dd>
4315 <dt>IPP_TAG_PRINTER
</dt>
4316 <dd class=
"description">Printer group
</dd>
4317 <dt>IPP_TAG_RANGE
</dt>
4318 <dd class=
"description">Range value
</dd>
4319 <dt>IPP_TAG_RESOLUTION
</dt>
4320 <dd class=
"description">Resolution value
</dd>
4321 <dt>IPP_TAG_STRING
</dt>
4322 <dd class=
"description">Octet string value
</dd>
4323 <dt>IPP_TAG_SUBSCRIPTION
</dt>
4324 <dd class=
"description">Subscription group
</dd>
4325 <dt>IPP_TAG_TEXT
</dt>
4326 <dd class=
"description">Text value
</dd>
4327 <dt>IPP_TAG_TEXTLANG
</dt>
4328 <dd class=
"description">Text-with-language value
</dd>
4329 <dt>IPP_TAG_UNKNOWN
</dt>
4330 <dd class=
"description">Unknown value
</dd>
4331 <dt>IPP_TAG_UNSUPPORTED_GROUP
</dt>
4332 <dd class=
"description">Unsupported attributes group
</dd>
4333 <dt>IPP_TAG_UNSUPPORTED_VALUE
</dt>
4334 <dd class=
"description">Unsupported value
</dd>
4335 <dt>IPP_TAG_URI
</dt>
4336 <dd class=
"description">URI value
</dd>
4337 <dt>IPP_TAG_URISCHEME
</dt>
4338 <dd class=
"description">URI scheme value
</dd>
4339 <dt>IPP_TAG_ZERO
</dt>
4340 <dd class=
"description">Zero tag - used for separators
</dd>