Commit | Line | Data |
---|---|---|
b311480e | 1 | -- Created on: 2007-05-29 |
2 | -- Created by: Vlad Romashko | |
973c2be1 | 3 | -- Copyright (c) 2007-2014 OPEN CASCADE SAS |
b311480e | 4 | -- |
973c2be1 | 5 | -- This file is part of Open CASCADE Technology software library. |
b311480e | 6 | -- |
d5f74e42 | 7 | -- This library is free software; you can redistribute it and/or modify it under |
8 | -- the terms of the GNU Lesser General Public License version 2.1 as published | |
973c2be1 | 9 | -- by the Free Software Foundation, with special exception defined in the file |
10 | -- OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT | |
11 | -- distribution for complete text of the license and disclaimer of any warranty. | |
b311480e | 12 | -- |
973c2be1 | 13 | -- Alternatively, this file may be used under the terms of Open CASCADE |
14 | -- commercial license or contractual agreement. | |
7fd59977 | 15 | |
16 | class ReferenceArray from TDataStd inherits Attribute from TDF | |
17 | ||
18 | ---Purpose: Contains an array of references to the labels. | |
19 | ||
20 | uses | |
21 | ||
22 | Attribute from TDF, | |
23 | GUID from Standard, | |
24 | Label from TDF, | |
25 | DataSet from TDF, | |
26 | RelocationTable from TDF, | |
27 | HLabelArray1 from TDataStd | |
28 | ||
29 | is | |
30 | ||
31 | ---Purpose: Static methods | |
32 | -- ============== | |
33 | ||
34 | GetID (myclass) | |
35 | ---C++: return const & | |
36 | ---Purpose: Returns the ID of the array of references (labels) attribute. | |
37 | returns GUID from Standard; | |
38 | ||
39 | Set (myclass; | |
40 | label : Label from TDF; | |
41 | lower, upper : Integer from Standard) | |
42 | ---Purpose: Finds or creates an array of reference values (labels) attribute. | |
43 | returns ReferenceArray from TDataStd; | |
44 | ||
45 | ||
46 | ---Category: ReferenceArray methods | |
47 | -- ====================== | |
48 | ||
49 | Init (me : mutable; | |
50 | lower, upper : Integer from Standard); | |
51 | ---Purpose: Initialize the inner array with bounds from <lower> to <upper> | |
52 | ||
53 | SetValue (me : mutable; | |
54 | index :Integer from Standard; | |
55 | value : Label from TDF); | |
56 | ---Purpose: Sets the <Index>th element of the array to <Value> | |
fa13a85d | 57 | -- OutOfRange exception is raised if <Index> doesn't respect Lower and Upper bounds of the internal array. |
7fd59977 | 58 | |
59 | Value (me; | |
60 | Index : Integer from Standard) | |
61 | ---Purpose: Returns the value of the <Index>th element of the array. | |
62 | ---C++: alias operator () | |
63 | returns Label from TDF; | |
64 | ||
65 | Lower (me) | |
66 | ---Purpose: Returns the lower boundary of the array. | |
67 | returns Integer from Standard; | |
68 | ||
69 | Upper (me) | |
70 | ---Purpose: Returns the upper boundary of the array. | |
71 | returns Integer from Standard; | |
72 | ||
73 | Length (me) | |
74 | ---Purpose: Returns the number of elements in the array. | |
75 | returns Integer from Standard; | |
76 | ||
77 | ||
78 | ---Category: Advanced area | |
79 | -- ============= | |
80 | ||
81 | InternalArray (me) | |
82 | ---C++: return const & | |
83 | returns HLabelArray1 from TDataStd; | |
84 | ||
85 | SetInternalArray (me : mutable; | |
a855b7eb S |
86 | values : HLabelArray1 from TDataStd; |
87 | isCheckItems : Boolean = Standard_True); | |
7fd59977 | 88 | |
89 | ||
90 | ---Category: Methodes of TDF_Attribute | |
91 | -- ========================= | |
92 | ||
93 | Create | |
6e33d3ce | 94 | returns ReferenceArray from TDataStd; |
7fd59977 | 95 | |
96 | ID (me) | |
97 | ---C++: return const & | |
98 | returns GUID from Standard; | |
99 | ||
100 | Restore (me: mutable; With : Attribute from TDF); | |
101 | ||
102 | NewEmpty (me) | |
6e33d3ce | 103 | returns Attribute from TDF; |
7fd59977 | 104 | |
6e33d3ce | 105 | Paste (me; Into : Attribute from TDF; |
106 | RT : RelocationTable from TDF); | |
7fd59977 | 107 | |
108 | References (me; DS : DataSet from TDF) | |
109 | is redefined; | |
110 | ||
111 | Dump(me; anOS : in out OStream from Standard) | |
112 | returns OStream from Standard | |
113 | is redefined; | |
114 | ---C++: return & | |
115 | ||
116 | ||
117 | fields | |
118 | ||
119 | myArray : HLabelArray1 from TDataStd; | |
120 | ||
121 | ||
122 | end ReferenceArray; |