Changeset 154:eb8dcb4ab78d in lemon-0.x for doc-docbook
- Timestamp:
- 03/04/04 16:13:43 (21 years ago)
- Branch:
- default
- Phase:
- public
- Convert:
- svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@216
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
doc-docbook/src/xml/search_iterator.xml
r153 r154 1 1 <etik:class> 2 2 <etik:name> 3 Osztaly neve 3 BfsIterator4<![CDATA[<]]>typename Graph, typename OutEdgeIt, 4 typename ReachedMap<![CDATA[>]]> 4 5 </etik:name> 5 6 6 7 <etik:description> 8 The class IteratorBfs4 <![CDATA[<]]>typename Graph, typename OutEdgeIt, 9 typename ReachedMap<![CDATA[>]]> implements an edge iterator which iterates on the edges of a directed or undirected graph in a breadth first search order. As a bare iterator, it stores the actual edge, the bfs queue and the map of reached nodes. The usual interpretation of bfs consists of computing auxiliary quantities i.e. distance from root or tree of edges on which the reachable nodes were reached. This iterator approach entrusts such functionalities to the user, they have to be implemented out of the class. 7 10 Ez itt egy tobbsoros, tobb reszes leiras arrol, hogy altalanossagban 8 11 mire is jo ez az osztaly. Ez itt egy tobbsoros, tobb reszes leiras … … 51 54 52 55 <etik:definition> 56 Defined in bfs_iterator.hh. 53 57 Ez a definition szekcio arra van, hogy beleirjuk, hogy milyen fajlban 54 58 van definialva az aktualis osztaly. … … 59 63 <etik:template_param> 60 64 <etik:templ_name> 61 T 65 Graph 62 66 </etik:templ_name> 63 67 <etik:templ_description> 64 Ez itt a T parameter. Ebben adod meg hogy milyen izekbol epitsunk kupacot.68 Graph is a graph type which have to satisfy some concept requirements defined at a later date. 65 69 </etik:templ_description> 66 70 <etik:templ_requirement> 71 Mittomen 67 72 Legyen implementalva neki az osszehasonlito operator. 68 73 </etik:templ_requirement> … … 73 78 <etik:template_param> 74 79 <etik:templ_name> 75 Af 80 OutEdgeIt 76 81 </etik:templ_name> 77 82 <etik:templ_description> 83 OutEdgeIt is an edge iterator type. 84 The bfs iterator iterates on the edges. 78 85 Az Af template parameter is egy olyan vacak, ami a generikussaghoz kell. 79 86 </etik:templ_description> … … 85 92 </etik:templ_default> 86 93 </etik:template_param> 94 <etik:template_param> 95 <etik:templ_name> 96 ReachedMap 97 </etik:templ_name> 98 <etik:templ_description> 99 ReachedMap is a map type which stores a bool for each node, and will ne used to maintain the set of reached nodes. 100 Az Af template parameter is egy olyan vacak, ami a generikussaghoz kell. 101 </etik:templ_description> 102 <etik:templ_requirement> 103 Readable and Writable nodemap. 104 Af szarmazzon az elemi osztalyokbol. 105 </etik:templ_requirement> 106 <etik:templ_default> 107 0 108 </etik:templ_default> 109 </etik:template_param> 87 110 </etik:template_params> 88 111 89 112 90 113 <etik:members> 91 <etik:member> 92 <etik:m_name> 93 iterator 94 </etik:m_name> 95 <etik:m_where_def> 96 container 97 </etik:m_where_def> 98 <etik:m_description> 99 Arra valo, hogy vegigiteraljunk vele. 100 </etik:m_description> 101 102 </etik:member> 103 <etik:member> 104 <etik:m_name> 105 void push_back(const T&) 106 </etik:m_name> 107 <etik:m_where_def> 108 Back Insertion Sequence 109 </etik:m_where_def> 110 <etik:m_description> 111 Egy uj element tesz e vegere. 112 </etik:m_description> 113 114 </etik:member> 114 115 <etik:member> 116 <etik:m_name> 117 BfsIterator4(const Graph& _G, ReachedMap& _reached) 118 </etik:m_name> 119 <etik:m_where_def> 120 121 </etik:m_where_def> 122 <etik:m_description> 123 Creates a bfs iterator with empty queue. The reached nodes will be stores in 124 the map for that _reached refers. Initially, _reached have to be an everywhere 125 false map. Other cases also can be specified, but due to the difficulty, I have no stomach to deal with it. 126 </etik:m_description> 127 128 </etik:member> 129 130 <etik:member> 131 <etik:m_name> 132 BfsIterator4(const Graph& _G) 133 </etik:m_name> 134 <etik:m_where_def> 135 - 136 </etik:m_where_def> 137 <etik:m_description> 138 The same as above, but an own map is constructed to store the reached nodes (and is destroyed at the and). 139 </etik:m_description> 140 141 </etik:member> 142 143 <etik:member> 144 <etik:m_name> 145 void pushAndSetReached(NodeIt s) 146 </etik:m_name> 147 <etik:m_where_def> 148 149 </etik:m_where_def> 150 <etik:m_description> 151 Inserts s in the bfs queue and marks it reached. 152 </etik:m_description> 153 154 </etik:member> 155 156 <etik:member> 157 <etik:m_name> 158 BfsIterator4<![CDATA[<]]>Graph, OutEdgeIt, ReachedMap<![CDATA[>]]>& operator++() 159 </etik:m_name> 160 <etik:m_where_def> 161 container 162 </etik:m_where_def> 163 <etik:m_description> 164 Executes one step on the bfs iterator. 165 </etik:m_description> 166 167 </etik:member> 168 169 <etik:member> 170 <etik:m_name> 171 bool finished() const 172 </etik:m_name> 173 <etik:m_where_def> 174 container 175 </etik:m_where_def> 176 <etik:m_description> 177 Returns true if and only if the iteration is finished. 178 </etik:m_description> 179 180 </etik:member> 181 182 <etik:member> 183 <etik:m_name> 184 operator OutEdgeIt () const 185 </etik:m_name> 186 <etik:m_where_def> 187 container 188 </etik:m_where_def> 189 <etik:m_description> 190 This conversion operator returns the actual value of the bfs iterator. 191 </etik:m_description> 192 193 </etik:member> 194 195 <etik:member> 196 <etik:m_name> 197 bool isBNodeNewlyReached() const 198 </etik:m_name> 199 <etik:m_where_def> 200 container 201 </etik:m_where_def> 202 <etik:m_description> 203 Precondition: OutEdgeIt() returns a valid iterator. 204 Returns true if and only if bNode of OutEdgeIt() is reached at the last 205 iteration step. 206 </etik:m_description> 207 208 </etik:member> 209 210 <etik:member> 211 <etik:m_name> 212 bool isANodeExamined() const 213 </etik:m_name> 214 <etik:m_where_def> 215 container 216 </etik:m_where_def> 217 <etik:m_description> 218 Returns true if and only if the actual node bacomes examined. 219 </etik:m_description> 220 221 </etik:member> 222 223 <etik:member> 224 <etik:m_name> 225 NodeIt aNode() const 226 </etik:m_name> 227 <etik:m_where_def> 228 container 229 </etik:m_where_def> 230 <etik:m_description> 231 Returns the actual node. 232 </etik:m_description> 233 234 </etik:member> 235 236 <etik:member> 237 <etik:m_name> 238 NodeIt bNode() const 239 </etik:m_name> 240 <etik:m_where_def> 241 container 242 </etik:m_where_def> 243 <etik:m_description> 244 Precondition: OutEdgeIt() returns a valid iterator. 245 Returns bNode of the actual edge.. 246 </etik:m_description> 247 248 </etik:member> 249 250 <etik:member> 251 <etik:m_name> 252 const ReachedMap& getReachedMap() const 253 </etik:m_name> 254 <etik:m_where_def> 255 container 256 </etik:m_where_def> 257 <etik:m_description> 258 Const reference to the reached map. 259 </etik:m_description> 260 261 </etik:member> 262 263 <etik:member> 264 <etik:m_name> 265 const std::queue<![CDATA[<]]>NodeIt<![CDATA[>]]>& getBfsQueue() const 266 </etik:m_name> 267 <etik:m_where_def> 268 container 269 </etik:m_where_def> 270 <etik:m_description> 271 Const reference to the bfs queue. 272 </etik:m_description> 273 274 </etik:member> 275 276 115 277 </etik:members> 116 278
Note: See TracChangeset
for help on using the changeset viewer.