]> git.ipfire.org Git - thirdparty/cups.git/blame - cups/array.h
Remove all of the Subversion keywords from various source files.
[thirdparty/cups.git] / cups / array.h
CommitLineData
ef416fc2 1/*
503b54c9 2 * Sorted array definitions for CUPS.
ef416fc2 3 *
503b54c9
MS
4 * Copyright 2007-2010 by Apple Inc.
5 * Copyright 1997-2007 by Easy Software Products.
ef416fc2 6 *
503b54c9
MS
7 * These coded instructions, statements, and computer programs are the
8 * property of Apple Inc. and are protected by Federal copyright
9 * law. Distribution and use rights are outlined in the file "LICENSE.txt"
10 * which should have been included with this file. If this file is
11 * file is missing or damaged, see the license at "http://www.cups.org/".
ef416fc2 12 *
503b54c9 13 * This file is subject to the Apple OS-Developed Software exception.
ef416fc2 14 */
15
16#ifndef _CUPS_ARRAY_H_
17# define _CUPS_ARRAY_H_
18
19/*
20 * Include necessary headers...
21 */
22
2fb76298 23# include "versioning.h"
ef416fc2 24# include <stdlib.h>
25
26
27/*
28 * C++ magic...
29 */
30
31# ifdef __cplusplus
32extern "C" {
33# endif /* __cplusplus */
34
35
36/*
37 * Types and structures...
38 */
39
40typedef struct _cups_array_s cups_array_t;
41 /**** CUPS array type ****/
42typedef int (*cups_array_func_t)(void *first, void *second, void *data);
43 /**** Array comparison function ****/
b94498cf 44typedef int (*cups_ahash_func_t)(void *element, void *data);
45 /**** Array hash function ****/
10d09e33
MS
46typedef void *(*cups_acopy_func_t)(void *element, void *data);
47 /**** Array element copy function ****/
48typedef void (*cups_afree_func_t)(void *element, void *data);
49 /**** Array element free function ****/
b94498cf 50
ef416fc2 51
52/*
53 * Functions...
54 */
55
2fb76298
MS
56extern int cupsArrayAdd(cups_array_t *a, void *e) _CUPS_API_1_2;
57extern void cupsArrayClear(cups_array_t *a) _CUPS_API_1_2;
58extern int cupsArrayCount(cups_array_t *a) _CUPS_API_1_2;
59extern void *cupsArrayCurrent(cups_array_t *a) _CUPS_API_1_2;
60extern void cupsArrayDelete(cups_array_t *a) _CUPS_API_1_2;
61extern cups_array_t *cupsArrayDup(cups_array_t *a) _CUPS_API_1_2;
62extern void *cupsArrayFind(cups_array_t *a, void *e) _CUPS_API_1_2;
63extern void *cupsArrayFirst(cups_array_t *a) _CUPS_API_1_2;
64extern int cupsArrayGetIndex(cups_array_t *a) _CUPS_API_1_3;
65extern int cupsArrayGetInsert(cups_array_t *a) _CUPS_API_1_3;
66extern void *cupsArrayIndex(cups_array_t *a, int n) _CUPS_API_1_2;
67extern int cupsArrayInsert(cups_array_t *a, void *e) _CUPS_API_1_2;
68extern void *cupsArrayLast(cups_array_t *a) _CUPS_API_1_2;
69extern cups_array_t *cupsArrayNew(cups_array_func_t f, void *d) _CUPS_API_1_2;
b94498cf 70extern cups_array_t *cupsArrayNew2(cups_array_func_t f, void *d,
2fb76298 71 cups_ahash_func_t h, int hsize) _CUPS_API_1_3;
10d09e33
MS
72extern cups_array_t *cupsArrayNew3(cups_array_func_t f, void *d,
73 cups_ahash_func_t h, int hsize,
74 cups_acopy_func_t cf,
75 cups_afree_func_t ff) _CUPS_API_1_5;
2fb76298
MS
76extern void *cupsArrayNext(cups_array_t *a) _CUPS_API_1_2;
77extern void *cupsArrayPrev(cups_array_t *a) _CUPS_API_1_2;
78extern int cupsArrayRemove(cups_array_t *a, void *e) _CUPS_API_1_2;
79extern void *cupsArrayRestore(cups_array_t *a) _CUPS_API_1_2;
80extern int cupsArraySave(cups_array_t *a) _CUPS_API_1_2;
81extern void *cupsArrayUserData(cups_array_t *a) _CUPS_API_1_2;
ef416fc2 82
83# ifdef __cplusplus
84}
85# endif /* __cplusplus */
86#endif /* !_CUPS_ARRAY_H_ */