summaryrefslogtreecommitdiff
path: root/doc/help/api-httpipp.html
blob: 795ebbf474d3eea8bea406319f7cc3972851c7aa (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
2201
2202
2203
2204
2205
2206
2207
2208
2209
2210
2211
2212
2213
2214
2215
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327
2328
2329
2330
2331
2332
2333
2334
2335
2336
2337
2338
2339
2340
2341
2342
2343
2344
2345
2346
2347
2348
2349
2350
2351
2352
2353
2354
2355
2356
2357
2358
2359
2360
2361
2362
2363
2364
2365
2366
2367
2368
2369
2370
2371
2372
2373
2374
2375
2376
2377
2378
2379
2380
2381
2382
2383
2384
2385
2386
2387
2388
2389
2390
2391
2392
2393
2394
2395
2396
2397
2398
2399
2400
2401
2402
2403
2404
2405
2406
2407
2408
2409
2410
2411
2412
2413
2414
2415
2416
2417
2418
2419
2420
2421
2422
2423
2424
2425
2426
2427
2428
2429
2430
2431
2432
2433
2434
2435
2436
2437
2438
2439
2440
2441
2442
2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457
2458
2459
2460
2461
2462
2463
2464
2465
2466
2467
2468
2469
2470
2471
2472
2473
2474
2475
2476
2477
2478
2479
2480
2481
2482
2483
2484
2485
2486
2487
2488
2489
2490
2491
2492
2493
2494
2495
2496
2497
2498
2499
2500
2501
2502
2503
2504
2505
2506
2507
2508
2509
2510
2511
2512
2513
2514
2515
2516
2517
2518
2519
2520
2521
2522
2523
2524
2525
2526
2527
2528
2529
2530
2531
2532
2533
2534
2535
2536
2537
2538
2539
2540
2541
2542
2543
2544
2545
2546
2547
2548
2549
2550
2551
2552
2553
2554
2555
2556
2557
2558
2559
2560
2561
2562
2563
2564
2565
2566
2567
2568
2569
2570
2571
2572
2573
2574
2575
2576
2577
2578
2579
2580
2581
2582
2583
2584
2585
2586
2587
2588
2589
2590
2591
2592
2593
2594
2595
2596
2597
2598
2599
2600
2601
2602
2603
2604
2605
2606
2607
2608
2609
2610
2611
2612
2613
2614
2615
2616
2617
2618
2619
2620
2621
2622
2623
2624
2625
2626
2627
2628
2629
2630
2631
2632
2633
2634
2635
2636
2637
2638
2639
2640
2641
2642
2643
2644
2645
2646
2647
2648
2649
2650
2651
2652
2653
2654
2655
2656
2657
2658
2659
2660
2661
2662
2663
2664
2665
2666
2667
2668
2669
2670
2671
2672
2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
2689
2690
2691
2692
2693
2694
2695
2696
2697
2698
2699
2700
2701
2702
2703
2704
2705
2706
2707
2708
2709
2710
2711
2712
2713
2714
2715
2716
2717
2718
2719
2720
2721
2722
2723
2724
2725
2726
2727
2728
2729
2730
2731
2732
2733
2734
2735
2736
2737
2738
2739
2740
2741
2742
2743
2744
2745
2746
2747
2748
2749
2750
2751
2752
2753
2754
2755
2756
2757
2758
2759
2760
2761
2762
2763
2764
2765
2766
2767
2768
2769
2770
2771
2772
2773
2774
2775
2776
2777
2778
2779
2780
2781
2782
2783
2784
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
2796
2797
2798
2799
2800
2801
2802
2803
2804
2805
2806
2807
2808
2809
2810
2811
2812
2813
2814
2815
2816
2817
2818
2819
2820
2821
2822
2823
2824
2825
2826
2827
2828
2829
2830
2831
2832
2833
2834
2835
2836
2837
2838
2839
2840
2841
2842
2843
2844
2845
2846
2847
2848
2849
2850
2851
2852
2853
2854
2855
2856
2857
2858
2859
2860
2861
2862
2863
2864
2865
2866
2867
2868
2869
2870
2871
2872
2873
2874
2875
2876
2877
2878
2879
2880
2881
2882
2883
2884
2885
2886
2887
2888
2889
2890
2891
2892
2893
2894
2895
2896
2897
2898
2899
2900
2901
2902
2903
2904
2905
2906
2907
2908
2909
2910
2911
2912
2913
2914
2915
2916
2917
2918
2919
2920
2921
2922
2923
2924
2925
2926
2927
2928
2929
2930
2931
2932
2933
2934
2935
2936
2937
2938
2939
2940
2941
2942
2943
2944
2945
2946
2947
2948
2949
2950
2951
2952
2953
2954
2955
2956
2957
2958
2959
2960
2961
2962
2963
2964
2965
2966
2967
2968
2969
2970
2971
2972
2973
2974
2975
2976
2977
2978
2979
2980
2981
2982
2983
2984
2985
2986
2987
2988
2989
2990
2991
2992
2993
2994
2995
2996
2997
2998
2999
3000
3001
3002
3003
3004
3005
3006
3007
3008
3009
3010
3011
3012
3013
3014
3015
3016
3017
3018
3019
3020
3021
3022
3023
3024
3025
3026
3027
3028
3029
3030
3031
3032
3033
3034
3035
3036
3037
3038
3039
3040
3041
3042
3043
3044
3045
3046
3047
3048
3049
3050
3051
3052
3053
3054
3055
3056
3057
3058
3059
3060
3061
3062
3063
3064
3065
3066
3067
3068
3069
3070
3071
3072
3073
3074
3075
3076
3077
3078
3079
3080
3081
3082
3083
3084
3085
3086
3087
3088
3089
3090
3091
3092
3093
3094
3095
3096
3097
3098
3099
3100
3101
3102
3103
3104
3105
3106
3107
3108
3109
3110
3111
3112
3113
3114
3115
3116
3117
3118
3119
3120
3121
3122
3123
3124
3125
3126
3127
3128
3129
3130
3131
3132
3133
3134
3135
3136
3137
3138
3139
3140
3141
3142
3143
3144
3145
3146
3147
3148
3149
3150
3151
3152
3153
3154
3155
3156
3157
3158
3159
3160
3161
3162
3163
3164
3165
3166
3167
3168
3169
3170
3171
3172
3173
3174
3175
3176
3177
3178
3179
3180
3181
3182
3183
3184
3185
3186
3187
3188
3189
3190
3191
3192
3193
3194
3195
3196
3197
3198
3199
3200
3201
3202
3203
3204
3205
3206
3207
3208
3209
3210
3211
3212
3213
3214
3215
3216
3217
3218
3219
3220
3221
3222
3223
3224
3225
3226
3227
3228
3229
3230
3231
3232
3233
3234
3235
3236
3237
3238
3239
3240
3241
3242
3243
3244
3245
3246
3247
3248
3249
3250
3251
3252
3253
3254
3255
3256
3257
3258
3259
3260
3261
3262
3263
3264
3265
3266
3267
3268
3269
3270
3271
3272
3273
3274
3275
3276
3277
3278
3279
3280
3281
3282
3283
3284
3285
3286
3287
3288
3289
3290
3291
3292
3293
3294
3295
3296
3297
3298
3299
3300
3301
3302
3303
3304
3305
3306
3307
3308
3309
3310
3311
3312
3313
3314
3315
3316
3317
3318
3319
3320
3321
3322
3323
3324
3325
3326
3327
3328
3329
3330
3331
3332
3333
3334
3335
3336
3337
3338
3339
3340
3341
3342
3343
3344
3345
3346
3347
3348
3349
3350
3351
3352
3353
3354
3355
3356
3357
3358
3359
3360
3361
3362
3363
3364
3365
3366
3367
3368
3369
3370
3371
3372
3373
3374
3375
3376
3377
3378
3379
3380
3381
3382
3383
3384
3385
3386
3387
3388
3389
3390
3391
3392
3393
3394
3395
3396
3397
3398
3399
3400
3401
3402
3403
3404
3405
3406
3407
3408
3409
3410
3411
3412
3413
3414
3415
3416
3417
3418
3419
3420
3421
3422
3423
3424
3425
3426
3427
3428
3429
3430
3431
3432
3433
3434
3435
3436
3437
3438
3439
3440
3441
3442
3443
3444
3445
3446
3447
3448
3449
3450
3451
3452
3453
3454
3455
3456
3457
3458
3459
3460
3461
3462
3463
3464
3465
3466
3467
3468
3469
3470
3471
3472
3473
3474
3475
3476
3477
3478
3479
3480
3481
3482
3483
3484
3485
3486
3487
3488
3489
3490
3491
3492
3493
3494
3495
3496
3497
3498
3499
3500
3501
3502
3503
3504
3505
3506
3507
3508
3509
3510
3511
3512
3513
3514
3515
3516
3517
3518
3519
3520
3521
3522
3523
3524
3525
3526
3527
3528
3529
3530
3531
3532
3533
3534
3535
3536
3537
3538
3539
3540
3541
3542
3543
3544
3545
3546
3547
3548
3549
3550
3551
3552
3553
3554
3555
3556
3557
3558
3559
3560
3561
3562
3563
3564
3565
3566
3567
3568
3569
3570
3571
3572
3573
3574
3575
3576
3577
3578
3579
3580
3581
3582
3583
3584
3585
3586
3587
3588
3589
3590
3591
3592
3593
3594
3595
3596
3597
3598
3599
3600
3601
3602
3603
3604
3605
3606
3607
3608
3609
3610
3611
3612
3613
3614
3615
3616
3617
3618
3619
3620
3621
3622
3623
3624
3625
3626
3627
3628
3629
3630
3631
3632
3633
3634
3635
3636
3637
3638
3639
3640
3641
3642
3643
3644
3645
3646
3647
3648
3649
3650
3651
3652
3653
3654
3655
3656
3657
3658
3659
3660
3661
3662
3663
3664
3665
3666
3667
3668
3669
3670
3671
3672
3673
3674
3675
3676
3677
3678
3679
3680
3681
3682
3683
3684
3685
3686
3687
3688
3689
3690
3691
3692
3693
3694
3695
3696
3697
3698
3699
3700
3701
3702
3703
3704
3705
3706
3707
3708
3709
3710
3711
3712
3713
3714
3715
3716
3717
3718
3719
3720
3721
3722
3723
3724
3725
3726
3727
3728
3729
3730
3731
3732
3733
3734
3735
3736
3737
3738
3739
3740
3741
3742
3743
3744
3745
3746
3747
3748
3749
3750
3751
3752
3753
3754
3755
3756
3757
3758
3759
3760
3761
3762
3763
3764
3765
3766
3767
3768
3769
3770
3771
3772
3773
3774
3775
3776
3777
3778
3779
3780
3781
3782
3783
3784
3785
3786
3787
3788
3789
3790
3791
3792
3793
3794
3795
3796
3797
3798
3799
3800
3801
3802
3803
3804
3805
3806
3807
3808
3809
3810
3811
3812
3813
3814
3815
3816
3817
3818
3819
3820
3821
3822
3823
3824
3825
3826
3827
3828
3829
3830
3831
3832
3833
3834
3835
3836
3837
3838
3839
3840
3841
3842
3843
3844
3845
3846
3847
3848
3849
3850
3851
3852
3853
3854
3855
3856
3857
3858
3859
3860
3861
3862
3863
3864
3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
3883
3884
3885
3886
3887
3888
3889
3890
3891
3892
3893
3894
3895
3896
3897
3898
3899
3900
3901
3902
3903
3904
3905
3906
3907
3908
3909
3910
3911
3912
3913
3914
3915
3916
3917
3918
3919
3920
3921
3922
3923
3924
3925
3926
3927
3928
3929
3930
3931
3932
3933
3934
3935
3936
3937
3938
3939
3940
3941
3942
3943
3944
3945
3946
3947
3948
3949
3950
3951
3952
3953
3954
3955
3956
3957
3958
3959
3960
3961
3962
3963
3964
3965
3966
3967
3968
3969
3970
3971
3972
3973
3974
3975
3976
3977
3978
3979
3980
3981
3982
3983
3984
3985
3986
3987
3988
3989
3990
3991
3992
3993
3994
3995
3996
3997
3998
3999
4000
4001
4002
4003
4004
4005
4006
4007
4008
4009
4010
4011
4012
4013
4014
4015
4016
4017
4018
4019
4020
4021
4022
4023
4024
4025
4026
4027
4028
4029
4030
4031
4032
4033
4034
4035
4036
4037
4038
4039
4040
4041
4042
4043
4044
4045
4046
4047
4048
4049
4050
4051
4052
4053
4054
4055
4056
4057
4058
4059
4060
4061
4062
4063
4064
4065
4066
4067
4068
4069
4070
4071
4072
4073
4074
4075
4076
4077
4078
4079
4080
4081
4082
4083
4084
4085
4086
4087
4088
4089
4090
4091
4092
4093
4094
4095
4096
4097
4098
4099
4100
4101
4102
4103
4104
4105
4106
4107
4108
4109
4110
4111
4112
4113
4114
4115
4116
4117
4118
4119
4120
4121
4122
4123
4124
4125
4126
4127
4128
4129
4130
4131
4132
4133
4134
4135
4136
4137
4138
4139
4140
4141
4142
4143
4144
4145
4146
4147
4148
4149
4150
4151
4152
4153
4154
4155
4156
4157
4158
4159
4160
4161
4162
4163
4164
4165
4166
4167
4168
4169
4170
4171
4172
4173
4174
4175
4176
4177
4178
4179
4180
4181
4182
4183
4184
4185
4186
4187
4188
4189
4190
4191
4192
4193
4194
4195
4196
4197
4198
4199
4200
4201
4202
4203
4204
4205
4206
4207
4208
4209
4210
4211
4212
4213
4214
4215
4216
4217
4218
4219
4220
4221
4222
4223
4224
4225
4226
4227
4228
4229
4230
4231
4232
4233
4234
4235
4236
4237
4238
4239
4240
4241
4242
4243
4244
4245
4246
4247
4248
4249
4250
4251
4252
4253
4254
4255
4256
4257
4258
4259
4260
4261
4262
4263
4264
4265
4266
4267
4268
4269
4270
4271
4272
4273
4274
4275
4276
4277
4278
4279
4280
4281
4282
4283
4284
4285
4286
4287
4288
4289
4290
4291
4292
4293
4294
4295
4296
4297
4298
4299
4300
4301
4302
4303
4304
4305
4306
4307
4308
4309
4310
4311
4312
4313
4314
4315
4316
4317
4318
4319
4320
4321
4322
4323
4324
4325
4326
4327
4328
4329
4330
4331
4332
4333
4334
4335
4336
4337
4338
4339
4340
4341
4342
4343
4344
4345
4346
4347
4348
4349
4350
4351
4352
4353
4354
4355
4356
4357
4358
4359
4360
4361
4362
4363
4364
4365
4366
4367
4368
4369
4370
4371
4372
4373
4374
4375
4376
4377
4378
4379
4380
4381
4382
4383
4384
4385
4386
4387
4388
4389
4390
4391
4392
4393
4394
4395
4396
4397
4398
4399
4400
4401
4402
4403
4404
4405
4406
4407
4408
4409
4410
4411
4412
4413
4414
4415
4416
4417
4418
4419
4420
4421
4422
4423
4424
4425
4426
4427
4428
4429
4430
4431
4432
4433
4434
4435
4436
4437
4438
4439
4440
4441
4442
4443
4444
4445
4446
4447
4448
4449
4450
4451
4452
4453
4454
4455
4456
4457
4458
4459
4460
4461
4462
4463
4464
4465
4466
4467
4468
4469
4470
4471
4472
4473
4474
4475
4476
4477
4478
4479
4480
4481
4482
4483
4484
4485
4486
4487
4488
4489
4490
4491
4492
4493
4494
4495
4496
4497
4498
4499
4500
4501
4502
4503
4504
4505
4506
4507
4508
4509
4510
4511
4512
4513
4514
4515
4516
4517
4518
4519
4520
4521
4522
4523
4524
4525
4526
4527
4528
4529
4530
4531
4532
4533
4534
4535
4536
4537
4538
4539
4540
4541
4542
4543
4544
4545
4546
4547
4548
4549
4550
4551
4552
4553
4554
4555
4556
4557
4558
4559
4560
4561
4562
4563
4564
4565
4566
4567
4568
4569
4570
4571
4572
4573
4574
4575
4576
4577
4578
4579
4580
4581
4582
4583
4584
4585
4586
4587
4588
4589
4590
4591
4592
4593
4594
4595
4596
4597
4598
4599
4600
4601
4602
4603
4604
4605
4606
4607
4608
4609
4610
4611
4612
4613
4614
4615
4616
4617
4618
4619
4620
4621
4622
4623
4624
4625
4626
4627
4628
4629
4630
4631
4632
4633
4634
4635
4636
4637
4638
4639
4640
4641
4642
4643
4644
4645
4646
4647
4648
4649
4650
4651
4652
4653
4654
4655
4656
4657
4658
4659
4660
4661
4662
4663
4664
4665
4666
4667
4668
4669
4670
4671
4672
4673
4674
4675
4676
4677
4678
4679
4680
4681
4682
4683
4684
4685
4686
4687
4688
4689
4690
4691
4692
4693
4694
4695
4696
4697
4698
4699
4700
4701
4702
4703
4704
4705
4706
4707
4708
4709
4710
4711
4712
4713
4714
4715
4716
4717
4718
4719
4720
4721
4722
4723
4724
4725
4726
4727
4728
4729
4730
4731
4732
4733
4734
4735
4736
4737
4738
4739
4740
4741
4742
4743
4744
4745
4746
4747
4748
4749
4750
4751
4752
4753
4754
4755
4756
4757
4758
4759
4760
4761
4762
4763
4764
4765
4766
4767
4768
4769
4770
4771
4772
4773
4774
4775
4776
4777
4778
4779
4780
4781
4782
4783
4784
4785
4786
4787
4788
4789
4790
4791
4792
4793
4794
4795
4796
4797
4798
4799
4800
4801
4802
4803
4804
4805
4806
4807
4808
4809
4810
4811
4812
4813
4814
4815
4816
4817
4818
4819
4820
4821
4822
4823
4824
4825
4826
4827
4828
4829
4830
4831
4832
4833
4834
4835
4836
4837
4838
4839
4840
4841
4842
4843
4844
4845
4846
4847
4848
4849
4850
4851
4852
4853
4854
4855
4856
4857
4858
4859
4860
4861
4862
4863
4864
4865
4866
4867
4868
4869
4870
4871
4872
4873
4874
4875
4876
4877
4878
4879
4880
4881
4882
4883
4884
4885
4886
4887
4888
4889
4890
4891
4892
4893
4894
4895
4896
4897
4898
4899
4900
4901
4902
4903
4904
4905
4906
4907
4908
4909
4910
4911
4912
4913
4914
4915
4916
4917
4918
4919
4920
4921
4922
4923
4924
4925
4926
4927
4928
4929
4930
4931
4932
4933
4934
4935
4936
4937
4938
4939
4940
4941
4942
4943
4944
4945
4946
4947
4948
4949
4950
4951
4952
4953
4954
4955
4956
4957
4958
4959
4960
4961
4962
4963
4964
4965
4966
4967
4968
4969
4970
4971
4972
4973
4974
4975
4976
4977
4978
4979
4980
4981
4982
4983
4984
4985
4986
4987
4988
4989
4990
4991
4992
4993
4994
4995
4996
4997
4998
4999
5000
5001
5002
5003
5004
5005
5006
5007
5008
5009
5010
5011
5012
5013
5014
5015
5016
5017
5018
5019
5020
5021
5022
5023
5024
5025
5026
5027
5028
5029
5030
5031
5032
5033
5034
5035
5036
5037
5038
5039
5040
5041
5042
5043
5044
5045
5046
5047
5048
5049
5050
5051
5052
5053
5054
5055
5056
5057
5058
5059
5060
5061
5062
5063
5064
5065
5066
5067
5068
5069
5070
5071
5072
5073
5074
5075
5076
5077
5078
5079
5080
5081
5082
5083
5084
5085
5086
5087
5088
5089
5090
5091
5092
5093
5094
5095
5096
5097
5098
5099
5100
5101
5102
5103
5104
5105
5106
5107
5108
5109
5110
5111
5112
5113
5114
5115
5116
5117
5118
5119
5120
5121
5122
5123
5124
5125
5126
5127
5128
5129
5130
5131
5132
5133
5134
5135
5136
5137
5138
5139
5140
5141
5142
5143
5144
5145
5146
5147
5148
5149
5150
5151
5152
5153
5154
5155
5156
5157
5158
5159
5160
5161
5162
5163
5164
5165
5166
5167
5168
5169
5170
5171
5172
5173
5174
5175
5176
5177
5178
5179
5180
5181
5182
5183
5184
5185
5186
5187
5188
5189
5190
5191
5192
5193
5194
5195
5196
5197
5198
5199
5200
5201
5202
5203
5204
5205
5206
5207
5208
5209
5210
5211
5212
5213
5214
5215
5216
5217
5218
5219
5220
5221
5222
5223
5224
5225
5226
5227
5228
5229
5230
5231
5232
5233
5234
5235
5236
5237
5238
5239
5240
5241
5242
5243
5244
5245
5246
5247
5248
5249
5250
5251
5252
5253
5254
5255
5256
5257
5258
5259
5260
5261
5262
5263
5264
5265
5266
5267
5268
5269
5270
5271
5272
5273
5274
5275
5276
5277
5278
5279
5280
5281
5282
5283
5284
5285
5286
5287
5288
5289
5290
5291
5292
5293
5294
5295
5296
5297
5298
5299
5300
5301
5302
5303
5304
5305
5306
5307
5308
5309
5310
5311
5312
5313
5314
5315
5316
5317
5318
5319
5320
5321
5322
5323
5324
5325
5326
5327
5328
5329
5330
5331
5332
5333
5334
5335
5336
5337
5338
5339
5340
5341
5342
5343
5344
5345
5346
5347
5348
5349
5350
5351
5352
5353
5354
5355
5356
5357
5358
5359
5360
5361
5362
5363
5364
5365
5366
5367
5368
5369
5370
5371
5372
5373
5374
5375
5376
5377
5378
5379
5380
5381
5382
5383
5384
5385
5386
5387
5388
5389
5390
5391
5392
5393
5394
5395
5396
5397
5398
5399
5400
5401
5402
5403
5404
5405
5406
5407
5408
5409
5410
5411
5412
5413
5414
5415
5416
5417
5418
5419
5420
5421
5422
5423
5424
5425
5426
5427
5428
5429
5430
5431
5432
5433
5434
5435
5436
5437
5438
5439
5440
5441
5442
5443
5444
5445
5446
5447
5448
5449
5450
5451
5452
5453
5454
5455
5456
5457
5458
5459
5460
5461
5462
5463
5464
5465
5466
5467
5468
5469
5470
5471
5472
5473
5474
5475
5476
5477
5478
5479
5480
5481
5482
5483
5484
5485
5486
5487
5488
5489
5490
5491
5492
5493
5494
5495
5496
5497
5498
5499
5500
5501
5502
5503
5504
5505
5506
5507
5508
5509
5510
5511
5512
5513
5514
5515
5516
5517
5518
5519
5520
5521
5522
5523
5524
5525
5526
5527
5528
5529
5530
5531
5532
5533
5534
5535
5536
5537
5538
5539
5540
5541
5542
5543
5544
5545
5546
5547
5548
5549
5550
5551
5552
5553
5554
5555
5556
5557
5558
5559
5560
5561
5562
5563
5564
5565
5566
5567
5568
5569
5570
5571
5572
5573
5574
5575
5576
5577
5578
5579
5580
5581
5582
5583
5584
5585
5586
5587
5588
5589
5590
5591
5592
5593
5594
5595
5596
5597
5598
5599
5600
5601
5602
5603
5604
5605
5606
5607
5608
5609
5610
5611
5612
5613
5614
5615
5616
5617
5618
5619
5620
5621
5622
5623
5624
5625
5626
5627
5628
5629
5630
5631
5632
5633
5634
5635
5636
5637
5638
5639
5640
5641
5642
5643
5644
5645
5646
5647
5648
5649
5650
5651
5652
5653
5654
5655
5656
5657
5658
5659
5660
5661
5662
5663
5664
5665
5666
5667
5668
5669
5670
5671
5672
5673
5674
5675
5676
5677
5678
5679
5680
5681
5682
5683
5684
5685
5686
5687
5688
5689
5690
5691
5692
5693
5694
5695
5696
5697
5698
5699
5700
5701
5702
5703
5704
5705
5706
5707
5708
5709
5710
5711
5712
5713
5714
5715
5716
5717
5718
5719
5720
5721
5722
5723
5724
5725
5726
5727
5728
5729
5730
5731
5732
5733
5734
5735
5736
5737
5738
5739
5740
5741
5742
5743
5744
5745
5746
5747
5748
5749
5750
5751
5752
5753
5754
5755
5756
5757
5758
5759
5760
5761
5762
5763
5764
5765
5766
5767
5768
5769
5770
5771
5772
5773
5774
5775
5776
5777
5778
5779
5780
5781
5782
5783
5784
5785
5786
5787
5788
5789
5790
5791
5792
5793
5794
5795
5796
5797
5798
5799
5800
5801
5802
5803
5804
5805
5806
5807
5808
5809
5810
5811
5812
5813
5814
5815
5816
5817
5818
5819
5820
5821
5822
5823
5824
5825
5826
5827
5828
5829
5830
5831
5832
5833
5834
5835
5836
5837
5838
5839
5840
5841
5842
5843
5844
5845
5846
5847
5848
5849
5850
5851
5852
5853
5854
5855
5856
5857
5858
5859
5860
5861
5862
5863
5864
5865
5866
5867
5868
5869
5870
5871
5872
5873
5874
5875
5876
5877
5878
5879
5880
5881
5882
5883
5884
5885
5886
5887
5888
5889
5890
5891
5892
5893
5894
5895
5896
5897
5898
5899
5900
5901
5902
5903
5904
5905
5906
5907
5908
5909
5910
5911
5912
5913
5914
5915
5916
5917
5918
5919
5920
5921
5922
5923
5924
5925
5926
5927
5928
5929
5930
5931
5932
5933
5934
5935
5936
5937
5938
5939
5940
5941
5942
5943
5944
5945
5946
5947
5948
5949
5950
5951
5952
5953
5954
5955
5956
5957
5958
5959
5960
5961
5962
5963
5964
5965
5966
5967
5968
5969
5970
5971
5972
5973
5974
5975
5976
5977
5978
5979
5980
5981
5982
5983
5984
5985
5986
5987
5988
5989
5990
5991
5992
5993
5994
5995
5996
5997
5998
5999
6000
6001
6002
6003
6004
6005
6006
6007
6008
6009
6010
6011
6012
6013
6014
6015
6016
6017
6018
6019
6020
6021
6022
6023
6024
6025
6026
6027
6028
6029
6030
6031
6032
6033
6034
6035
6036
6037
6038
6039
6040
6041
6042
6043
6044
6045
6046
6047
6048
6049
6050
6051
6052
6053
6054
6055
6056
6057
6058
6059
6060
6061
6062
6063
6064
6065
6066
6067
6068
6069
6070
6071
6072
6073
6074
6075
6076
6077
6078
6079
6080
6081
6082
6083
6084
6085
6086
6087
6088
6089
6090
6091
6092
6093
6094
6095
6096
6097
6098
6099
6100
6101
6102
6103
6104
6105
6106
6107
6108
6109
6110
6111
6112
6113
6114
6115
6116
6117
6118
6119
6120
6121
6122
6123
6124
6125
6126
6127
6128
6129
6130
6131
6132
6133
6134
6135
6136
6137
6138
6139
6140
6141
6142
6143
6144
6145
6146
6147
6148
6149
6150
6151
6152
6153
6154
6155
6156
6157
6158
6159
6160
6161
6162
6163
6164
6165
6166
6167
6168
6169
6170
6171
6172
6173
6174
6175
6176
6177
6178
6179
6180
6181
6182
6183
6184
6185
6186
6187
6188
6189
6190
6191
6192
6193
6194
6195
6196
6197
6198
6199
6200
6201
6202
6203
6204
6205
6206
6207
6208
6209
6210
6211
6212
6213
6214
6215
6216
6217
6218
6219
6220
6221
6222
6223
6224
6225
6226
6227
6228
6229
6230
6231
6232
6233
6234
6235
6236
6237
6238
6239
6240
6241
6242
6243
6244
6245
6246
6247
6248
6249
6250
6251
6252
6253
6254
6255
6256
6257
6258
6259
6260
6261
6262
6263
6264
6265
6266
6267
6268
6269
6270
6271
6272
6273
6274
6275
6276
6277
6278
6279
6280
6281
6282
6283
6284
6285
6286
6287
6288
6289
6290
6291
6292
6293
6294
6295
6296
6297
6298
6299
6300
6301
6302
6303
6304
6305
6306
6307
6308
6309
6310
6311
6312
6313
6314
6315
6316
6317
6318
6319
6320
6321
6322
6323
6324
6325
6326
6327
6328
6329
6330
6331
6332
6333
6334
6335
6336
6337
6338
6339
6340
6341
6342
6343
6344
6345
6346
6347
6348
6349
6350
6351
6352
6353
6354
6355
6356
6357
6358
6359
6360
6361
6362
6363
6364
6365
6366
6367
6368
6369
6370
6371
6372
6373
6374
6375
6376
6377
6378
6379
6380
6381
6382
6383
6384
6385
6386
6387
6388
6389
6390
6391
6392
6393
6394
6395
6396
6397
6398
6399
6400
6401
6402
6403
6404
6405
6406
6407
6408
6409
6410
6411
6412
6413
6414
6415
6416
6417
6418
6419
6420
6421
6422
6423
6424
6425
6426
6427
6428
6429
6430
6431
6432
6433
6434
6435
6436
6437
6438
6439
6440
6441
6442
6443
6444
6445
6446
6447
6448
6449
6450
6451
6452
6453
6454
6455
6456
6457
6458
6459
6460
6461
6462
6463
6464
6465
6466
6467
6468
6469
6470
6471
6472
6473
6474
6475
6476
6477
6478
6479
6480
6481
6482
6483
6484
6485
6486
6487
6488
6489
6490
6491
6492
6493
6494
6495
6496
6497
6498
6499
6500
6501
6502
6503
6504
6505
6506
6507
6508
6509
6510
6511
6512
6513
6514
6515
6516
6517
6518
6519
6520
6521
6522
6523
6524
6525
6526
6527
6528
6529
6530
6531
6532
6533
6534
6535
6536
6537
6538
6539
6540
6541
6542
6543
6544
6545
6546
6547
6548
6549
6550
6551
6552
6553
6554
6555
6556
6557
6558
6559
6560
6561
6562
6563
6564
6565
6566
6567
6568
6569
6570
6571
6572
6573
6574
6575
6576
6577
6578
6579
6580
6581
6582
6583
6584
6585
6586
6587
6588
6589
6590
6591
6592
6593
6594
6595
6596
6597
6598
6599
6600
6601
6602
6603
6604
6605
6606
6607
6608
6609
6610
6611
6612
6613
6614
6615
6616
6617
6618
6619
6620
6621
6622
6623
6624
6625
6626
6627
6628
6629
6630
6631
6632
6633
6634
6635
6636
6637
6638
6639
6640
6641
6642
6643
6644
6645
6646
6647
6648
6649
6650
6651
6652
6653
6654
6655
6656
6657
6658
6659
6660
6661
6662
6663
6664
6665
6666
6667
6668
6669
6670
6671
6672
6673
6674
6675
6676
6677
6678
6679
6680
6681
6682
6683
6684
6685
6686
6687
6688
6689
6690
6691
6692
6693
6694
6695
6696
6697
6698
6699
6700
6701
6702
6703
6704
6705
6706
6707
6708
6709
6710
6711
6712
6713
6714
6715
6716
6717
6718
6719
6720
6721
6722
6723
6724
6725
6726
6727
6728
6729
6730
6731
6732
6733
6734
6735
6736
6737
6738
6739
6740
6741
6742
6743
6744
6745
6746
6747
6748
6749
6750
6751
6752
6753
6754
6755
6756
6757
6758
6759
6760
6761
6762
6763
6764
6765
6766
6767
6768
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<!-- SECTION: Programming -->
<head>
	<title>HTTP and IPP APIs	</title>
	<meta name="keywords" content="Programming">
	<meta http-equiv="Content-Type" content="text/html;charset=utf-8">
	<meta name="creator" content="Mini-XML v2.7">
<style type="text/css"><!--
BODY {
  font-family: lucida grande, geneva, helvetica, arial, sans-serif;
}

H1, H2, H3, H4, H5, H6, P, TD, TH {
  font-family: lucida grande, geneva, helvetica, arial, sans-serif;
}

KBD {
  font-family: monaco, courier, monospace;
  font-weight: bold;
}

PRE {
  font-family: monaco, courier, monospace;
}

PRE.command {
  border: dotted thin #7f7f7f;
  margin-left: 36pt;
  padding: 10px;
}

P.compact {
  margin: 0;
}

P.example {
  font-style: italic;
  margin-left: 36pt;
}

DL.man DD {
  margin-left: 5em;
}

DL.man DT {
  margin-left: 0;
}

PRE.man {
  margin: 0;
}

PRE.example {
  background: #eeeeee;
  border: dotted thin #999999;
  margin-left: 36pt;
  padding: 10pt;
}

PRE.command EM, PRE.example EM {
  font-family: lucida grande, geneva, helvetica, arial, sans-serif;
}

P.command {
  font-family: monaco, courier, monospace;
  margin-left: 36pt;
}

P.formula {
  font-style: italic;
  margin-left: 36pt;
}

BLOCKQUOTE {
  background: #eeeeee;
  border: solid thin #999999;
  padding: 10pt;
}

A IMG {
  border: none;
}

A:link:hover IMG {
  background: #f0f0f0;
  border-radius: 10px;
  -moz-border-radius: 10px;
}

A:link, A:visited {
  font-weight: inherit;
  text-decoration: none;
}

A:link:hover, A:visited:hover, A:active {
  text-decoration: underline;
}

SUB, SUP {
  font-size: 50%;
}

TR.data, TD.data, TR.data TD {
  margin-top: 10pt;
  padding: 5pt;
  border-bottom: solid 1pt #999999;
}

TR.data TH {
  border-bottom: solid 1pt #999999;
  padding-top: 10pt;
  padding-left: 5pt;
  text-align: left;
}

DIV.table TABLE {
  border: solid thin #999999;
  border-collapse: collapse;
  border-spacing: 0;
  margin-left: auto;
  margin-right: auto;
}

DIV.table CAPTION {
  caption-side: top;
  font-size: 120%;
  font-style: italic;
  font-weight: bold;
  margin-left: auto;
  margin-right: auto;
}

DIV.table TABLE TD {
  border: solid thin #cccccc;
  padding-top: 5pt;
}

DIV.table TABLE TH {
  background: #cccccc;
  border: none;
  border-bottom: solid thin #999999;
}

DIV.figure TABLE {
  margin-left: auto;
  margin-right: auto;
}

DIV.figure CAPTION {
  caption-side: bottom;
  font-size: 120%;
  font-style: italic;
  font-weight: bold;
  margin-left: auto;
  margin-right: auto;
}

TH.label {
  text-align: right;
  vertical-align: top;
}

TH.sublabel {
  text-align: right;
  font-weight: normal;
}

HR {
  border: solid thin;
}

SPAN.info {
  background: black;
  border: thin solid black;
  color: white;
  font-size: 80%;
  font-style: italic;
  font-weight: bold;
  white-space: nowrap;
}

H2 SPAN.info, H3 SPAN.info, H4 SPAN.info {
  float: right;
  font-size: 100%;
}

H1.title {
}

H2.title, H3.title {
  border-bottom: solid 2pt #000000;
}

DIV.indent, TABLE.indent {
  margin-top: 2em;
  margin-left: auto;
  margin-right: auto;
  width: 90%;
}

TABLE.indent {
  border-collapse: collapse;
}

TABLE.indent TD, TABLE.indent TH {
  padding: 0;
}

TABLE.list {
  border-collapse: collapse;
  margin-left: auto;
  margin-right: auto;
  width: 90%;
}

TABLE.list TH {
  background: white;
  border-bottom: solid thin #cccccc;
  color: #444444;
  padding-top: 10pt;
  padding-left: 5pt;
  text-align: left;
  vertical-align: bottom;
  white-space: nowrap;
}

TABLE.list TH A {
  color: #4444cc;
}

TABLE.list TD {
  border-bottom: solid thin #eeeeee;
  padding-top: 5pt;
  padding-left: 5pt;
}

TABLE.list TR:nth-child(even) {
  background: #f8f8f8;
}

TABLE.list TR:nth-child(odd) {
  background: #f4f4f4;
}

DT {
  margin-left: 36pt;
  margin-top: 12pt;
}

DD {
  margin-left: 54pt;
}

DL.category DT {
  font-weight: bold;
}

P.summary {
  margin-left: 36pt;
  font-family: monaco, courier, monospace;
}

DIV.summary TABLE {
  border: solid thin #999999;
  border-collapse: collapse;
  border-spacing: 0;
  margin: 10px;
}

DIV.summary TABLE TD, DIV.summary TABLE TH {
  border: solid thin #999999;
  padding: 5px;
  text-align: left;
  vertical-align: top;
}

DIV.summary TABLE THEAD TH {
  background: #eeeeee;
}

/* API documentation styles... */
div.body h1 {
  margin: 0;
}
div.body h2 {
  margin-top: 1.5em;
}
div.body h3, div.body h4, div.body h5 {
  margin-bottom: 0.5em;
  margin-top: 1.5em;
}
.class, .enumeration, .function, .struct, .typedef, .union {
  border-bottom: solid thin #999999;
  margin-bottom: 0;
  margin-top: 2em;
}
.description {
  margin-top: 0.5em;
}
code, p.code, pre, ul.code li {
  font-family: monaco, courier, monospace;
  font-size: 90%;
}
ul.code, ul.contents, ul.subcontents {
  list-style-type: none;
  margin: 0;
  padding-left: 0;
}
ul.code li {
  margin: 0;
}
ul.contents > li {
  margin-top: 1em;
}
ul.contents li ul.code, ul.contents li ul.subcontents {
  padding-left: 2em;
}
div.body dl {
  margin-left: 0;
  margin-top: 0;
}
div.body dt {
  font-style: italic;
  margin-left: 0;
  margin-top: 0;
}
div.body dd {
  margin-bottom: 0.5em;
}

/* This is just for the HTML files generated with the framedhelp target */
div.contents {
  background: #e8e8e8;
  border: solid thin black;
  padding: 10px;
}
div.contents h1 {
  font-size: 110%;
}
div.contents h2 {
  font-size: 100%;
}
div.contents ul.contents {
  font-size: 80%;
}
div.contents ul.subcontents li {
  margin-left: 1em;
  text-indent: -1em;
}
--></style>
</head>
<body>
<div class='body'>
<!--
  "$Id: api-httpipp.header 7258 2008-01-28 00:15:05Z mike $"

  HTTP and IPP API header for CUPS.

  Copyright 2007-2011 by Apple Inc.
  Copyright 1997-2006 by Easy Software Products, all rights reserved.

  These coded instructions, statements, and computer programs are the
  property of Apple Inc. and are protected by Federal copyright
  law.  Distribution and use rights are outlined in the file "LICENSE.txt"
  which should have been included with this file.  If this file is
  file is missing or damaged, see the license at "http://www.cups.org/".
-->

<h1 class='title'>HTTP and IPP APIs</h1>

<div class='summary'><table summary='General Information'>
<thead>
<tr>
	<th>Header</th>
	<th>cups/cups.h</th>
</tr>
</thead>
<tbody>
<tr>
	<th>Library</th>
	<td>-lcups</td>
</tr>
<tr>
	<th>See Also</th>
	<td>Programming: <a href='api-overview.html'>Introduction to CUPS Programming</a><br>
	Programming: <a href='api-cups.html'>CUPS API</a><br>
	References: <a href='spec-ipp.html'>CUPS Implementation of IPP</a></td>
</tr>
</tbody>
</table></div>
<h2 class="title">Contents</h2>
<ul class="contents">
<li><a href="#OVERVIEW">Overview</a><ul class="subcontents">
	<li><a href="#CREATING_URI_STRINGS">Creating URI Strings</a></li>
	<li><a href="#SENDING_REQUESTS_WITH_FILES">Sending Requests with Files</a></li>
	<li><a href="#ASYNCHRONOUS_REQUEST_PROCESSING">Asynchronous Request Processing</a></li>
</ul></li>
<li><a href="#FUNCTIONS">Functions</a><ul class="code">
	<li><a href="#cupsDoAuthentication" title="Authenticate a request.">cupsDoAuthentication</a></li>
	<li><a href="#cupsDoFileRequest" title="Do an IPP request with a file.">cupsDoFileRequest</a></li>
	<li><a href="#cupsDoIORequest" title="Do an IPP request with file descriptors.">cupsDoIORequest</a></li>
	<li><a href="#cupsDoRequest" title="Do an IPP request.">cupsDoRequest</a></li>
	<li><a href="#cupsEncodeOptions" title="Encode printer options into IPP attributes.">cupsEncodeOptions</a></li>
	<li><a href="#cupsEncodeOptions2" title="Encode printer options into IPP attributes for a group.">cupsEncodeOptions2</a></li>
	<li><a href="#cupsGetDevices" title="Get available printer devices.">cupsGetDevices</a></li>
	<li><a href="#cupsGetFd" title="Get a file from the server.">cupsGetFd</a></li>
	<li><a href="#cupsGetFile" title="Get a file from the server.">cupsGetFile</a></li>
	<li><a href="#cupsGetResponse" title="Get a response to an IPP request.">cupsGetResponse</a></li>
	<li><a href="#cupsLastError" title="Return the last IPP status code received on the current
thread.">cupsLastError</a></li>
	<li><a href="#cupsLastErrorString" title="Return the last IPP status-message received on the
current thread.">cupsLastErrorString</a></li>
	<li><a href="#cupsPutFd" title="Put a file on the server.">cupsPutFd</a></li>
	<li><a href="#cupsPutFile" title="Put a file on the server.">cupsPutFile</a></li>
	<li><a href="#cupsReadResponseData" title="Read additional data after the IPP response.">cupsReadResponseData</a></li>
	<li><a href="#cupsSendRequest" title="Send an IPP request.">cupsSendRequest</a></li>
	<li><a href="#cupsWriteRequestData" title="Write additional data after an IPP request.">cupsWriteRequestData</a></li>
	<li><a href="#httpAcceptConnection" title="Accept a new HTTP client connection from the
specified listening socket.">httpAcceptConnection</a></li>
	<li><a href="#httpAddCredential" title="Allocates and adds a single credential to an array.">httpAddCredential</a></li>
	<li><a href="#httpAddrAny" title="Check for the &quot;any&quot; address.">httpAddrAny</a></li>
	<li><a href="#httpAddrClose" title="Close a socket created by httpAddrConnect or
httpAddrListen.">httpAddrClose</a></li>
	<li><a href="#httpAddrEqual" title="Compare two addresses.">httpAddrEqual</a></li>
	<li><a href="#httpAddrFamily" title="Get the address family of an address.">httpAddrFamily</a></li>
	<li><a href="#httpAddrLength" title="Return the length of the address in bytes.">httpAddrLength</a></li>
	<li><a href="#httpAddrListen" title="Create a listening socket bound to the specified
address and port.">httpAddrListen</a></li>
	<li><a href="#httpAddrLocalhost" title="Check for the local loopback address.">httpAddrLocalhost</a></li>
	<li><a href="#httpAddrLookup" title="Lookup the hostname associated with the address.">httpAddrLookup</a></li>
	<li><a href="#httpAddrPort" title="Get the port number associated with an address.">httpAddrPort</a></li>
	<li><a href="#httpAddrString" title="Convert an address to a numeric string.">httpAddrString</a></li>
	<li><a href="#httpAssembleURI" title="Assemble a uniform resource identifier from its
components.">httpAssembleURI</a></li>
	<li><a href="#httpAssembleURIf" title="Assemble a uniform resource identifier from its
components with a formatted resource.">httpAssembleURIf</a></li>
	<li><a href="#httpAssembleUUID" title="Assemble a name-based UUID URN conforming to RFC 4122.">httpAssembleUUID</a></li>
	<li><a href="#httpBlocking" title="Set blocking/non-blocking behavior on a connection.">httpBlocking</a></li>
	<li><a href="#httpCheck" title="Check to see if there is a pending response from the server.">httpCheck</a></li>
	<li><a href="#httpClearCookie" title="Clear the cookie value(s).">httpClearCookie</a></li>
	<li><a href="#httpClearFields" title="Clear HTTP request fields.">httpClearFields</a></li>
	<li><a href="#httpClose" title="Close an HTTP connection.">httpClose</a></li>
	<li><a href="#httpCompareCredentials" title="Compare two sets of X.509 credentials.">httpCompareCredentials</a></li>
	<li><a href="#httpConnect" title="Connect to a HTTP server.">httpConnect</a></li>
	<li><a href="#httpConnect2" title="Connect to a HTTP server.">httpConnect2</a></li>
	<li><a href="#httpConnectEncrypt" title="Connect to a HTTP server using encryption.">httpConnectEncrypt</a></li>
	<li><a href="#httpDecode64" title="Base64-decode a string.">httpDecode64</a></li>
	<li><a href="#httpDecode64_2" title="Base64-decode a string.">httpDecode64_2</a></li>
	<li><a href="#httpDelete" title="Send a DELETE request to the server.">httpDelete</a></li>
	<li><a href="#httpEncode64" title="Base64-encode a string.">httpEncode64</a></li>
	<li><a href="#httpEncode64_2" title="Base64-encode a string.">httpEncode64_2</a></li>
	<li><a href="#httpEncryption" title="Set the required encryption on the link.">httpEncryption</a></li>
	<li><a href="#httpError" title="Get the last error on a connection.">httpError</a></li>
	<li><a href="#httpFieldValue" title="Return the HTTP field enumeration value for a field
name.">httpFieldValue</a></li>
	<li><a href="#httpFlush" title="Flush data from a HTTP connection.">httpFlush</a></li>
	<li><a href="#httpFlushWrite" title="Flush data in write buffer.">httpFlushWrite</a></li>
	<li><a href="#httpFreeCredentials" title="Free an array of credentials.">httpFreeCredentials</a></li>
	<li><a href="#httpGet" title="Send a GET request to the server.">httpGet</a></li>
	<li><a href="#httpGetActivity" title="Get the most recent activity for a connection.">httpGetActivity</a></li>
	<li><a href="#httpGetAddress" title="Get the address of the connected peer of a connection.">httpGetAddress</a></li>
	<li><a href="#httpGetAuthString" title="Get the current authorization string.">httpGetAuthString</a></li>
	<li><a href="#httpGetBlocking" title="Get the blocking/non-block state of a connection.">httpGetBlocking</a></li>
	<li><a href="#httpGetContentEncoding" title="Get a common content encoding, if any, between
the client and server.">httpGetContentEncoding</a></li>
	<li><a href="#httpGetCookie" title="Get any cookie data from the response.">httpGetCookie</a></li>
	<li><a href="#httpGetDateString" title="Get a formatted date/time string from a time value.">httpGetDateString</a></li>
	<li><a href="#httpGetDateString2" title="Get a formatted date/time string from a time value.">httpGetDateString2</a></li>
	<li><a href="#httpGetDateTime" title="Get a time value from a formatted date/time string.">httpGetDateTime</a></li>
	<li><a href="#httpGetEncryption" title="Get the current encryption mode of a connection.">httpGetEncryption</a></li>
	<li><a href="#httpGetExpect" title="Get the value of the Expect header, if any.">httpGetExpect</a></li>
	<li><a href="#httpGetFd" title="Get the file descriptor associated with a connection.">httpGetFd</a></li>
	<li><a href="#httpGetField" title="Get a field value from a request/response.">httpGetField</a></li>
	<li><a href="#httpGetHostByName" title="Lookup a hostname or IPv4 address, and return
address records for the specified name.">httpGetHostByName</a></li>
	<li><a href="#httpGetHostname" title="Get the FQDN for the connection or local system.">httpGetHostname</a></li>
	<li><a href="#httpGetKeepAlive" title="Get the current Keep-Alive state of the connection.">httpGetKeepAlive</a></li>
	<li><a href="#httpGetLength" title="Get the amount of data remaining from the
content-length or transfer-encoding fields.">httpGetLength</a></li>
	<li><a href="#httpGetLength2" title="Get the amount of data remaining from the
content-length or transfer-encoding fields.">httpGetLength2</a></li>
	<li><a href="#httpGetPending" title="Get the number of bytes that are buffered for writing.">httpGetPending</a></li>
	<li><a href="#httpGetReady" title="Get the number of bytes that can be read without blocking.">httpGetReady</a></li>
	<li><a href="#httpGetRemaining" title="Get the number of remaining bytes in the message
body or current chunk.">httpGetRemaining</a></li>
	<li><a href="#httpGetState" title="Get the current state of the HTTP request.">httpGetState</a></li>
	<li><a href="#httpGetStatus" title="Get the status of the last HTTP request.">httpGetStatus</a></li>
	<li><a href="#httpGetSubField" title="Get a sub-field value.">httpGetSubField</a></li>
	<li><a href="#httpGetSubField2" title="Get a sub-field value.">httpGetSubField2</a></li>
	<li><a href="#httpGetVersion" title="Get the HTTP version at the other end.">httpGetVersion</a></li>
	<li><a href="#httpGets" title="Get a line of text from a HTTP connection.">httpGets</a></li>
	<li><a href="#httpHead" title="Send a HEAD request to the server.">httpHead</a></li>
	<li><a href="#httpInitialize" title="Initialize the HTTP interface library and set the
default HTTP proxy (if any).">httpInitialize</a></li>
	<li><a href="#httpIsChunked" title="Report whether a message body is chunked.">httpIsChunked</a></li>
	<li><a href="#httpIsEncrypted" title="Report whether a connection is encrypted.">httpIsEncrypted</a></li>
	<li><a href="#httpMD5" title="Compute the MD5 sum of the username:group:password.">httpMD5</a></li>
	<li><a href="#httpMD5Final" title="Combine the MD5 sum of the username, group, and password
with the server-supplied nonce value, method, and
request-uri.">httpMD5Final</a></li>
	<li><a href="#httpMD5String" title="Convert an MD5 sum to a character string.">httpMD5String</a></li>
	<li><a href="#httpOptions" title="Send an OPTIONS request to the server.">httpOptions</a></li>
	<li><a href="#httpPeek" title="Peek at data from a HTTP connection.">httpPeek</a></li>
	<li><a href="#httpPost" title="Send a POST request to the server.">httpPost</a></li>
	<li><a href="#httpPut" title="Send a PUT request to the server.">httpPut</a></li>
	<li><a href="#httpRead" title="Read data from a HTTP connection.">httpRead</a></li>
	<li><a href="#httpRead2" title="Read data from a HTTP connection.">httpRead2</a></li>
	<li><a href="#httpReadRequest" title="Read a HTTP request from a connection.">httpReadRequest</a></li>
	<li><a href="#httpReconnect" title="Reconnect to a HTTP server.">httpReconnect</a></li>
	<li><a href="#httpReconnect2" title="Reconnect to a HTTP server with timeout and optional
cancel.">httpReconnect2</a></li>
	<li><a href="#httpResolveHostname" title="Resolve the hostname of the HTTP connection
address.">httpResolveHostname</a></li>
	<li><a href="#httpSeparate" title="Separate a Universal Resource Identifier into its
components.">httpSeparate</a></li>
	<li><a href="#httpSeparate2" title="Separate a Universal Resource Identifier into its
components.">httpSeparate2</a></li>
	<li><a href="#httpSeparateURI" title="Separate a Universal Resource Identifier into its
components.">httpSeparateURI</a></li>
	<li><a href="#httpSetAuthString" title="Set the current authorization string.">httpSetAuthString</a></li>
	<li><a href="#httpSetCookie" title="Set the cookie value(s).">httpSetCookie</a></li>
	<li><a href="#httpSetCredentials" title="Set the credentials associated with an encrypted
connection.">httpSetCredentials</a></li>
	<li><a href="#httpSetDefaultField" title="Set the default value of an HTTP header.">httpSetDefaultField</a></li>
	<li><a href="#httpSetExpect" title="Set the Expect: header in a request.">httpSetExpect</a></li>
	<li><a href="#httpSetField" title="Set the value of an HTTP header.">httpSetField</a></li>
	<li><a href="#httpSetKeepAlive" title="Set the current Keep-Alive state of a connection.">httpSetKeepAlive</a></li>
	<li><a href="#httpSetLength" title="Set the content-length and content-encoding.">httpSetLength</a></li>
	<li><a href="#httpSetTimeout" title="Set read/write timeouts and an optional callback.">httpSetTimeout</a></li>
	<li><a href="#httpShutdown" title="Shutdown one side of an HTTP connection.">httpShutdown</a></li>
	<li><a href="#httpStateString" title="Return the string describing a HTTP state value.">httpStateString</a></li>
	<li><a href="#httpStatus" title="Return a short string describing a HTTP status code.">httpStatus</a></li>
	<li><a href="#httpTrace" title="Send an TRACE request to the server.">httpTrace</a></li>
	<li><a href="#httpURIStatusString" title="Return a string describing a URI status code.">httpURIStatusString</a></li>
	<li><a href="#httpUpdate" title="Update the current HTTP state for incoming data.">httpUpdate</a></li>
	<li><a href="#httpWait" title="Wait for data available on a connection.">httpWait</a></li>
	<li><a href="#httpWrite" title="Write data to a HTTP connection.">httpWrite</a></li>
	<li><a href="#httpWrite2" title="Write data to a HTTP connection.">httpWrite2</a></li>
	<li><a href="#httpWriteResponse" title="Write a HTTP response to a client connection.">httpWriteResponse</a></li>
	<li><a href="#ippAddBoolean" title="Add a boolean attribute to an IPP message.">ippAddBoolean</a></li>
	<li><a href="#ippAddBooleans" title="Add an array of boolean values.">ippAddBooleans</a></li>
	<li><a href="#ippAddCollection" title="Add a collection value.">ippAddCollection</a></li>
	<li><a href="#ippAddCollections" title="Add an array of collection values.">ippAddCollections</a></li>
	<li><a href="#ippAddDate" title="Add a date attribute to an IPP message.">ippAddDate</a></li>
	<li><a href="#ippAddInteger" title="Add a integer attribute to an IPP message.">ippAddInteger</a></li>
	<li><a href="#ippAddIntegers" title="Add an array of integer values.">ippAddIntegers</a></li>
	<li><a href="#ippAddOctetString" title="Add an octetString value to an IPP message.">ippAddOctetString</a></li>
	<li><a href="#ippAddOutOfBand" title="Add an out-of-band value to an IPP message.">ippAddOutOfBand</a></li>
	<li><a href="#ippAddRange" title="Add a range of values to an IPP message.">ippAddRange</a></li>
	<li><a href="#ippAddRanges" title="Add ranges of values to an IPP message.">ippAddRanges</a></li>
	<li><a href="#ippAddResolution" title="Add a resolution value to an IPP message.">ippAddResolution</a></li>
	<li><a href="#ippAddResolutions" title="Add resolution values to an IPP message.">ippAddResolutions</a></li>
	<li><a href="#ippAddSeparator" title="Add a group separator to an IPP message.">ippAddSeparator</a></li>
	<li><a href="#ippAddString" title="Add a language-encoded string to an IPP message.">ippAddString</a></li>
	<li><a href="#ippAddStringf" title="Add a formatted string to an IPP message.">ippAddStringf</a></li>
	<li><a href="#ippAddStringfv" title="Add a formatted string to an IPP message.">ippAddStringfv</a></li>
	<li><a href="#ippAddStrings" title="Add language-encoded strings to an IPP message.">ippAddStrings</a></li>
	<li><a href="#ippAttributeString" title="Convert the attribute's value to a string.">ippAttributeString</a></li>
	<li><a href="#ippContainsInteger" title="Determine whether an attribute contains the
specified value or is within the list of ranges.">ippContainsInteger</a></li>
	<li><a href="#ippContainsString" title="Determine whether an attribute contains the
specified string value.">ippContainsString</a></li>
	<li><a href="#ippCopyAttribute" title="Copy an attribute.">ippCopyAttribute</a></li>
	<li><a href="#ippCopyAttributes" title="Copy attributes from one IPP message to another.">ippCopyAttributes</a></li>
	<li><a href="#ippCreateRequestedArray" title="Create a CUPS array of attribute names from the
given requested-attributes attribute.">ippCreateRequestedArray</a></li>
	<li><a href="#ippDateToTime" title="Convert from RFC 1903 Date/Time format to UNIX time
in seconds.">ippDateToTime</a></li>
	<li><a href="#ippDelete" title="Delete an IPP message.">ippDelete</a></li>
	<li><a href="#ippDeleteAttribute" title="Delete a single attribute in an IPP message.">ippDeleteAttribute</a></li>
	<li><a href="#ippDeleteValues" title="Delete values in an attribute.">ippDeleteValues</a></li>
	<li><a href="#ippEnumString" title="Return a string corresponding to the enum value.">ippEnumString</a></li>
	<li><a href="#ippEnumValue" title="Return the value associated with a given enum string.">ippEnumValue</a></li>
	<li><a href="#ippErrorString" title="Return a name for the given status code.">ippErrorString</a></li>
	<li><a href="#ippErrorValue" title="Return a status code for the given name.">ippErrorValue</a></li>
	<li><a href="#ippFindAttribute" title="Find a named attribute in a request.">ippFindAttribute</a></li>
	<li><a href="#ippFindNextAttribute" title="Find the next named attribute in a request.">ippFindNextAttribute</a></li>
	<li><a href="#ippFirstAttribute" title="Return the first attribute in the message.">ippFirstAttribute</a></li>
	<li><a href="#ippGetBoolean" title="Get a boolean value for an attribute.">ippGetBoolean</a></li>
	<li><a href="#ippGetCollection" title="Get a collection value for an attribute.">ippGetCollection</a></li>
	<li><a href="#ippGetCount" title="Get the number of values in an attribute.">ippGetCount</a></li>
	<li><a href="#ippGetDate" title="Get a date value for an attribute.">ippGetDate</a></li>
	<li><a href="#ippGetGroupTag" title="Get the group associated with an attribute.">ippGetGroupTag</a></li>
	<li><a href="#ippGetInteger" title="Get the integer/enum value for an attribute.">ippGetInteger</a></li>
	<li><a href="#ippGetName" title="Get the attribute name.">ippGetName</a></li>
	<li><a href="#ippGetOctetString" title="Get an octetString value from an IPP attribute.">ippGetOctetString</a></li>
	<li><a href="#ippGetOperation" title="Get the operation ID in an IPP message.">ippGetOperation</a></li>
	<li><a href="#ippGetRange" title="Get a rangeOfInteger value from an attribute.">ippGetRange</a></li>
	<li><a href="#ippGetRequestId" title="Get the request ID from an IPP message.">ippGetRequestId</a></li>
	<li><a href="#ippGetResolution" title="Get a resolution value for an attribute.">ippGetResolution</a></li>
	<li><a href="#ippGetState" title="Get the IPP message state.">ippGetState</a></li>
	<li><a href="#ippGetStatusCode" title="Get the status code from an IPP response or event message.">ippGetStatusCode</a></li>
	<li><a href="#ippGetString" title="Return the value...">ippGetString</a></li>
	<li><a href="#ippGetValueTag" title="Get the value tag for an attribute.">ippGetValueTag</a></li>
	<li><a href="#ippGetVersion" title="Get the major and minor version number from an IPP message.">ippGetVersion</a></li>
	<li><a href="#ippLength" title="Compute the length of an IPP message.">ippLength</a></li>
	<li><a href="#ippNew" title="Allocate a new IPP message.">ippNew</a></li>
	<li><a href="#ippNewRequest" title="Allocate a new IPP request message.">ippNewRequest</a></li>
	<li><a href="#ippNewResponse" title="Allocate a new IPP response message.">ippNewResponse</a></li>
	<li><a href="#ippNextAttribute" title="Return the next attribute in the message.">ippNextAttribute</a></li>
	<li><a href="#ippOpString" title="Return a name for the given operation id.">ippOpString</a></li>
	<li><a href="#ippOpValue" title="Return an operation id for the given name.">ippOpValue</a></li>
	<li><a href="#ippPort" title="Return the default IPP port number.">ippPort</a></li>
	<li><a href="#ippRead" title="Read data for an IPP message from a HTTP connection.">ippRead</a></li>
	<li><a href="#ippReadFile" title="Read data for an IPP message from a file.">ippReadFile</a></li>
	<li><a href="#ippReadIO" title="Read data for an IPP message.">ippReadIO</a></li>
	<li><a href="#ippSetBoolean" title="Set a boolean value in an attribute.">ippSetBoolean</a></li>
	<li><a href="#ippSetCollection" title="Set a collection value in an attribute.">ippSetCollection</a></li>
	<li><a href="#ippSetDate" title="Set a date value in an attribute.">ippSetDate</a></li>
	<li><a href="#ippSetGroupTag" title="Set the group tag of an attribute.">ippSetGroupTag</a></li>
	<li><a href="#ippSetInteger" title="Set an integer or enum value in an attribute.">ippSetInteger</a></li>
	<li><a href="#ippSetName" title="Set the name of an attribute.">ippSetName</a></li>
	<li><a href="#ippSetOctetString" title="Set an octetString value in an IPP attribute.">ippSetOctetString</a></li>
	<li><a href="#ippSetOperation" title="Set the operation ID in an IPP request message.">ippSetOperation</a></li>
	<li><a href="#ippSetPort" title="Set the default port number.">ippSetPort</a></li>
	<li><a href="#ippSetRange" title="Set a rangeOfInteger value in an attribute.">ippSetRange</a></li>
	<li><a href="#ippSetRequestId" title="Set the request ID in an IPP message.">ippSetRequestId</a></li>
	<li><a href="#ippSetResolution" title="Set a resolution value in an attribute.">ippSetResolution</a></li>
	<li><a href="#ippSetState" title="Set the current state of the IPP message.">ippSetState</a></li>
	<li><a href="#ippSetStatusCode" title="Set the status code in an IPP response or event message.">ippSetStatusCode</a></li>
	<li><a href="#ippSetString" title="Set a string value in an attribute.">ippSetString</a></li>
	<li><a href="#ippSetStringf" title="Set a formatted string value of an attribute.">ippSetStringf</a></li>
	<li><a href="#ippSetStringfv" title="Set a formatted string value of an attribute.">ippSetStringfv</a></li>
	<li><a href="#ippSetValueTag" title="Set the value tag of an attribute.">ippSetValueTag</a></li>
	<li><a href="#ippSetVersion" title="Set the version number in an IPP message.">ippSetVersion</a></li>
	<li><a href="#ippStateString" title="Return the name corresponding to a state value.">ippStateString</a></li>
	<li><a href="#ippTagString" title="Return the tag name corresponding to a tag value.">ippTagString</a></li>
	<li><a href="#ippTagValue" title="Return the tag value corresponding to a tag name.">ippTagValue</a></li>
	<li><a href="#ippTimeToDate" title="Convert from UNIX time to RFC 1903 format.">ippTimeToDate</a></li>
	<li><a href="#ippValidateAttribute" title="Validate the contents of an attribute.">ippValidateAttribute</a></li>
	<li><a href="#ippValidateAttributes" title="Validate all attributes in an IPP message.">ippValidateAttributes</a></li>
	<li><a href="#ippWrite" title="Write data for an IPP message to a HTTP connection.">ippWrite</a></li>
	<li><a href="#ippWriteFile" title="Write data for an IPP message to a file.">ippWriteFile</a></li>
	<li><a href="#ippWriteIO" title="Write data for an IPP message.">ippWriteIO</a></li>
</ul></li>
<li><a href="#TYPES">Data Types</a><ul class="code">
	<li><a href="#gss_auth_identity_desc" title="Local functions...">gss_auth_identity_desc</a></li>
	<li><a href="#http_addr_t" title="Socket address union, which
makes using IPv6 and other
address types easier and
more portable. ">http_addr_t</a></li>
	<li><a href="#http_addrlist_t" title="Socket address list, which is
used to enumerate all of the
addresses that are associated
with a hostname. ">http_addrlist_t</a></li>
	<li><a href="#http_auth_t" title="HTTP authentication types">http_auth_t</a></li>
	<li><a href="#http_credential_t" title="HTTP credential data ">http_credential_t</a></li>
	<li><a href="#http_encoding_t" title="HTTP transfer encoding values">http_encoding_t</a></li>
	<li><a href="#http_encryption_t" title="HTTP encryption values">http_encryption_t</a></li>
	<li><a href="#http_field_t" title="HTTP field names">http_field_t</a></li>
	<li><a href="#http_keepalive_t" title="HTTP keep-alive values">http_keepalive_t</a></li>
	<li><a href="#http_state_t" title="HTTP state values; states
are server-oriented...">http_state_t</a></li>
	<li><a href="#http_t" title="HTTP connection type">http_t</a></li>
	<li><a href="#http_timeout_cb_t" title="HTTP timeout callback ">http_timeout_cb_t</a></li>
	<li><a href="#http_trust_t" title="Level of trust for credentials ">http_trust_t</a></li>
	<li><a href="#http_uri_coding_t" title="URI en/decode flags">http_uri_coding_t</a></li>
	<li><a href="#http_uri_status_t" title="URI separation status ">http_uri_status_t</a></li>
	<li><a href="#http_version_t" title="HTTP version numbers">http_version_t</a></li>
	<li><a href="#ipp_attribute_t" title="IPP attribute">ipp_attribute_t</a></li>
	<li><a href="#ipp_copycb_t" title="The following structures are PRIVATE starting with CUPS 1.6/OS X 10.8.
Please use the new accessor functions available in CUPS 1.6 and later, as
these definitions will be moved to a private header file in a future release.">ipp_copycb_t</a></li>
	<li><a href="#ipp_dstate_t" title="Document states">ipp_dstate_t</a></li>
	<li><a href="#ipp_finish_t" title="Job collation types">ipp_finish_t</a></li>
	<li><a href="#ipp_iocb_t" title="IPP IO Callback Function ">ipp_iocb_t</a></li>
	<li><a href="#ipp_jcollate_t" title="Job collation types">ipp_jcollate_t</a></li>
	<li><a href="#ipp_orient_t" title="Orientation values">ipp_orient_t</a></li>
	<li><a href="#ipp_pstate_t" title="Printer states">ipp_pstate_t</a></li>
	<li><a href="#ipp_quality_t" title="Qualities">ipp_quality_t</a></li>
	<li><a href="#ipp_res_t" title="Resolution units">ipp_res_t</a></li>
	<li><a href="#ipp_state_t" title="IPP states">ipp_state_t</a></li>
	<li><a href="#ipp_t" title="IPP request/response data">ipp_t</a></li>
	<li><a href="#ipp_uchar_t" title="Unsigned 8-bit integer/character">ipp_uchar_t</a></li>
</ul></li>
<li><a href="#STRUCTURES">Structures</a><ul class="code">
	<li><a href="#gss_auth_identity" title="Local functions...">gss_auth_identity</a></li>
	<li><a href="#http_addrlist_s" title="Socket address list, which is
used to enumerate all of the
addresses that are associated
with a hostname. ">http_addrlist_s</a></li>
	<li><a href="#http_credential_s" title="HTTP credential data ">http_credential_s</a></li>
	<li><a href="#pollfd" title="User data (unused)">pollfd</a></li>
</ul></li>
<li><a href="#ENUMERATIONS">Constants</a><ul class="code">
	<li><a href="#http_auth_e" title="HTTP authentication types">http_auth_e</a></li>
	<li><a href="#http_encoding_e" title="HTTP transfer encoding values">http_encoding_e</a></li>
	<li><a href="#http_encryption_e" title="HTTP encryption values">http_encryption_e</a></li>
	<li><a href="#http_field_e" title="HTTP field names">http_field_e</a></li>
	<li><a href="#http_keepalive_e" title="HTTP keep-alive values">http_keepalive_e</a></li>
	<li><a href="#http_state_e" title="HTTP state values; states
are server-oriented...">http_state_e</a></li>
	<li><a href="#http_status_e" title="HTTP status codes">http_status_e</a></li>
	<li><a href="#http_trust_e" title="Level of trust for credentials ">http_trust_e</a></li>
	<li><a href="#http_uri_coding_e" title="URI en/decode flags">http_uri_coding_e</a></li>
	<li><a href="#http_uri_status_e" title="URI separation status ">http_uri_status_e</a></li>
	<li><a href="#http_version_e" title="HTTP version numbers">http_version_e</a></li>
	<li><a href="#ipp_dstate_e" title="Document states">ipp_dstate_e</a></li>
	<li><a href="#ipp_finishings_e" title="Finishings">ipp_finishings_e</a></li>
	<li><a href="#ipp_jcollate_e" title="Job collation types">ipp_jcollate_e</a></li>
	<li><a href="#ipp_jstate_e" title="Job states">ipp_jstate_e</a></li>
	<li><a href="#ipp_op_e" title="IPP operations">ipp_op_e</a></li>
	<li><a href="#ipp_orient_e" title="Orientation values">ipp_orient_e</a></li>
	<li><a href="#ipp_pstate_e" title="Printer states">ipp_pstate_e</a></li>
	<li><a href="#ipp_quality_e" title="Qualities">ipp_quality_e</a></li>
	<li><a href="#ipp_res_e" title="Resolution units">ipp_res_e</a></li>
	<li><a href="#ipp_state_e" title="IPP states">ipp_state_e</a></li>
	<li><a href="#ipp_status_e" title="IPP status codes">ipp_status_e</a></li>
	<li><a href="#ipp_tag_e" title="Format tags for attributes">ipp_tag_e</a></li>
</ul></li>
</ul>
<!--
  "$Id: api-httpipp.shtml 7684 2008-06-23 16:47:38Z mike $"

  HTTP and IPP API introduction for CUPS.

  Copyright 2007-2012 by Apple Inc.
  Copyright 1997-2006 by Easy Software Products, all rights reserved.

  These coded instructions, statements, and computer programs are the
  property of Apple Inc. and are protected by Federal copyright
  law.  Distribution and use rights are outlined in the file "LICENSE.txt"
  which should have been included with this file.  If this file is
  file is missing or damaged, see the license at "http://www.cups.org/".
-->

<h2 class='title'><a name='OVERVIEW'>Overview</a></h2>

<p>The CUPS HTTP and IPP APIs provide low-level access to the HTTP and IPP
protocols and CUPS scheduler. They are typically used by monitoring and
administration programs to perform specific functions not supported by the
high-level CUPS API functions.</p>

<p>The HTTP APIs use an opaque structure called
<a href='#http_t'><code>http_t</code></a> to manage connections to
a particular HTTP or IPP server. The
<a href='#httpConnectEncrypt'><code>httpConnectEncrypt</code></a> function is
used to create an instance of this structure for a particular server.
The constant <code>CUPS_HTTP_DEFAULT</code> can be used with all of the
<code>cups</code> functions to refer to the default CUPS server - the functions
create a per-thread <a href='#http_t'><code>http_t</code></a> as needed.</p>

<p>The IPP APIs use two opaque structures for requests (messages sent to the CUPS scheduler) and responses (messages sent back to your application from the scheduler). The <a href='#ipp_t'><code>ipp_t</code></a> type holds a complete request or response and is allocated using the <a href='#ippNew'><code>ippNew</code></a> or <a href='#ippNewRequest'><code>ippNewRequest</code></a> functions and freed using the <a href='#ippDelete'><code>ippDelete</code></a> function.</p>

<p>The second opaque structure is called <a href='#ipp_attribute_t'><code>ipp_attribute_t</code></a> and holds a single IPP attribute which consists of a group tag (<a href='#ippGetGroupTag'><code>ippGetGroupTag</code></a>), a value type tag (<a href='#ippGetValueTag'><code>ippGetValueTag</code></a>), the attribute name (<a href='#ippGetName'><code>ippGetName</code></a>), and 1 or more values (<a href='#ippGetCount'><code>ippGetCount</code></a>, <a href='#ippGetBoolean'><code>ippGetBoolean</code></a>, <a href='#ippGetCollection'><code>ippGetCollection</code></a>, <a href='#ippGetDate'><code>ippGetDate</code></a>, <a href='#ippGetInteger'><code>ippGetInteger</code></a>, <a href='#ippGetRange'><code>ippGetRange</code></a>, <a href='#ippGetResolution'><code>ippGetResolution</code></a>, and <a href='#ippGetString'><code>ippGetString</code></a>). Attributes are added to an <a href='#ipp_t'><code>ipp_t</code></a> pointer using one of the <code>ippAdd</code> functions. For example, use <a href='#ippAddString'><code>ippAddString</code></a> to add the "printer-uri" and "requesting-user-name" string attributes to a request:</p>

<pre class='example'>
<a href='#ipp_t'>ipp_t</a> *request = <a href='#ippNewRequest'>ippNewRequest</a>(IPP_GET_JOBS);

<a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_URI, "printer-uri",
             NULL, "ipp://localhost/printers/");
<a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "requesting-user-name",
             NULL, cupsUser());
</pre>

<p>Once you have created an IPP request, use the <code>cups</code> functions to send the request to and read the response from the server. For example, the <a href='#cupsDoRequest'><code>cupsDoRequest</code></a> function can be used for simple query operations that do not involve files:</p>

<pre class='example'>
#include &lt;cups/cups.h&gt;


<a href='#ipp_t'>ipp_t</a> *<a name='get_jobs'>get_jobs</a>(void)
{
  <a href='#ipp_t'>ipp_t</a> *request = <a href='#ippNewRequest'>ippNewRequest</a>(IPP_GET_JOBS);

  <a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_URI, "printer-uri",
               NULL, "ipp://localhost/printers/");
  <a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "requesting-user-name",
               NULL, cupsUser());

  return (<a href='#cupsDoRequest'>cupsDoRequest</a>(CUPS_HTTP_DEFAULT, request, "/"));
}
</pre>

<p>The <a href='#cupsDoRequest'><code>cupsDoRequest</code></a> function frees the request and returns an IPP response or <code>NULL</code> pointer if the request could not be sent to the server. Once you have a response from the server, you can either use the <a href='#ippFindAttribute'><code>ippFindAttribute</code></a> and <a href='#ippFindNextAttribute'><code>ippFindNextAttribute</code></a> functions to find specific attributes, for example:</p>

<pre class='example'>
<a href='#ipp_t'>ipp_t</a> *response;
<a href='#ipp_attribute_t'>ipp_attribute_t</a> *attr;

attr = <a href='#ippFindAttribute'>ippFindAttribute</a>(response, "printer-state", IPP_TAG_ENUM);
</pre>

<p>You can also walk the list of attributes with a simple <code>for</code> loop like this:</p>

<pre class='example'>
<a href='#ipp_t'>ipp_t</a> *response;
<a href='#ipp_attribute_t'>ipp_attribute_t</a> *attr;

for (attr = <a href='#ippFirstAttribute'>ippFirstAttribute</a>(response); attr != NULL; attr = <a href='#ippNextAttribute'>ippNextAttribute</a>(response))
  if (ippGetName(attr) == NULL)
    puts("--SEPARATOR--");
  else
    puts(ippGetName(attr));
</pre>

<p>The <code>for</code> loop approach is normally used when collecting attributes for multiple objects (jobs, printers, etc.) in a response. Attributes with <code>NULL</code> names indicate a separator between the attributes of each object. For example, the following code will list the jobs returned from our previous <a href='#get_jobs'><code>get_jobs</code></a> example code:</p>

<pre class='example'>
<a href='#ipp_t'>ipp_t</a> *response = <a href='#get_jobs'>get_jobs</a>();

if (response != NULL)
{
  <a href='#ipp_attribute_t'>ipp_attribute_t</a> *attr;
  const char *attrname;
  int job_id = 0;
  const char *job_name = NULL;
  const char *job_originating_user_name = NULL;

  puts("Job ID  Owner             Title");
  puts("------  ----------------  ---------------------------------");

  for (attr = <a href='#ippFirstAttribute'>ippFirstAttribute</a>(response); attr != NULL; attr = <a href='#ippNextAttribute'>ippNextAttribute</a>(response))
  {
   /* Attributes without names are separators between jobs */
    attrname = ippGetName(attr);
    if (attrname == NULL)
    {
      if (job_id > 0)
      {
        if (job_name == NULL)
          job_name = "(withheld)";

        if (job_originating_user_name == NULL)
          job_originating_user_name = "(withheld)";

        printf("%5d  %-16s  %s\n", job_id, job_originating_user_name, job_name);
      }

      job_id = 0;
      job_name = NULL;
      job_originating_user_name = NULL;
      continue;
    }
    else if (!strcmp(attrname, "job-id") &amp;&amp; ippGetValueTag(attr) == IPP_TAG_INTEGER)
      job_id = ippGetInteger(attr, 0);
    else if (!strcmp(attrname, "job-name") &amp;&amp; ippGetValueTag(attr) == IPP_TAG_NAME)
      job_name = ippGetString(attr, 0, NULL);
    else if (!strcmp(attrname, "job-originating-user-name") &amp;&amp;
             ippGetValueTag(attr) == IPP_TAG_NAME)
      job_originating_user_name = ippGetString(attr, 0, NULL);
  }

  if (job_id > 0)
  {
    if (job_name == NULL)
      job_name = "(withheld)";

    if (job_originating_user_name == NULL)
      job_originating_user_name = "(withheld)";

    printf("%5d  %-16s  %s\n", job_id, job_originating_user_name, job_name);
  }
}
</pre>

<h3><a name='CREATING_URI_STRINGS'>Creating URI Strings</a></h3>

<p>To ensure proper encoding, the
<a href='#httpAssembleURIf'><code>httpAssembleURIf</code></a> function must be
used to format a "printer-uri" string for all printer-based requests:</p>

<pre class='example'>
const char *name = "Foo";
char uri[1024];
<a href='#ipp_t'>ipp_t</a> *request;

<a href='#httpAssembleURIf'>httpAssembleURIf</a>(HTTP_URI_CODING_ALL, uri, sizeof(uri), "ipp", NULL, cupsServer(),
                 ippPort(), "/printers/%s", name);
<a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_URI, "printer-uri", NULL, uri);
</pre>

<h3><a name='SENDING_REQUESTS_WITH_FILES'>Sending Requests with Files</a></h3>

<p>The <a href='#cupsDoFileRequest'><code>cupsDoFileRequest</code></a> and
<a href='#cupsDoIORequest'><code>cupsDoIORequest</code></a> functions are
used for requests involving files. The
<a href='#cupsDoFileRequest'><code>cupsDoFileRequest</code></a> function
attaches the named file to a request and is typically used when sending a print
file or changing a printer's PPD file:</p>

<pre class='example'>
const char *filename = "/usr/share/cups/data/testprint.ps";
const char *name = "Foo";
char uri[1024];
char resource[1024];
<a href='#ipp_t'>ipp_t</a> *request = <a href='#ippNewRequest'>ippNewRequest</a>(IPP_PRINT_JOB);
<a href='#ipp_t'>ipp_t</a> *response;

/* Use httpAssembleURIf for the printer-uri string */
<a href='#httpAssembleURIf'>httpAssembleURIf</a>(HTTP_URI_CODING_ALL, uri, sizeof(uri), "ipp", NULL, cupsServer(),
                 ippPort(), "/printers/%s", name);
<a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_URI, "printer-uri", NULL, uri);
<a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "requesting-user-name",
             NULL, cupsUser());
<a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "job-name",
             NULL, "testprint.ps");

/* Use snprintf for the resource path */
snprintf(resource, sizeof(resource), "/printers/%s", name);

response = <a href='#cupsDoFileRequest'>cupsDoFileRequest</a>(CUPS_HTTP_DEFAULT, request, resource, filename);
</pre>

<p>The <a href='#cupsDoIORequest'><code>cupsDoIORequest</code></a> function
optionally attaches a file to the request and optionally saves a file in the
response from the server. It is used when using a pipe for the request
attachment or when using a request that returns a file, currently only
<code>CUPS_GET_DOCUMENT</code> and <code>CUPS_GET_PPD</code>. For example,
the following code will download the PPD file for the sample HP LaserJet
printer driver:</p>

<pre class='example'>
char tempfile[1024];
int tempfd;
<a href='#ipp_t'>ipp_t</a> *request = <a href='#ippNewRequest'>ippNewRequest</a>(CUPS_GET_PPD);
<a href='#ipp_t'>ipp_t</a> *response;

<a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "ppd-name",
             NULL, "laserjet.ppd");

tempfd = cupsTempFd(tempfile, sizeof(tempfile));

response = <a href='#cupsDoIORequest'>cupsDoIORequest</a>(CUPS_HTTP_DEFAULT, request, "/", -1, tempfd);
</pre>

<p>The example passes <code>-1</code> for the input file descriptor to specify
that no file is to be attached to the request. The PPD file attached to the
response is written to the temporary file descriptor we created using the
<code>cupsTempFd</code> function.</p>

<h3><a name='ASYNCHRONOUS_REQUEST_PROCESSING'>Asynchronous Request Processing</a></h3>

<p>The <a href='#cupsSendRequest'><code>cupsSendRequest</code></a> and
<a href='#cupsGetResponse'><code>cupsGetResponse</code></a> support
asynchronous communications with the server. Unlike the other request
functions, the IPP request is not automatically freed, so remember to
free your request with the <a href='#ippDelete'><code>ippDelete</code></a>
function.</p>

<p>File data is attached to the request using the
<a href='#cupsWriteRequestData'><code>cupsWriteRequestData</code></a>
function, while file data returned from the server is read using the
<a href='#cupsReadResponseData'><code>cupsReadResponseData</code></a>
function. We can rewrite the previous <code>CUPS_GET_PPD</code> example
to use the asynchronous functions quite easily:</p>

<pre class='example'>
char tempfile[1024];
int tempfd;
<a href='#ipp_t'>ipp_t</a> *request = <a href='#ippNewRequest'>ippNewRequest</a>(CUPS_GET_PPD);
<a href='#ipp_t'>ipp_t</a> *response;

<a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "ppd-name",
             NULL, "laserjet.ppd");

tempfd = cupsTempFd(tempfile, sizeof(tempfile));

if (<a href='#cupsSendRequest'>cupsSendRequest</a>(CUPS_HTTP_DEFAULT, request, "/") == HTTP_CONTINUE)
{
  response = <a href='#cupsGetResponse'>cupsGetResponse</a>(CUPS_HTTP_DEFAULT, "/");

  if (response != NULL)
  {
    ssize_t bytes;
    char buffer[8192];

    while ((bytes = <a href='#cupsReadResponseData'>cupsReadResponseData</a>(CUPS_HTTP_DEFAULT, buffer, sizeof(buffer))) > 0)
      write(tempfd, buffer, bytes);
  }
}

/* Free the request! */
<a href='#ippDelete'>ippDelete</a>(request);
</pre>

<p>The <a href='#cupsSendRequest'><code>cupsSendRequest</code></a> function
returns the initial HTTP request status, typically either
<code>HTTP_CONTINUE</code> or <code>HTTP_UNAUTHORIZED</code>. The latter status
is returned when the request requires authentication of some sort. The
<a href='#cupsDoAuthentication'><code>cupsDoAuthentication</code></a> function
must be called when your see <code>HTTP_UNAUTHORIZED</code> and the request
re-sent. We can add authentication support to our example code by using a
<code>do ... while</code> loop:</p>

<pre class='example'>
char tempfile[1024];
int tempfd;
<a href='#ipp_t'>ipp_t</a> *request = <a href='#ippNewRequest'>ippNewRequest</a>(CUPS_GET_PPD);
<a href='#ipp_t'>ipp_t</a> *response;
http_status_t status;

<a href='#ippAddString'>ippAddString</a>(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "ppd-name",
             NULL, "laserjet.ppd");

tempfd = cupsTempFd(tempfile, sizeof(tempfile));

/* Loop for authentication */
do
{
  status = <a href='#cupsSendRequest'>cupsSendRequest</a>(CUPS_HTTP_DEFAULT, request, "/");

  if (status == HTTP_UNAUTHORIZED)
  {
    /* Try to authenticate, break out of the loop if that fails */
    if (<a href='#cupsDoAuthentication'>cupsDoAuthentication</a>(CUPS_HTTP_DEFAULT, "POST", "/"))
      break;
  }
}
while (status != HTTP_CONTINUE &amp;&amp; status != HTTP_UNAUTHORIZED);

if (status == HTTP_CONTINUE)
{
  response = <a href='#cupsGetResponse'>cupsGetResponse</a>(CUPS_HTTP_DEFAULT, "/");

  if (response != NULL)
  {
    ssize_t bytes;
    char buffer[8192];

    while ((bytes = <a href='#cupsReadResponseData'>cupsReadResponseData</a>(CUPS_HTTP_DEFAULT, buffer, sizeof(buffer))) > 0)
      write(tempfd, buffer, bytes);
  }
}

/* Free the request! */
<a href='#ippDelete'>ippDelete</a>(request);
</pre>
<h2 class="title"><a name="FUNCTIONS">Functions</a></h2>
<h3 class="function"><span class="info">&nbsp;CUPS 1.1.20/OS X 10.4&nbsp;</span><a name="cupsDoAuthentication">cupsDoAuthentication</a></h3>
<p class="description">Authenticate a request.</p>
<p class="code">
int cupsDoAuthentication (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *method,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *resource<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd>
<dt>method</dt>
<dd class="description">Request method (&quot;GET&quot;, &quot;POST&quot;, &quot;PUT&quot;)</dd>
<dt>resource</dt>
<dd class="description">Resource path</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">0 on success, -1 on error</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function should be called in response to a <code>HTTP_STATUS_UNAUTHORIZED</code>
status, prior to resubmitting your request.

</p>
<h3 class="function"><a name="cupsDoFileRequest">cupsDoFileRequest</a></h3>
<p class="description">Do an IPP request with a file.</p>
<p class="code">
<a href="#ipp_t">ipp_t</a> *cupsDoFileRequest (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *request,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *resource,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *filename<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd>
<dt>request</dt>
<dd class="description">IPP request</dd>
<dt>resource</dt>
<dd class="description">HTTP resource for POST</dd>
<dt>filename</dt>
<dd class="description">File to send or <code>NULL</code> for none</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Response data</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function sends the IPP request and attached file to the specified
server, retrying and authenticating as necessary.  The request is freed with
<a href="#ippDelete"><code>ippDelete</code></a>.</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.3/OS X 10.5&nbsp;</span><a name="cupsDoIORequest">cupsDoIORequest</a></h3>
<p class="description">Do an IPP request with file descriptors.</p>
<p class="code">
<a href="#ipp_t">ipp_t</a> *cupsDoIORequest (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *request,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *resource,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int infile,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int outfile<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd>
<dt>request</dt>
<dd class="description">IPP request</dd>
<dt>resource</dt>
<dd class="description">HTTP resource for POST</dd>
<dt>infile</dt>
<dd class="description">File to read from or -1 for none</dd>
<dt>outfile</dt>
<dd class="description">File to write to or -1 for none</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Response data</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function sends the IPP request with the optional input file &quot;infile&quot; to
the specified server, retrying and authenticating as necessary.  The request
is freed with <a href="#ippDelete"><code>ippDelete</code></a>.<br>
<br>
If &quot;infile&quot; is a valid file descriptor, <code>cupsDoIORequest</code> copies
all of the data from the file after the IPP request message.<br>
<br>
If &quot;outfile&quot; is a valid file descriptor, <code>cupsDoIORequest</code> copies
all of the data after the IPP response message to the file.

</p>
<h3 class="function"><a name="cupsDoRequest">cupsDoRequest</a></h3>
<p class="description">Do an IPP request.</p>
<p class="code">
<a href="#ipp_t">ipp_t</a> *cupsDoRequest (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *request,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *resource<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd>
<dt>request</dt>
<dd class="description">IPP request</dd>
<dt>resource</dt>
<dd class="description">HTTP resource for POST</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Response data</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function sends the IPP request to the specified server, retrying
and authenticating as necessary.  The request is freed with <a href="#ippDelete"><code>ippDelete</code></a>.</p>
<h3 class="function"><a name="cupsEncodeOptions">cupsEncodeOptions</a></h3>
<p class="description">Encode printer options into IPP attributes.</p>
<p class="code">
void cupsEncodeOptions (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int num_options,<br>
&nbsp;&nbsp;&nbsp;&nbsp;cups_option_t *options<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">Request to add to</dd>
<dt>num_options</dt>
<dd class="description">Number of options</dd>
<dt>options</dt>
<dd class="description">Options</dd>
</dl>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function adds operation, job, and then subscription attributes,
in that order. Use the cupsEncodeOptions2() function to add attributes
for a single group.</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="cupsEncodeOptions2">cupsEncodeOptions2</a></h3>
<p class="description">Encode printer options into IPP attributes for a group.</p>
<p class="code">
void cupsEncodeOptions2 (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int num_options,<br>
&nbsp;&nbsp;&nbsp;&nbsp;cups_option_t *options,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group_tag<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">Request to add to</dd>
<dt>num_options</dt>
<dd class="description">Number of options</dd>
<dt>options</dt>
<dd class="description">Options</dd>
<dt>group_tag</dt>
<dd class="description">Group to encode</dd>
</dl>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function only adds attributes for a single group. Call this
function multiple times for each group, or use cupsEncodeOptions()
to add the standard groups.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.4/OS X 10.6&nbsp;</span><a name="cupsGetDevices">cupsGetDevices</a></h3>
<p class="description">Get available printer devices.</p>
<p class="code">
ipp_status_t cupsGetDevices (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int timeout,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *include_schemes,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *exclude_schemes,<br>
&nbsp;&nbsp;&nbsp;&nbsp;cups_device_cb_t callback,<br>
&nbsp;&nbsp;&nbsp;&nbsp;void *user_data<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd>
<dt>timeout</dt>
<dd class="description">Timeout in seconds or <code>CUPS_TIMEOUT_DEFAULT</code></dd>
<dt>include_schemes</dt>
<dd class="description">Comma-separated URI schemes to include or <code>CUPS_INCLUDE_ALL</code></dd>
<dt>exclude_schemes</dt>
<dd class="description">Comma-separated URI schemes to exclude or <code>CUPS_EXCLUDE_NONE</code></dd>
<dt>callback</dt>
<dd class="description">Callback function</dd>
<dt>user_data</dt>
<dd class="description">User data pointer</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Request status - <code>IPP_OK</code> on success.</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function sends a CUPS-Get-Devices request and streams the discovered
devices to the specified callback function. The &quot;timeout&quot; parameter controls
how long the request lasts, while the &quot;include_schemes&quot; and &quot;exclude_schemes&quot;
parameters provide comma-delimited lists of backends to include or omit from
the request respectively.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.1.20/OS X 10.4&nbsp;</span><a name="cupsGetFd">cupsGetFd</a></h3>
<p class="description">Get a file from the server.</p>
<p class="code">
http_status_t cupsGetFd (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *resource,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int fd<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd>
<dt>resource</dt>
<dd class="description">Resource name</dd>
<dt>fd</dt>
<dd class="description">File descriptor</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">HTTP status</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function returns <code>HTTP_STATUS_OK</code> when the file is successfully retrieved.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.1.20/OS X 10.4&nbsp;</span><a name="cupsGetFile">cupsGetFile</a></h3>
<p class="description">Get a file from the server.</p>
<p class="code">
http_status_t cupsGetFile (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *resource,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *filename<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd>
<dt>resource</dt>
<dd class="description">Resource name</dd>
<dt>filename</dt>
<dd class="description">Filename</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">HTTP status</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function returns <code>HTTP_STATUS_OK</code> when the file is successfully retrieved.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.4/OS X 10.6&nbsp;</span><a name="cupsGetResponse">cupsGetResponse</a></h3>
<p class="description">Get a response to an IPP request.</p>
<p class="code">
<a href="#ipp_t">ipp_t</a> *cupsGetResponse (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *resource<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd>
<dt>resource</dt>
<dd class="description">HTTP resource for POST</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Response or <code>NULL</code> on HTTP error</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">Use this function to get the response for an IPP request sent using
<a href="#cupsSendRequest"><code>cupsSendRequest</code></a>. For requests that return additional data, use
<a href="#cupsReadResponseData"><code>cupsReadResponseData</code></a> after getting a successful response,
otherwise call <a href="#httpFlush"><code>httpFlush</code></a> to complete the response processing.

</p>
<h3 class="function"><a name="cupsLastError">cupsLastError</a></h3>
<p class="description">Return the last IPP status code received on the current
thread.</p>
<p class="code">
ipp_status_t cupsLastError (void);</p>
<h4 class="returnvalue">Return Value</h4>
<p class="description">IPP status code from last request</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="cupsLastErrorString">cupsLastErrorString</a></h3>
<p class="description">Return the last IPP status-message received on the
current thread.</p>
<p class="code">
const char *cupsLastErrorString (void);</p>
<h4 class="returnvalue">Return Value</h4>
<p class="description">status-message text from last request</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.1.20/OS X 10.4&nbsp;</span><a name="cupsPutFd">cupsPutFd</a></h3>
<p class="description">Put a file on the server.</p>
<p class="code">
http_status_t cupsPutFd (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *resource,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int fd<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd>
<dt>resource</dt>
<dd class="description">Resource name</dd>
<dt>fd</dt>
<dd class="description">File descriptor</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">HTTP status</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function returns <code>HTTP_STATUS_CREATED</code> when the file is stored
successfully.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.1.20/OS X 10.4&nbsp;</span><a name="cupsPutFile">cupsPutFile</a></h3>
<p class="description">Put a file on the server.</p>
<p class="code">
http_status_t cupsPutFile (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *resource,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *filename<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd>
<dt>resource</dt>
<dd class="description">Resource name</dd>
<dt>filename</dt>
<dd class="description">Filename</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">HTTP status</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function returns <code>HTTP_CREATED</code> when the file is stored
successfully.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.4/OS X 10.6&nbsp;</span><a name="cupsReadResponseData">cupsReadResponseData</a></h3>
<p class="description">Read additional data after the IPP response.</p>
<p class="code">
ssize_t cupsReadResponseData (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *buffer,<br>
&nbsp;&nbsp;&nbsp;&nbsp;size_t length<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd>
<dt>buffer</dt>
<dd class="description">Buffer to use</dd>
<dt>length</dt>
<dd class="description">Number of bytes to read</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Bytes read, 0 on EOF, -1 on error</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function is used after <a href="#cupsGetResponse"><code>cupsGetResponse</code></a> to read the PPD or document
files from <code>CUPS_GET_PPD</code> and <code>CUPS_GET_DOCUMENT</code> requests,
respectively.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.4/OS X 10.6&nbsp;</span><a name="cupsSendRequest">cupsSendRequest</a></h3>
<p class="description">Send an IPP request.</p>
<p class="code">
http_status_t cupsSendRequest (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *request,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *resource,<br>
&nbsp;&nbsp;&nbsp;&nbsp;size_t length<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd>
<dt>request</dt>
<dd class="description">IPP request</dd>
<dt>resource</dt>
<dd class="description">Resource path</dd>
<dt>length</dt>
<dd class="description">Length of data to follow or <code>CUPS_LENGTH_VARIABLE</code></dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Initial HTTP status</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">Use <a href="#cupsWriteRequestData"><code>cupsWriteRequestData</code></a> to write any additional data (document, PPD
file, etc.) for the request, <a href="#cupsGetResponse"><code>cupsGetResponse</code></a> to get the IPP response,
and <a href="#cupsReadResponseData"><code>cupsReadResponseData</code></a> to read any additional data following the
response. Only one request can be sent/queued at a time per <code>http_t</code>
connection.<br>
<br>
Returns the initial HTTP status code, which will be <code>HTTP_STATUS_CONTINUE</code>
on a successful send of the request.<br>
<br>
Note: Unlike <a href="#cupsDoFileRequest"><code>cupsDoFileRequest</code></a>, <a href="#cupsDoIORequest"><code>cupsDoIORequest</code></a>, and
<a href="#cupsDoRequest"><code>cupsDoRequest</code></a>, the request is NOT freed with <a href="#ippDelete"><code>ippDelete</code></a>.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.4/OS X 10.6&nbsp;</span><a name="cupsWriteRequestData">cupsWriteRequestData</a></h3>
<p class="description">Write additional data after an IPP request.</p>
<p class="code">
http_status_t cupsWriteRequestData (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *buffer,<br>
&nbsp;&nbsp;&nbsp;&nbsp;size_t length<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">Connection to server or <code>CUPS_HTTP_DEFAULT</code></dd>
<dt>buffer</dt>
<dd class="description">Bytes to write</dd>
<dt>length</dt>
<dd class="description">Number of bytes to write</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description"><code>HTTP_STATUS_CONTINUE</code> if OK or HTTP status on error</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function is used after <a href="#cupsSendRequest"><code>cupsSendRequest</code></a> to provide a PPD and
after <a href="#cupsStartDocument"><code>cupsStartDocument</code></a> to provide a document file.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="httpAcceptConnection">httpAcceptConnection</a></h3>
<p class="description">Accept a new HTTP client connection from the
specified listening socket.</p>
<p class="code">
<a href="#http_t">http_t</a> *httpAcceptConnection (<br>
&nbsp;&nbsp;&nbsp;&nbsp;int fd,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int blocking<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>fd</dt>
<dd class="description">Listen socket file descriptor</dd>
<dt>blocking</dt>
<dd class="description">1 if the connection should be
blocking, 0 otherwise</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">HTTP connection or <code>NULL</code></p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.5/OS X 10.7&nbsp;</span><a name="httpAddCredential">httpAddCredential</a></h3>
<p class="description">Allocates and adds a single credential to an array.</p>
<p class="code">
int httpAddCredential (<br>
&nbsp;&nbsp;&nbsp;&nbsp;cups_array_t *credentials,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const void *data,<br>
&nbsp;&nbsp;&nbsp;&nbsp;size_t datalen<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>credentials</dt>
<dd class="description">Credentials array</dd>
<dt>data</dt>
<dd class="description">PEM-encoded X.509 data</dd>
<dt>datalen</dt>
<dd class="description">Length of data</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">0 on success, -1 on error</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">Use <code>cupsArrayNew(NULL, NULL)</code> to create a credentials array.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpAddrAny">httpAddrAny</a></h3>
<p class="description">Check for the &quot;any&quot; address.</p>
<p class="code">
int httpAddrAny (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const <a href="#http_addr_t">http_addr_t</a> *addr<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>addr</dt>
<dd class="description">Address to check</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 if &quot;any&quot;, 0 otherwise</p>
<h3 class="function"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="httpAddrClose">httpAddrClose</a></h3>
<p class="description">Close a socket created by <a href="#httpAddrConnect"><code>httpAddrConnect</code></a> or
<a href="#httpAddrListen"><code>httpAddrListen</code></a>.</p>
<p class="code">
int httpAddrClose (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_addr_t">http_addr_t</a> *addr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int fd<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>addr</dt>
<dd class="description">Listen address or <code>NULL</code></dd>
<dt>fd</dt>
<dd class="description">Socket file descriptor</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">0 on success, -1 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">Pass <code>NULL</code> for sockets created with <a href="#httpAddrConnect"><code>httpAddrConnect</code></a> and the
listen address for sockets created with <a href="#httpAddrListen"><code>httpAddrListen</code></a>. This will
ensure that domain sockets are removed when closed.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpAddrEqual">httpAddrEqual</a></h3>
<p class="description">Compare two addresses.</p>
<p class="code">
int httpAddrEqual (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const <a href="#http_addr_t">http_addr_t</a> *addr1,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const <a href="#http_addr_t">http_addr_t</a> *addr2<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>addr1</dt>
<dd class="description">First address</dd>
<dt>addr2</dt>
<dd class="description">Second address</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 if equal, 0 if not</p>
<h3 class="function"><a name="httpAddrFamily">httpAddrFamily</a></h3>
<p class="description">Get the address family of an address.</p>
<p class="code">
int httpAddrFamily (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_addr_t">http_addr_t</a> *addr<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>addr</dt>
<dd class="description">Address</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Address family</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpAddrLength">httpAddrLength</a></h3>
<p class="description">Return the length of the address in bytes.</p>
<p class="code">
int httpAddrLength (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const <a href="#http_addr_t">http_addr_t</a> *addr<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>addr</dt>
<dd class="description">Address</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Length in bytes</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="httpAddrListen">httpAddrListen</a></h3>
<p class="description">Create a listening socket bound to the specified
address and port.</p>
<p class="code">
int httpAddrListen (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_addr_t">http_addr_t</a> *addr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int port<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>addr</dt>
<dd class="description">Address to bind to</dd>
<dt>port</dt>
<dd class="description">Port number to bind to</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Socket or -1 on error</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpAddrLocalhost">httpAddrLocalhost</a></h3>
<p class="description">Check for the local loopback address.</p>
<p class="code">
int httpAddrLocalhost (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const <a href="#http_addr_t">http_addr_t</a> *addr<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>addr</dt>
<dd class="description">Address to check</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 if local host, 0 otherwise</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpAddrLookup">httpAddrLookup</a></h3>
<p class="description">Lookup the hostname associated with the address.</p>
<p class="code">
char *httpAddrLookup (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const <a href="#http_addr_t">http_addr_t</a> *addr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int namelen<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>addr</dt>
<dd class="description">Address to lookup</dd>
<dt>name</dt>
<dd class="description">Host name buffer</dd>
<dt>namelen</dt>
<dd class="description">Size of name buffer</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Host name</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="httpAddrPort">httpAddrPort</a></h3>
<p class="description">Get the port number associated with an address.</p>
<p class="code">
int httpAddrPort (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_addr_t">http_addr_t</a> *addr<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>addr</dt>
<dd class="description">Address</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Port number</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpAddrString">httpAddrString</a></h3>
<p class="description">Convert an address to a numeric string.</p>
<p class="code">
char *httpAddrString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const <a href="#http_addr_t">http_addr_t</a> *addr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *s,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int slen<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>addr</dt>
<dd class="description">Address to convert</dd>
<dt>s</dt>
<dd class="description">String buffer</dd>
<dt>slen</dt>
<dd class="description">Length of string</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Numeric address string</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpAssembleURI">httpAssembleURI</a></h3>
<p class="description">Assemble a uniform resource identifier from its
components.</p>
<p class="code">
<a href="#http_uri_status_t">http_uri_status_t</a> httpAssembleURI (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_uri_coding_t">http_uri_coding_t</a> encoding,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *uri,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int urilen,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *scheme,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *username,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *host,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int port,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *resource<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>encoding</dt>
<dd class="description">Encoding flags</dd>
<dt>uri</dt>
<dd class="description">URI buffer</dd>
<dt>urilen</dt>
<dd class="description">Size of URI buffer</dd>
<dt>scheme</dt>
<dd class="description">Scheme name</dd>
<dt>username</dt>
<dd class="description">Username</dd>
<dt>host</dt>
<dd class="description">Hostname or address</dd>
<dt>port</dt>
<dd class="description">Port number</dd>
<dt>resource</dt>
<dd class="description">Resource</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">URI status</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function escapes reserved characters in the URI depending on the
value of the &quot;encoding&quot; argument.  You should use this function in
place of traditional string functions whenever you need to create a
URI string.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpAssembleURIf">httpAssembleURIf</a></h3>
<p class="description">Assemble a uniform resource identifier from its
components with a formatted resource.</p>
<p class="code">
<a href="#http_uri_status_t">http_uri_status_t</a> httpAssembleURIf (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_uri_coding_t">http_uri_coding_t</a> encoding,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *uri,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int urilen,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *scheme,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *username,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *host,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int port,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *resourcef,<br>
&nbsp;&nbsp;&nbsp;&nbsp;...<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>encoding</dt>
<dd class="description">Encoding flags</dd>
<dt>uri</dt>
<dd class="description">URI buffer</dd>
<dt>urilen</dt>
<dd class="description">Size of URI buffer</dd>
<dt>scheme</dt>
<dd class="description">Scheme name</dd>
<dt>username</dt>
<dd class="description">Username</dd>
<dt>host</dt>
<dd class="description">Hostname or address</dd>
<dt>port</dt>
<dd class="description">Port number</dd>
<dt>resourcef</dt>
<dd class="description">Printf-style resource</dd>
<dt>...</dt>
<dd class="description">Additional arguments as needed</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">URI status</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function creates a formatted version of the resource string
argument &quot;resourcef&quot; and escapes reserved characters in the URI
depending on the value of the &quot;encoding&quot; argument.  You should use
this function in place of traditional string functions whenever
you need to create a URI string.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="httpAssembleUUID">httpAssembleUUID</a></h3>
<p class="description">Assemble a name-based UUID URN conforming to RFC 4122.</p>
<p class="code">
char *httpAssembleUUID (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *server,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int port,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int number,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *buffer,<br>
&nbsp;&nbsp;&nbsp;&nbsp;size_t bufsize<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>server</dt>
<dd class="description">Server name</dd>
<dt>port</dt>
<dd class="description">Port number</dd>
<dt>name</dt>
<dd class="description">Object name or NULL</dd>
<dt>number</dt>
<dd class="description">Object number or 0</dd>
<dt>buffer</dt>
<dd class="description">String buffer</dd>
<dt>bufsize</dt>
<dd class="description">Size of buffer</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">UUID string</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function creates a unique 128-bit identifying number using the server
name, port number, random data, and optionally an object name and/or object
number.  The result is formatted as a UUID URN as defined in RFC 4122.<br>
<br>
The buffer needs to be at least 46 bytes in size.

</p>
<h3 class="function"><a name="httpBlocking">httpBlocking</a></h3>
<p class="description">Set blocking/non-blocking behavior on a connection.</p>
<p class="code">
void httpBlocking (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int b<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>b</dt>
<dd class="description">1 = blocking, 0 = non-blocking</dd>
</dl>
<h3 class="function"><a name="httpCheck">httpCheck</a></h3>
<p class="description">Check to see if there is a pending response from the server.</p>
<p class="code">
int httpCheck (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">0 = no data, 1 = data available</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.1.19/OS X 10.3&nbsp;</span><a name="httpClearCookie">httpClearCookie</a></h3>
<p class="description">Clear the cookie value(s).</p>
<p class="code">
void httpClearCookie (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h3 class="function"><a name="httpClearFields">httpClearFields</a></h3>
<p class="description">Clear HTTP request fields.</p>
<p class="code">
void httpClearFields (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h3 class="function"><a name="httpClose">httpClose</a></h3>
<p class="description">Close an HTTP connection.</p>
<p class="code">
void httpClose (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h3 class="function"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="httpCompareCredentials">httpCompareCredentials</a></h3>
<p class="description">Compare two sets of X.509 credentials.</p>
<p class="code">
int httpCompareCredentials (<br>
&nbsp;&nbsp;&nbsp;&nbsp;cups_array_t *cred1,<br>
&nbsp;&nbsp;&nbsp;&nbsp;cups_array_t *cred2<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>cred1</dt>
<dd class="description">First set of X.509 credentials</dd>
<dt>cred2</dt>
<dd class="description">Second set of X.509 credentials</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 if they match, 0 if they do not</p>
<h3 class="function"><span class="info">&nbsp;DEPRECATED&nbsp;</span><a name="httpConnect">httpConnect</a></h3>
<p class="description">Connect to a HTTP server.</p>
<p class="code">
<a href="#http_t">http_t</a> *httpConnect (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *host,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int port<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>host</dt>
<dd class="description">Host to connect to</dd>
<dt>port</dt>
<dd class="description">Port number</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New HTTP connection</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function is deprecated - use <a href="#httpConnect2"><code>httpConnect2</code></a> instead.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="httpConnect2">httpConnect2</a></h3>
<p class="description">Connect to a HTTP server.</p>
<p class="code">
<a href="#http_t">http_t</a> *httpConnect2 (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *host,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int port,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_addrlist_t">http_addrlist_t</a> *addrlist,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int family,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_encryption_t">http_encryption_t</a> encryption,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int blocking,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int msec,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int *cancel<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>host</dt>
<dd class="description">Host to connect to</dd>
<dt>port</dt>
<dd class="description">Port number</dd>
<dt>addrlist</dt>
<dd class="description">List of addresses or NULL to lookup</dd>
<dt>family</dt>
<dd class="description">Address family to use or <code>AF_UNSPEC</code> for any</dd>
<dt>encryption</dt>
<dd class="description">Type of encryption to use</dd>
<dt>blocking</dt>
<dd class="description">1 for blocking connection, 0 for non-blocking</dd>
<dt>msec</dt>
<dd class="description">Connection timeout in milliseconds, 0 means don't connect</dd>
<dt>cancel</dt>
<dd class="description">Pointer to &quot;cancel&quot; variable</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New HTTP connection</p>
<h3 class="function"><span class="info">&nbsp;DEPRECATED&nbsp;</span><a name="httpConnectEncrypt">httpConnectEncrypt</a></h3>
<p class="description">Connect to a HTTP server using encryption.</p>
<p class="code">
<a href="#http_t">http_t</a> *httpConnectEncrypt (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *host,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int port,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_encryption_t">http_encryption_t</a> encryption<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>host</dt>
<dd class="description">Host to connect to</dd>
<dt>port</dt>
<dd class="description">Port number</dd>
<dt>encryption</dt>
<dd class="description">Type of encryption to use</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New HTTP connection</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function is now deprecated. Please use the <a href="#httpConnect2"><code>httpConnect2</code></a> function
instead.

</p>
<h3 class="function"><span class="info">&nbsp;DEPRECATED&nbsp;</span><a name="httpDecode64">httpDecode64</a></h3>
<p class="description">Base64-decode a string.</p>
<p class="code">
char *httpDecode64 (<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *out,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *in<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>out</dt>
<dd class="description">String to write to</dd>
<dt>in</dt>
<dd class="description">String to read from</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Decoded string</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function is deprecated. Use the httpDecode64_2() function instead
which provides buffer length arguments.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.1.21/OS X 10.4&nbsp;</span><a name="httpDecode64_2">httpDecode64_2</a></h3>
<p class="description">Base64-decode a string.</p>
<p class="code">
char *httpDecode64_2 (<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *out,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int *outlen,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *in<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>out</dt>
<dd class="description">String to write to</dd>
<dt>outlen</dt>
<dd class="description">Size of output string</dd>
<dt>in</dt>
<dd class="description">String to read from</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Decoded string</p>
<h3 class="function"><a name="httpDelete">httpDelete</a></h3>
<p class="description">Send a DELETE request to the server.</p>
<p class="code">
int httpDelete (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *uri<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>uri</dt>
<dd class="description">URI to delete</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Status of call (0 = success)</p>
<h3 class="function"><span class="info">&nbsp;DEPRECATED&nbsp;</span><a name="httpEncode64">httpEncode64</a></h3>
<p class="description">Base64-encode a string.</p>
<p class="code">
char *httpEncode64 (<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *out,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *in<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>out</dt>
<dd class="description">String to write to</dd>
<dt>in</dt>
<dd class="description">String to read from</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Encoded string</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function is deprecated. Use the httpEncode64_2() function instead
which provides buffer length arguments.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.1.21/OS X 10.4&nbsp;</span><a name="httpEncode64_2">httpEncode64_2</a></h3>
<p class="description">Base64-encode a string.</p>
<p class="code">
char *httpEncode64_2 (<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *out,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int outlen,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *in,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int inlen<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>out</dt>
<dd class="description">String to write to</dd>
<dt>outlen</dt>
<dd class="description">Size of output string</dd>
<dt>in</dt>
<dd class="description">String to read from</dd>
<dt>inlen</dt>
<dd class="description">Size of input string</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Encoded string</p>
<h3 class="function"><a name="httpEncryption">httpEncryption</a></h3>
<p class="description">Set the required encryption on the link.</p>
<p class="code">
int httpEncryption (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_encryption_t">http_encryption_t</a> e<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>e</dt>
<dd class="description">New encryption preference</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">-1 on error, 0 on success</p>
<h3 class="function"><a name="httpError">httpError</a></h3>
<p class="description">Get the last error on a connection.</p>
<p class="code">
int httpError (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Error code (errno) value</p>
<h3 class="function"><a name="httpFieldValue">httpFieldValue</a></h3>
<p class="description">Return the HTTP field enumeration value for a field
name.</p>
<p class="code">
<a href="#http_field_t">http_field_t</a> httpFieldValue (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>name</dt>
<dd class="description">String name</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Field index</p>
<h3 class="function"><a name="httpFlush">httpFlush</a></h3>
<p class="description">Flush data from a HTTP connection.</p>
<p class="code">
void httpFlush (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpFlushWrite">httpFlushWrite</a></h3>
<p class="description">Flush data in write buffer.</p>
<p class="code">
int httpFlushWrite (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Bytes written or -1 on error</p>
<h3 class="function"><a name="httpFreeCredentials">httpFreeCredentials</a></h3>
<p class="description">Free an array of credentials.</p>
<p class="code">
void httpFreeCredentials (<br>
&nbsp;&nbsp;&nbsp;&nbsp;cups_array_t *credentials<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>credentials</dt>
<dd class="description">Array of credentials</dd>
</dl>
<h3 class="function"><a name="httpGet">httpGet</a></h3>
<p class="description">Send a GET request to the server.</p>
<p class="code">
int httpGet (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *uri<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>uri</dt>
<dd class="description">URI to get</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Status of call (0 = success)</p>
<h3 class="function"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="httpGetActivity">httpGetActivity</a></h3>
<p class="description">Get the most recent activity for a connection.</p>
<p class="code">
time_t httpGetActivity (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Time of last read or write</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The return value is the UNIX time of the last read or write.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="httpGetAddress">httpGetAddress</a></h3>
<p class="description">Get the address of the connected peer of a connection.</p>
<p class="code">
<a href="#http_addr_t">http_addr_t</a> *httpGetAddress (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Connected address or <code>NULL</code></p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">Returns <code>NULL</code> if the socket is currently unconnected.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.3/OS X 10.5&nbsp;</span><a name="httpGetAuthString">httpGetAuthString</a></h3>
<p class="description">Get the current authorization string.</p>
<p class="code">
char *httpGetAuthString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Authorization string</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The authorization string is set by cupsDoAuthentication() and
httpSetAuthString().  Use httpGetAuthString() to retrieve the
string to use with httpSetField() for the HTTP_FIELD_AUTHORIZATION
value.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpGetBlocking">httpGetBlocking</a></h3>
<p class="description">Get the blocking/non-block state of a connection.</p>
<p class="code">
int httpGetBlocking (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 if blocking, 0 if non-blocking</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="httpGetContentEncoding">httpGetContentEncoding</a></h3>
<p class="description">Get a common content encoding, if any, between
the client and server.</p>
<p class="code">
const char *httpGetContentEncoding (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Content-Coding value or
<code>NULL</code> for the identity
coding.</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function uses the value of the Accepts-Encoding HTTP header and must be
called after receiving a response from the server or a request from the
client.  The value returned can be use in subsequent requests (for clients)
or in the response (for servers) in order to compress the content stream.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.1.19/OS X 10.3&nbsp;</span><a name="httpGetCookie">httpGetCookie</a></h3>
<p class="description">Get any cookie data from the response.</p>
<p class="code">
const char *httpGetCookie (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Cookie data or NULL</p>
<h3 class="function"><span class="info">&nbsp;DEPRECATED&nbsp;</span><a name="httpGetDateString">httpGetDateString</a></h3>
<p class="description">Get a formatted date/time string from a time value.</p>
<p class="code">
const char *httpGetDateString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;time_t t<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>t</dt>
<dd class="description">UNIX time</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Date/time string</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpGetDateString2">httpGetDateString2</a></h3>
<p class="description">Get a formatted date/time string from a time value.</p>
<p class="code">
const char *httpGetDateString2 (<br>
&nbsp;&nbsp;&nbsp;&nbsp;time_t t,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *s,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int slen<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>t</dt>
<dd class="description">UNIX time</dd>
<dt>s</dt>
<dd class="description">String buffer</dd>
<dt>slen</dt>
<dd class="description">Size of string buffer</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Date/time string</p>
<h3 class="function"><a name="httpGetDateTime">httpGetDateTime</a></h3>
<p class="description">Get a time value from a formatted date/time string.</p>
<p class="code">
time_t httpGetDateTime (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *s<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>s</dt>
<dd class="description">Date/time string</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">UNIX time</p>
<h3 class="function"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="httpGetEncryption">httpGetEncryption</a></h3>
<p class="description">Get the current encryption mode of a connection.</p>
<p class="code">
<a href="#http_encryption_t">http_encryption_t</a> httpGetEncryption (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Current encryption mode</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function returns the encryption mode for the connection. Use the
<a href="#httpIsEncrypted"><code>httpIsEncrypted</code></a> function to determine whether a TLS session has
been established.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="httpGetExpect">httpGetExpect</a></h3>
<p class="description">Get the value of the Expect header, if any.</p>
<p class="code">
http_status_t httpGetExpect (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Expect: status, if any</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">Returns <code>HTTP_STATUS_NONE</code> if there is no Expect header, otherwise
returns the expected HTTP status code, typically <code>HTTP_STATUS_CONTINUE</code>.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpGetFd">httpGetFd</a></h3>
<p class="description">Get the file descriptor associated with a connection.</p>
<p class="code">
int httpGetFd (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">File descriptor or -1 if none</p>
<h3 class="function"><a name="httpGetField">httpGetField</a></h3>
<p class="description">Get a field value from a request/response.</p>
<p class="code">
const char *httpGetField (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_field_t">http_field_t</a> field<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>field</dt>
<dd class="description">Field to get</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Field value</p>
<h3 class="function"><span class="info">&nbsp;DEPRECATED&nbsp;</span><a name="httpGetHostByName">httpGetHostByName</a></h3>
<p class="description">Lookup a hostname or IPv4 address, and return
address records for the specified name.</p>
<p class="code">
struct hostent *httpGetHostByName (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>name</dt>
<dd class="description">Hostname or IP address</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Host entry</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpGetHostname">httpGetHostname</a></h3>
<p class="description">Get the FQDN for the connection or local system.</p>
<p class="code">
const char *httpGetHostname (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *s,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int slen<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection or NULL</dd>
<dt>s</dt>
<dd class="description">String buffer for name</dd>
<dt>slen</dt>
<dd class="description">Size of buffer</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">FQDN for connection or system</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">When &quot;http&quot; points to a connected socket, return the hostname or
address that was used in the call to httpConnect() or httpConnectEncrypt(),
or the address of the client for the connection from httpAcceptConnection().
Otherwise, return the FQDN for the local system using both gethostname()
and gethostbyname() to get the local hostname with domain.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="httpGetKeepAlive">httpGetKeepAlive</a></h3>
<p class="description">Get the current Keep-Alive state of the connection.</p>
<p class="code">
<a href="#http_keepalive_t">http_keepalive_t</a> httpGetKeepAlive (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Keep-Alive state</p>
<h3 class="function"><span class="info">&nbsp;DEPRECATED&nbsp;</span><a name="httpGetLength">httpGetLength</a></h3>
<p class="description">Get the amount of data remaining from the
content-length or transfer-encoding fields.</p>
<p class="code">
int httpGetLength (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Content length</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function is deprecated and will not return lengths larger than
2^31 - 1; use httpGetLength2() instead.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpGetLength2">httpGetLength2</a></h3>
<p class="description">Get the amount of data remaining from the
content-length or transfer-encoding fields.</p>
<p class="code">
off_t httpGetLength2 (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Content length</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function returns the complete content length, even for
content larger than 2^31 - 1.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="httpGetPending">httpGetPending</a></h3>
<p class="description">Get the number of bytes that are buffered for writing.</p>
<p class="code">
size_t httpGetPending (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Number of bytes buffered</p>
<h3 class="function"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="httpGetReady">httpGetReady</a></h3>
<p class="description">Get the number of bytes that can be read without blocking.</p>
<p class="code">
size_t httpGetReady (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Number of bytes available</p>
<h3 class="function"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="httpGetRemaining">httpGetRemaining</a></h3>
<p class="description">Get the number of remaining bytes in the message
body or current chunk.</p>
<p class="code">
size_t httpGetRemaining (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Remaining bytes</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <a href="#httpIsChunked"><code>httpIsChunked</code></a> function can be used to determine whether the
message body is chunked or fixed-length.

</p>
<h3 class="function"><a name="httpGetState">httpGetState</a></h3>
<p class="description">Get the current state of the HTTP request.</p>
<p class="code">
<a href="#http_state_t">http_state_t</a> httpGetState (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">HTTP state</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpGetStatus">httpGetStatus</a></h3>
<p class="description">Get the status of the last HTTP request.</p>
<p class="code">
http_status_t httpGetStatus (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">HTTP status</p>
<h3 class="function"><span class="info">&nbsp;DEPRECATED&nbsp;</span><a name="httpGetSubField">httpGetSubField</a></h3>
<p class="description">Get a sub-field value.</p>
<p class="code">
char *httpGetSubField (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_field_t">http_field_t</a> field,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *value<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>field</dt>
<dd class="description">Field index</dd>
<dt>name</dt>
<dd class="description">Name of sub-field</dd>
<dt>value</dt>
<dd class="description">Value string</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Value or NULL</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpGetSubField2">httpGetSubField2</a></h3>
<p class="description">Get a sub-field value.</p>
<p class="code">
char *httpGetSubField2 (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_field_t">http_field_t</a> field,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *value,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int valuelen<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>field</dt>
<dd class="description">Field index</dd>
<dt>name</dt>
<dd class="description">Name of sub-field</dd>
<dt>value</dt>
<dd class="description">Value string</dd>
<dt>valuelen</dt>
<dd class="description">Size of value buffer</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Value or NULL</p>
<h3 class="function"><a name="httpGetVersion">httpGetVersion</a></h3>
<p class="description">Get the HTTP version at the other end.</p>
<p class="code">
<a href="#http_version_t">http_version_t</a> httpGetVersion (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Version number</p>
<h3 class="function"><a name="httpGets">httpGets</a></h3>
<p class="description">Get a line of text from a HTTP connection.</p>
<p class="code">
char *httpGets (<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *line,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int length,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>line</dt>
<dd class="description">Line to read into</dd>
<dt>length</dt>
<dd class="description">Max length of buffer</dd>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Line or NULL</p>
<h3 class="function"><a name="httpHead">httpHead</a></h3>
<p class="description">Send a HEAD request to the server.</p>
<p class="code">
int httpHead (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *uri<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>uri</dt>
<dd class="description">URI for head</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Status of call (0 = success)</p>
<h3 class="function"><a name="httpInitialize">httpInitialize</a></h3>
<p class="description">Initialize the HTTP interface library and set the
default HTTP proxy (if any).</p>
<p class="code">
void httpInitialize (void);</p>
<h3 class="function"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="httpIsChunked">httpIsChunked</a></h3>
<p class="description">Report whether a message body is chunked.</p>
<p class="code">
int httpIsChunked (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 if chunked, 0 if not</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function returns non-zero if the message body is composed of
variable-length chunks.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="httpIsEncrypted">httpIsEncrypted</a></h3>
<p class="description">Report whether a connection is encrypted.</p>
<p class="code">
int httpIsEncrypted (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 if encrypted, 0 if not</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function returns non-zero if the connection is currently encrypted.

</p>
<h3 class="function"><a name="httpMD5">httpMD5</a></h3>
<p class="description">Compute the MD5 sum of the username:group:password.</p>
<p class="code">
char *httpMD5 (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *username,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *realm,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *passwd,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char md5[33]<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>username</dt>
<dd class="description">User name</dd>
<dt>realm</dt>
<dd class="description">Realm name</dd>
<dt>passwd</dt>
<dd class="description">Password string</dd>
<dt>md5[33]</dt>
<dd class="description">MD5 string</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">MD5 sum</p>
<h3 class="function"><a name="httpMD5Final">httpMD5Final</a></h3>
<p class="description">Combine the MD5 sum of the username, group, and password
with the server-supplied nonce value, method, and
request-uri.</p>
<p class="code">
char *httpMD5Final (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *nonce,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *method,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *resource,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char md5[33]<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>nonce</dt>
<dd class="description">Server nonce value</dd>
<dt>method</dt>
<dd class="description">METHOD (GET, POST, etc.)</dd>
<dt>resource</dt>
<dd class="description">Resource path</dd>
<dt>md5[33]</dt>
<dd class="description">MD5 sum</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New sum</p>
<h3 class="function"><a name="httpMD5String">httpMD5String</a></h3>
<p class="description">Convert an MD5 sum to a character string.</p>
<p class="code">
char *httpMD5String (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const unsigned char *sum,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char md5[33]<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>sum</dt>
<dd class="description">MD5 sum data</dd>
<dt>md5[33]</dt>
<dd class="description">MD5 sum in hex</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">MD5 sum in hex</p>
<h3 class="function"><a name="httpOptions">httpOptions</a></h3>
<p class="description">Send an OPTIONS request to the server.</p>
<p class="code">
int httpOptions (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *uri<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>uri</dt>
<dd class="description">URI for options</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Status of call (0 = success)</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="httpPeek">httpPeek</a></h3>
<p class="description">Peek at data from a HTTP connection.</p>
<p class="code">
ssize_t httpPeek (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *buffer,<br>
&nbsp;&nbsp;&nbsp;&nbsp;size_t length<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>buffer</dt>
<dd class="description">Buffer for data</dd>
<dt>length</dt>
<dd class="description">Maximum number of bytes</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Number of bytes copied</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function copies available data from the given HTTP connection, reading
a buffer as needed.  The data is still available for reading using
<a href="#httpRead"><code>httpRead</code></a> or <a href="#httpRead2"><code>httpRead2</code></a>.<br>
<br>
For non-blocking connections the usual timeouts apply.

</p>
<h3 class="function"><a name="httpPost">httpPost</a></h3>
<p class="description">Send a POST request to the server.</p>
<p class="code">
int httpPost (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *uri<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>uri</dt>
<dd class="description">URI for post</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Status of call (0 = success)</p>
<h3 class="function"><a name="httpPut">httpPut</a></h3>
<p class="description">Send a PUT request to the server.</p>
<p class="code">
int httpPut (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *uri<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>uri</dt>
<dd class="description">URI to put</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Status of call (0 = success)</p>
<h3 class="function"><span class="info">&nbsp;DEPRECATED&nbsp;</span><a name="httpRead">httpRead</a></h3>
<p class="description">Read data from a HTTP connection.</p>
<p class="code">
int httpRead (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *buffer,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int length<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>buffer</dt>
<dd class="description">Buffer for data</dd>
<dt>length</dt>
<dd class="description">Maximum number of bytes</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Number of bytes read</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function is deprecated. Use the httpRead2() function which can
read more than 2GB of data.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpRead2">httpRead2</a></h3>
<p class="description">Read data from a HTTP connection.</p>
<p class="code">
ssize_t httpRead2 (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *buffer,<br>
&nbsp;&nbsp;&nbsp;&nbsp;size_t length<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>buffer</dt>
<dd class="description">Buffer for data</dd>
<dt>length</dt>
<dd class="description">Maximum number of bytes</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Number of bytes read</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="httpReadRequest">httpReadRequest</a></h3>
<p class="description">Read a HTTP request from a connection.</p>
<p class="code">
<a href="#http_state_t">http_state_t</a> httpReadRequest (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *uri,<br>
&nbsp;&nbsp;&nbsp;&nbsp;size_t urilen<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>uri</dt>
<dd class="description">URI buffer</dd>
<dt>urilen</dt>
<dd class="description">Size of URI buffer</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New state of connection</p>
<h3 class="function"><span class="info">&nbsp;DEPRECATED&nbsp;</span><a name="httpReconnect">httpReconnect</a></h3>
<p class="description">Reconnect to a HTTP server.</p>
<p class="code">
int httpReconnect (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">0 on success, non-zero on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function is deprecated. Please use the <a href="#httpReconnect2"><code>httpReconnect2</code></a> function
instead.

</p>
<h3 class="function"><a name="httpReconnect2">httpReconnect2</a></h3>
<p class="description">Reconnect to a HTTP server with timeout and optional
cancel.</p>
<p class="code">
int httpReconnect2 (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int msec,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int *cancel<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>msec</dt>
<dd class="description">Timeout in milliseconds</dd>
<dt>cancel</dt>
<dd class="description">Pointer to &quot;cancel&quot; variable</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">0 on success, non-zero on failure</p>
<h3 class="function"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="httpResolveHostname">httpResolveHostname</a></h3>
<p class="description">Resolve the hostname of the HTTP connection
address.</p>
<p class="code">
const char *httpResolveHostname (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *buffer,<br>
&nbsp;&nbsp;&nbsp;&nbsp;size_t bufsize<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>buffer</dt>
<dd class="description">Hostname buffer</dd>
<dt>bufsize</dt>
<dd class="description">Size of buffer</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Resolved hostname or <code>NULL</code></p>
<h3 class="function"><span class="info">&nbsp;DEPRECATED&nbsp;</span><a name="httpSeparate">httpSeparate</a></h3>
<p class="description">Separate a Universal Resource Identifier into its
components.</p>
<p class="code">
void httpSeparate (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *uri,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *scheme,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *username,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *host,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int *port,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *resource<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>uri</dt>
<dd class="description">Universal Resource Identifier</dd>
<dt>scheme</dt>
<dd class="description">Scheme [32] (http, https, etc.)</dd>
<dt>username</dt>
<dd class="description">Username [1024]</dd>
<dt>host</dt>
<dd class="description">Hostname [1024]</dd>
<dt>port</dt>
<dd class="description">Port number to use</dd>
<dt>resource</dt>
<dd class="description">Resource/filename [1024]</dd>
</dl>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function is deprecated; use the httpSeparateURI() function instead.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.1.21/OS X 10.4&nbsp;</span><a name="httpSeparate2">httpSeparate2</a></h3>
<p class="description">Separate a Universal Resource Identifier into its
components.</p>
<p class="code">
void httpSeparate2 (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *uri,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *scheme,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int schemelen,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *username,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int usernamelen,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *host,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int hostlen,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int *port,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *resource,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int resourcelen<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>uri</dt>
<dd class="description">Universal Resource Identifier</dd>
<dt>scheme</dt>
<dd class="description">Scheme (http, https, etc.)</dd>
<dt>schemelen</dt>
<dd class="description">Size of scheme buffer</dd>
<dt>username</dt>
<dd class="description">Username</dd>
<dt>usernamelen</dt>
<dd class="description">Size of username buffer</dd>
<dt>host</dt>
<dd class="description">Hostname</dd>
<dt>hostlen</dt>
<dd class="description">Size of hostname buffer</dd>
<dt>port</dt>
<dd class="description">Port number to use</dd>
<dt>resource</dt>
<dd class="description">Resource/filename</dd>
<dt>resourcelen</dt>
<dd class="description">Size of resource buffer</dd>
</dl>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function is deprecated; use the httpSeparateURI() function instead.


</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpSeparateURI">httpSeparateURI</a></h3>
<p class="description">Separate a Universal Resource Identifier into its
components.</p>
<p class="code">
<a href="#http_uri_status_t">http_uri_status_t</a> httpSeparateURI (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_uri_coding_t">http_uri_coding_t</a> decoding,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *uri,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *scheme,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int schemelen,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *username,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int usernamelen,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *host,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int hostlen,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int *port,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *resource,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int resourcelen<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>decoding</dt>
<dd class="description">Decoding flags</dd>
<dt>uri</dt>
<dd class="description">Universal Resource Identifier</dd>
<dt>scheme</dt>
<dd class="description">Scheme (http, https, etc.)</dd>
<dt>schemelen</dt>
<dd class="description">Size of scheme buffer</dd>
<dt>username</dt>
<dd class="description">Username</dd>
<dt>usernamelen</dt>
<dd class="description">Size of username buffer</dd>
<dt>host</dt>
<dd class="description">Hostname</dd>
<dt>hostlen</dt>
<dd class="description">Size of hostname buffer</dd>
<dt>port</dt>
<dd class="description">Port number to use</dd>
<dt>resource</dt>
<dd class="description">Resource/filename</dd>
<dt>resourcelen</dt>
<dd class="description">Size of resource buffer</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Result of separation</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.3/OS X 10.5&nbsp;</span><a name="httpSetAuthString">httpSetAuthString</a></h3>
<p class="description">Set the current authorization string.</p>
<p class="code">
void httpSetAuthString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *scheme,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *data<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>scheme</dt>
<dd class="description">Auth scheme (NULL to clear it)</dd>
<dt>data</dt>
<dd class="description">Auth data (NULL for none)</dd>
</dl>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function just stores a copy of the current authorization string in
the HTTP connection object.  You must still call httpSetField() to set
HTTP_FIELD_AUTHORIZATION prior to issuing a HTTP request using httpGet(),
httpHead(), httpOptions(), httpPost, or httpPut().

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.1.19/OS X 10.3&nbsp;</span><a name="httpSetCookie">httpSetCookie</a></h3>
<p class="description">Set the cookie value(s).</p>
<p class="code">
void httpSetCookie (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *cookie<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">Connection</dd>
<dt>cookie</dt>
<dd class="description">Cookie string</dd>
</dl>
<h3 class="function"><span class="info">&nbsp;CUPS 1.5/OS X 10.7&nbsp;</span><a name="httpSetCredentials">httpSetCredentials</a></h3>
<p class="description">Set the credentials associated with an encrypted
connection.</p>
<p class="code">
int httpSetCredentials (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;cups_array_t *credentials<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>credentials</dt>
<dd class="description">Array of credentials</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Status of call (0 = success)</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="httpSetDefaultField">httpSetDefaultField</a></h3>
<p class="description">Set the default value of an HTTP header.</p>
<p class="code">
void httpSetDefaultField (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_field_t">http_field_t</a> field,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *value<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>field</dt>
<dd class="description">Field index</dd>
<dt>value</dt>
<dd class="description">Value</dd>
</dl>
<h4 class="discussion">Discussion</h4>
<p class="discussion">Currently only <code>HTTP_FIELD_ACCEPT_ENCODING</code>, <code>HTTP_FIELD_SERVER</code>,
and <code>HTTP_FIELD_USER_AGENT</code> can be set.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpSetExpect">httpSetExpect</a></h3>
<p class="description">Set the Expect: header in a request.</p>
<p class="code">
void httpSetExpect (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;http_status_t expect<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>expect</dt>
<dd class="description">HTTP status to expect
(<code>HTTP_STATUS_CONTINUE</code>)</dd>
</dl>
<h4 class="discussion">Discussion</h4>
<p class="discussion">Currently only <code>HTTP_STATUS_CONTINUE</code> is supported for the &quot;expect&quot;
argument.

</p>
<h3 class="function"><a name="httpSetField">httpSetField</a></h3>
<p class="description">Set the value of an HTTP header.</p>
<p class="code">
void httpSetField (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_field_t">http_field_t</a> field,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *value<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>field</dt>
<dd class="description">Field index</dd>
<dt>value</dt>
<dd class="description">Value</dd>
</dl>
<h3 class="function"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="httpSetKeepAlive">httpSetKeepAlive</a></h3>
<p class="description">Set the current Keep-Alive state of a connection.</p>
<p class="code">
void httpSetKeepAlive (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_keepalive_t">http_keepalive_t</a> keep_alive<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>keep_alive</dt>
<dd class="description">New Keep-Alive value</dd>
</dl>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpSetLength">httpSetLength</a></h3>
<p class="description">Set the content-length and content-encoding.</p>
<p class="code">
void httpSetLength (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;size_t length<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>length</dt>
<dd class="description">Length (0 for chunked)</dd>
</dl>
<h3 class="function"><span class="info">&nbsp;CUPS 1.5/OS X 10.7&nbsp;</span><a name="httpSetTimeout">httpSetTimeout</a></h3>
<p class="description">Set read/write timeouts and an optional callback.</p>
<p class="code">
void httpSetTimeout (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;double timeout,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_timeout_cb_t">http_timeout_cb_t</a> cb,<br>
&nbsp;&nbsp;&nbsp;&nbsp;void *user_data<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>timeout</dt>
<dd class="description">Number of seconds for timeout,
must be greater than 0</dd>
<dt>cb</dt>
<dd class="description">Callback function or NULL</dd>
<dt>user_data</dt>
<dd class="description">User data pointer</dd>
</dl>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The optional timeout callback receives both the HTTP connection and a user
data pointer and must return 1 to continue or 0 to error (time) out.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="httpShutdown">httpShutdown</a></h3>
<p class="description">Shutdown one side of an HTTP connection.</p>
<p class="code">
void httpShutdown (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h3 class="function"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="httpStateString">httpStateString</a></h3>
<p class="description">Return the string describing a HTTP state value.</p>
<p class="code">
const char *httpStateString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_state_t">http_state_t</a> state<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>state</dt>
<dd class="description">HTTP state value</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">State string</p>
<h3 class="function"><a name="httpStatus">httpStatus</a></h3>
<p class="description">Return a short string describing a HTTP status code.</p>
<p class="code">
const char *httpStatus (<br>
&nbsp;&nbsp;&nbsp;&nbsp;http_status_t status<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>status</dt>
<dd class="description">HTTP status code</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Localized status string</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The returned string is localized to the current POSIX locale and is based
on the status strings defined in RFC 2616.</p>
<h3 class="function"><a name="httpTrace">httpTrace</a></h3>
<p class="description">Send an TRACE request to the server.</p>
<p class="code">
int httpTrace (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *uri<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>uri</dt>
<dd class="description">URI for trace</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Status of call (0 = success)</p>
<h3 class="function"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="httpURIStatusString">httpURIStatusString</a></h3>
<p class="description">Return a string describing a URI status code.</p>
<p class="code">
const char *httpURIStatusString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_uri_status_t">http_uri_status_t</a> status<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>status</dt>
<dd class="description">URI status code</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Localized status string</p>
<h3 class="function"><a name="httpUpdate">httpUpdate</a></h3>
<p class="description">Update the current HTTP state for incoming data.</p>
<p class="code">
http_status_t httpUpdate (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">HTTP status</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.1.19/OS X 10.3&nbsp;</span><a name="httpWait">httpWait</a></h3>
<p class="description">Wait for data available on a connection.</p>
<p class="code">
int httpWait (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int msec<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>msec</dt>
<dd class="description">Milliseconds to wait</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 if data is available, 0 otherwise</p>
<h3 class="function"><span class="info">&nbsp;DEPRECATED&nbsp;</span><a name="httpWrite">httpWrite</a></h3>
<p class="description">Write data to a HTTP connection.</p>
<p class="code">
int httpWrite (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *buffer,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int length<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>buffer</dt>
<dd class="description">Buffer for data</dd>
<dt>length</dt>
<dd class="description">Number of bytes to write</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Number of bytes written</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function is deprecated. Use the httpWrite2() function which can
write more than 2GB of data.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="httpWrite2">httpWrite2</a></h3>
<p class="description">Write data to a HTTP connection.</p>
<p class="code">
ssize_t httpWrite2 (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *buffer,<br>
&nbsp;&nbsp;&nbsp;&nbsp;size_t length<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>buffer</dt>
<dd class="description">Buffer for data</dd>
<dt>length</dt>
<dd class="description">Number of bytes to write</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Number of bytes written</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="httpWriteResponse">httpWriteResponse</a></h3>
<p class="description">Write a HTTP response to a client connection.</p>
<p class="code">
int httpWriteResponse (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;http_status_t status<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>status</dt>
<dd class="description">Status code</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">0 on success, -1 on error</p>
<h3 class="function"><a name="ippAddBoolean">ippAddBoolean</a></h3>
<p class="description">Add a boolean attribute to an IPP message.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddBoolean (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char value<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>group</dt>
<dd class="description">IPP group</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
<dt>value</dt>
<dd class="description">Value of attribute</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>group</code> parameter specifies the IPP attribute group tag: none
(<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>),
event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation
(<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription
(<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).</p>
<h3 class="function"><a name="ippAddBooleans">ippAddBooleans</a></h3>
<p class="description">Add an array of boolean values.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddBooleans (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int num_values,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *values<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>group</dt>
<dd class="description">IPP group</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
<dt>num_values</dt>
<dd class="description">Number of values</dd>
<dt>values</dt>
<dd class="description">Values</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>group</code> parameter specifies the IPP attribute group tag: none
(<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>),
event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation
(<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription
(<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.1.19/OS X 10.3&nbsp;</span><a name="ippAddCollection">ippAddCollection</a></h3>
<p class="description">Add a collection value.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddCollection (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *value<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>group</dt>
<dd class="description">IPP group</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
<dt>value</dt>
<dd class="description">Value</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>group</code> parameter specifies the IPP attribute group tag: none
(<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>),
event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation
(<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription
(<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.1.19/OS X 10.3&nbsp;</span><a name="ippAddCollections">ippAddCollections</a></h3>
<p class="description">Add an array of collection values.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddCollections (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int num_values,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const <a href="#ipp_t">ipp_t</a> **values<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>group</dt>
<dd class="description">IPP group</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
<dt>num_values</dt>
<dd class="description">Number of values</dd>
<dt>values</dt>
<dd class="description">Values</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>group</code> parameter specifies the IPP attribute group tag: none
(<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>),
event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation
(<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription
(<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).

</p>
<h3 class="function"><a name="ippAddDate">ippAddDate</a></h3>
<p class="description">Add a date attribute to an IPP message.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddDate (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const <a href="#ipp_uchar_t">ipp_uchar_t</a> *value<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>group</dt>
<dd class="description">IPP group</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
<dt>value</dt>
<dd class="description">Value</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>group</code> parameter specifies the IPP attribute group tag: none
(<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>),
event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation
(<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription
(<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).</p>
<h3 class="function"><a name="ippAddInteger">ippAddInteger</a></h3>
<p class="description">Add a integer attribute to an IPP message.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddInteger (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t value_tag,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int value<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>group</dt>
<dd class="description">IPP group</dd>
<dt>value_tag</dt>
<dd class="description">Type of attribute</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
<dt>value</dt>
<dd class="description">Value of attribute</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>group</code> parameter specifies the IPP attribute group tag: none
(<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>),
event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation
(<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription
(<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).<br>
<br>
Supported values include enum (<code>IPP_TAG_ENUM</code>) and integer
(<code>IPP_TAG_INTEGER</code>).</p>
<h3 class="function"><a name="ippAddIntegers">ippAddIntegers</a></h3>
<p class="description">Add an array of integer values.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddIntegers (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t value_tag,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int num_values,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const int *values<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>group</dt>
<dd class="description">IPP group</dd>
<dt>value_tag</dt>
<dd class="description">Type of attribute</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
<dt>num_values</dt>
<dd class="description">Number of values</dd>
<dt>values</dt>
<dd class="description">Values</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>group</code> parameter specifies the IPP attribute group tag: none
(<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>),
event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation
(<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription
(<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).<br>
<br>
Supported values include enum (<code>IPP_TAG_ENUM</code>) and integer
(<code>IPP_TAG_INTEGER</code>).</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="ippAddOctetString">ippAddOctetString</a></h3>
<p class="description">Add an octetString value to an IPP message.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddOctetString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const void *data,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int datalen<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>group</dt>
<dd class="description">IPP group</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
<dt>data</dt>
<dd class="description">octetString data</dd>
<dt>datalen</dt>
<dd class="description">Length of data in bytes</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>group</code> parameter specifies the IPP attribute group tag: none
(<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>),
event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation
(<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription
(<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippAddOutOfBand">ippAddOutOfBand</a></h3>
<p class="description">Add an out-of-band value to an IPP message.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddOutOfBand (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t value_tag,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>group</dt>
<dd class="description">IPP group</dd>
<dt>value_tag</dt>
<dd class="description">Type of attribute</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>group</code> parameter specifies the IPP attribute group tag: none
(<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>),
event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation
(<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription
(<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).<br>
<br>
Supported out-of-band values include unsupported-value
(<code>IPP_TAG_UNSUPPORTED_VALUE</code>), default (<code>IPP_TAG_DEFAULT</code>), unknown
(<code>IPP_TAG_UNKNOWN</code>), no-value (<code>IPP_TAG_NOVALUE</code>), not-settable
(<code>IPP_TAG_NOTSETTABLE</code>), delete-attribute (<code>IPP_TAG_DELETEATTR</code>), and
admin-define (<code>IPP_TAG_ADMINDEFINE</code>).

</p>
<h3 class="function"><a name="ippAddRange">ippAddRange</a></h3>
<p class="description">Add a range of values to an IPP message.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddRange (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int lower,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int upper<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>group</dt>
<dd class="description">IPP group</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
<dt>lower</dt>
<dd class="description">Lower value</dd>
<dt>upper</dt>
<dd class="description">Upper value</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>group</code> parameter specifies the IPP attribute group tag: none
(<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>),
event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation
(<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription
(<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).<br>
<br>
The <code>lower</code> parameter must be less than or equal to the <code>upper</code> parameter.</p>
<h3 class="function"><a name="ippAddRanges">ippAddRanges</a></h3>
<p class="description">Add ranges of values to an IPP message.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddRanges (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int num_values,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const int *lower,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const int *upper<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>group</dt>
<dd class="description">IPP group</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
<dt>num_values</dt>
<dd class="description">Number of values</dd>
<dt>lower</dt>
<dd class="description">Lower values</dd>
<dt>upper</dt>
<dd class="description">Upper values</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>group</code> parameter specifies the IPP attribute group tag: none
(<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>),
event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation
(<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription
(<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).</p>
<h3 class="function"><a name="ippAddResolution">ippAddResolution</a></h3>
<p class="description">Add a resolution value to an IPP message.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddResolution (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_res_t">ipp_res_t</a> units,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int xres,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int yres<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>group</dt>
<dd class="description">IPP group</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
<dt>units</dt>
<dd class="description">Units for resolution</dd>
<dt>xres</dt>
<dd class="description">X resolution</dd>
<dt>yres</dt>
<dd class="description">Y resolution</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>group</code> parameter specifies the IPP attribute group tag: none
(<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>),
event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation
(<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription
(<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).</p>
<h3 class="function"><a name="ippAddResolutions">ippAddResolutions</a></h3>
<p class="description">Add resolution values to an IPP message.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddResolutions (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int num_values,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_res_t">ipp_res_t</a> units,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const int *xres,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const int *yres<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>group</dt>
<dd class="description">IPP group</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
<dt>num_values</dt>
<dd class="description">Number of values</dd>
<dt>units</dt>
<dd class="description">Units for resolution</dd>
<dt>xres</dt>
<dd class="description">X resolutions</dd>
<dt>yres</dt>
<dd class="description">Y resolutions</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>group</code> parameter specifies the IPP attribute group tag: none
(<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>),
event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation
(<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription
(<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).</p>
<h3 class="function"><a name="ippAddSeparator">ippAddSeparator</a></h3>
<p class="description">Add a group separator to an IPP message.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddSeparator (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.</p>
<h3 class="function"><a name="ippAddString">ippAddString</a></h3>
<p class="description">Add a language-encoded string to an IPP message.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t value_tag,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *language,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *value<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>group</dt>
<dd class="description">IPP group</dd>
<dt>value_tag</dt>
<dd class="description">Type of attribute</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
<dt>language</dt>
<dd class="description">Language code</dd>
<dt>value</dt>
<dd class="description">Value</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>group</code> parameter specifies the IPP attribute group tag: none
(<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>),
event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation
(<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription
(<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).<br>
<br>
Supported string values include charset (<code>IPP_TAG_CHARSET</code>), keyword
(<code>IPP_TAG_KEYWORD</code>), language (<code>IPP_TAG_LANGUAGE</code>), mimeMediaType
(<code>IPP_TAG_MIMETYPE</code>), name (<code>IPP_TAG_NAME</code>), nameWithLanguage
(<code>IPP_TAG_NAMELANG), text (</code>code IPP_TAG_TEXT@), textWithLanguage
(<code>IPP_TAG_TEXTLANG</code>), uri (<code>IPP_TAG_URI</code>), and uriScheme
(<code>IPP_TAG_URISCHEME</code>).<br>
<br>
The <code>language</code> parameter must be non-<code>NULL</code> for nameWithLanguage and
textWithLanguage string values and must be <code>NULL</code> for all other string values.</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="ippAddStringf">ippAddStringf</a></h3>
<p class="description">Add a formatted string to an IPP message.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddStringf (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t value_tag,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *language,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *format,<br>
&nbsp;&nbsp;&nbsp;&nbsp;...<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>group</dt>
<dd class="description">IPP group</dd>
<dt>value_tag</dt>
<dd class="description">Type of attribute</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
<dt>language</dt>
<dd class="description">Language code (<code>NULL</code> for default)</dd>
<dt>format</dt>
<dd class="description">Printf-style format string</dd>
<dt>...</dt>
<dd class="description">Additional arguments as needed</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>group</code> parameter specifies the IPP attribute group tag: none
(<code>IPP_TAG_ZERO</code>, for member attributes), document
(<code>IPP_TAG_DOCUMENT</code>), event notification
(<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation (<code>IPP_TAG_OPERATION</code>),
printer (<code>IPP_TAG_PRINTER</code>), subscription (<code>IPP_TAG_SUBSCRIPTION</code>),
or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).<br>
<br>
Supported string values include charset (<code>IPP_TAG_CHARSET</code>), keyword
(<code>IPP_TAG_KEYWORD</code>), language (<code>IPP_TAG_LANGUAGE</code>), mimeMediaType
(<code>IPP_TAG_MIMETYPE</code>), name (<code>IPP_TAG_NAME</code>), nameWithLanguage
(<code>IPP_TAG_NAMELANG), text (</code>code IPP_TAG_TEXT@), textWithLanguage
(<code>IPP_TAG_TEXTLANG</code>), uri (<code>IPP_TAG_URI</code>), and uriScheme
(<code>IPP_TAG_URISCHEME</code>).<br>
<br>
The <code>language</code> parameter must be non-<code>NULL</code> for nameWithLanguage
and textWithLanguage string values and must be <code>NULL</code> for all other
string values.<br>
<br>
The <code>format</code> parameter uses formatting characters compatible with the
printf family of standard functions.  Additional arguments follow it as
needed.  The formatted string is truncated as needed to the maximum length of
the corresponding value type.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="ippAddStringfv">ippAddStringfv</a></h3>
<p class="description">Add a formatted string to an IPP message.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddStringfv (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t value_tag,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *language,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *format,<br>
&nbsp;&nbsp;&nbsp;&nbsp;va_list ap<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>group</dt>
<dd class="description">IPP group</dd>
<dt>value_tag</dt>
<dd class="description">Type of attribute</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
<dt>language</dt>
<dd class="description">Language code (<code>NULL</code> for default)</dd>
<dt>format</dt>
<dd class="description">Printf-style format string</dd>
<dt>ap</dt>
<dd class="description">Additional arguments</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>group</code> parameter specifies the IPP attribute group tag: none
(<code>IPP_TAG_ZERO</code>, for member attributes), document
(<code>IPP_TAG_DOCUMENT</code>), event notification
(<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation (<code>IPP_TAG_OPERATION</code>),
printer (<code>IPP_TAG_PRINTER</code>), subscription (<code>IPP_TAG_SUBSCRIPTION</code>),
or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).<br>
<br>
Supported string values include charset (<code>IPP_TAG_CHARSET</code>), keyword
(<code>IPP_TAG_KEYWORD</code>), language (<code>IPP_TAG_LANGUAGE</code>), mimeMediaType
(<code>IPP_TAG_MIMETYPE</code>), name (<code>IPP_TAG_NAME</code>), nameWithLanguage
(<code>IPP_TAG_NAMELANG), text (</code>code IPP_TAG_TEXT@), textWithLanguage
(<code>IPP_TAG_TEXTLANG</code>), uri (<code>IPP_TAG_URI</code>), and uriScheme
(<code>IPP_TAG_URISCHEME</code>).<br>
<br>
The <code>language</code> parameter must be non-<code>NULL</code> for nameWithLanguage
and textWithLanguage string values and must be <code>NULL</code> for all other
string values.<br>
<br>
The <code>format</code> parameter uses formatting characters compatible with the
printf family of standard functions.  Additional arguments are passed in the
stdarg pointer <code>ap</code>.  The formatted string is truncated as needed to the
maximum length of the corresponding value type.

</p>
<h3 class="function"><a name="ippAddStrings">ippAddStrings</a></h3>
<p class="description">Add language-encoded strings to an IPP message.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippAddStrings (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t value_tag,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int num_values,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *language,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *const *values<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>group</dt>
<dd class="description">IPP group</dd>
<dt>value_tag</dt>
<dd class="description">Type of attribute</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
<dt>num_values</dt>
<dd class="description">Number of values</dd>
<dt>language</dt>
<dd class="description">Language code (<code>NULL</code> for default)</dd>
<dt>values</dt>
<dd class="description">Values</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>group</code> parameter specifies the IPP attribute group tag: none
(<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>),
event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation
(<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription
(<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).<br>
<br>
Supported string values include charset (<code>IPP_TAG_CHARSET</code>), keyword
(<code>IPP_TAG_KEYWORD</code>), language (<code>IPP_TAG_LANGUAGE</code>), mimeMediaType
(<code>IPP_TAG_MIMETYPE</code>), name (<code>IPP_TAG_NAME</code>), nameWithLanguage
(<code>IPP_TAG_NAMELANG), text (</code>code IPP_TAG_TEXT@), textWithLanguage
(<code>IPP_TAG_TEXTLANG</code>), uri (<code>IPP_TAG_URI</code>), and uriScheme
(<code>IPP_TAG_URISCHEME</code>).<br>
<br>
The <code>language</code> parameter must be non-<code>NULL</code> for nameWithLanguage and
textWithLanguage string values and must be <code>NULL</code> for all other string values.</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippAttributeString">ippAttributeString</a></h3>
<p class="description">Convert the attribute's value to a string.</p>
<p class="code">
size_t ippAttributeString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *buffer,<br>
&nbsp;&nbsp;&nbsp;&nbsp;size_t bufsize<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>attr</dt>
<dd class="description">Attribute</dd>
<dt>buffer</dt>
<dd class="description">String buffer or NULL</dd>
<dt>bufsize</dt>
<dd class="description">Size of string buffer</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Number of bytes less nul</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">Returns the number of bytes that would be written, not including the
trailing nul. The buffer pointer can be NULL to get the required length,
just like (v)snprintf.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="ippContainsInteger">ippContainsInteger</a></h3>
<p class="description">Determine whether an attribute contains the
specified value or is within the list of ranges.</p>
<p class="code">
int ippContainsInteger (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int value<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>attr</dt>
<dd class="description">Attribute</dd>
<dt>value</dt>
<dd class="description">Integer/enum value</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on a match, 0 on no match</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">Returns non-zero when the attribute contains either a matching integer or
enum value, or the value falls within one of the rangeOfInteger values for
the attribute.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="ippContainsString">ippContainsString</a></h3>
<p class="description">Determine whether an attribute contains the
specified string value.</p>
<p class="code">
int ippContainsString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *value<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>attr</dt>
<dd class="description">Attribute</dd>
<dt>value</dt>
<dd class="description">String value</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on a match, 0 on no match</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">Returns non-zero when the attribute contains a matching charset, keyword,
language, mimeMediaType, name, text, URI, or URI scheme value.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippCopyAttribute">ippCopyAttribute</a></h3>
<p class="description">Copy an attribute.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippCopyAttribute (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *dst,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> *srcattr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int quickcopy<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>dst</dt>
<dd class="description">Destination IPP message</dd>
<dt>srcattr</dt>
<dd class="description">Attribute to copy</dd>
<dt>quickcopy</dt>
<dd class="description">1 for a referenced copy, 0 for normal</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The specified attribute, <code>attr</code>, is copied to the destination IPP message.
When <code>quickcopy</code> is non-zero, a &quot;shallow&quot; reference copy of the attribute is
created - this should only be done as long as the original source IPP message will
not be freed for the life of the destination.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippCopyAttributes">ippCopyAttributes</a></h3>
<p class="description">Copy attributes from one IPP message to another.</p>
<p class="code">
int ippCopyAttributes (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *dst,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *src,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int quickcopy,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_copycb_t">ipp_copycb_t</a> cb,<br>
&nbsp;&nbsp;&nbsp;&nbsp;void *context<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>dst</dt>
<dd class="description">Destination IPP message</dd>
<dt>src</dt>
<dd class="description">Source IPP message</dd>
<dt>quickcopy</dt>
<dd class="description">1 for a referenced copy, 0 for normal</dd>
<dt>cb</dt>
<dd class="description">Copy callback or <code>NULL</code> for none</dd>
<dt>context</dt>
<dd class="description">Context pointer</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on error</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">Zero or more attributes are copied from the source IPP message, <code>src</code>, to the
destination IPP message, <code>dst</code>. When <code>quickcopy</code> is non-zero, a &quot;shallow&quot;
reference copy of the attribute is created - this should only be done as long as the
original source IPP message will not be freed for the life of the destination.<br>
<br>
The <code>cb</code> and <code>context</code> parameters provide a generic way to &quot;filter&quot; the
attributes that are copied - the function must return 1 to copy the attribute or
0 to skip it. The function may also choose to do a partial copy of the source attribute
itself.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="ippCreateRequestedArray">ippCreateRequestedArray</a></h3>
<p class="description">Create a CUPS array of attribute names from the
given requested-attributes attribute.</p>
<p class="code">
cups_array_t *ippCreateRequestedArray (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *request<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>request</dt>
<dd class="description">IPP request</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">CUPS array or <code>NULL</code> if all</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function creates a (sorted) CUPS array of attribute names matching the
list of &quot;requested-attribute&quot; values supplied in an IPP request.  All IANA-
registered values are supported in addition to the CUPS IPP extension
attributes.<br>
<br>
The <code>request</code> parameter specifies the request message that was read from
the client.

<code>NULL</code> is returned if all attributes should be returned.  Otherwise, the
result is a sorted array of attribute names, where <code>cupsArrayFind(array,
"attribute-name")</code> will return a non-NULL pointer.  The array must be freed
using the <code>cupsArrayDelete</code> function.

</p>
<h3 class="function"><a name="ippDateToTime">ippDateToTime</a></h3>
<p class="description">Convert from RFC 1903 Date/Time format to UNIX time
in seconds.</p>
<p class="code">
time_t ippDateToTime (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const <a href="#ipp_uchar_t">ipp_uchar_t</a> *date<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>date</dt>
<dd class="description">RFC 1903 date info</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">UNIX time value</p>
<h3 class="function"><a name="ippDelete">ippDelete</a></h3>
<p class="description">Delete an IPP message.</p>
<p class="code">
void ippDelete (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
</dl>
<h3 class="function"><span class="info">&nbsp;CUPS 1.1.19/OS X 10.3&nbsp;</span><a name="ippDeleteAttribute">ippDeleteAttribute</a></h3>
<p class="description">Delete a single attribute in an IPP message.</p>
<p class="code">
void ippDeleteAttribute (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> *attr<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>attr</dt>
<dd class="description">Attribute to delete</dd>
</dl>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippDeleteValues">ippDeleteValues</a></h3>
<p class="description">Delete values in an attribute.</p>
<p class="code">
int ippDeleteValues (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int count<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>attr</dt>
<dd class="description">Attribute</dd>
<dt>element</dt>
<dd class="description">Index of first value to delete (0-based)</dd>
<dt>count</dt>
<dd class="description">Number of values to delete</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>element</code> parameter specifies the first value to delete, starting at
0. It must be less than the number of values returned by <a href="#ippGetCount"><code>ippGetCount</code></a>.<br>
<br>
The <code>attr</code> parameter may be modified as a result of setting the value.<br>
<br>
Deleting all values in an attribute deletes the attribute.

</p>
<h3 class="function"><a name="ippEnumString">ippEnumString</a></h3>
<p class="description">Return a string corresponding to the enum value.</p>
<p class="code">
const char *ippEnumString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *attrname,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int enumvalue<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>attrname</dt>
<dd class="description">Attribute name</dd>
<dt>enumvalue</dt>
<dd class="description">Enum value</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Enum string</p>
<h3 class="function"><a name="ippEnumValue">ippEnumValue</a></h3>
<p class="description">Return the value associated with a given enum string.</p>
<p class="code">
int ippEnumValue (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *attrname,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *enumstring<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>attrname</dt>
<dd class="description">Attribute name</dd>
<dt>enumstring</dt>
<dd class="description">Enum string</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Enum value or -1 if unknown</p>
<h3 class="function"><a name="ippErrorString">ippErrorString</a></h3>
<p class="description">Return a name for the given status code.</p>
<p class="code">
const char *ippErrorString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_status_t error<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>error</dt>
<dd class="description">Error status</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Text string</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="ippErrorValue">ippErrorValue</a></h3>
<p class="description">Return a status code for the given name.</p>
<p class="code">
ipp_status_t ippErrorValue (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>name</dt>
<dd class="description">Name</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">IPP status code</p>
<h3 class="function"><a name="ippFindAttribute">ippFindAttribute</a></h3>
<p class="description">Find a named attribute in a request.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippFindAttribute (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t type<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
<dt>type</dt>
<dd class="description">Type of attribute</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Matching attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">Starting with CUPS 2.0, the attribute name can contain a hierarchical list
of attribute and member names separated by slashes, for example
&quot;media-col/media-size&quot;.</p>
<h3 class="function"><a name="ippFindNextAttribute">ippFindNextAttribute</a></h3>
<p class="description">Find the next named attribute in a request.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippFindNextAttribute (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t type<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>name</dt>
<dd class="description">Name of attribute</dd>
<dt>type</dt>
<dd class="description">Type of attribute</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Matching attribute</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">Starting with CUPS 2.0, the attribute name can contain a hierarchical list
of attribute and member names separated by slashes, for example
&quot;media-col/media-size&quot;.</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippFirstAttribute">ippFirstAttribute</a></h3>
<p class="description">Return the first attribute in the message.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippFirstAttribute (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">First attribute or <code>NULL</code> if none</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippGetBoolean">ippGetBoolean</a></h3>
<p class="description">Get a boolean value for an attribute.</p>
<p class="code">
int ippGetBoolean (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>element</dt>
<dd class="description">Value number (0-based)</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Boolean value or 0 on error</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>element</code> parameter specifies which value to get from 0 to
<a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a> - 1.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippGetCollection">ippGetCollection</a></h3>
<p class="description">Get a collection value for an attribute.</p>
<p class="code">
<a href="#ipp_t">ipp_t</a> *ippGetCollection (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>element</dt>
<dd class="description">Value number (0-based)</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Collection value or <code>NULL</code> on error</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>element</code> parameter specifies which value to get from 0 to
<a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a> - 1.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippGetCount">ippGetCount</a></h3>
<p class="description">Get the number of values in an attribute.</p>
<p class="code">
int ippGetCount (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> *attr<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Number of values or 0 on error</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippGetDate">ippGetDate</a></h3>
<p class="description">Get a date value for an attribute.</p>
<p class="code">
const <a href="#ipp_uchar_t">ipp_uchar_t</a> *ippGetDate (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>element</dt>
<dd class="description">Value number (0-based)</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Date value or <code>NULL</code></p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>element</code> parameter specifies which value to get from 0 to
<a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a> - 1.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippGetGroupTag">ippGetGroupTag</a></h3>
<p class="description">Get the group associated with an attribute.</p>
<p class="code">
ipp_tag_t ippGetGroupTag (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> *attr<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Group tag or <code>IPP_TAG_ZERO</code> on error</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippGetInteger">ippGetInteger</a></h3>
<p class="description">Get the integer/enum value for an attribute.</p>
<p class="code">
int ippGetInteger (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>element</dt>
<dd class="description">Value number (0-based)</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Value or 0 on error</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>element</code> parameter specifies which value to get from 0 to
<a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a> - 1.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippGetName">ippGetName</a></h3>
<p class="description">Get the attribute name.</p>
<p class="code">
const char *ippGetName (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> *attr<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Attribute name or <code>NULL</code> for separators</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="ippGetOctetString">ippGetOctetString</a></h3>
<p class="description">Get an octetString value from an IPP attribute.</p>
<p class="code">
void *ippGetOctetString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int *datalen<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>element</dt>
<dd class="description">Value number (0-based)</dd>
<dt>datalen</dt>
<dd class="description">Length of octetString data</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Pointer to octetString data</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>element</code> parameter specifies which value to get from 0 to
<a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a> - 1.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippGetOperation">ippGetOperation</a></h3>
<p class="description">Get the operation ID in an IPP message.</p>
<p class="code">
ipp_op_t ippGetOperation (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP request message</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Operation ID or 0 on error</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippGetRange">ippGetRange</a></h3>
<p class="description">Get a rangeOfInteger value from an attribute.</p>
<p class="code">
int ippGetRange (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int *uppervalue<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>element</dt>
<dd class="description">Value number (0-based)</dd>
<dt>uppervalue</dt>
<dd class="description">Upper value of range</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Lower value of range or 0</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>element</code> parameter specifies which value to get from 0 to
<a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a> - 1.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippGetRequestId">ippGetRequestId</a></h3>
<p class="description">Get the request ID from an IPP message.</p>
<p class="code">
int ippGetRequestId (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Request ID or 0 on error</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippGetResolution">ippGetResolution</a></h3>
<p class="description">Get a resolution value for an attribute.</p>
<p class="code">
int ippGetResolution (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int *yres,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_res_t">ipp_res_t</a> *units<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>element</dt>
<dd class="description">Value number (0-based)</dd>
<dt>yres</dt>
<dd class="description">Vertical/feed resolution</dd>
<dt>units</dt>
<dd class="description">Units for resolution</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Horizontal/cross feed resolution or 0</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>element</code> parameter specifies which value to get from 0 to
<a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a> - 1.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippGetState">ippGetState</a></h3>
<p class="description">Get the IPP message state.</p>
<p class="code">
<a href="#ipp_state_t">ipp_state_t</a> ippGetState (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">IPP message state value</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippGetStatusCode">ippGetStatusCode</a></h3>
<p class="description">Get the status code from an IPP response or event message.</p>
<p class="code">
ipp_status_t ippGetStatusCode (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP response or event message</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Status code in IPP message</p>
<h3 class="function"><a name="ippGetString">ippGetString</a></h3>
<p class="description">Return the value...</p>
<p class="code">
const char *ippGetString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> *attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char **language<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>element</dt>
<dd class="description">Value number (0-based)</dd>
<dt>language</dt>
<dd class="description">Language code (<code>NULL</code> for don't care)</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Get the string and optionally the language code for an attribute.</p>
<p class="discussion">The <code>element</code> parameter specifies which value to get from 0 to
<a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a> - 1.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippGetValueTag">ippGetValueTag</a></h3>
<p class="description">Get the value tag for an attribute.</p>
<p class="code">
ipp_tag_t ippGetValueTag (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> *attr<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Value tag or <code>IPP_TAG_ZERO</code> on error</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippGetVersion">ippGetVersion</a></h3>
<p class="description">Get the major and minor version number from an IPP message.</p>
<p class="code">
int ippGetVersion (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int *minor<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>minor</dt>
<dd class="description">Minor version number or <code>NULL</code></dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Major version number or 0 on error</p>
<h3 class="function"><a name="ippLength">ippLength</a></h3>
<p class="description">Compute the length of an IPP message.</p>
<p class="code">
size_t ippLength (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Size of IPP message</p>
<h3 class="function"><a name="ippNew">ippNew</a></h3>
<p class="description">Allocate a new IPP message.</p>
<p class="code">
<a href="#ipp_t">ipp_t</a> *ippNew (void);</p>
<h4 class="returnvalue">Return Value</h4>
<p class="description">New IPP message</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="ippNewRequest">ippNewRequest</a></h3>
<p class="description">Allocate a new IPP request message.</p>
<p class="code">
<a href="#ipp_t">ipp_t</a> *ippNewRequest (<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_op_t op<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>op</dt>
<dd class="description">Operation code</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">IPP request message</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The new request message is initialized with the attributes-charset and
attributes-natural-language attributes added. The
attributes-natural-language value is derived from the current locale.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="ippNewResponse">ippNewResponse</a></h3>
<p class="description">Allocate a new IPP response message.</p>
<p class="code">
<a href="#ipp_t">ipp_t</a> *ippNewResponse (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *request<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>request</dt>
<dd class="description">IPP request message</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">IPP response message</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The new response message is initialized with the same version-number,
request-id, attributes-charset, and attributes-natural-language as the
provided request message.  If the attributes-charset or
attributes-natural-language attributes are missing from the request,
&quot;utf-8&quot; and a value derived from the current locale are substituted,
respectively.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippNextAttribute">ippNextAttribute</a></h3>
<p class="description">Return the next attribute in the message.</p>
<p class="code">
<a href="#ipp_attribute_t">ipp_attribute_t</a> *ippNextAttribute (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Next attribute or <code>NULL</code> if none</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="ippOpString">ippOpString</a></h3>
<p class="description">Return a name for the given operation id.</p>
<p class="code">
const char *ippOpString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_op_t op<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>op</dt>
<dd class="description">Operation ID</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Name</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="ippOpValue">ippOpValue</a></h3>
<p class="description">Return an operation id for the given name.</p>
<p class="code">
ipp_op_t ippOpValue (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>name</dt>
<dd class="description">Textual name</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Operation ID</p>
<h3 class="function"><a name="ippPort">ippPort</a></h3>
<p class="description">Return the default IPP port number.</p>
<p class="code">
int ippPort (void);</p>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Port number</p>
<h3 class="function"><a name="ippRead">ippRead</a></h3>
<p class="description">Read data for an IPP message from a HTTP connection.</p>
<p class="code">
<a href="#ipp_state_t">ipp_state_t</a> ippRead (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>ipp</dt>
<dd class="description">IPP data</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Current state</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.1.19/OS X 10.3&nbsp;</span><a name="ippReadFile">ippReadFile</a></h3>
<p class="description">Read data for an IPP message from a file.</p>
<p class="code">
<a href="#ipp_state_t">ipp_state_t</a> ippReadFile (<br>
&nbsp;&nbsp;&nbsp;&nbsp;int fd,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>fd</dt>
<dd class="description">HTTP data</dd>
<dt>ipp</dt>
<dd class="description">IPP data</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Current state</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="ippReadIO">ippReadIO</a></h3>
<p class="description">Read data for an IPP message.</p>
<p class="code">
<a href="#ipp_state_t">ipp_state_t</a> ippReadIO (<br>
&nbsp;&nbsp;&nbsp;&nbsp;void *src,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_iocb_t">ipp_iocb_t</a> cb,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int blocking,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *parent,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>src</dt>
<dd class="description">Data source</dd>
<dt>cb</dt>
<dd class="description">Read callback function</dd>
<dt>blocking</dt>
<dd class="description">Use blocking IO?</dd>
<dt>parent</dt>
<dd class="description">Parent request, if any</dd>
<dt>ipp</dt>
<dd class="description">IPP data</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Current state</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippSetBoolean">ippSetBoolean</a></h3>
<p class="description">Set a boolean value in an attribute.</p>
<p class="code">
int ippSetBoolean (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int boolvalue<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>element</dt>
<dd class="description">Value number (0-based)</dd>
<dt>boolvalue</dt>
<dd class="description">Boolean value</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>attr</code> parameter may be modified as a result of setting the value.<br>
<br>
The <code>element</code> parameter specifies which value to set from 0 to
<a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippSetCollection">ippSetCollection</a></h3>
<p class="description">Set a collection value in an attribute.</p>
<p class="code">
int ippSetCollection (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *colvalue<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>element</dt>
<dd class="description">Value number (0-based)</dd>
<dt>colvalue</dt>
<dd class="description">Collection value</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>attr</code> parameter may be modified as a result of setting the value.<br>
<br>
The <code>element</code> parameter specifies which value to set from 0 to
<a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippSetDate">ippSetDate</a></h3>
<p class="description">Set a date value in an attribute.</p>
<p class="code">
int ippSetDate (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const <a href="#ipp_uchar_t">ipp_uchar_t</a> *datevalue<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>element</dt>
<dd class="description">Value number (0-based)</dd>
<dt>datevalue</dt>
<dd class="description">Date value</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>attr</code> parameter may be modified as a result of setting the value.<br>
<br>
The <code>element</code> parameter specifies which value to set from 0 to
<a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippSetGroupTag">ippSetGroupTag</a></h3>
<p class="description">Set the group tag of an attribute.</p>
<p class="code">
int ippSetGroupTag (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t group_tag<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>attr</dt>
<dd class="description">Attribute</dd>
<dt>group_tag</dt>
<dd class="description">Group tag</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>attr</code> parameter may be modified as a result of setting the value.<br>
<br>
The <code>group</code> parameter specifies the IPP attribute group tag: none
(<code>IPP_TAG_ZERO</code>, for member attributes), document (<code>IPP_TAG_DOCUMENT</code>),
event notification (<code>IPP_TAG_EVENT_NOTIFICATION</code>), operation
(<code>IPP_TAG_OPERATION</code>), printer (<code>IPP_TAG_PRINTER</code>), subscription
(<code>IPP_TAG_SUBSCRIPTION</code>), or unsupported (<code>IPP_TAG_UNSUPPORTED_GROUP</code>).

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippSetInteger">ippSetInteger</a></h3>
<p class="description">Set an integer or enum value in an attribute.</p>
<p class="code">
int ippSetInteger (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int intvalue<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>element</dt>
<dd class="description">Value number (0-based)</dd>
<dt>intvalue</dt>
<dd class="description">Integer/enum value</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>attr</code> parameter may be modified as a result of setting the value.<br>
<br>
The <code>element</code> parameter specifies which value to set from 0 to
<a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippSetName">ippSetName</a></h3>
<p class="description">Set the name of an attribute.</p>
<p class="code">
int ippSetName (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>name</dt>
<dd class="description">Attribute name</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>attr</code> parameter may be modified as a result of setting the value.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="ippSetOctetString">ippSetOctetString</a></h3>
<p class="description">Set an octetString value in an IPP attribute.</p>
<p class="code">
int ippSetOctetString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const void *data,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int datalen<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>element</dt>
<dd class="description">Value number (0-based)</dd>
<dt>data</dt>
<dd class="description">Pointer to octetString data</dd>
<dt>datalen</dt>
<dd class="description">Length of octetString data</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>attr</code> parameter may be modified as a result of setting the value.<br>
<br>
The <code>element</code> parameter specifies which value to set from 0 to
<a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippSetOperation">ippSetOperation</a></h3>
<p class="description">Set the operation ID in an IPP request message.</p>
<p class="code">
int ippSetOperation (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_op_t op<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP request message</dd>
<dt>op</dt>
<dd class="description">Operation ID</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.

</p>
<h3 class="function"><a name="ippSetPort">ippSetPort</a></h3>
<p class="description">Set the default port number.</p>
<p class="code">
void ippSetPort (<br>
&nbsp;&nbsp;&nbsp;&nbsp;int p<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>p</dt>
<dd class="description">Port number to use</dd>
</dl>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippSetRange">ippSetRange</a></h3>
<p class="description">Set a rangeOfInteger value in an attribute.</p>
<p class="code">
int ippSetRange (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int lowervalue,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int uppervalue<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>element</dt>
<dd class="description">Value number (0-based)</dd>
<dt>lowervalue</dt>
<dd class="description">Lower bound for range</dd>
<dt>uppervalue</dt>
<dd class="description">Upper bound for range</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>attr</code> parameter may be modified as a result of setting the value.<br>
<br>
The <code>element</code> parameter specifies which value to set from 0 to
<a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippSetRequestId">ippSetRequestId</a></h3>
<p class="description">Set the request ID in an IPP message.</p>
<p class="code">
int ippSetRequestId (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int request_id<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>request_id</dt>
<dd class="description">Request ID</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>request_id</code> parameter must be greater than 0.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippSetResolution">ippSetResolution</a></h3>
<p class="description">Set a resolution value in an attribute.</p>
<p class="code">
int ippSetResolution (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_res_t">ipp_res_t</a> unitsvalue,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int xresvalue,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int yresvalue<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>element</dt>
<dd class="description">Value number (0-based)</dd>
<dt>unitsvalue</dt>
<dd class="description">Resolution units</dd>
<dt>xresvalue</dt>
<dd class="description">Horizontal/cross feed resolution</dd>
<dt>yresvalue</dt>
<dd class="description">Vertical/feed resolution</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>attr</code> parameter may be modified as a result of setting the value.<br>
<br>
The <code>element</code> parameter specifies which value to set from 0 to
<a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippSetState">ippSetState</a></h3>
<p class="description">Set the current state of the IPP message.</p>
<p class="code">
int ippSetState (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_state_t">ipp_state_t</a> state<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>state</dt>
<dd class="description">IPP state value</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippSetStatusCode">ippSetStatusCode</a></h3>
<p class="description">Set the status code in an IPP response or event message.</p>
<p class="code">
int ippSetStatusCode (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_status_t status<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP response or event message</dd>
<dt>status</dt>
<dd class="description">Status code</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippSetString">ippSetString</a></h3>
<p class="description">Set a string value in an attribute.</p>
<p class="code">
int ippSetString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *strvalue<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>element</dt>
<dd class="description">Value number (0-based)</dd>
<dt>strvalue</dt>
<dd class="description">String value</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>attr</code> parameter may be modified as a result of setting the value.<br>
<br>
The <code>element</code> parameter specifies which value to set from 0 to
<a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="ippSetStringf">ippSetStringf</a></h3>
<p class="description">Set a formatted string value of an attribute.</p>
<p class="code">
int ippSetStringf (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *format,<br>
&nbsp;&nbsp;&nbsp;&nbsp;...<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>element</dt>
<dd class="description">Value number (0-based)</dd>
<dt>format</dt>
<dd class="description">Printf-style format string</dd>
<dt>...</dt>
<dd class="description">Additional arguments as needed</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>attr</code> parameter may be modified as a result of setting the value.<br>
<br>
The <code>element</code> parameter specifies which value to set from 0 to
<a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>.<br>
<br>
The <code>format</code> parameter uses formatting characters compatible with the
printf family of standard functions.  Additional arguments follow it as
needed.  The formatted string is truncated as needed to the maximum length of
the corresponding value type.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="ippSetStringfv">ippSetStringfv</a></h3>
<p class="description">Set a formatted string value of an attribute.</p>
<p class="code">
int ippSetStringfv (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int element,<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *format,<br>
&nbsp;&nbsp;&nbsp;&nbsp;va_list ap<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>element</dt>
<dd class="description">Value number (0-based)</dd>
<dt>format</dt>
<dd class="description">Printf-style format string</dd>
<dt>ap</dt>
<dd class="description">Pointer to additional arguments</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>attr</code> parameter may be modified as a result of setting the value.<br>
<br>
The <code>element</code> parameter specifies which value to set from 0 to
<a href="#ippGetCount(attr)"><code>ippGetCount(attr)</code></a>.<br>
<br>
The <code>format</code> parameter uses formatting characters compatible with the
printf family of standard functions.  Additional arguments follow it as
needed.  The formatted string is truncated as needed to the maximum length of
the corresponding value type.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippSetValueTag">ippSetValueTag</a></h3>
<p class="description">Set the value tag of an attribute.</p>
<p class="code">
int ippSetValueTag (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> **attr,<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t value_tag<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>attr</dt>
<dd class="description">IPP attribute</dd>
<dt>value_tag</dt>
<dd class="description">Value tag</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The <code>attr</code> parameter may be modified as a result of setting the value.<br>
<br>
Integer (<code>IPP_TAG_INTEGER</code>) values can be promoted to rangeOfInteger
(<code>IPP_TAG_RANGE</code>) values, the various string tags can be promoted to name
(<code>IPP_TAG_NAME</code>) or nameWithLanguage (<code>IPP_TAG_NAMELANG</code>) values, text
(<code>IPP_TAG_TEXT</code>) values can be promoted to textWithLanguage
(<code>IPP_TAG_TEXTLANG</code>) values, and all values can be demoted to the various
out-of-band value tags such as no-value (<code>IPP_TAG_NOVALUE</code>). All other changes
will be rejected.<br>
<br>
Promoting a string attribute to nameWithLanguage or textWithLanguage adds the language
code in the &quot;attributes-natural-language&quot; attribute or, if not present, the language
code for the current locale.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.6/OS X 10.8&nbsp;</span><a name="ippSetVersion">ippSetVersion</a></h3>
<p class="description">Set the version number in an IPP message.</p>
<p class="code">
int ippSetVersion (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int major,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int minor<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
<dt>major</dt>
<dd class="description">Major version number (major.minor)</dd>
<dt>minor</dt>
<dd class="description">Minor version number (major.minor)</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 on success, 0 on failure</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The <code>ipp</code> parameter refers to an IPP message previously created using
the <a href="#ippNew"><code>ippNew</code></a>, <a href="#ippNewRequest"><code>ippNewRequest</code></a>, or  <a href="#ippNewResponse"><code>ippNewResponse</code></a> functions.<br>
<br>
The valid version numbers are currently 1.0, 1.1, 2.0, 2.1, and 2.2.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="ippStateString">ippStateString</a></h3>
<p class="description">Return the name corresponding to a state value.</p>
<p class="code">
const char *ippStateString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_state_t">ipp_state_t</a> state<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>state</dt>
<dd class="description">State value</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">State name</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.4/OS X 10.6&nbsp;</span><a name="ippTagString">ippTagString</a></h3>
<p class="description">Return the tag name corresponding to a tag value.</p>
<p class="code">
const char *ippTagString (<br>
&nbsp;&nbsp;&nbsp;&nbsp;ipp_tag_t tag<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>tag</dt>
<dd class="description">Tag value</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Tag name</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The returned names are defined in RFC 2911 and 3382.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.4/OS X 10.6&nbsp;</span><a name="ippTagValue">ippTagValue</a></h3>
<p class="description">Return the tag value corresponding to a tag name.</p>
<p class="code">
ipp_tag_t ippTagValue (<br>
&nbsp;&nbsp;&nbsp;&nbsp;const char *name<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>name</dt>
<dd class="description">Tag name</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Tag value</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">The tag names are defined in RFC 2911 and 3382.

</p>
<h3 class="function"><a name="ippTimeToDate">ippTimeToDate</a></h3>
<p class="description">Convert from UNIX time to RFC 1903 format.</p>
<p class="code">
const <a href="#ipp_uchar_t">ipp_uchar_t</a> *ippTimeToDate (<br>
&nbsp;&nbsp;&nbsp;&nbsp;time_t t<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>t</dt>
<dd class="description">UNIX time value</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">RFC-1903 date/time data</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="ippValidateAttribute">ippValidateAttribute</a></h3>
<p class="description">Validate the contents of an attribute.</p>
<p class="code">
int ippValidateAttribute (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_attribute_t">ipp_attribute_t</a> *attr<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>attr</dt>
<dd class="description">Attribute</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 if valid, 0 otherwise</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function validates the contents of an attribute based on the name and
value tag.  1 is returned if the attribute is valid, 0 otherwise.  On
failure, cupsLastErrorString() is set to a human-readable message.

</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span><a name="ippValidateAttributes">ippValidateAttributes</a></h3>
<p class="description">Validate all attributes in an IPP message.</p>
<p class="code">
int ippValidateAttributes (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>ipp</dt>
<dd class="description">IPP message</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">1 if valid, 0 otherwise</p>
<h4 class="discussion">Discussion</h4>
<p class="discussion">This function validates the contents of the IPP message, including each
attribute.  Like <a href="#ippValidateAttribute"><code>ippValidateAttribute</code></a>, cupsLastErrorString() is set
to a human-readable message on failure.

</p>
<h3 class="function"><a name="ippWrite">ippWrite</a></h3>
<p class="description">Write data for an IPP message to a HTTP connection.</p>
<p class="code">
<a href="#ipp_state_t">ipp_state_t</a> ippWrite (<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_t">http_t</a> *http,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>http</dt>
<dd class="description">HTTP connection</dd>
<dt>ipp</dt>
<dd class="description">IPP data</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Current state</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.1.19/OS X 10.3&nbsp;</span><a name="ippWriteFile">ippWriteFile</a></h3>
<p class="description">Write data for an IPP message to a file.</p>
<p class="code">
<a href="#ipp_state_t">ipp_state_t</a> ippWriteFile (<br>
&nbsp;&nbsp;&nbsp;&nbsp;int fd,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>fd</dt>
<dd class="description">HTTP data</dd>
<dt>ipp</dt>
<dd class="description">IPP data</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Current state</p>
<h3 class="function"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="ippWriteIO">ippWriteIO</a></h3>
<p class="description">Write data for an IPP message.</p>
<p class="code">
<a href="#ipp_state_t">ipp_state_t</a> ippWriteIO (<br>
&nbsp;&nbsp;&nbsp;&nbsp;void *dst,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_iocb_t">ipp_iocb_t</a> cb,<br>
&nbsp;&nbsp;&nbsp;&nbsp;int blocking,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *parent,<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#ipp_t">ipp_t</a> *ipp<br>
);</p>
<h4 class="parameters">Parameters</h4>
<dl>
<dt>dst</dt>
<dd class="description">Destination</dd>
<dt>cb</dt>
<dd class="description">Write callback function</dd>
<dt>blocking</dt>
<dd class="description">Use blocking IO?</dd>
<dt>parent</dt>
<dd class="description">Parent IPP message</dd>
<dt>ipp</dt>
<dd class="description">IPP data</dd>
</dl>
<h4 class="returnvalue">Return Value</h4>
<p class="description">Current state</p>
<h2 class="title"><a name="TYPES">Data Types</a></h2>
<h3 class="typedef"><a name="gss_auth_identity_desc">gss_auth_identity_desc</a></h3>
<p class="description">Local functions...</p>
<p class="code">
typedef struct <a href="#gss_auth_identity">gss_auth_identity</a> gss_auth_identity_desc;
</p>
<h3 class="typedef"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="http_addr_t">http_addr_t</a></h3>
<p class="description">Socket address union, which
makes using IPv6 and other
address types easier and
more portable. </p>
<p class="code">
typedef union _http_addr_u / http_addr_t;
</p>
<h3 class="typedef"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="http_addrlist_t">http_addrlist_t</a></h3>
<p class="description">Socket address list, which is
used to enumerate all of the
addresses that are associated
with a hostname. </p>
<p class="code">
typedef struct <a href="#http_addrlist_s">http_addrlist_s</a> / http_addrlist_t;
</p>
<h3 class="typedef"><a name="http_auth_t">http_auth_t</a></h3>
<p class="description">HTTP authentication types</p>
<p class="code">
typedef enum <a href="#http_auth_e">http_auth_e</a> http_auth_t;
</p>
<h3 class="typedef"><span class="info">&nbsp;CUPS 1.5/OS X 10.7&nbsp;</span><a name="http_credential_t">http_credential_t</a></h3>
<p class="description">HTTP credential data </p>
<p class="code">
typedef struct <a href="#http_credential_s">http_credential_s</a> http_credential_t;
</p>
<h3 class="typedef"><a name="http_encoding_t">http_encoding_t</a></h3>
<p class="description">HTTP transfer encoding values</p>
<p class="code">
typedef enum <a href="#http_encoding_e">http_encoding_e</a> http_encoding_t;
</p>
<h3 class="typedef"><a name="http_encryption_t">http_encryption_t</a></h3>
<p class="description">HTTP encryption values</p>
<p class="code">
typedef enum <a href="#http_encryption_e">http_encryption_e</a> http_encryption_t;
</p>
<h3 class="typedef"><a name="http_field_t">http_field_t</a></h3>
<p class="description">HTTP field names</p>
<p class="code">
typedef enum <a href="#http_field_e">http_field_e</a> http_field_t;
</p>
<h3 class="typedef"><a name="http_keepalive_t">http_keepalive_t</a></h3>
<p class="description">HTTP keep-alive values</p>
<p class="code">
typedef enum <a href="#http_keepalive_e">http_keepalive_e</a> http_keepalive_t;
</p>
<h3 class="typedef"><a name="http_state_t">http_state_t</a></h3>
<p class="description">HTTP state values; states
are server-oriented...</p>
<p class="code">
typedef enum <a href="#http_state_e">http_state_e</a> http_state_t;
</p>
<h3 class="typedef"><a name="http_t">http_t</a></h3>
<p class="description">HTTP connection type</p>
<p class="code">
typedef struct _http_s http_t;
</p>
<h3 class="typedef"><span class="info">&nbsp;CUPS 1.5/OS X 10.7&nbsp;</span><a name="http_timeout_cb_t">http_timeout_cb_t</a></h3>
<p class="description">HTTP timeout callback </p>
<p class="code">
typedef int (*http_timeout_cb_t)(<a href="#http_t">http_t</a> *http, void *user_data);
</p>
<h3 class="typedef"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="http_trust_t">http_trust_t</a></h3>
<p class="description">Level of trust for credentials </p>
<p class="code">
typedef enum <a href="#http_trust_e">http_trust_e</a> http_trust_t;
</p>
<h3 class="typedef"><a name="http_uri_coding_t">http_uri_coding_t</a></h3>
<p class="description">URI en/decode flags</p>
<p class="code">
typedef enum <a href="#http_uri_coding_e">http_uri_coding_e</a> http_uri_coding_t;
</p>
<h3 class="typedef"><span class="info">&nbsp;CUPS 1.2&nbsp;</span><a name="http_uri_status_t">http_uri_status_t</a></h3>
<p class="description">URI separation status </p>
<p class="code">
typedef enum <a href="#http_uri_status_e">http_uri_status_e</a> http_uri_status_t;
</p>
<h3 class="typedef"><a name="http_version_t">http_version_t</a></h3>
<p class="description">HTTP version numbers</p>
<p class="code">
typedef enum <a href="#http_version_e">http_version_e</a> http_version_t;
</p>
<h3 class="typedef"><a name="ipp_attribute_t">ipp_attribute_t</a></h3>
<p class="description">IPP attribute</p>
<p class="code">
typedef struct _ipp_attribute_s ipp_attribute_t;
</p>
<h3 class="typedef"><a name="ipp_copycb_t">ipp_copycb_t</a></h3>
<p class="description">The following structures are PRIVATE starting with CUPS 1.6/OS X 10.8.
Please use the new accessor functions available in CUPS 1.6 and later, as
these definitions will be moved to a private header file in a future release.</p>
<p class="code">
typedef int (*ipp_copycb_t)(void *context, <a href="#ipp_t">ipp_t</a> *dst, <a href="#ipp_attribute_t">ipp_attribute_t</a> *attr);
</p>
<h3 class="typedef"><a name="ipp_dstate_t">ipp_dstate_t</a></h3>
<p class="description">Document states</p>
<p class="code">
typedef enum <a href="#ipp_dstate_e">ipp_dstate_e</a> ipp_dstate_t;
</p>
<h3 class="typedef"><a name="ipp_finish_t">ipp_finish_t</a></h3>
<p class="description">Job collation types</p>
<p class="code">
typedef enum <a href="#ipp_finishings_e">ipp_finishings_e</a> ipp_finish_t;
</p>
<h3 class="typedef"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="ipp_iocb_t">ipp_iocb_t</a></h3>
<p class="description">IPP IO Callback Function </p>
<p class="code">
typedef ssize_t (*ipp_iocb_t)(void *context, <a href="#ipp_uchar_t">ipp_uchar_t</a> *buffer, size_t bytes);
</p>
<h3 class="typedef"><a name="ipp_jcollate_t">ipp_jcollate_t</a></h3>
<p class="description">Job collation types</p>
<p class="code">
typedef enum <a href="#ipp_jcollate_e">ipp_jcollate_e</a> ipp_jcollate_t;
</p>
<h3 class="typedef"><a name="ipp_orient_t">ipp_orient_t</a></h3>
<p class="description">Orientation values</p>
<p class="code">
typedef enum <a href="#ipp_orient_e">ipp_orient_e</a> ipp_orient_t;
</p>
<h3 class="typedef"><a name="ipp_pstate_t">ipp_pstate_t</a></h3>
<p class="description">Printer states</p>
<p class="code">
typedef enum <a href="#ipp_pstate_e">ipp_pstate_e</a> ipp_pstate_t;
</p>
<h3 class="typedef"><a name="ipp_quality_t">ipp_quality_t</a></h3>
<p class="description">Qualities</p>
<p class="code">
typedef enum <a href="#ipp_quality_e">ipp_quality_e</a> ipp_quality_t;
</p>
<h3 class="typedef"><a name="ipp_res_t">ipp_res_t</a></h3>
<p class="description">Resolution units</p>
<p class="code">
typedef enum <a href="#ipp_res_e">ipp_res_e</a> ipp_res_t;
</p>
<h3 class="typedef"><a name="ipp_state_t">ipp_state_t</a></h3>
<p class="description">IPP states</p>
<p class="code">
typedef enum <a href="#ipp_state_e">ipp_state_e</a> ipp_state_t;
</p>
<h3 class="typedef"><a name="ipp_t">ipp_t</a></h3>
<p class="description">IPP request/response data</p>
<p class="code">
typedef struct _ipp_s ipp_t;
</p>
<h3 class="typedef"><a name="ipp_uchar_t">ipp_uchar_t</a></h3>
<p class="description">Unsigned 8-bit integer/character</p>
<p class="code">
typedef unsigned char ipp_uchar_t;
</p>
<h2 class="title"><a name="STRUCTURES">Structures</a></h2>
<h3 class="struct"><a name="gss_auth_identity">gss_auth_identity</a></h3>
<p class="description">Local functions...</p>
<p class="code">struct gss_auth_identity {<br>
&nbsp;&nbsp;&nbsp;&nbsp;gss_buffer_t *credentialsRef;<br>
&nbsp;&nbsp;&nbsp;&nbsp;uint32_t flags;<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *password;<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *realm;<br>
&nbsp;&nbsp;&nbsp;&nbsp;uint32_t type;<br>
&nbsp;&nbsp;&nbsp;&nbsp;char *username;<br>
};</p>
<h4 class="members">Members</h4>
<dl>
<dt>credentialsRef </dt>
<dt>flags </dt>
<dt>password </dt>
<dt>realm </dt>
<dt>type </dt>
<dt>username </dt>
</dl>
<h3 class="struct"><span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span><a name="http_addrlist_s">http_addrlist_s</a></h3>
<p class="description">Socket address list, which is
used to enumerate all of the
addresses that are associated
with a hostname. </p>
<p class="code">struct http_addrlist_s {<br>
&nbsp;&nbsp;&nbsp;&nbsp;<a href="#http_addr_t">http_addr_t</a> addr;<br>
&nbsp;&nbsp;&nbsp;&nbsp;struct <a href="#http_addrlist_s">http_addrlist_s</a> *next;<br>
};</p>
<h4 class="members">Members</h4>
<dl>
<dt>addr </dt>
<dd class="description">Address</dd>
<dt>next </dt>
<dd class="description">Pointer to next address in list</dd>
</dl>
<h3 class="struct"><span class="info">&nbsp;CUPS 1.5/OS X 10.7&nbsp;</span><a name="http_credential_s">http_credential_s</a></h3>
<p class="description">HTTP credential data </p>
<p class="code">struct http_credential_s {<br>
&nbsp;&nbsp;&nbsp;&nbsp;void *data;<br>
&nbsp;&nbsp;&nbsp;&nbsp;size_t datalen;<br>
};</p>
<h4 class="members">Members</h4>
<dl>
<dt>data </dt>
<dd class="description">Pointer to credential data</dd>
<dt>datalen </dt>
<dd class="description">Credential length</dd>
</dl>
<h3 class="struct"><a name="pollfd">pollfd</a></h3>
<p class="description">User data (unused)</p>
<p class="code">struct pollfd *pollfds, unsigned int num_pollfds, int timeout, void *context) {<br>
&nbsp;&nbsp;&nbsp;&nbsp;void) context;<br>
&nbsp;&nbsp;&nbsp;&nbsp;void) timeout;<br>
};</p>
<h4 class="members">Members</h4>
<dl>
<dt>context </dt>
<dt>timeout </dt>
</dl>
<h2 class="title"><a name="ENUMERATIONS">Constants</a></h2>
<h3 class="enumeration"><a name="http_auth_e">http_auth_e</a></h3>
<p class="description">HTTP authentication types</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>HTTP_AUTH_BASIC </dt>
<dd class="description">Basic authentication in use</dd>
<dt>HTTP_AUTH_MD5 </dt>
<dd class="description">Digest authentication in use</dd>
<dt>HTTP_AUTH_MD5_INT </dt>
<dd class="description">Digest authentication in use for body</dd>
<dt>HTTP_AUTH_MD5_SESS </dt>
<dd class="description">MD5-session authentication in use</dd>
<dt>HTTP_AUTH_MD5_SESS_INT </dt>
<dd class="description">MD5-session authentication in use for body</dd>
<dt>HTTP_AUTH_NEGOTIATE <span class="info">&nbsp;CUPS 1.3/OS X 10.5&nbsp;</span></dt>
<dd class="description">GSSAPI authentication in use </dd>
<dt>HTTP_AUTH_NONE </dt>
<dd class="description">No authentication in use</dd>
</dl>
<h3 class="enumeration"><a name="http_encoding_e">http_encoding_e</a></h3>
<p class="description">HTTP transfer encoding values</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>HTTP_ENCODING_CHUNKED </dt>
<dd class="description">Data is chunked</dd>
<dt>HTTP_ENCODING_FIELDS </dt>
<dd class="description">Sending HTTP fields</dd>
<dt>HTTP_ENCODING_LENGTH </dt>
<dd class="description">Data is sent with Content-Length</dd>
</dl>
<h3 class="enumeration"><a name="http_encryption_e">http_encryption_e</a></h3>
<p class="description">HTTP encryption values</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>HTTP_ENCRYPTION_ALWAYS </dt>
<dd class="description">Always encrypt (SSL)</dd>
<dt>HTTP_ENCRYPTION_IF_REQUESTED </dt>
<dd class="description">Encrypt if requested (TLS upgrade)</dd>
<dt>HTTP_ENCRYPTION_NEVER </dt>
<dd class="description">Never encrypt</dd>
<dt>HTTP_ENCRYPTION_REQUIRED </dt>
<dd class="description">Encryption is required (TLS upgrade)</dd>
</dl>
<h3 class="enumeration"><a name="http_field_e">http_field_e</a></h3>
<p class="description">HTTP field names</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>HTTP_FIELD_ACCEPT_ENCODING <span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span></dt>
<dd class="description">Accepting-Encoding field </dd>
<dt>HTTP_FIELD_ACCEPT_LANGUAGE </dt>
<dd class="description">Accept-Language field</dd>
<dt>HTTP_FIELD_ACCEPT_RANGES </dt>
<dd class="description">Accept-Ranges field</dd>
<dt>HTTP_FIELD_ALLOW <span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span></dt>
<dd class="description">Allow field </dd>
<dt>HTTP_FIELD_AUTHORIZATION </dt>
<dd class="description">Authorization field</dd>
<dt>HTTP_FIELD_CONNECTION </dt>
<dd class="description">Connection field</dd>
<dt>HTTP_FIELD_CONTENT_ENCODING </dt>
<dd class="description">Content-Encoding field</dd>
<dt>HTTP_FIELD_CONTENT_LANGUAGE </dt>
<dd class="description">Content-Language field</dd>
<dt>HTTP_FIELD_CONTENT_LENGTH </dt>
<dd class="description">Content-Length field</dd>
<dt>HTTP_FIELD_CONTENT_LOCATION </dt>
<dd class="description">Content-Location field</dd>
<dt>HTTP_FIELD_CONTENT_MD5 </dt>
<dd class="description">Content-MD5 field</dd>
<dt>HTTP_FIELD_CONTENT_RANGE </dt>
<dd class="description">Content-Range field</dd>
<dt>HTTP_FIELD_CONTENT_TYPE </dt>
<dd class="description">Content-Type field</dd>
<dt>HTTP_FIELD_CONTENT_VERSION </dt>
<dd class="description">Content-Version field</dd>
<dt>HTTP_FIELD_DATE </dt>
<dd class="description">Date field</dd>
<dt>HTTP_FIELD_HOST </dt>
<dd class="description">Host field</dd>
<dt>HTTP_FIELD_IF_MODIFIED_SINCE </dt>
<dd class="description">If-Modified-Since field</dd>
<dt>HTTP_FIELD_IF_UNMODIFIED_SINCE </dt>
<dd class="description">If-Unmodified-Since field</dd>
<dt>HTTP_FIELD_KEEP_ALIVE </dt>
<dd class="description">Keep-Alive field</dd>
<dt>HTTP_FIELD_LAST_MODIFIED </dt>
<dd class="description">Last-Modified field</dd>
<dt>HTTP_FIELD_LINK </dt>
<dd class="description">Link field</dd>
<dt>HTTP_FIELD_LOCATION </dt>
<dd class="description">Location field</dd>
<dt>HTTP_FIELD_MAX </dt>
<dd class="description">Maximum field index</dd>
<dt>HTTP_FIELD_RANGE </dt>
<dd class="description">Range field</dd>
<dt>HTTP_FIELD_REFERER </dt>
<dd class="description">Referer field</dd>
<dt>HTTP_FIELD_RETRY_AFTER </dt>
<dd class="description">Retry-After field</dd>
<dt>HTTP_FIELD_SERVER <span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span></dt>
<dd class="description">Server field </dd>
<dt>HTTP_FIELD_TRANSFER_ENCODING </dt>
<dd class="description">Transfer-Encoding field</dd>
<dt>HTTP_FIELD_UNKNOWN </dt>
<dd class="description">Unknown field</dd>
<dt>HTTP_FIELD_UPGRADE </dt>
<dd class="description">Upgrade field</dd>
<dt>HTTP_FIELD_USER_AGENT </dt>
<dd class="description">User-Agent field</dd>
<dt>HTTP_FIELD_WWW_AUTHENTICATE </dt>
<dd class="description">WWW-Authenticate field</dd>
</dl>
<h3 class="enumeration"><a name="http_keepalive_e">http_keepalive_e</a></h3>
<p class="description">HTTP keep-alive values</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>HTTP_KEEPALIVE_OFF </dt>
<dd class="description">No keep alive support</dd>
<dt>HTTP_KEEPALIVE_ON </dt>
<dd class="description">Use keep alive</dd>
</dl>
<h3 class="enumeration"><a name="http_state_e">http_state_e</a></h3>
<p class="description">HTTP state values; states
are server-oriented...</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>HTTP_STATE_CONNECT </dt>
<dd class="description">CONNECT command, waiting for blank line</dd>
<dt>HTTP_STATE_DELETE </dt>
<dd class="description">DELETE command, waiting for blank line</dd>
<dt>HTTP_STATE_ERROR </dt>
<dd class="description">Error on socket</dd>
<dt>HTTP_STATE_GET </dt>
<dd class="description">GET command, waiting for blank line</dd>
<dt>HTTP_STATE_GET_SEND </dt>
<dd class="description">GET command, sending data</dd>
<dt>HTTP_STATE_HEAD </dt>
<dd class="description">HEAD command, waiting for blank line</dd>
<dt>HTTP_STATE_OPTIONS </dt>
<dd class="description">OPTIONS command, waiting for blank line</dd>
<dt>HTTP_STATE_POST </dt>
<dd class="description">POST command, waiting for blank line</dd>
<dt>HTTP_STATE_POST_RECV </dt>
<dd class="description">POST command, receiving data</dd>
<dt>HTTP_STATE_POST_SEND </dt>
<dd class="description">POST command, sending data</dd>
<dt>HTTP_STATE_PUT </dt>
<dd class="description">PUT command, waiting for blank line</dd>
<dt>HTTP_STATE_PUT_RECV </dt>
<dd class="description">PUT command, receiving data</dd>
<dt>HTTP_STATE_STATUS </dt>
<dd class="description">Command complete, sending status</dd>
<dt>HTTP_STATE_TRACE </dt>
<dd class="description">TRACE command, waiting for blank line</dd>
<dt>HTTP_STATE_UNKNOWN_METHOD <span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span></dt>
<dd class="description">Unknown request method, waiting for blank line </dd>
<dt>HTTP_STATE_UNKNOWN_VERSION <span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span></dt>
<dd class="description">Unknown request method, waiting for blank line </dd>
<dt>HTTP_STATE_WAITING </dt>
<dd class="description">Waiting for command</dd>
</dl>
<h3 class="enumeration"><a name="http_status_e">http_status_e</a></h3>
<p class="description">HTTP status codes</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>HTTP_STATUS_ACCEPTED </dt>
<dd class="description">DELETE command was successful</dd>
<dt>HTTP_STATUS_BAD_GATEWAY </dt>
<dd class="description">Bad gateway</dd>
<dt>HTTP_STATUS_BAD_REQUEST </dt>
<dd class="description">Bad request</dd>
<dt>HTTP_STATUS_CONFLICT </dt>
<dd class="description">Request is self-conflicting</dd>
<dt>HTTP_STATUS_CONTINUE </dt>
<dd class="description">Everything OK, keep going...</dd>
<dt>HTTP_STATUS_CREATED </dt>
<dd class="description">PUT command was successful</dd>
<dt>HTTP_STATUS_CUPS_AUTHORIZATION_CANCELED <span class="info">&nbsp;CUPS 1.4&nbsp;</span></dt>
<dd class="description">User canceled authorization </dd>
<dt>HTTP_STATUS_CUPS_PKI_ERROR <span class="info">&nbsp;CUPS 1.5/OS X 10.7&nbsp;</span></dt>
<dd class="description">Error negotiating a secure connection </dd>
<dt>HTTP_STATUS_ERROR </dt>
<dd class="description">An error response from httpXxxx()</dd>
<dt>HTTP_STATUS_EXPECTATION_FAILED </dt>
<dd class="description">The expectation given in an Expect header field was not met</dd>
<dt>HTTP_STATUS_FORBIDDEN </dt>
<dd class="description">Forbidden to access this URI</dd>
<dt>HTTP_STATUS_GATEWAY_TIMEOUT </dt>
<dd class="description">Gateway connection timed out</dd>
<dt>HTTP_STATUS_GONE </dt>
<dd class="description">Server has gone away</dd>
<dt>HTTP_STATUS_LENGTH_REQUIRED </dt>
<dd class="description">A content length or encoding is required</dd>
<dt>HTTP_STATUS_METHOD_NOT_ALLOWED </dt>
<dd class="description">Method is not allowed</dd>
<dt>HTTP_STATUS_MOVED_PERMANENTLY </dt>
<dd class="description">Document has moved permanently</dd>
<dt>HTTP_STATUS_MOVED_TEMPORARILY </dt>
<dd class="description">Document has moved temporarily</dd>
<dt>HTTP_STATUS_MULTIPLE_CHOICES </dt>
<dd class="description">Multiple files match request</dd>
<dt>HTTP_STATUS_NONE <span class="info">&nbsp;CUPS 1.7/OS X 10.9&nbsp;</span></dt>
<dd class="description">No Expect value </dd>
<dt>HTTP_STATUS_NOT_ACCEPTABLE </dt>
<dd class="description">Not Acceptable</dd>
<dt>HTTP_STATUS_NOT_AUTHORITATIVE </dt>
<dd class="description">Information isn't authoritative</dd>
<dt>HTTP_STATUS_NOT_FOUND </dt>
<dd class="description">URI was not found</dd>
<dt>HTTP_STATUS_NOT_IMPLEMENTED </dt>
<dd class="description">Feature not implemented</dd>
<dt>HTTP_STATUS_NOT_MODIFIED </dt>
<dd class="description">File not modified</dd>
<dt>HTTP_STATUS_NOT_SUPPORTED </dt>
<dd class="description">HTTP version not supported</dd>
<dt>HTTP_STATUS_NO_CONTENT </dt>
<dd class="description">Successful command, no new data</dd>
<dt>HTTP_STATUS_OK </dt>
<dd class="description">OPTIONS/GET/HEAD/POST/TRACE command was successful</dd>
<dt>HTTP_STATUS_PARTIAL_CONTENT </dt>
<dd class="description">Only a partial file was received/sent</dd>
<dt>HTTP_STATUS_PAYMENT_REQUIRED </dt>
<dd class="description">Payment required</dd>
<dt>HTTP_STATUS_PRECONDITION </dt>
<dd class="description">Precondition failed</dd>
<dt>HTTP_STATUS_PROXY_AUTHENTICATION </dt>
<dd class="description">Proxy Authentication is Required</dd>
<dt>HTTP_STATUS_REQUESTED_RANGE </dt>
<dd class="description">The requested range is not satisfiable</dd>
<dt>HTTP_STATUS_REQUEST_TIMEOUT </dt>
<dd class="description">Request timed out</dd>
<dt>HTTP_STATUS_REQUEST_TOO_LARGE </dt>
<dd class="description">Request entity too large</dd>
<dt>HTTP_STATUS_RESET_CONTENT </dt>
<dd class="description">Content was reset/recreated</dd>
<dt>HTTP_STATUS_SEE_OTHER </dt>
<dd class="description">See this other link...</dd>
<dt>HTTP_STATUS_SERVER_ERROR </dt>
<dd class="description">Internal server error</dd>
<dt>HTTP_STATUS_SERVICE_UNAVAILABLE </dt>
<dd class="description">Service is unavailable</dd>
<dt>HTTP_STATUS_SWITCHING_PROTOCOLS </dt>
<dd class="description">HTTP upgrade to TLS/SSL</dd>
<dt>HTTP_STATUS_UNAUTHORIZED </dt>
<dd class="description">Unauthorized to access host</dd>
<dt>HTTP_STATUS_UNSUPPORTED_MEDIATYPE </dt>
<dd class="description">The requested media type is unsupported</dd>
<dt>HTTP_STATUS_UPGRADE_REQUIRED </dt>
<dd class="description">Upgrade to SSL/TLS required</dd>
<dt>HTTP_STATUS_URI_TOO_LONG </dt>
<dd class="description">URI too long</dd>
<dt>HTTP_STATUS_USE_PROXY </dt>
<dd class="description">Must use a proxy to access this URI</dd>
</dl>
<h3 class="enumeration"><span class="info">&nbsp;CUPS 2.0/OS 10.10&nbsp;</span><a name="http_trust_e">http_trust_e</a></h3>
<p class="description">Level of trust for credentials </p>
<h4 class="constants">Constants</h4>
<dl>
<dt>HTTP_TRUST_CHANGED </dt>
<dd class="description">Credentials have changed</dd>
<dt>HTTP_TRUST_EXPIRED </dt>
<dd class="description">Credentials are expired</dd>
<dt>HTTP_TRUST_INVALID </dt>
<dd class="description">Credentials are invalid</dd>
<dt>HTTP_TRUST_OK </dt>
<dd class="description">Credentials are OK/trusted</dd>
<dt>HTTP_TRUST_RENEWED </dt>
<dd class="description">Credentials have been renewed</dd>
<dt>HTTP_TRUST_UNKNOWN </dt>
<dd class="description">Credentials are unknown/new</dd>
</dl>
<h3 class="enumeration"><a name="http_uri_coding_e">http_uri_coding_e</a></h3>
<p class="description">URI en/decode flags</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>HTTP_URI_CODING_ALL </dt>
<dd class="description">En/decode everything</dd>
<dt>HTTP_URI_CODING_HOSTNAME </dt>
<dd class="description">En/decode the hostname portion</dd>
<dt>HTTP_URI_CODING_MOST </dt>
<dd class="description">En/decode all but the query</dd>
<dt>HTTP_URI_CODING_NONE </dt>
<dd class="description">Don't en/decode anything</dd>
<dt>HTTP_URI_CODING_QUERY </dt>
<dd class="description">En/decode the query portion</dd>
<dt>HTTP_URI_CODING_RESOURCE </dt>
<dd class="description">En/decode the resource portion</dd>
<dt>HTTP_URI_CODING_RFC6874 </dt>
<dd class="description">Use RFC 6874 address format</dd>
<dt>HTTP_URI_CODING_USERNAME </dt>
<dd class="description">En/decode the username portion</dd>
</dl>
<h3 class="enumeration"><span class="info">&nbsp;CUPS 1.2&nbsp;</span><a name="http_uri_status_e">http_uri_status_e</a></h3>
<p class="description">URI separation status </p>
<h4 class="constants">Constants</h4>
<dl>
<dt>HTTP_URI_STATUS_BAD_ARGUMENTS </dt>
<dd class="description">Bad arguments to function (error)</dd>
<dt>HTTP_URI_STATUS_BAD_HOSTNAME </dt>
<dd class="description">Bad hostname in URI (error)</dd>
<dt>HTTP_URI_STATUS_BAD_PORT </dt>
<dd class="description">Bad port number in URI (error)</dd>
<dt>HTTP_URI_STATUS_BAD_RESOURCE </dt>
<dd class="description">Bad resource in URI (error)</dd>
<dt>HTTP_URI_STATUS_BAD_SCHEME </dt>
<dd class="description">Bad scheme in URI (error)</dd>
<dt>HTTP_URI_STATUS_BAD_URI </dt>
<dd class="description">Bad/empty URI (error)</dd>
<dt>HTTP_URI_STATUS_BAD_USERNAME </dt>
<dd class="description">Bad username in URI (error)</dd>
<dt>HTTP_URI_STATUS_MISSING_RESOURCE </dt>
<dd class="description">Missing resource in URI (warning)</dd>
<dt>HTTP_URI_STATUS_MISSING_SCHEME </dt>
<dd class="description">Missing scheme in URI (warning)</dd>
<dt>HTTP_URI_STATUS_OK </dt>
<dd class="description">URI decoded OK</dd>
<dt>HTTP_URI_STATUS_OVERFLOW </dt>
<dd class="description">URI buffer for httpAssembleURI is too small</dd>
<dt>HTTP_URI_STATUS_UNKNOWN_SCHEME </dt>
<dd class="description">Unknown scheme in URI (warning)</dd>
</dl>
<h3 class="enumeration"><a name="http_version_e">http_version_e</a></h3>
<p class="description">HTTP version numbers</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>HTTP_VERSION_0_9 </dt>
<dd class="description">HTTP/0.9</dd>
<dt>HTTP_VERSION_1_0 </dt>
<dd class="description">HTTP/1.0</dd>
<dt>HTTP_VERSION_1_1 </dt>
<dd class="description">HTTP/1.1</dd>
</dl>
<h3 class="enumeration"><a name="ipp_dstate_e">ipp_dstate_e</a></h3>
<p class="description">Document states</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>IPP_DOCUMENT_ABORTED </dt>
<dd class="description">Document is aborted</dd>
<dt>IPP_DOCUMENT_CANCELED </dt>
<dd class="description">Document is canceled</dd>
<dt>IPP_DOCUMENT_COMPLETED </dt>
<dd class="description">Document is completed</dd>
<dt>IPP_DOCUMENT_PENDING </dt>
<dd class="description">Document is pending</dd>
<dt>IPP_DOCUMENT_PROCESSING </dt>
<dd class="description">Document is processing</dd>
</dl>
<h3 class="enumeration"><a name="ipp_finishings_e">ipp_finishings_e</a></h3>
<p class="description">Finishings</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>IPP_FINISHINGS_BALE </dt>
<dd class="description">Bale (any type)</dd>
<dt>IPP_FINISHINGS_BIND </dt>
<dd class="description">Bind</dd>
<dt>IPP_FINISHINGS_BIND_BOTTOM </dt>
<dd class="description">Bind on bottom</dd>
<dt>IPP_FINISHINGS_BIND_LEFT </dt>
<dd class="description">Bind on left</dd>
<dt>IPP_FINISHINGS_BIND_RIGHT </dt>
<dd class="description">Bind on right</dd>
<dt>IPP_FINISHINGS_BIND_TOP </dt>
<dd class="description">Bind on top</dd>
<dt>IPP_FINISHINGS_BOOKLET_MAKER </dt>
<dd class="description">Fold to make booklet</dd>
<dt>IPP_FINISHINGS_COAT </dt>
<dd class="description">Apply protective liquid or powder coating</dd>
<dt>IPP_FINISHINGS_COVER </dt>
<dd class="description">Add cover</dd>
<dt>IPP_FINISHINGS_CUPS_FOLD_ACCORDIAN </dt>
<dd class="description">Accordian-fold the paper vertically into four sections</dd>
<dt>IPP_FINISHINGS_CUPS_FOLD_DOUBLE_GATE </dt>
<dd class="description">Fold the top and bottom quarters of the paper towards the midline, then fold in half vertically</dd>
<dt>IPP_FINISHINGS_CUPS_FOLD_GATE </dt>
<dd class="description">Fold the top and bottom quarters of the paper towards the midline</dd>
<dt>IPP_FINISHINGS_CUPS_FOLD_HALF </dt>
<dd class="description">Fold the paper in half vertically</dd>
<dt>IPP_FINISHINGS_CUPS_FOLD_HALF_Z </dt>
<dd class="description">Fold the paper in half horizontally, then Z-fold the paper vertically</dd>
<dt>IPP_FINISHINGS_CUPS_FOLD_LEFT_GATE </dt>
<dd class="description">Fold the top quarter of the paper towards the midline</dd>
<dt>IPP_FINISHINGS_CUPS_FOLD_LETTER </dt>
<dd class="description">Fold the paper into three sections vertically; sometimes also known as a C fold</dd>
<dt>IPP_FINISHINGS_CUPS_FOLD_PARALLEL </dt>
<dd class="description">Fold the paper in half vertically two times, yielding four sections</dd>
<dt>IPP_FINISHINGS_CUPS_FOLD_POSTER </dt>
<dd class="description">Fold the paper in half horizontally and vertically; sometimes also called a cross fold</dd>
<dt>IPP_FINISHINGS_CUPS_FOLD_RIGHT_GATE </dt>
<dd class="description">Fold the bottom quarter of the paper towards the midline</dd>
<dt>IPP_FINISHINGS_CUPS_FOLD_Z </dt>
<dd class="description">Fold the paper vertically into three sections, forming a Z</dd>
<dt>IPP_FINISHINGS_CUPS_PUNCH_BOTTOM_LEFT </dt>
<dd class="description">Punch 1 hole bottom left</dd>
<dt>IPP_FINISHINGS_CUPS_PUNCH_BOTTOM_RIGHT </dt>
<dd class="description">Punch 1 hole bottom right</dd>
<dt>IPP_FINISHINGS_CUPS_PUNCH_DUAL_BOTTOM </dt>
<dd class="description">Punch 2 holes bottom edge</dd>
<dt>IPP_FINISHINGS_CUPS_PUNCH_DUAL_LEFT </dt>
<dd class="description">Punch 2 holes left side</dd>
<dt>IPP_FINISHINGS_CUPS_PUNCH_DUAL_RIGHT </dt>
<dd class="description">Punch 2 holes right side</dd>
<dt>IPP_FINISHINGS_CUPS_PUNCH_DUAL_TOP </dt>
<dd class="description">Punch 2 holes top edge</dd>
<dt>IPP_FINISHINGS_CUPS_PUNCH_QUAD_BOTTOM </dt>
<dd class="description">Punch 4 holes bottom edge</dd>
<dt>IPP_FINISHINGS_CUPS_PUNCH_QUAD_LEFT </dt>
<dd class="description">Punch 4 holes left side</dd>
<dt>IPP_FINISHINGS_CUPS_PUNCH_QUAD_RIGHT </dt>
<dd class="description">Punch 4 holes right side</dd>
<dt>IPP_FINISHINGS_CUPS_PUNCH_QUAD_TOP </dt>
<dd class="description">Punch 4 holes top edge</dd>
<dt>IPP_FINISHINGS_CUPS_PUNCH_TOP_LEFT </dt>
<dd class="description">Punch 1 hole top left</dd>
<dt>IPP_FINISHINGS_CUPS_PUNCH_TOP_RIGHT </dt>
<dd class="description">Punch 1 hole top right</dd>
<dt>IPP_FINISHINGS_CUPS_PUNCH_TRIPLE_BOTTOM </dt>
<dd class="description">Punch 3 holes bottom edge</dd>
<dt>IPP_FINISHINGS_CUPS_PUNCH_TRIPLE_LEFT </dt>
<dd class="description">Punch 3 holes left side</dd>
<dt>IPP_FINISHINGS_CUPS_PUNCH_TRIPLE_RIGHT </dt>
<dd class="description">Punch 3 holes right side</dd>
<dt>IPP_FINISHINGS_CUPS_PUNCH_TRIPLE_TOP </dt>
<dd class="description">Punch 3 holes top edge</dd>
<dt>IPP_FINISHINGS_EDGE_STITCH </dt>
<dd class="description">Stitch along any side</dd>
<dt>IPP_FINISHINGS_EDGE_STITCH_BOTTOM </dt>
<dd class="description">Stitch along bottom edge</dd>
<dt>IPP_FINISHINGS_EDGE_STITCH_LEFT </dt>
<dd class="description">Stitch along left side</dd>
<dt>IPP_FINISHINGS_EDGE_STITCH_RIGHT </dt>
<dd class="description">Stitch along right side</dd>
<dt>IPP_FINISHINGS_EDGE_STITCH_TOP </dt>
<dd class="description">Stitch along top edge</dd>
<dt>IPP_FINISHINGS_FOLD </dt>
<dd class="description">Fold (any type)</dd>
<dt>IPP_FINISHINGS_FOLD_ACCORDIAN </dt>
<dd class="description">Accordian-fold the paper vertically into four sections</dd>
<dt>IPP_FINISHINGS_FOLD_DOUBLE_GATE </dt>
<dd class="description">Fold the top and bottom quarters of the paper towards the midline, then fold in half vertically</dd>
<dt>IPP_FINISHINGS_FOLD_GATE </dt>
<dd class="description">Fold the top and bottom quarters of the paper towards the midline</dd>
<dt>IPP_FINISHINGS_FOLD_HALF </dt>
<dd class="description">Fold the paper in half vertically</dd>
<dt>IPP_FINISHINGS_FOLD_HALF_Z </dt>
<dd class="description">Fold the paper in half horizontally, then Z-fold the paper vertically</dd>
<dt>IPP_FINISHINGS_FOLD_LEFT_GATE </dt>
<dd class="description">Fold the top quarter of the paper towards the midline</dd>
<dt>IPP_FINISHINGS_FOLD_LETTER </dt>
<dd class="description">Fold the paper into three sections vertically; sometimes also known as a C fold</dd>
<dt>IPP_FINISHINGS_FOLD_PARALLEL </dt>
<dd class="description">Fold the paper in half vertically two times, yielding four sections</dd>
<dt>IPP_FINISHINGS_FOLD_POSTER </dt>
<dd class="description">Fold the paper in half horizontally and vertically; sometimes also called a cross fold</dd>
<dt>IPP_FINISHINGS_FOLD_RIGHT_GATE </dt>
<dd class="description">Fold the bottom quarter of the paper towards the midline</dd>
<dt>IPP_FINISHINGS_FOLD_Z </dt>
<dd class="description">Fold the paper vertically into three sections, forming a Z</dd>
<dt>IPP_FINISHINGS_JOG_OFFSET </dt>
<dd class="description">Offset for binding (any type)</dd>
<dt>IPP_FINISHINGS_LAMINATE </dt>
<dd class="description">Apply protective (solid) material</dd>
<dt>IPP_FINISHINGS_NONE </dt>
<dd class="description">No finishing</dd>
<dt>IPP_FINISHINGS_PUNCH </dt>
<dd class="description">Punch (any location/count)</dd>
<dt>IPP_FINISHINGS_PUNCH_BOTTOM_LEFT </dt>
<dd class="description">Punch 1 hole bottom left</dd>
<dt>IPP_FINISHINGS_PUNCH_BOTTOM_RIGHT </dt>
<dd class="description">Punch 1 hole bottom right</dd>
<dt>IPP_FINISHINGS_PUNCH_DUAL_BOTTOM </dt>
<dd class="description">Punch 2 holes bottom edge</dd>
<dt>IPP_FINISHINGS_PUNCH_DUAL_LEFT </dt>
<dd class="description">Punch 2 holes left side</dd>
<dt>IPP_FINISHINGS_PUNCH_DUAL_RIGHT </dt>
<dd class="description">Punch 2 holes right side</dd>
<dt>IPP_FINISHINGS_PUNCH_DUAL_TOP </dt>
<dd class="description">Punch 2 holes top edge</dd>
<dt>IPP_FINISHINGS_PUNCH_QUAD_BOTTOM </dt>
<dd class="description">Punch 4 holes bottom edge</dd>
<dt>IPP_FINISHINGS_PUNCH_QUAD_LEFT </dt>
<dd class="description">Punch 4 holes left side</dd>
<dt>IPP_FINISHINGS_PUNCH_QUAD_RIGHT </dt>
<dd class="description">Punch 4 holes right side</dd>
<dt>IPP_FINISHINGS_PUNCH_QUAD_TOP </dt>
<dd class="description">Punch 4 holes top edge</dd>
<dt>IPP_FINISHINGS_PUNCH_TOP_LEFT </dt>
<dd class="description">Punch 1 hole top left</dd>
<dt>IPP_FINISHINGS_PUNCH_TOP_RIGHT </dt>
<dd class="description">Punch 1 hole top right</dd>
<dt>IPP_FINISHINGS_PUNCH_TRIPLE_BOTTOM </dt>
<dd class="description">Punch 3 holes bottom edge</dd>
<dt>IPP_FINISHINGS_PUNCH_TRIPLE_LEFT </dt>
<dd class="description">Punch 3 holes left side</dd>
<dt>IPP_FINISHINGS_PUNCH_TRIPLE_RIGHT </dt>
<dd class="description">Punch 3 holes right side</dd>
<dt>IPP_FINISHINGS_PUNCH_TRIPLE_TOP </dt>
<dd class="description">Punch 3 holes top edge</dd>
<dt>IPP_FINISHINGS_SADDLE_STITCH </dt>
<dd class="description">Staple interior</dd>
<dt>IPP_FINISHINGS_STAPLE </dt>
<dd class="description">Staple (any location)</dd>
<dt>IPP_FINISHINGS_STAPLE_BOTTOM_LEFT </dt>
<dd class="description">Staple bottom left corner</dd>
<dt>IPP_FINISHINGS_STAPLE_BOTTOM_RIGHT </dt>
<dd class="description">Staple bottom right corner</dd>
<dt>IPP_FINISHINGS_STAPLE_DUAL_BOTTOM </dt>
<dd class="description">Two staples on bottom</dd>
<dt>IPP_FINISHINGS_STAPLE_DUAL_LEFT </dt>
<dd class="description">Two staples on left</dd>
<dt>IPP_FINISHINGS_STAPLE_DUAL_RIGHT </dt>
<dd class="description">Two staples on right</dd>
<dt>IPP_FINISHINGS_STAPLE_DUAL_TOP </dt>
<dd class="description">Two staples on top</dd>
<dt>IPP_FINISHINGS_STAPLE_TOP_LEFT </dt>
<dd class="description">Staple top left corner</dd>
<dt>IPP_FINISHINGS_STAPLE_TOP_RIGHT </dt>
<dd class="description">Staple top right corner</dd>
<dt>IPP_FINISHINGS_STAPLE_TRIPLE_BOTTOM </dt>
<dd class="description">Three staples on bottom</dd>
<dt>IPP_FINISHINGS_STAPLE_TRIPLE_LEFT </dt>
<dd class="description">Three staples on left</dd>
<dt>IPP_FINISHINGS_STAPLE_TRIPLE_RIGHT </dt>
<dd class="description">Three staples on right</dd>
<dt>IPP_FINISHINGS_STAPLE_TRIPLE_TOP </dt>
<dd class="description">Three staples on top</dd>
<dt>IPP_FINISHINGS_TRIM </dt>
<dd class="description">Trim (any type)</dd>
<dt>IPP_FINISHINGS_TRIM_AFTER_COPIES </dt>
<dd class="description">Trim output after each copy</dd>
<dt>IPP_FINISHINGS_TRIM_AFTER_DOCUMENTS </dt>
<dd class="description">Trim output after each document</dd>
<dt>IPP_FINISHINGS_TRIM_AFTER_JOB </dt>
<dd class="description">Trim output after job</dd>
<dt>IPP_FINISHINGS_TRIM_AFTER_PAGES </dt>
<dd class="description">Trim output after each page</dd>
</dl>
<h3 class="enumeration"><a name="ipp_jcollate_e">ipp_jcollate_e</a></h3>
<p class="description">Job collation types</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>IPP_JCOLLATE_COLLATED_DOCUMENTS </dt>
<dt>IPP_JCOLLATE_UNCOLLATED_DOCUMENTS </dt>
<dt>IPP_JCOLLATE_UNCOLLATED_SHEETS </dt>
</dl>
<h3 class="enumeration"><a name="ipp_jstate_e">ipp_jstate_e</a></h3>
<p class="description">Job states</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>IPP_JSTATE_ABORTED </dt>
<dd class="description">Job has aborted due to error</dd>
<dt>IPP_JSTATE_CANCELED </dt>
<dd class="description">Job has been canceled</dd>
<dt>IPP_JSTATE_COMPLETED </dt>
<dd class="description">Job has completed successfully</dd>
<dt>IPP_JSTATE_HELD </dt>
<dd class="description">Job is held for printing</dd>
<dt>IPP_JSTATE_PENDING </dt>
<dd class="description">Job is waiting to be printed</dd>
<dt>IPP_JSTATE_PROCESSING </dt>
<dd class="description">Job is currently printing</dd>
<dt>IPP_JSTATE_STOPPED </dt>
<dd class="description">Job has been stopped</dd>
</dl>
<h3 class="enumeration"><a name="ipp_op_e">ipp_op_e</a></h3>
<p class="description">IPP operations</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>IPP_OP_ACKNOWLEDGE_DOCUMENT </dt>
<dd class="description">Acknowledge-Document</dd>
<dt>IPP_OP_ACKNOWLEDGE_IDENTIFY_PRINTER </dt>
<dd class="description">Acknowledge-Identify-Printer</dd>
<dt>IPP_OP_ACKNOWLEDGE_JOB </dt>
<dd class="description">Acknowledge-Job</dd>
<dt>IPP_OP_ACTIVATE_PRINTER </dt>
<dd class="description">Start a printer</dd>
<dt>IPP_OP_CANCEL_CURRENT_JOB </dt>
<dd class="description">Cancel the current job</dd>
<dt>IPP_OP_CANCEL_DOCUMENT </dt>
<dd class="description">Cancel-Document</dd>
<dt>IPP_OP_CANCEL_JOB </dt>
<dd class="description">Cancel a job</dd>
<dt>IPP_OP_CANCEL_JOBS </dt>
<dd class="description">Cancel-Jobs</dd>
<dt>IPP_OP_CANCEL_MY_JOBS </dt>
<dd class="description">Cancel-My-Jobs</dd>
<dt>IPP_OP_CANCEL_SUBSCRIPTION <span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span></dt>
<dd class="description">Cancel a subscription </dd>
<dt>IPP_OP_CLOSE_JOB </dt>
<dd class="description">Close-Job</dd>
<dt>IPP_OP_CREATE_JOB </dt>
<dd class="description">Create an empty print job</dd>
<dt>IPP_OP_CREATE_JOB_SUBSCRIPTIONS <span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span></dt>
<dd class="description">Create one of more job subscriptions </dd>
<dt>IPP_OP_CREATE_PRINTER_SUBSCRIPTIONS <span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span></dt>
<dd class="description">Create one or more printer subscriptions </dd>
<dt>IPP_OP_CUPS_ACCEPT_JOBS </dt>
<dd class="description">Accept new jobs on a printer</dd>
<dt>IPP_OP_CUPS_ADD_MODIFY_CLASS </dt>
<dd class="description">Add or modify a class</dd>
<dt>IPP_OP_CUPS_ADD_MODIFY_PRINTER </dt>
<dd class="description">Add or modify a printer</dd>
<dt>IPP_OP_CUPS_AUTHENTICATE_JOB <span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span></dt>
<dd class="description">Authenticate a job </dd>
<dt>IPP_OP_CUPS_DELETE_CLASS </dt>
<dd class="description">Delete a class</dd>
<dt>IPP_OP_CUPS_DELETE_PRINTER </dt>
<dd class="description">Delete a printer</dd>
<dt>IPP_OP_CUPS_GET_CLASSES <span class="info">&nbsp;DEPRECATED&nbsp;</span></dt>
<dd class="description">Get a list of classes </dd>
<dt>IPP_OP_CUPS_GET_DEFAULT </dt>
<dd class="description">Get the default printer</dd>
<dt>IPP_OP_CUPS_GET_DEVICES </dt>
<dd class="description">Get a list of supported devices</dd>
<dt>IPP_OP_CUPS_GET_DOCUMENT <span class="info">&nbsp;CUPS 1.4/OS X 10.6&nbsp;</span></dt>
<dd class="description">Get a document file </dd>
<dt>IPP_OP_CUPS_GET_PPD <span class="info">&nbsp;CUPS 1.3/OS X 10.5&nbsp;</span></dt>
<dd class="description">Get a PPD file </dd>
<dt>IPP_OP_CUPS_GET_PPDS </dt>
<dd class="description">Get a list of supported drivers</dd>
<dt>IPP_OP_CUPS_GET_PRINTERS </dt>
<dd class="description">Get a list of printers and/or classes</dd>
<dt>IPP_OP_CUPS_INVALID </dt>
<dd class="description">Invalid operation name for <a href="#ippOpValue"><code>ippOpValue</code></a></dd>
<dt>IPP_OP_CUPS_MOVE_JOB </dt>
<dd class="description">Move a job to a different printer</dd>
<dt>IPP_OP_CUPS_REJECT_JOBS </dt>
<dd class="description">Reject new jobs on a printer</dd>
<dt>IPP_OP_CUPS_SET_DEFAULT </dt>
<dd class="description">Set the default printer</dd>
<dt>IPP_OP_DEACTIVATE_PRINTER </dt>
<dd class="description">Stop a printer</dd>
<dt>IPP_OP_DELETE_DOCUMENT </dt>
<dd class="description">Delete-Document</dd>
<dt>IPP_OP_DEREGISTER_OUTPUT_DEVICE </dt>
<dd class="description">Deregister-Output-Device</dd>
<dt>IPP_OP_DISABLE_PRINTER </dt>
<dd class="description">Stop a printer</dd>
<dt>IPP_OP_ENABLE_PRINTER </dt>
<dd class="description">Start a printer</dd>
<dt>IPP_OP_FETCH_DOCUMENT </dt>
<dd class="description">Fetch-Document</dd>
<dt>IPP_OP_FETCH_JOB </dt>
<dd class="description">Fetch-Job</dd>
<dt>IPP_OP_GET_DOCUMENTS </dt>
<dd class="description">Get-Documents</dd>
<dt>IPP_OP_GET_DOCUMENT_ATTRIBUTES </dt>
<dd class="description">Get-Document-Attributes</dd>
<dt>IPP_OP_GET_JOBS </dt>
<dd class="description">Get a list of jobs</dd>
<dt>IPP_OP_GET_JOB_ATTRIBUTES </dt>
<dd class="description">Get job attributes</dd>
<dt>IPP_OP_GET_NEXT_DOCUMENT_DATA </dt>
<dd class="description">Get-Next-Document-Data</dd>
<dt>IPP_OP_GET_NOTIFICATIONS <span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span></dt>
<dd class="description">Get notification events </dd>
<dt>IPP_OP_GET_OUTPUT_DEVICE_ATTRIBUTES </dt>
<dd class="description">Get-Output-Device-Attributes</dd>
<dt>IPP_OP_GET_PRINTER_ATTRIBUTES </dt>
<dd class="description">Get printer attributes</dd>
<dt>IPP_OP_GET_PRINTER_SUPPORTED_VALUES </dt>
<dd class="description">Get supported attribute values</dd>
<dt>IPP_OP_GET_SUBSCRIPTIONS <span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span></dt>
<dd class="description">Get list of subscriptions </dd>
<dt>IPP_OP_GET_SUBSCRIPTION_ATTRIBUTES <span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span></dt>
<dd class="description">Get subscription attributes </dd>
<dt>IPP_OP_HOLD_JOB </dt>
<dd class="description">Hold a job for printing</dd>
<dt>IPP_OP_HOLD_NEW_JOBS </dt>
<dd class="description">Hold new jobs</dd>
<dt>IPP_OP_IDENTIFY_PRINTER </dt>
<dd class="description">Identify-Printer</dd>
<dt>IPP_OP_PAUSE_PRINTER </dt>
<dd class="description">Stop a printer</dd>
<dt>IPP_OP_PAUSE_PRINTER_AFTER_CURRENT_JOB </dt>
<dd class="description">Stop printer after the current job</dd>
<dt>IPP_OP_PRINT_JOB </dt>
<dd class="description">Print a single file</dd>
<dt>IPP_OP_PRINT_URI </dt>
<dd class="description">Print a single URL</dd>
<dt>IPP_OP_PROMOTE_JOB </dt>
<dd class="description">Promote a job to print sooner</dd>
<dt>IPP_OP_PURGE_JOBS </dt>
<dd class="description">Cancel all jobs</dd>
<dt>IPP_OP_RELEASE_HELD_NEW_JOBS </dt>
<dd class="description">Release new jobs</dd>
<dt>IPP_OP_RELEASE_JOB </dt>
<dd class="description">Release a job for printing</dd>
<dt>IPP_OP_RENEW_SUBSCRIPTION <span class="info">&nbsp;CUPS 1.2/OS X 10.5&nbsp;</span></dt>
<dd class="description">Renew a printer subscription </dd>
<dt>IPP_OP_REPROCESS_JOB </dt>
<dd class="description">Reprint a job</dd>
<dt>IPP_OP_RESTART_JOB </dt>
<dd class="description">Reprint a job</dd>
<dt>IPP_OP_RESTART_PRINTER </dt>
<dd class="description">Restart a printer</dd>
<dt>IPP_OP_RESUBMIT_JOB </dt>
<dd class="description">Resubmit-Job</dd>
<dt>IPP_OP_RESUME_JOB </dt>
<dd class="description">Resume the current job</dd>
<dt>IPP_OP_RESUME_PRINTER </dt>
<dd class="description">Start a printer</dd>
<dt>IPP_OP_SCHEDULE_JOB_AFTER </dt>
<dd class="description">Schedule a job to print after another</dd>
<dt>IPP_OP_SEND_DOCUMENT </dt>
<dd class="description">Add a file to a job</dd>
<dt>IPP_OP_SEND_HARDCOPY_DOCUMENT </dt>
<dd class="description">Send-Hardcopy-Document</dd>
<dt>IPP_OP_SEND_URI </dt>
<dd class="description">Add a URL to a job</dd>
<dt>IPP_OP_SET_DOCUMENT_ATTRIBUTES </dt>
<dd class="description">Set-Document-Attributes</dd>
<dt>IPP_OP_SET_JOB_ATTRIBUTES </dt>
<dd class="description">Set job attributes</dd>
<dt>IPP_OP_SET_PRINTER_ATTRIBUTES </dt>
<dd class="description">Set printer attributes</dd>
<dt>IPP_OP_SHUTDOWN_PRINTER </dt>
<dd class="description">Turn a printer off</dd>
<dt>IPP_OP_STARTUP_PRINTER </dt>
<dd class="description">Turn a printer on</dd>
<dt>IPP_OP_SUSPEND_CURRENT_JOB </dt>
<dd class="description">Suspend the current job</dd>
<dt>IPP_OP_UPDATE_ACTIVE_JOBS </dt>
<dd class="description">Update-Active-Jobs</dd>
<dt>IPP_OP_UPDATE_DOCUMENT_STATUS </dt>
<dd class="description">Update-Document-Status</dd>
<dt>IPP_OP_UPDATE_JOB_STATUS </dt>
<dd class="description">Update-Job-Status</dd>
<dt>IPP_OP_UPDATE_OUTPUT_DEVICE_ATTRIBUTES </dt>
<dd class="description">Update-Output-Device-Attributes</dd>
<dt>IPP_OP_VALIDATE_DOCUMENT </dt>
<dd class="description">Validate-Document</dd>
<dt>IPP_OP_VALIDATE_JOB </dt>
<dd class="description">Validate job options</dd>
</dl>
<h3 class="enumeration"><a name="ipp_orient_e">ipp_orient_e</a></h3>
<p class="description">Orientation values</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>IPP_ORIENT_LANDSCAPE </dt>
<dd class="description">90 degrees counter-clockwise</dd>
<dt>IPP_ORIENT_NONE </dt>
<dd class="description">No rotation</dd>
<dt>IPP_ORIENT_PORTRAIT </dt>
<dd class="description">No rotation</dd>
<dt>IPP_ORIENT_REVERSE_LANDSCAPE </dt>
<dd class="description">90 degrees clockwise</dd>
<dt>IPP_ORIENT_REVERSE_PORTRAIT </dt>
<dd class="description">180 degrees</dd>
</dl>
<h3 class="enumeration"><a name="ipp_pstate_e">ipp_pstate_e</a></h3>
<p class="description">Printer states</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>IPP_PSTATE_IDLE </dt>
<dd class="description">Printer is idle</dd>
<dt>IPP_PSTATE_PROCESSING </dt>
<dd class="description">Printer is working</dd>
<dt>IPP_PSTATE_STOPPED </dt>
<dd class="description">Printer is stopped</dd>
</dl>
<h3 class="enumeration"><a name="ipp_quality_e">ipp_quality_e</a></h3>
<p class="description">Qualities</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>IPP_QUALITY_DRAFT </dt>
<dd class="description">Draft quality</dd>
<dt>IPP_QUALITY_HIGH </dt>
<dd class="description">High quality</dd>
<dt>IPP_QUALITY_NORMAL </dt>
<dd class="description">Normal quality</dd>
</dl>
<h3 class="enumeration"><a name="ipp_res_e">ipp_res_e</a></h3>
<p class="description">Resolution units</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>IPP_RES_PER_CM </dt>
<dd class="description">Pixels per centimeter</dd>
<dt>IPP_RES_PER_INCH </dt>
<dd class="description">Pixels per inch</dd>
</dl>
<h3 class="enumeration"><a name="ipp_state_e">ipp_state_e</a></h3>
<p class="description">IPP states</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>IPP_STATE_ATTRIBUTE </dt>
<dd class="description">One or more attributes need to be sent/received</dd>
<dt>IPP_STATE_DATA </dt>
<dd class="description">IPP request data needs to be sent/received</dd>
<dt>IPP_STATE_ERROR </dt>
<dd class="description">An error occurred</dd>
<dt>IPP_STATE_HEADER </dt>
<dd class="description">The request header needs to be sent/received</dd>
<dt>IPP_STATE_IDLE </dt>
<dd class="description">Nothing is happening/request completed</dd>
</dl>
<h3 class="enumeration"><a name="ipp_status_e">ipp_status_e</a></h3>
<p class="description">IPP status codes</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>IPP_STATUS_CUPS_INVALID </dt>
<dd class="description">Invalid status name for <a href="#ippErrorValue"><code>ippErrorValue</code></a></dd>
<dt>IPP_STATUS_CUPS_SEE_OTHER </dt>
<dd class="description">cups-see-other</dd>
<dt>IPP_STATUS_ERROR_ACCOUNT_AUTHORIZATION_FAILED </dt>
<dd class="description">client-error-account-authorization-failed</dd>
<dt>IPP_STATUS_ERROR_ACCOUNT_CLOSED </dt>
<dd class="description">client-error-account-closed</dd>
<dt>IPP_STATUS_ERROR_ACCOUNT_INFO_NEEDED </dt>
<dd class="description">client-error-account-info-needed</dd>
<dt>IPP_STATUS_ERROR_ACCOUNT_LIMIT_REACHED </dt>
<dd class="description">client-error-account-limit-reached</dd>
<dt>IPP_STATUS_ERROR_ATTRIBUTES_NOT_SETTABLE </dt>
<dd class="description">client-error-attributes-not-settable</dd>
<dt>IPP_STATUS_ERROR_ATTRIBUTES_OR_VALUES </dt>
<dd class="description">client-error-attributes-or-values-not-supported</dd>
<dt>IPP_STATUS_ERROR_BAD_REQUEST </dt>
<dd class="description">client-error-bad-request</dd>
<dt>IPP_STATUS_ERROR_BUSY </dt>
<dd class="description">server-error-busy</dd>
<dt>IPP_STATUS_ERROR_CHARSET </dt>
<dd class="description">client-error-charset-not-supported</dd>
<dt>IPP_STATUS_ERROR_COMPRESSION_ERROR </dt>
<dd class="description">client-error-compression-error</dd>
<dt>IPP_STATUS_ERROR_COMPRESSION_NOT_SUPPORTED </dt>
<dd class="description">client-error-compression-not-supported</dd>
<dt>IPP_STATUS_ERROR_CONFLICTING </dt>
<dd class="description">client-error-conflicting-attributes</dd>
<dt>IPP_STATUS_ERROR_CUPS_ACCOUNT_AUTHORIZATION_FAILED <span class="info">&nbsp;DEPRECATED&nbsp;</span></dt>
<dd class="description">cups-error-account-authorization-failed </dd>
<dt>IPP_STATUS_ERROR_CUPS_ACCOUNT_CLOSED </dt>
<dd class="description">cups-error-account-closed @deprecate@</dd>
<dt>IPP_STATUS_ERROR_CUPS_ACCOUNT_INFO_NEEDED <span class="info">&nbsp;DEPRECATED&nbsp;</span></dt>
<dd class="description">cups-error-account-info-needed </dd>
<dt>IPP_STATUS_ERROR_CUPS_ACCOUNT_LIMIT_REACHED <span class="info">&nbsp;DEPRECATED&nbsp;</span></dt>
<dd class="description">cups-error-account-limit-reached </dd>
<dt>IPP_STATUS_ERROR_CUPS_AUTHENTICATION_CANCELED <span class="info">&nbsp;CUPS 1.5/OS X 10.7&nbsp;</span></dt>
<dd class="description">cups-authentication-canceled - Authentication canceled by user </dd>
<dt>IPP_STATUS_ERROR_CUPS_PKI <span class="info">&nbsp;CUPS 1.5/OS X 10.7&nbsp;</span></dt>
<dd class="description">cups-pki-error - Error negotiating a secure connection </dd>
<dt>IPP_STATUS_ERROR_CUPS_UPGRADE_REQUIRED </dt>
<dd class="description">cups-upgrade-required - TLS upgrade required</dd>
<dt>IPP_STATUS_ERROR_DEVICE </dt>
<dd class="description">server-error-device-error</dd>
<dt>IPP_STATUS_ERROR_DOCUMENT_ACCESS </dt>
<dd class="description">client-error-document-access-error</dd>
<dt>IPP_STATUS_ERROR_DOCUMENT_FORMAT_ERROR </dt>
<dd class="description">client-error-document-format-error</dd>
<dt>IPP_STATUS_ERROR_DOCUMENT_FORMAT_NOT_SUPPORTED </dt>
<dd class="description">client-error-document-format-not-supported</dd>
<dt>IPP_STATUS_ERROR_DOCUMENT_PASSWORD </dt>
<dd class="description">client-error-document-password-error</dd>
<dt>IPP_STATUS_ERROR_DOCUMENT_PERMISSION </dt>
<dd class="description">client-error-document-permission-error</dd>
<dt>IPP_STATUS_ERROR_DOCUMENT_SECURITY </dt>
<dd class="description">client-error-document-security-error</dd>
<dt>IPP_STATUS_ERROR_DOCUMENT_UNPRINTABLE </dt>
<dd class="description">client-error-document-unprintable-error</dd>
<dt>IPP_STATUS_ERROR_FORBIDDEN </dt>
<dd class="description">client-error-forbidden</dd>
<dt>IPP_STATUS_ERROR_GONE </dt>
<dd class="description">client-error-gone</dd>
<dt>IPP_STATUS_ERROR_IGNORED_ALL_SUBSCRIPTIONS </dt>
<dd class="description">client-error-ignored-all-subscriptions</dd>
<dt>IPP_STATUS_ERROR_INTERNAL </dt>
<dd class="description">server-error-internal-error</dd>
<dt>IPP_STATUS_ERROR_JOB_CANCELED </dt>
<dd class="description">server-error-job-canceled</dd>
<dt>IPP_STATUS_ERROR_MULTIPLE_JOBS_NOT_SUPPORTED </dt>
<dd class="description">server-error-multiple-document-jobs-not-supported</dd>
<dt>IPP_STATUS_ERROR_NOT_ACCEPTING_JOBS </dt>
<dd class="description">server-error-not-accepting-jobs</dd>
<dt>IPP_STATUS_ERROR_NOT_AUTHENTICATED </dt>
<dd class="description">client-error-not-authenticated</dd>
<dt>IPP_STATUS_ERROR_NOT_AUTHORIZED </dt>
<dd class="description">client-error-not-authorized</dd>
<dt>IPP_STATUS_ERROR_NOT_FETCHABLE </dt>
<dd class="description">client-error-not-fetchable</dd>
<dt>IPP_STATUS_ERROR_NOT_FOUND </dt>
<dd class="description">client-error-not-found</dd>
<dt>IPP_STATUS_ERROR_NOT_POSSIBLE </dt>
<dd class="description">client-error-not-possible</dd>
<dt>IPP_STATUS_ERROR_OPERATION_NOT_SUPPORTED </dt>
<dd class="description">server-error-operation-not-supported</dd>
<dt>IPP_STATUS_ERROR_PRINTER_IS_DEACTIVATED </dt>
<dd class="description">server-error-printer-is-deactivated</dd>
<dt>IPP_STATUS_ERROR_REQUEST_ENTITY </dt>
<dd class="description">client-error-request-entity-too-large</dd>
<dt>IPP_STATUS_ERROR_REQUEST_VALUE </dt>
<dd class="description">client-error-request-value-too-long</dd>
<dt>IPP_STATUS_ERROR_SERVICE_UNAVAILABLE </dt>
<dd class="description">server-error-service-unavailable</dd>
<dt>IPP_STATUS_ERROR_TEMPORARY </dt>
<dd class="description">server-error-temporary-error</dd>
<dt>IPP_STATUS_ERROR_TIMEOUT </dt>
<dd class="description">client-error-timeout</dd>
<dt>IPP_STATUS_ERROR_TOO_MANY_DOCUMENTS </dt>
<dd class="description">server-error-too-many-documents</dd>
<dt>IPP_STATUS_ERROR_TOO_MANY_JOBS </dt>
<dd class="description">server-error-too-many-jobs</dd>
<dt>IPP_STATUS_ERROR_TOO_MANY_SUBSCRIPTIONS </dt>
<dd class="description">client-error-too-many-subscriptions</dd>
<dt>IPP_STATUS_ERROR_URI_SCHEME </dt>
<dd class="description">client-error-uri-scheme-not-supported</dd>
<dt>IPP_STATUS_ERROR_VERSION_NOT_SUPPORTED </dt>
<dd class="description">server-error-version-not-supported</dd>
<dt>IPP_STATUS_OK </dt>
<dd class="description">successful-ok</dd>
<dt>IPP_STATUS_OK_CONFLICTING </dt>
<dd class="description">successful-ok-conflicting-attributes</dd>
<dt>IPP_STATUS_OK_EVENTS_COMPLETE </dt>
<dd class="description">successful-ok-events-complete</dd>
<dt>IPP_STATUS_OK_IGNORED_OR_SUBSTITUTED </dt>
<dd class="description">successful-ok-ignored-or-substituted-attributes</dd>
<dt>IPP_STATUS_OK_IGNORED_SUBSCRIPTIONS </dt>
<dd class="description">successful-ok-ignored-subscriptions</dd>
<dt>IPP_STATUS_OK_TOO_MANY_EVENTS </dt>
<dd class="description">successful-ok-too-many-events</dd>
</dl>
<h3 class="enumeration"><a name="ipp_tag_e">ipp_tag_e</a></h3>
<p class="description">Format tags for attributes</p>
<h4 class="constants">Constants</h4>
<dl>
<dt>IPP_TAG_ADMINDEFINE </dt>
<dd class="description">Admin-defined value</dd>
<dt>IPP_TAG_BEGIN_COLLECTION </dt>
<dd class="description">Beginning of collection value</dd>
<dt>IPP_TAG_BOOLEAN </dt>
<dd class="description">Boolean value</dd>
<dt>IPP_TAG_CHARSET </dt>
<dd class="description">Character set value</dd>
<dt>IPP_TAG_CUPS_INVALID </dt>
<dd class="description">Invalid tag name for <a href="#ippTagValue"><code>ippTagValue</code></a></dd>
<dt>IPP_TAG_DATE </dt>
<dd class="description">Date/time value</dd>
<dt>IPP_TAG_DEFAULT </dt>
<dd class="description">Default value</dd>
<dt>IPP_TAG_DELETEATTR </dt>
<dd class="description">Delete-attribute value</dd>
<dt>IPP_TAG_DOCUMENT </dt>
<dd class="description">Document group</dd>
<dt>IPP_TAG_END </dt>
<dd class="description">End-of-attributes</dd>
<dt>IPP_TAG_END_COLLECTION </dt>
<dd class="description">End of collection value</dd>
<dt>IPP_TAG_ENUM </dt>
<dd class="description">Enumeration value</dd>
<dt>IPP_TAG_EVENT_NOTIFICATION </dt>
<dd class="description">Event group</dd>
<dt>IPP_TAG_EXTENSION </dt>
<dd class="description">Extension point for 32-bit tags</dd>
<dt>IPP_TAG_INTEGER </dt>
<dd class="description">Integer value</dd>
<dt>IPP_TAG_JOB </dt>
<dd class="description">Job group</dd>
<dt>IPP_TAG_KEYWORD </dt>
<dd class="description">Keyword value</dd>
<dt>IPP_TAG_LANGUAGE </dt>
<dd class="description">Language value</dd>
<dt>IPP_TAG_MEMBERNAME </dt>
<dd class="description">Collection member name value</dd>
<dt>IPP_TAG_MIMETYPE </dt>
<dd class="description">MIME media type value</dd>
<dt>IPP_TAG_NAME </dt>
<dd class="description">Name value</dd>
<dt>IPP_TAG_NAMELANG </dt>
<dd class="description">Name-with-language value</dd>
<dt>IPP_TAG_NOTSETTABLE </dt>
<dd class="description">Not-settable value</dd>
<dt>IPP_TAG_NOVALUE </dt>
<dd class="description">No-value value</dd>
<dt>IPP_TAG_OPERATION </dt>
<dd class="description">Operation group</dd>
<dt>IPP_TAG_PRINTER </dt>
<dd class="description">Printer group</dd>
<dt>IPP_TAG_RANGE </dt>
<dd class="description">Range value</dd>
<dt>IPP_TAG_RESOLUTION </dt>
<dd class="description">Resolution value</dd>
<dt>IPP_TAG_STRING </dt>
<dd class="description">Octet string value</dd>
<dt>IPP_TAG_SUBSCRIPTION </dt>
<dd class="description">Subscription group</dd>
<dt>IPP_TAG_TEXT </dt>
<dd class="description">Text value</dd>
<dt>IPP_TAG_TEXTLANG </dt>
<dd class="description">Text-with-language value</dd>
<dt>IPP_TAG_UNKNOWN </dt>
<dd class="description">Unknown value</dd>
<dt>IPP_TAG_UNSUPPORTED_GROUP </dt>
<dd class="description">Unsupported attributes group</dd>
<dt>IPP_TAG_UNSUPPORTED_VALUE </dt>
<dd class="description">Unsupported value</dd>
<dt>IPP_TAG_URI </dt>
<dd class="description">URI value</dd>
<dt>IPP_TAG_URISCHEME </dt>
<dd class="description">URI scheme value</dd>
<dt>IPP_TAG_ZERO </dt>
<dd class="description">Zero tag - used for separators</dd>
</dl>
</div>
</body>
</html>