• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1      * Summary: lists interfaces
2      * Description: this module implement the list support used in
3      * various place in the library.
4      *
5      * Copy: See Copyright for the status of this software.
6      *
7      * Author: Patrick Monnerat <pm@datasphere.ch>, DATASPHERE S.A.
8
9      /if not defined(XML_LINK_INCLUDE__)
10      /define XML_LINK_INCLUDE__
11
12      /include "libxmlrpg/xmlversion"
13      /include "libxmlrpg/xmlTypesC"
14
15     d xmlLinkPtr      s               *   based(######typedef######)
16
17     d xmlListPtr      s               *   based(######typedef######)
18
19      * xmlListDeallocator:
20      * @lk:  the data to deallocate
21      *
22      * Callback function used to free data from a list.
23
24     d xmlListDeallocator...
25     d                 s               *   based(######typedef######)
26     d                                     procptr
27
28      * xmlListDataCompare:
29      * @data0: the first data
30      * @data1: the second data
31      *
32      * Callback function used to compare 2 data.
33      *
34      * Returns 0 is equality, -1 or 1 otherwise depending on the ordering.
35
36     d xmlListDataCompare...
37     d                 s               *   based(######typedef######)
38     d                                     procptr
39
40      * xmlListWalker:
41      * @data: the data found in the list
42      * @user: extra user provided data to the walker
43      *
44      * Callback function used when walking a list with xmlListWalk().
45      *
46      * Returns 0 to stop walking the list, 1 otherwise.
47
48     d xmlListWalker   s               *   based(######typedef######)
49     d                                     procptr
50
51      * Creation/Deletion
52
53     d xmlListCreate   pr                  extproc('xmlListCreate')
54     d                                     like(xmlListPtr)
55     d  deallocator                        value like(xmlListDeallocator)
56     d  compare                            value like(xmlListDataCompare)
57
58     d xmlListDelete   pr                  extproc('xmlListDelete')
59     d  l                                  value like(xmlListPtr)
60
61      * Basic Operators
62
63     d xmlListSearch   pr              *   extproc('xmlListSearch')             void *
64     d  l                                  value like(xmlListPtr)
65     d  data                           *   value                                void *
66
67     d xmlListReverseSearch...
68     d                 pr              *   extproc('xmlListReverseSearch')      void *
69     d  l                                  value like(xmlListPtr)
70     d  data                           *   value                                void *
71
72     d xmlListInsert   pr                  extproc('xmlListInsert')
73     d                                     like(xmlCint)
74     d  l                                  value like(xmlListPtr)
75     d  data                           *   value                                void *
76
77     d xmlListAppend   pr                  extproc('xmlListAppend')
78     d                                     like(xmlCint)
79     d  l                                  value like(xmlListPtr)
80     d  data                           *   value                                void *
81
82     d xmlListRemoveFirst...
83     d                 pr                  extproc('xmlListRemoveFirst')
84     d                                     like(xmlCint)
85     d  l                                  value like(xmlListPtr)
86     d  data                           *   value                                void *
87
88     d xmlListRemoveLast...
89     d                 pr                  extproc('xmlListRemoveLast')
90     d                                     like(xmlCint)
91     d  l                                  value like(xmlListPtr)
92     d  data                           *   value                                void *
93
94     d xmlListRemoveAll...
95     d                 pr                  extproc('xmlListRemoveAll')
96     d                                     like(xmlCint)
97     d  l                                  value like(xmlListPtr)
98     d  data                           *   value                                void *
99
100     d xmlListClear    pr                  extproc('xmlListClear')
101     d  l                                  value like(xmlListPtr)
102
103     d xmlListEmpty    pr                  extproc('xmlListEmpty')
104     d                                     like(xmlCint)
105     d  l                                  value like(xmlListPtr)
106
107     d xmlListFront    pr                  extproc('xmlListFront')
108     d                                     like(xmlLinkPtr)
109     d  l                                  value like(xmlListPtr)
110
111     d xmlListEnd      pr                  extproc('xmlListEnd')
112     d                                     like(xmlLinkPtr)
113     d  l                                  value like(xmlListPtr)
114
115     d xmlListSize     pr                  extproc('xmlListSize')
116     d                                     like(xmlCint)
117     d  l                                  value like(xmlListPtr)
118
119     d xmlListPopFront...
120     d                 pr                  extproc('xmlListPopFront')
121     d  l                                  value like(xmlListPtr)
122
123     d xmlListPopBack...
124     d                 pr                  extproc('xmlListPopBack')
125     d  l                                  value like(xmlListPtr)
126
127     d xmlListPushFront...
128     d                 pr                  extproc('xmlListPushFront')
129     d                                     like(xmlCint)
130     d  l                                  value like(xmlListPtr)
131     d  data                           *   value                                void *
132
133     d xmlListPushBack...
134     d                 pr                  extproc('xmlListPushBack')
135     d                                     like(xmlCint)
136     d  l                                  value like(xmlListPtr)
137     d  data                           *   value                                void *
138
139      * Advanced Operators
140
141     d xmlListReverse  pr                  extproc('xmlListReverse')
142     d  l                                  value like(xmlListPtr)
143
144     d xmlListSort     pr                  extproc('xmlListSort')
145     d  l                                  value like(xmlListPtr)
146
147     d xmlListWalk     pr                  extproc('xmlListWalk')
148     d  l                                  value like(xmlListPtr)
149     d  walker                             value like(xmlListWalker)
150     d  user                           *   value                                const void *
151
152     d xmlListReverseWalk...
153     d                 pr                  extproc('xmlListReverseWalk')
154     d  l                                  value like(xmlListPtr)
155     d  walker                             value like(xmlListWalker)
156     d  user                           *   value                                const void *
157
158     d xmlListMerge    pr                  extproc('xmlListMerge')
159     d  l1                                 value like(xmlListPtr)
160     d  l2                                 value like(xmlListPtr)
161
162     d xmlListDup      pr                  extproc('xmlListDup')
163     d                                     like(xmlListPtr)
164     d  old                                value like(xmlListPtr)
165
166     d xmlListCopy     pr                  extproc('xmlListCopy')
167     d                                     like(xmlCint)
168     d  cur                                value like(xmlListPtr)
169     d  old                                value like(xmlListPtr)               const
170
171      * Link operators
172
173     d xmlListGetData  pr              *   extproc('xmlListGetData')            void *
174     d  lk                                 value like(xmlLinkPtr)
175
176      * xmlListUnique()
177      * xmlListSwap
178
179      /endif                                                                    XML_LINK_INCLUDE__
180