blob: 369d6bf19830a193c2ed9d10b3a3e7b8b82a332a (
plain)
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
|
-- File: GraphTools_VertexIterator.cdl
-- Created: Wed Mar 6 18:20:11 1991
-- Author: Denis Pascal
-- <dp@topsn3>
---Copyright: Matra Datavision 1991, 1992
generic class VertexIterator from GraphTools (Graph as any;
Vertex as any)
--template class VertexIterator from GraphTools (Graph as any,
-- Vertex as any)
---Purpose: Template class which defines Signature of an iterator
-- to visit each adjacent vertex of a given one in the
-- underlying graph.
raises NoMoreObject from Standard,
NoSuchObject from Standard
is
Create (G : Graph; V : Vertex) returns VertexIterator;
More (me) returns Boolean;
---Purpose: Returns TRUE if there are other vertices.
---Level: Public
Next(me : in out)
--- Purpose : Set the iterator to the next Vertex.
---Level: Public
raises NoMoreObject from Standard;
Value(me) returns Vertex
--- Purpose: Returns the vertex value for the current position
-- of the iterator.
---Level: Public
raises NoSuchObject from Standard;
end VertexIterator;
|