summaryrefslogtreecommitdiff
path: root/src/BOP/BOP_BlockIterator.cdl
blob: 0a3b085f665625328c4aac2a704ef868a56d21a0 (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
61
62
63
64
65
66
67
68
69
70
71
-- File:	BOP_BlockIterator.cdl
-- Created:	Thu Feb 25 18:01:55 1993
-- Author:	Jean Yves LEBEY
--		<jyl@phylox>
---Copyright:	 Matra Datavision 1993

class BlockIterator from BOP 

    ---Purpose:  
     
    --  Auxiliary class to provide 
    --  simple iteration on indexes that 
    --  belongs to the integer range  [Lower,Upper]  
    --  with increment =1 

raises

    NoMoreObject from Standard

is

    Create  
    	returns BlockIterator from BOP;
    	---Purpose:  
    	--- Empty  Constructor 
    	---
    Create(Lower,Upper : Integer from Standard) 
    	returns BlockIterator from BOP;
    	---Purpose:  
    	--- Creates an object with initial range 
    	--- of  [Lower,Upper]  	     
    	---
    
    Initialize(me : in out)  
    	is static;
    	---Purpose:  
    	--- Initialize an object with initial range 
    	--- of  [Lower,Upper]  	     
    	---
    More(me)  
    	returns Boolean from Standard  
    	is static;
    	---Purpose:  
    	--- Support of Iteration 
    	---
    Next(me : in out)  
    	raises NoMoreObject  
    	is static;
    	---Purpose:  
    	--- Support of Iteration 
    	---
    Value(me)  
    	returns Integer from Standard  
    	is static;
    	---Purpose:  
    	--- Support of Iteration 
    	---
    Extent(me)  
    	returns Integer from Standard  
    	is static;
    	---Purpose:  
    	--- Returns the extension=myUpper - myLower + 1;   
    	---
    
fields

    myLower : Integer from Standard;
    myUpper : Integer from Standard;
    myValue : Integer from Standard;

end BlockIterator;