This repository was archived by the owner on Dec 5, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathalgorithm_8h.html
131 lines (128 loc) · 11.1 KB
/
algorithm_8h.html
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
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.9.1"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>swift: src/blackmisc/algorithm.h File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="doxygen-awesome.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<td id="projectalign" style="padding-left: 0.5em;">
<div id="projectname">swift
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.1 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search','.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
$(function() {
initMenu('',true,false,'search.php','Search');
$(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0"
name="MSearchResults" id="MSearchResults">
</iframe>
</div>
<div id="nav-path" class="navpath">
<ul>
<li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="dir_9687d2aaac47be79d7525830e55feee8.html">blackmisc</a></li> </ul>
</div>
</div><!-- top -->
<div class="header">
<div class="summary">
<a href="#namespaces">Namespaces</a> |
<a href="#func-members">Functions</a> </div>
<div class="headertitle">
<div class="title">algorithm.h File Reference</div> </div>
</div><!--header-->
<div class="contents">
<p><a href="algorithm_8h_source.html">Go to the source code of this file.</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="namespaces"></a>
Namespaces</h2></td></tr>
<tr class="memitem:namespace_black_misc"><td class="memItemLeft" align="right" valign="top">  </td><td class="memItemRight" valign="bottom"><a class="el" href="namespace_black_misc.html">BlackMisc</a></td></tr>
<tr class="memdesc:namespace_black_misc"><td class="mdescLeft"> </td><td class="mdescRight">Base and utility classes available in all other projects. <br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:aa918138f03d3ca52f9ff8008ead74b72"><td class="memTemplParams" colspan="2">template<typename I , typename J > </td></tr>
<tr class="memitem:aa918138f03d3ca52f9ff8008ead74b72"><td class="memTemplItemLeft" align="right" valign="top">auto </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="namespace_black_misc.html#aa918138f03d3ca52f9ff8008ead74b72">BlackMisc::removeIfIn</a> (I begin1, I end1, J begin2, J end2)</td></tr>
<tr class="memdesc:aa918138f03d3ca52f9ff8008ead74b72"><td class="mdescLeft"> </td><td class="mdescRight">Removes those elements in range 1 that appear also in range 2 leaving only those that do not appear in range 2. <a href="namespace_black_misc.html#aa918138f03d3ca52f9ff8008ead74b72">More...</a><br /></td></tr>
<tr class="separator:aa918138f03d3ca52f9ff8008ead74b72"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a3ec2397131a0f780a4d7cf18dda9cbd1"><td class="memTemplParams" colspan="2"><a id="a3ec2397131a0f780a4d7cf18dda9cbd1"></a>
template<typename ForwardIt , typename OutputIt , typename Generator > </td></tr>
<tr class="memitem:a3ec2397131a0f780a4d7cf18dda9cbd1"><td class="memTemplItemLeft" align="right" valign="top">void </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="namespace_black_misc.html#a3ec2397131a0f780a4d7cf18dda9cbd1">BlackMisc::copyRandomElements</a> (ForwardIt in, ForwardIt end, OutputIt out, int n, Generator &&rng)</td></tr>
<tr class="memdesc:a3ec2397131a0f780a4d7cf18dda9cbd1"><td class="mdescLeft"> </td><td class="mdescRight">Use the random number generator rng to choose n elements from the range [in,end) and copy them to out. <br /></td></tr>
<tr class="separator:a3ec2397131a0f780a4d7cf18dda9cbd1"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a2d591d748d4ba98a4626747234d18772"><td class="memTemplParams" colspan="2"><a id="a2d591d748d4ba98a4626747234d18772"></a>
template<typename ForwardIt , typename OutputIt > </td></tr>
<tr class="memitem:a2d591d748d4ba98a4626747234d18772"><td class="memTemplItemLeft" align="right" valign="top">void </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="namespace_black_misc.html#a2d591d748d4ba98a4626747234d18772">BlackMisc::copyRandomElements</a> (ForwardIt in, ForwardIt end, OutputIt out, int n)</td></tr>
<tr class="memdesc:a2d591d748d4ba98a4626747234d18772"><td class="mdescLeft"> </td><td class="mdescRight">Randomly choose n elements from the range [in,end) and copy them to out. <br /></td></tr>
<tr class="separator:a2d591d748d4ba98a4626747234d18772"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:af210f9e81bfdb9abf5ed177df2dd862a"><td class="memTemplParams" colspan="2"><a id="af210f9e81bfdb9abf5ed177df2dd862a"></a>
template<typename ForwardIt , typename OutputIt , typename Generator > </td></tr>
<tr class="memitem:af210f9e81bfdb9abf5ed177df2dd862a"><td class="memTemplItemLeft" align="right" valign="top">void </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="namespace_black_misc.html#af210f9e81bfdb9abf5ed177df2dd862a">BlackMisc::copySampleElements</a> (ForwardIt in, ForwardIt end, OutputIt out, int n, Generator &&rng)</td></tr>
<tr class="memdesc:af210f9e81bfdb9abf5ed177df2dd862a"><td class="mdescLeft"> </td><td class="mdescRight">Split the range [in,end) into n equal chunks and use the random number generator rng to choose one element from each. <br /></td></tr>
<tr class="separator:af210f9e81bfdb9abf5ed177df2dd862a"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ac2881ec2da4e12a6a2e6099595ae1bcb"><td class="memTemplParams" colspan="2"><a id="ac2881ec2da4e12a6a2e6099595ae1bcb"></a>
template<typename ForwardIt , typename OutputIt > </td></tr>
<tr class="memitem:ac2881ec2da4e12a6a2e6099595ae1bcb"><td class="memTemplItemLeft" align="right" valign="top">void </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="namespace_black_misc.html#ac2881ec2da4e12a6a2e6099595ae1bcb">BlackMisc::copySampleElements</a> (ForwardIt in, ForwardIt end, OutputIt out, int n)</td></tr>
<tr class="memdesc:ac2881ec2da4e12a6a2e6099595ae1bcb"><td class="mdescLeft"> </td><td class="mdescRight">Split the range [in,end) into n equal chunks and randomly choose one element from each. <br /></td></tr>
<tr class="separator:ac2881ec2da4e12a6a2e6099595ae1bcb"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a2f8ed585265f07cc9c5b1934ac93783e"><td class="memTemplParams" colspan="2">template<typename I , typename F > </td></tr>
<tr class="memitem:a2f8ed585265f07cc9c5b1934ac93783e"><td class="memTemplItemLeft" align="right" valign="top">void </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="namespace_black_misc.html#a2f8ed585265f07cc9c5b1934ac93783e">BlackMisc::topologicalSort</a> (I begin, I end, F comparator)</td></tr>
<tr class="memdesc:a2f8ed585265f07cc9c5b1934ac93783e"><td class="mdescLeft"> </td><td class="mdescRight">Topological sorting algorithm. <a href="namespace_black_misc.html#a2f8ed585265f07cc9c5b1934ac93783e">More...</a><br /></td></tr>
<tr class="separator:a2f8ed585265f07cc9c5b1934ac93783e"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a36fc0d2dafb0d7b8c26ece95bd731ffe"><td class="memTemplParams" colspan="2">template<typename C , typename T , typename F > </td></tr>
<tr class="memitem:a36fc0d2dafb0d7b8c26ece95bd731ffe"><td class="memTemplItemLeft" align="right" valign="top">void </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="namespace_black_misc.html#a36fc0d2dafb0d7b8c26ece95bd731ffe">BlackMisc::topologicallySortedInsert</a> (C &container, T &&value, F comparator)</td></tr>
<tr class="memdesc:a36fc0d2dafb0d7b8c26ece95bd731ffe"><td class="mdescLeft"> </td><td class="mdescRight">Insert an element into a sequential container while preserving the topological ordering of the container. <a href="namespace_black_misc.html#a36fc0d2dafb0d7b8c26ece95bd731ffe">More...</a><br /></td></tr>
<tr class="separator:a36fc0d2dafb0d7b8c26ece95bd731ffe"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:adbb6a47a2ad158aa7b88e1f498c45dc3"><td class="memTemplParams" colspan="2"><a id="adbb6a47a2ad158aa7b88e1f498c45dc3"></a>
template<typename T , typename F > </td></tr>
<tr class="memitem:adbb6a47a2ad158aa7b88e1f498c45dc3"><td class="memTemplItemLeft" align="right" valign="top">void </td><td class="memTemplItemRight" valign="bottom"><a class="el" href="namespace_black_misc.html#adbb6a47a2ad158aa7b88e1f498c45dc3">BlackMisc::tupleForEachPair</a> (T &&tuple, F &&visitor)</td></tr>
<tr class="memdesc:adbb6a47a2ad158aa7b88e1f498c45dc3"><td class="mdescLeft"> </td><td class="mdescRight">Invoke a visitor function on each pair of elements of a tuple in order. <br /></td></tr>
<tr class="separator:adbb6a47a2ad158aa7b88e1f498c45dc3"><td class="memSeparator" colspan="2"> </td></tr>
</table>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Sun Dec 3 2023 18:38:42 for swift by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.1
</small></address>
</body>
</html>