1------------------------------------------------------------------------------ 2-- -- 3-- Matreshka Project -- 4-- -- 5-- Ada Modeling Framework -- 6-- -- 7-- Runtime Library Component -- 8-- -- 9------------------------------------------------------------------------------ 10-- -- 11-- Copyright © 2011-2012, Vadim Godunko <vgodunko@gmail.com> -- 12-- All rights reserved. -- 13-- -- 14-- Redistribution and use in source and binary forms, with or without -- 15-- modification, are permitted provided that the following conditions -- 16-- are met: -- 17-- -- 18-- * Redistributions of source code must retain the above copyright -- 19-- notice, this list of conditions and the following disclaimer. -- 20-- -- 21-- * Redistributions in binary form must reproduce the above copyright -- 22-- notice, this list of conditions and the following disclaimer in the -- 23-- documentation and/or other materials provided with the distribution. -- 24-- -- 25-- * Neither the name of the Vadim Godunko, IE nor the names of its -- 26-- contributors may be used to endorse or promote products derived from -- 27-- this software without specific prior written permission. -- 28-- -- 29-- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- 30-- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- 31-- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- 32-- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- 33-- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- 34-- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -- 35-- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -- 36-- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -- 37-- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -- 38-- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -- 39-- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- 40-- -- 41------------------------------------------------------------------------------ 42-- $Revision: 2937 $ $Date: 2012-05-01 21:07:27 +0400 (Tue, 01 May 2012) $ 43------------------------------------------------------------------------------ 44with AMF.Internals.UML_Named_Elements; 45with AMF.String_Collections; 46with AMF.UML.Constraints.Collections; 47with AMF.UML.Dependencies.Collections; 48with AMF.UML.Element_Imports.Collections; 49with AMF.UML.General_Orderings.Collections; 50with AMF.UML.Interaction_Constraints; 51with AMF.UML.Interaction_Fragments.Collections; 52with AMF.UML.Interaction_Operands; 53with AMF.UML.Interactions; 54with AMF.UML.Lifelines.Collections; 55with AMF.UML.Named_Elements.Collections; 56with AMF.UML.Namespaces; 57with AMF.UML.Package_Imports.Collections; 58with AMF.UML.Packageable_Elements.Collections; 59with AMF.UML.Packages.Collections; 60with AMF.UML.String_Expressions; 61with AMF.Visitors; 62 63package AMF.Internals.UML_Interaction_Operands is 64 65 type UML_Interaction_Operand_Proxy is 66 limited new AMF.Internals.UML_Named_Elements.UML_Named_Element_Proxy 67 and AMF.UML.Interaction_Operands.UML_Interaction_Operand with null record; 68 69 overriding function Get_Fragment 70 (Self : not null access constant UML_Interaction_Operand_Proxy) 71 return AMF.UML.Interaction_Fragments.Collections.Ordered_Set_Of_UML_Interaction_Fragment; 72 -- Getter of InteractionOperand::fragment. 73 -- 74 -- The fragments of the operand. 75 76 overriding function Get_Guard 77 (Self : not null access constant UML_Interaction_Operand_Proxy) 78 return AMF.UML.Interaction_Constraints.UML_Interaction_Constraint_Access; 79 -- Getter of InteractionOperand::guard. 80 -- 81 -- Constraint of the operand. 82 83 overriding procedure Set_Guard 84 (Self : not null access UML_Interaction_Operand_Proxy; 85 To : AMF.UML.Interaction_Constraints.UML_Interaction_Constraint_Access); 86 -- Setter of InteractionOperand::guard. 87 -- 88 -- Constraint of the operand. 89 90 overriding function Get_Covered 91 (Self : not null access constant UML_Interaction_Operand_Proxy) 92 return AMF.UML.Lifelines.Collections.Set_Of_UML_Lifeline; 93 -- Getter of InteractionFragment::covered. 94 -- 95 -- References the Lifelines that the InteractionFragment involves. 96 97 overriding function Get_Enclosing_Interaction 98 (Self : not null access constant UML_Interaction_Operand_Proxy) 99 return AMF.UML.Interactions.UML_Interaction_Access; 100 -- Getter of InteractionFragment::enclosingInteraction. 101 -- 102 -- The Interaction enclosing this InteractionFragment. 103 104 overriding procedure Set_Enclosing_Interaction 105 (Self : not null access UML_Interaction_Operand_Proxy; 106 To : AMF.UML.Interactions.UML_Interaction_Access); 107 -- Setter of InteractionFragment::enclosingInteraction. 108 -- 109 -- The Interaction enclosing this InteractionFragment. 110 111 overriding function Get_Enclosing_Operand 112 (Self : not null access constant UML_Interaction_Operand_Proxy) 113 return AMF.UML.Interaction_Operands.UML_Interaction_Operand_Access; 114 -- Getter of InteractionFragment::enclosingOperand. 115 -- 116 -- The operand enclosing this InteractionFragment (they may nest 117 -- recursively) 118 119 overriding procedure Set_Enclosing_Operand 120 (Self : not null access UML_Interaction_Operand_Proxy; 121 To : AMF.UML.Interaction_Operands.UML_Interaction_Operand_Access); 122 -- Setter of InteractionFragment::enclosingOperand. 123 -- 124 -- The operand enclosing this InteractionFragment (they may nest 125 -- recursively) 126 127 overriding function Get_General_Ordering 128 (Self : not null access constant UML_Interaction_Operand_Proxy) 129 return AMF.UML.General_Orderings.Collections.Set_Of_UML_General_Ordering; 130 -- Getter of InteractionFragment::generalOrdering. 131 -- 132 -- The general ordering relationships contained in this fragment. 133 134 overriding function Get_Client_Dependency 135 (Self : not null access constant UML_Interaction_Operand_Proxy) 136 return AMF.UML.Dependencies.Collections.Set_Of_UML_Dependency; 137 -- Getter of NamedElement::clientDependency. 138 -- 139 -- Indicates the dependencies that reference the client. 140 141 overriding function Get_Name_Expression 142 (Self : not null access constant UML_Interaction_Operand_Proxy) 143 return AMF.UML.String_Expressions.UML_String_Expression_Access; 144 -- Getter of NamedElement::nameExpression. 145 -- 146 -- The string expression used to define the name of this named element. 147 148 overriding procedure Set_Name_Expression 149 (Self : not null access UML_Interaction_Operand_Proxy; 150 To : AMF.UML.String_Expressions.UML_String_Expression_Access); 151 -- Setter of NamedElement::nameExpression. 152 -- 153 -- The string expression used to define the name of this named element. 154 155 overriding function Get_Namespace 156 (Self : not null access constant UML_Interaction_Operand_Proxy) 157 return AMF.UML.Namespaces.UML_Namespace_Access; 158 -- Getter of NamedElement::namespace. 159 -- 160 -- Specifies the namespace that owns the NamedElement. 161 162 overriding function Get_Qualified_Name 163 (Self : not null access constant UML_Interaction_Operand_Proxy) 164 return AMF.Optional_String; 165 -- Getter of NamedElement::qualifiedName. 166 -- 167 -- A name which allows the NamedElement to be identified within a 168 -- hierarchy of nested Namespaces. It is constructed from the names of the 169 -- containing namespaces starting at the root of the hierarchy and ending 170 -- with the name of the NamedElement itself. 171 172 overriding function Get_Element_Import 173 (Self : not null access constant UML_Interaction_Operand_Proxy) 174 return AMF.UML.Element_Imports.Collections.Set_Of_UML_Element_Import; 175 -- Getter of Namespace::elementImport. 176 -- 177 -- References the ElementImports owned by the Namespace. 178 179 overriding function Get_Imported_Member 180 (Self : not null access constant UML_Interaction_Operand_Proxy) 181 return AMF.UML.Packageable_Elements.Collections.Set_Of_UML_Packageable_Element; 182 -- Getter of Namespace::importedMember. 183 -- 184 -- References the PackageableElements that are members of this Namespace 185 -- as a result of either PackageImports or ElementImports. 186 187 overriding function Get_Member 188 (Self : not null access constant UML_Interaction_Operand_Proxy) 189 return AMF.UML.Named_Elements.Collections.Set_Of_UML_Named_Element; 190 -- Getter of Namespace::member. 191 -- 192 -- A collection of NamedElements identifiable within the Namespace, either 193 -- by being owned or by being introduced by importing or inheritance. 194 195 overriding function Get_Owned_Member 196 (Self : not null access constant UML_Interaction_Operand_Proxy) 197 return AMF.UML.Named_Elements.Collections.Set_Of_UML_Named_Element; 198 -- Getter of Namespace::ownedMember. 199 -- 200 -- A collection of NamedElements owned by the Namespace. 201 202 overriding function Get_Owned_Rule 203 (Self : not null access constant UML_Interaction_Operand_Proxy) 204 return AMF.UML.Constraints.Collections.Set_Of_UML_Constraint; 205 -- Getter of Namespace::ownedRule. 206 -- 207 -- Specifies a set of Constraints owned by this Namespace. 208 209 overriding function Get_Package_Import 210 (Self : not null access constant UML_Interaction_Operand_Proxy) 211 return AMF.UML.Package_Imports.Collections.Set_Of_UML_Package_Import; 212 -- Getter of Namespace::packageImport. 213 -- 214 -- References the PackageImports owned by the Namespace. 215 216 overriding function All_Owning_Packages 217 (Self : not null access constant UML_Interaction_Operand_Proxy) 218 return AMF.UML.Packages.Collections.Set_Of_UML_Package; 219 -- Operation NamedElement::allOwningPackages. 220 -- 221 -- The query allOwningPackages() returns all the directly or indirectly 222 -- owning packages. 223 224 overriding function Is_Distinguishable_From 225 (Self : not null access constant UML_Interaction_Operand_Proxy; 226 N : AMF.UML.Named_Elements.UML_Named_Element_Access; 227 Ns : AMF.UML.Namespaces.UML_Namespace_Access) 228 return Boolean; 229 -- Operation NamedElement::isDistinguishableFrom. 230 -- 231 -- The query isDistinguishableFrom() determines whether two NamedElements 232 -- may logically co-exist within a Namespace. By default, two named 233 -- elements are distinguishable if (a) they have unrelated types or (b) 234 -- they have related types but different names. 235 236 overriding function Namespace 237 (Self : not null access constant UML_Interaction_Operand_Proxy) 238 return AMF.UML.Namespaces.UML_Namespace_Access; 239 -- Operation NamedElement::namespace. 240 -- 241 -- Missing derivation for NamedElement::/namespace : Namespace 242 243 overriding function Exclude_Collisions 244 (Self : not null access constant UML_Interaction_Operand_Proxy; 245 Imps : AMF.UML.Packageable_Elements.Collections.Set_Of_UML_Packageable_Element) 246 return AMF.UML.Packageable_Elements.Collections.Set_Of_UML_Packageable_Element; 247 -- Operation Namespace::excludeCollisions. 248 -- 249 -- The query excludeCollisions() excludes from a set of 250 -- PackageableElements any that would not be distinguishable from each 251 -- other in this namespace. 252 253 overriding function Get_Names_Of_Member 254 (Self : not null access constant UML_Interaction_Operand_Proxy; 255 Element : AMF.UML.Named_Elements.UML_Named_Element_Access) 256 return AMF.String_Collections.Set_Of_String; 257 -- Operation Namespace::getNamesOfMember. 258 -- 259 -- The query getNamesOfMember() takes importing into account. It gives 260 -- back the set of names that an element would have in an importing 261 -- namespace, either because it is owned, or if not owned then imported 262 -- individually, or if not individually then from a package. 263 -- The query getNamesOfMember() gives a set of all of the names that a 264 -- member would have in a Namespace. In general a member can have multiple 265 -- names in a Namespace if it is imported more than once with different 266 -- aliases. The query takes account of importing. It gives back the set of 267 -- names that an element would have in an importing namespace, either 268 -- because it is owned, or if not owned then imported individually, or if 269 -- not individually then from a package. 270 271 overriding function Import_Members 272 (Self : not null access constant UML_Interaction_Operand_Proxy; 273 Imps : AMF.UML.Packageable_Elements.Collections.Set_Of_UML_Packageable_Element) 274 return AMF.UML.Packageable_Elements.Collections.Set_Of_UML_Packageable_Element; 275 -- Operation Namespace::importMembers. 276 -- 277 -- The query importMembers() defines which of a set of PackageableElements 278 -- are actually imported into the namespace. This excludes hidden ones, 279 -- i.e., those which have names that conflict with names of owned members, 280 -- and also excludes elements which would have the same name when imported. 281 282 overriding function Imported_Member 283 (Self : not null access constant UML_Interaction_Operand_Proxy) 284 return AMF.UML.Packageable_Elements.Collections.Set_Of_UML_Packageable_Element; 285 -- Operation Namespace::importedMember. 286 -- 287 -- The importedMember property is derived from the ElementImports and the 288 -- PackageImports. References the PackageableElements that are members of 289 -- this Namespace as a result of either PackageImports or ElementImports. 290 291 overriding function Members_Are_Distinguishable 292 (Self : not null access constant UML_Interaction_Operand_Proxy) 293 return Boolean; 294 -- Operation Namespace::membersAreDistinguishable. 295 -- 296 -- The Boolean query membersAreDistinguishable() determines whether all of 297 -- the namespace's members are distinguishable within it. 298 299 overriding function Owned_Member 300 (Self : not null access constant UML_Interaction_Operand_Proxy) 301 return AMF.UML.Named_Elements.Collections.Set_Of_UML_Named_Element; 302 -- Operation Namespace::ownedMember. 303 -- 304 -- Missing derivation for Namespace::/ownedMember : NamedElement 305 306 overriding procedure Enter_Element 307 (Self : not null access constant UML_Interaction_Operand_Proxy; 308 Visitor : in out AMF.Visitors.Abstract_Visitor'Class; 309 Control : in out AMF.Visitors.Traverse_Control); 310 -- Dispatch call to corresponding subprogram of visitor interface. 311 312 overriding procedure Leave_Element 313 (Self : not null access constant UML_Interaction_Operand_Proxy; 314 Visitor : in out AMF.Visitors.Abstract_Visitor'Class; 315 Control : in out AMF.Visitors.Traverse_Control); 316 -- Dispatch call to corresponding subprogram of visitor interface. 317 318 overriding procedure Visit_Element 319 (Self : not null access constant UML_Interaction_Operand_Proxy; 320 Iterator : in out AMF.Visitors.Abstract_Iterator'Class; 321 Visitor : in out AMF.Visitors.Abstract_Visitor'Class; 322 Control : in out AMF.Visitors.Traverse_Control); 323 -- Dispatch call to corresponding subprogram of iterator interface. 324 325end AMF.Internals.UML_Interaction_Operands; 326