Debian Codegraph @

dwsys/Collection_extensions.h

raw
1 #ifndef _Collection_extensions_h_
2 #define _Collection_extensions_h_
3 /* Collection_extensions.h
4 *
5 * Copyright (C) 1994-2019,2022 David Weenink, 2015,2018,2025 Paul Boersma
6 *
7 * This code is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 3 of the License, or (at
10 * your option) any later version.
11 *
12 * This code is distributed in the hope that it will be useful, but
13 * WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this work. If not, see <http://www.gnu.org/licenses/>.
19 */
20
21 #include "Collection.h"
22 #include "Graphics.h"
23 #include "Permutation.h"
24
25 autoCollection Collection_Permutation_permuteItems (Collection me, Permutation him);
26 void Collection_Permutation_permuteItems_inplace (Collection me, Permutation him);
27
28 autoCollection Collection_permuteItems (Collection me);
29 void Collection_permuteItems_inplace (Collection me);
30
31 /* permute the order of my items */
32
33 int OrderedOfString_append (StringList me, conststring32 append);
34
35 autoStringList OrderedOfString_joinItems (StringList me, StringList thee);
36 /* Join each item */
37
38 autoStringSet StringList_to_StringSet (StringList me);
39
40 double OrderedOfString_getFractionDifferent (StringList me, StringList thee);
41
42 integer OrderedOfString_getNumberOfDifferences (StringList me, StringList thee);
43
44 integer OrderedOfString_indexOfItem (StringList me, conststring32 str);
45
46 void OrderedOfString_initWithSequentialNumbers (StringList me, integer n);
47
48 void OrderedOfString_removeOccurrences (StringList me, conststring32 search, bool use_regexp);
49
50 void OrderedOfString_changeStrings (StringList me, char32 *search, char32 *replace,
51 integer maximumNumberOfReplaces, integer *out_numberOfMatches, integer *out_numberOfStringmatches, bool use_regexp);
52
53 bool OrderedOfString_containSameElements (StringList me, StringList thee);
54 /*
55 Check whether my items are all in thy items.
56
57 Postconditions:
58 if (index.size == my size) the returned index table has the following property:
59 if (index [i] > 0)
60 my label [i] = thy label [index [i]];
61 else if (index [i] == 0) my label [i] not in thy labels.
62 */
63
64 #endif /* _Collection_extensions_h_ */