Free cookie consent management tool by TermsFeed Policy Generator

source: branches/SimulationCore/HeuristicLab.SimulationCore.Dsl/Dsl/GeneratedCode/DomainRelationships.cs @ 12214

Last change on this file since 12214 was 10525, checked in by abeham, 11 years ago

#1610: added visual model

File size: 50.2 KB
Line 
1//------------------------------------------------------------------------------
2// <auto-generated>
3//     This code was generated by a tool.
4//
5//     Changes to this file may cause incorrect behavior and will be lost if
6//     the code is regenerated.
7// </auto-generated>
8//------------------------------------------------------------------------------
9
10using DslModeling = global::Microsoft.VisualStudio.Modeling;
11using DslDesign = global::Microsoft.VisualStudio.Modeling.Design;
12namespace HeuristicLab.SimulationCore
13{
14  /// <summary>
15  /// DomainRelationship SimulationModelHasActivities
16  /// Description for HeuristicLab.SimulationCore.SimulationModelHasActivities
17  /// </summary>
18  [DslDesign::DisplayNameResource("HeuristicLab.SimulationCore.SimulationModelHasActivities.DisplayName", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
19  [DslDesign::DescriptionResource("HeuristicLab.SimulationCore.SimulationModelHasActivities.Description", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
20  [DslModeling::DomainModelOwner(typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel))]
21  [global::System.CLSCompliant(true)]
22  [DslModeling::DomainRelationship(IsEmbedding=true)]
23  [DslModeling::DomainObjectId("4a4161d0-95d3-4727-8959-372bd8ba3fc7")]
24  public partial class SimulationModelHasActivities : DslModeling::ElementLink
25  {
26    #region Constructors, domain class Id
27   
28    /// <summary>
29    /// SimulationModelHasActivities domain class Id.
30    /// </summary>
31    public static readonly new global::System.Guid DomainClassId = new global::System.Guid(0x4a4161d0, 0x95d3, 0x4727, 0x89, 0x59, 0x37, 0x2b, 0xd8, 0xba, 0x3f, 0xc7);
32 
33       
34    /// <summary>
35    /// Constructor
36    /// Creates a SimulationModelHasActivities link in the same Partition as the given SimulationModel
37    /// </summary>
38    /// <param name="source">SimulationModel to use as the source of the relationship.</param>
39    /// <param name="target">Activity to use as the target of the relationship.</param>
40    public SimulationModelHasActivities(SimulationModel source, Activity target)
41      : base((source != null ? source.Partition : null), new DslModeling::RoleAssignment[]{new DslModeling::RoleAssignment(SimulationModelHasActivities.SimulationModelDomainRoleId, source), new DslModeling::RoleAssignment(SimulationModelHasActivities.ActivityDomainRoleId, target)}, null)
42    {
43    }
44   
45    /// <summary>
46    /// Constructor
47    /// </summary>
48    /// <param name="store">Store where new link is to be created.</param>
49    /// <param name="roleAssignments">List of relationship role assignments.</param>
50    public SimulationModelHasActivities(DslModeling::Store store, params DslModeling::RoleAssignment[] roleAssignments)
51      : base(store != null ? store.DefaultPartitionForClass(DomainClassId) : null, roleAssignments, null)
52    {
53    }
54   
55    /// <summary>
56    /// Constructor
57    /// </summary>
58    /// <param name="store">Store where new link is to be created.</param>
59    /// <param name="roleAssignments">List of relationship role assignments.</param>
60    /// <param name="propertyAssignments">List of properties assignments to set on the new link.</param>
61    public SimulationModelHasActivities(DslModeling::Store store, DslModeling::RoleAssignment[] roleAssignments, DslModeling::PropertyAssignment[] propertyAssignments)
62      : base(store != null ? store.DefaultPartitionForClass(DomainClassId) : null, roleAssignments, propertyAssignments)
63    {
64    }
65   
66    /// <summary>
67    /// Constructor
68    /// </summary>
69    /// <param name="partition">Partition where new link is to be created.</param>
70    /// <param name="roleAssignments">List of relationship role assignments.</param>
71    public SimulationModelHasActivities(DslModeling::Partition partition, params DslModeling::RoleAssignment[] roleAssignments)
72      : base(partition, roleAssignments, null)
73    {
74    }
75   
76    /// <summary>
77    /// Constructor
78    /// </summary>
79    /// <param name="partition">Partition where new link is to be created.</param>
80    /// <param name="roleAssignments">List of relationship role assignments.</param>
81    /// <param name="propertyAssignments">List of properties assignments to set on the new link.</param>
82    public SimulationModelHasActivities(DslModeling::Partition partition, DslModeling::RoleAssignment[] roleAssignments, DslModeling::PropertyAssignment[] propertyAssignments)
83      : base(partition, roleAssignments, propertyAssignments)
84    {
85    }
86    #endregion
87    #region SimulationModel domain role code
88   
89    /// <summary>
90    /// SimulationModel domain role Id.
91    /// </summary>
92    public static readonly global::System.Guid SimulationModelDomainRoleId = new global::System.Guid(0x1026f01d, 0xc2bd, 0x47e0, 0xa7, 0xf9, 0x01, 0xc0, 0x55, 0x1c, 0x0e, 0x8d);
93   
94    /// <summary>
95    /// DomainRole SimulationModel
96    /// Description for
97    /// HeuristicLab.SimulationCore.SimulationModelHasActivities.SimulationModel
98    /// </summary>
99    [DslDesign::DisplayNameResource("HeuristicLab.SimulationCore.SimulationModelHasActivities/SimulationModel.DisplayName", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
100    [DslDesign::DescriptionResource("HeuristicLab.SimulationCore.SimulationModelHasActivities/SimulationModel.Description", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
101    [DslModeling::DomainRole(DslModeling::DomainRoleOrder.Source, PropertyName = "Activities", PropertyDisplayNameKey="HeuristicLab.SimulationCore.SimulationModelHasActivities/SimulationModel.PropertyDisplayName",  PropagatesCopy = DslModeling::PropagatesCopyOption.PropagatesCopyToLinkAndOppositeRolePlayer, Multiplicity = DslModeling::Multiplicity.ZeroMany)]
102    [DslModeling::DomainObjectId("1026f01d-c2bd-47e0-a7f9-01c0551c0e8d")]
103    public virtual SimulationModel SimulationModel
104    {
105      [global::System.Diagnostics.DebuggerStepThrough]
106      get
107      {
108        return (SimulationModel)DslModeling::DomainRoleInfo.GetRolePlayer(this, SimulationModelDomainRoleId);
109      }
110      [global::System.Diagnostics.DebuggerStepThrough]
111      set
112      {
113        DslModeling::DomainRoleInfo.SetRolePlayer(this, SimulationModelDomainRoleId, value);
114      }
115    }
116       
117    #endregion
118    #region Static methods to access SimulationModel of a Activity
119    /// <summary>
120    /// Gets SimulationModel.
121    /// </summary>
122    [global::System.Diagnostics.DebuggerStepThrough]
123    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
124    public static SimulationModel GetSimulationModel(Activity element)
125    {
126      return DslModeling::DomainRoleInfo.GetLinkedElement(element, ActivityDomainRoleId) as SimulationModel;
127    }
128   
129    /// <summary>
130    /// Sets SimulationModel.
131    /// </summary>
132    [global::System.Diagnostics.DebuggerStepThrough]
133    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
134    public static void SetSimulationModel(Activity element, SimulationModel newSimulationModel)
135    {
136      DslModeling::DomainRoleInfo.SetLinkedElement(element, ActivityDomainRoleId, newSimulationModel);
137    }
138    #endregion
139    #region Activity domain role code
140   
141    /// <summary>
142    /// Activity domain role Id.
143    /// </summary>
144    public static readonly global::System.Guid ActivityDomainRoleId = new global::System.Guid(0xcd685a0e, 0x906c, 0x49b2, 0xbc, 0x7b, 0x0b, 0xdc, 0xc4, 0x39, 0xb6, 0x9e);
145   
146    /// <summary>
147    /// DomainRole Activity
148    /// Description for
149    /// HeuristicLab.SimulationCore.SimulationModelHasActivities.Activity
150    /// </summary>
151    [DslDesign::DisplayNameResource("HeuristicLab.SimulationCore.SimulationModelHasActivities/Activity.DisplayName", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
152    [DslDesign::DescriptionResource("HeuristicLab.SimulationCore.SimulationModelHasActivities/Activity.Description", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
153    [DslModeling::DomainRole(DslModeling::DomainRoleOrder.Target, PropertyName = "SimulationModel", PropertyDisplayNameKey="HeuristicLab.SimulationCore.SimulationModelHasActivities/Activity.PropertyDisplayName", PropagatesDelete = true,  PropagatesCopy = DslModeling::PropagatesCopyOption.DoNotPropagateCopy, Multiplicity = DslModeling::Multiplicity.One)]
154    [DslModeling::DomainObjectId("cd685a0e-906c-49b2-bc7b-0bdcc439b69e")]
155    public virtual Activity Activity
156    {
157      [global::System.Diagnostics.DebuggerStepThrough]
158      get
159      {
160        return (Activity)DslModeling::DomainRoleInfo.GetRolePlayer(this, ActivityDomainRoleId);
161      }
162      [global::System.Diagnostics.DebuggerStepThrough]
163      set
164      {
165        DslModeling::DomainRoleInfo.SetRolePlayer(this, ActivityDomainRoleId, value);
166      }
167    }
168       
169    #endregion
170    #region Static methods to access Activities of a SimulationModel
171    /// <summary>
172    /// Gets a list of Activities.
173    /// </summary>
174    [global::System.Diagnostics.DebuggerStepThrough]
175    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
176    public static DslModeling::LinkedElementCollection<Activity> GetActivities(SimulationModel element)
177    {
178      return GetRoleCollection<DslModeling::LinkedElementCollection<Activity>, Activity>(element, SimulationModelDomainRoleId);
179    }
180    #endregion
181    #region SimulationModel link accessor
182    /// <summary>
183    /// Get the list of SimulationModelHasActivities links to a SimulationModel.
184    /// </summary>
185    [global::System.Diagnostics.DebuggerStepThrough]
186    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
187    public static global::System.Collections.ObjectModel.ReadOnlyCollection<global::HeuristicLab.SimulationCore.SimulationModelHasActivities> GetLinksToActivities ( global::HeuristicLab.SimulationCore.SimulationModel simulationModelInstance )
188    {
189      return DslModeling::DomainRoleInfo.GetElementLinks<global::HeuristicLab.SimulationCore.SimulationModelHasActivities>(simulationModelInstance, global::HeuristicLab.SimulationCore.SimulationModelHasActivities.SimulationModelDomainRoleId);
190    }
191    #endregion
192    #region Activity link accessor
193    /// <summary>
194    /// Get the SimulationModelHasActivities link to a Activity.
195    /// </summary>
196    [global::System.Diagnostics.DebuggerStepThrough]
197    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
198    public static global::HeuristicLab.SimulationCore.SimulationModelHasActivities GetLinkToSimulationModel (global::HeuristicLab.SimulationCore.Activity activityInstance)
199    {
200      global::System.Collections.Generic.IList<global::HeuristicLab.SimulationCore.SimulationModelHasActivities> links = DslModeling::DomainRoleInfo.GetElementLinks<global::HeuristicLab.SimulationCore.SimulationModelHasActivities>(activityInstance, global::HeuristicLab.SimulationCore.SimulationModelHasActivities.ActivityDomainRoleId);
201      global::System.Diagnostics.Debug.Assert(links.Count <= 1, "Multiplicity of Activity not obeyed.");
202      if ( links.Count == 0 )
203      {
204        return null;
205      }
206      else
207      {
208        return links[0];
209      }
210    }
211    #endregion
212    #region SimulationModelHasActivities instance accessors
213   
214    /// <summary>
215    /// Get any SimulationModelHasActivities links between a given SimulationModel and a Activity.
216    /// </summary>
217    [global::System.Diagnostics.DebuggerStepThrough]
218    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
219    public static global::System.Collections.ObjectModel.ReadOnlyCollection<global::HeuristicLab.SimulationCore.SimulationModelHasActivities> GetLinks( global::HeuristicLab.SimulationCore.SimulationModel source, global::HeuristicLab.SimulationCore.Activity target )
220    {
221      global::System.Collections.Generic.List<global::HeuristicLab.SimulationCore.SimulationModelHasActivities> outLinks = new global::System.Collections.Generic.List<global::HeuristicLab.SimulationCore.SimulationModelHasActivities>();
222      global::System.Collections.Generic.IList<global::HeuristicLab.SimulationCore.SimulationModelHasActivities> links = DslModeling::DomainRoleInfo.GetElementLinks<global::HeuristicLab.SimulationCore.SimulationModelHasActivities>(source, global::HeuristicLab.SimulationCore.SimulationModelHasActivities.SimulationModelDomainRoleId);
223      foreach ( global::HeuristicLab.SimulationCore.SimulationModelHasActivities link in links )
224      {
225        if ( target.Equals(link.Activity) )
226        {
227          outLinks.Add(link);
228        }
229      }
230      return outLinks.AsReadOnly();
231    }
232    /// <summary>
233    /// Get the one SimulationModelHasActivities link between a given SimulationModeland a Activity.
234    /// </summary>
235    [global::System.Diagnostics.DebuggerStepThrough]
236    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
237    public static global::HeuristicLab.SimulationCore.SimulationModelHasActivities GetLink( global::HeuristicLab.SimulationCore.SimulationModel source, global::HeuristicLab.SimulationCore.Activity target )
238    {
239      global::System.Collections.Generic.IList<global::HeuristicLab.SimulationCore.SimulationModelHasActivities> links = DslModeling::DomainRoleInfo.GetElementLinks<global::HeuristicLab.SimulationCore.SimulationModelHasActivities>(source, global::HeuristicLab.SimulationCore.SimulationModelHasActivities.SimulationModelDomainRoleId);
240      foreach ( global::HeuristicLab.SimulationCore.SimulationModelHasActivities link in links )
241      {
242        if ( target.Equals(link.Activity) )
243        {
244          return link;
245        }
246      }
247      return null;
248    }
249   
250    #endregion
251  }
252}
253namespace HeuristicLab.SimulationCore
254{
255  /// <summary>
256  /// DomainRelationship SimulationModelHasActions
257  /// Description for HeuristicLab.SimulationCore.SimulationModelHasActions
258  /// </summary>
259  [DslDesign::DisplayNameResource("HeuristicLab.SimulationCore.SimulationModelHasActions.DisplayName", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
260  [DslDesign::DescriptionResource("HeuristicLab.SimulationCore.SimulationModelHasActions.Description", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
261  [DslModeling::DomainModelOwner(typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel))]
262  [global::System.CLSCompliant(true)]
263  [DslModeling::DomainRelationship(IsEmbedding=true)]
264  [DslModeling::DomainObjectId("4f6020f0-423c-4469-af3f-09ac8db8d19a")]
265  public partial class SimulationModelHasActions : DslModeling::ElementLink
266  {
267    #region Constructors, domain class Id
268   
269    /// <summary>
270    /// SimulationModelHasActions domain class Id.
271    /// </summary>
272    public static readonly new global::System.Guid DomainClassId = new global::System.Guid(0x4f6020f0, 0x423c, 0x4469, 0xaf, 0x3f, 0x09, 0xac, 0x8d, 0xb8, 0xd1, 0x9a);
273 
274       
275    /// <summary>
276    /// Constructor
277    /// Creates a SimulationModelHasActions link in the same Partition as the given SimulationModel
278    /// </summary>
279    /// <param name="source">SimulationModel to use as the source of the relationship.</param>
280    /// <param name="target">Action to use as the target of the relationship.</param>
281    public SimulationModelHasActions(SimulationModel source, Action target)
282      : base((source != null ? source.Partition : null), new DslModeling::RoleAssignment[]{new DslModeling::RoleAssignment(SimulationModelHasActions.SimulationModelDomainRoleId, source), new DslModeling::RoleAssignment(SimulationModelHasActions.ActionDomainRoleId, target)}, null)
283    {
284    }
285   
286    /// <summary>
287    /// Constructor
288    /// </summary>
289    /// <param name="store">Store where new link is to be created.</param>
290    /// <param name="roleAssignments">List of relationship role assignments.</param>
291    public SimulationModelHasActions(DslModeling::Store store, params DslModeling::RoleAssignment[] roleAssignments)
292      : base(store != null ? store.DefaultPartitionForClass(DomainClassId) : null, roleAssignments, null)
293    {
294    }
295   
296    /// <summary>
297    /// Constructor
298    /// </summary>
299    /// <param name="store">Store where new link is to be created.</param>
300    /// <param name="roleAssignments">List of relationship role assignments.</param>
301    /// <param name="propertyAssignments">List of properties assignments to set on the new link.</param>
302    public SimulationModelHasActions(DslModeling::Store store, DslModeling::RoleAssignment[] roleAssignments, DslModeling::PropertyAssignment[] propertyAssignments)
303      : base(store != null ? store.DefaultPartitionForClass(DomainClassId) : null, roleAssignments, propertyAssignments)
304    {
305    }
306   
307    /// <summary>
308    /// Constructor
309    /// </summary>
310    /// <param name="partition">Partition where new link is to be created.</param>
311    /// <param name="roleAssignments">List of relationship role assignments.</param>
312    public SimulationModelHasActions(DslModeling::Partition partition, params DslModeling::RoleAssignment[] roleAssignments)
313      : base(partition, roleAssignments, null)
314    {
315    }
316   
317    /// <summary>
318    /// Constructor
319    /// </summary>
320    /// <param name="partition">Partition where new link is to be created.</param>
321    /// <param name="roleAssignments">List of relationship role assignments.</param>
322    /// <param name="propertyAssignments">List of properties assignments to set on the new link.</param>
323    public SimulationModelHasActions(DslModeling::Partition partition, DslModeling::RoleAssignment[] roleAssignments, DslModeling::PropertyAssignment[] propertyAssignments)
324      : base(partition, roleAssignments, propertyAssignments)
325    {
326    }
327    #endregion
328    #region SimulationModel domain role code
329   
330    /// <summary>
331    /// SimulationModel domain role Id.
332    /// </summary>
333    public static readonly global::System.Guid SimulationModelDomainRoleId = new global::System.Guid(0x5f2e5817, 0x063b, 0x4f23, 0xa9, 0x96, 0xd4, 0x90, 0xac, 0x05, 0xec, 0x40);
334   
335    /// <summary>
336    /// DomainRole SimulationModel
337    /// Description for
338    /// HeuristicLab.SimulationCore.SimulationModelHasActions.SimulationModel
339    /// </summary>
340    [DslDesign::DisplayNameResource("HeuristicLab.SimulationCore.SimulationModelHasActions/SimulationModel.DisplayName", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
341    [DslDesign::DescriptionResource("HeuristicLab.SimulationCore.SimulationModelHasActions/SimulationModel.Description", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
342    [DslModeling::DomainRole(DslModeling::DomainRoleOrder.Source, PropertyName = "Actions", PropertyDisplayNameKey="HeuristicLab.SimulationCore.SimulationModelHasActions/SimulationModel.PropertyDisplayName",  PropagatesCopy = DslModeling::PropagatesCopyOption.PropagatesCopyToLinkAndOppositeRolePlayer, Multiplicity = DslModeling::Multiplicity.ZeroMany)]
343    [DslModeling::DomainObjectId("5f2e5817-063b-4f23-a996-d490ac05ec40")]
344    public virtual SimulationModel SimulationModel
345    {
346      [global::System.Diagnostics.DebuggerStepThrough]
347      get
348      {
349        return (SimulationModel)DslModeling::DomainRoleInfo.GetRolePlayer(this, SimulationModelDomainRoleId);
350      }
351      [global::System.Diagnostics.DebuggerStepThrough]
352      set
353      {
354        DslModeling::DomainRoleInfo.SetRolePlayer(this, SimulationModelDomainRoleId, value);
355      }
356    }
357       
358    #endregion
359    #region Static methods to access SimulationModel of a Action
360    /// <summary>
361    /// Gets SimulationModel.
362    /// </summary>
363    [global::System.Diagnostics.DebuggerStepThrough]
364    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
365    public static SimulationModel GetSimulationModel(Action element)
366    {
367      return DslModeling::DomainRoleInfo.GetLinkedElement(element, ActionDomainRoleId) as SimulationModel;
368    }
369   
370    /// <summary>
371    /// Sets SimulationModel.
372    /// </summary>
373    [global::System.Diagnostics.DebuggerStepThrough]
374    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
375    public static void SetSimulationModel(Action element, SimulationModel newSimulationModel)
376    {
377      DslModeling::DomainRoleInfo.SetLinkedElement(element, ActionDomainRoleId, newSimulationModel);
378    }
379    #endregion
380    #region Action domain role code
381   
382    /// <summary>
383    /// Action domain role Id.
384    /// </summary>
385    public static readonly global::System.Guid ActionDomainRoleId = new global::System.Guid(0xa7f0817d, 0x4f04, 0x49ef, 0x95, 0x92, 0xe2, 0xf7, 0x84, 0x32, 0xcc, 0x4f);
386   
387    /// <summary>
388    /// DomainRole Action
389    /// Description for HeuristicLab.SimulationCore.SimulationModelHasActions.Action
390    /// </summary>
391    [DslDesign::DisplayNameResource("HeuristicLab.SimulationCore.SimulationModelHasActions/Action.DisplayName", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
392    [DslDesign::DescriptionResource("HeuristicLab.SimulationCore.SimulationModelHasActions/Action.Description", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
393    [DslModeling::DomainRole(DslModeling::DomainRoleOrder.Target, PropertyName = "SimulationModel", PropertyDisplayNameKey="HeuristicLab.SimulationCore.SimulationModelHasActions/Action.PropertyDisplayName", PropagatesDelete = true,  PropagatesCopy = DslModeling::PropagatesCopyOption.DoNotPropagateCopy, Multiplicity = DslModeling::Multiplicity.One)]
394    [DslModeling::DomainObjectId("a7f0817d-4f04-49ef-9592-e2f78432cc4f")]
395    public virtual Action Action
396    {
397      [global::System.Diagnostics.DebuggerStepThrough]
398      get
399      {
400        return (Action)DslModeling::DomainRoleInfo.GetRolePlayer(this, ActionDomainRoleId);
401      }
402      [global::System.Diagnostics.DebuggerStepThrough]
403      set
404      {
405        DslModeling::DomainRoleInfo.SetRolePlayer(this, ActionDomainRoleId, value);
406      }
407    }
408       
409    #endregion
410    #region Static methods to access Actions of a SimulationModel
411    /// <summary>
412    /// Gets a list of Actions.
413    /// </summary>
414    [global::System.Diagnostics.DebuggerStepThrough]
415    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
416    public static DslModeling::LinkedElementCollection<Action> GetActions(SimulationModel element)
417    {
418      return GetRoleCollection<DslModeling::LinkedElementCollection<Action>, Action>(element, SimulationModelDomainRoleId);
419    }
420    #endregion
421    #region SimulationModel link accessor
422    /// <summary>
423    /// Get the list of SimulationModelHasActions links to a SimulationModel.
424    /// </summary>
425    [global::System.Diagnostics.DebuggerStepThrough]
426    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
427    public static global::System.Collections.ObjectModel.ReadOnlyCollection<global::HeuristicLab.SimulationCore.SimulationModelHasActions> GetLinksToActions ( global::HeuristicLab.SimulationCore.SimulationModel simulationModelInstance )
428    {
429      return DslModeling::DomainRoleInfo.GetElementLinks<global::HeuristicLab.SimulationCore.SimulationModelHasActions>(simulationModelInstance, global::HeuristicLab.SimulationCore.SimulationModelHasActions.SimulationModelDomainRoleId);
430    }
431    #endregion
432    #region Action link accessor
433    /// <summary>
434    /// Get the SimulationModelHasActions link to a Action.
435    /// </summary>
436    [global::System.Diagnostics.DebuggerStepThrough]
437    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
438    public static global::HeuristicLab.SimulationCore.SimulationModelHasActions GetLinkToSimulationModel (global::HeuristicLab.SimulationCore.Action actionInstance)
439    {
440      global::System.Collections.Generic.IList<global::HeuristicLab.SimulationCore.SimulationModelHasActions> links = DslModeling::DomainRoleInfo.GetElementLinks<global::HeuristicLab.SimulationCore.SimulationModelHasActions>(actionInstance, global::HeuristicLab.SimulationCore.SimulationModelHasActions.ActionDomainRoleId);
441      global::System.Diagnostics.Debug.Assert(links.Count <= 1, "Multiplicity of Action not obeyed.");
442      if ( links.Count == 0 )
443      {
444        return null;
445      }
446      else
447      {
448        return links[0];
449      }
450    }
451    #endregion
452    #region SimulationModelHasActions instance accessors
453   
454    /// <summary>
455    /// Get any SimulationModelHasActions links between a given SimulationModel and a Action.
456    /// </summary>
457    [global::System.Diagnostics.DebuggerStepThrough]
458    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
459    public static global::System.Collections.ObjectModel.ReadOnlyCollection<global::HeuristicLab.SimulationCore.SimulationModelHasActions> GetLinks( global::HeuristicLab.SimulationCore.SimulationModel source, global::HeuristicLab.SimulationCore.Action target )
460    {
461      global::System.Collections.Generic.List<global::HeuristicLab.SimulationCore.SimulationModelHasActions> outLinks = new global::System.Collections.Generic.List<global::HeuristicLab.SimulationCore.SimulationModelHasActions>();
462      global::System.Collections.Generic.IList<global::HeuristicLab.SimulationCore.SimulationModelHasActions> links = DslModeling::DomainRoleInfo.GetElementLinks<global::HeuristicLab.SimulationCore.SimulationModelHasActions>(source, global::HeuristicLab.SimulationCore.SimulationModelHasActions.SimulationModelDomainRoleId);
463      foreach ( global::HeuristicLab.SimulationCore.SimulationModelHasActions link in links )
464      {
465        if ( target.Equals(link.Action) )
466        {
467          outLinks.Add(link);
468        }
469      }
470      return outLinks.AsReadOnly();
471    }
472    /// <summary>
473    /// Get the one SimulationModelHasActions link between a given SimulationModeland a Action.
474    /// </summary>
475    [global::System.Diagnostics.DebuggerStepThrough]
476    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
477    public static global::HeuristicLab.SimulationCore.SimulationModelHasActions GetLink( global::HeuristicLab.SimulationCore.SimulationModel source, global::HeuristicLab.SimulationCore.Action target )
478    {
479      global::System.Collections.Generic.IList<global::HeuristicLab.SimulationCore.SimulationModelHasActions> links = DslModeling::DomainRoleInfo.GetElementLinks<global::HeuristicLab.SimulationCore.SimulationModelHasActions>(source, global::HeuristicLab.SimulationCore.SimulationModelHasActions.SimulationModelDomainRoleId);
480      foreach ( global::HeuristicLab.SimulationCore.SimulationModelHasActions link in links )
481      {
482        if ( target.Equals(link.Action) )
483        {
484          return link;
485        }
486      }
487      return null;
488    }
489   
490    #endregion
491  }
492}
493namespace HeuristicLab.SimulationCore
494{
495  /// <summary>
496  /// DomainRelationship ActivityReferencesTriggers
497  /// Description for HeuristicLab.SimulationCore.ActivityReferencesTriggers
498  /// </summary>
499  [DslDesign::DisplayNameResource("HeuristicLab.SimulationCore.ActivityReferencesTriggers.DisplayName", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
500  [DslDesign::DescriptionResource("HeuristicLab.SimulationCore.ActivityReferencesTriggers.Description", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
501  [DslModeling::DomainModelOwner(typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel))]
502  [global::System.CLSCompliant(true)]
503  [DslModeling::DomainRelationship()]
504  [DslModeling::DomainObjectId("717952d5-7c93-4315-8e41-453cffe17811")]
505  public partial class ActivityReferencesTriggers : DslModeling::ElementLink
506  {
507    #region Constructors, domain class Id
508   
509    /// <summary>
510    /// ActivityReferencesTriggers domain class Id.
511    /// </summary>
512    public static readonly new global::System.Guid DomainClassId = new global::System.Guid(0x717952d5, 0x7c93, 0x4315, 0x8e, 0x41, 0x45, 0x3c, 0xff, 0xe1, 0x78, 0x11);
513 
514       
515    /// <summary>
516    /// Constructor
517    /// Creates a ActivityReferencesTriggers link in the same Partition as the given Activity
518    /// </summary>
519    /// <param name="source">Activity to use as the source of the relationship.</param>
520    /// <param name="target">Action to use as the target of the relationship.</param>
521    public ActivityReferencesTriggers(Activity source, Action target)
522      : base((source != null ? source.Partition : null), new DslModeling::RoleAssignment[]{new DslModeling::RoleAssignment(ActivityReferencesTriggers.ActivityDomainRoleId, source), new DslModeling::RoleAssignment(ActivityReferencesTriggers.ActionDomainRoleId, target)}, null)
523    {
524    }
525   
526    /// <summary>
527    /// Constructor
528    /// </summary>
529    /// <param name="store">Store where new link is to be created.</param>
530    /// <param name="roleAssignments">List of relationship role assignments.</param>
531    public ActivityReferencesTriggers(DslModeling::Store store, params DslModeling::RoleAssignment[] roleAssignments)
532      : base(store != null ? store.DefaultPartitionForClass(DomainClassId) : null, roleAssignments, null)
533    {
534    }
535   
536    /// <summary>
537    /// Constructor
538    /// </summary>
539    /// <param name="store">Store where new link is to be created.</param>
540    /// <param name="roleAssignments">List of relationship role assignments.</param>
541    /// <param name="propertyAssignments">List of properties assignments to set on the new link.</param>
542    public ActivityReferencesTriggers(DslModeling::Store store, DslModeling::RoleAssignment[] roleAssignments, DslModeling::PropertyAssignment[] propertyAssignments)
543      : base(store != null ? store.DefaultPartitionForClass(DomainClassId) : null, roleAssignments, propertyAssignments)
544    {
545    }
546   
547    /// <summary>
548    /// Constructor
549    /// </summary>
550    /// <param name="partition">Partition where new link is to be created.</param>
551    /// <param name="roleAssignments">List of relationship role assignments.</param>
552    public ActivityReferencesTriggers(DslModeling::Partition partition, params DslModeling::RoleAssignment[] roleAssignments)
553      : base(partition, roleAssignments, null)
554    {
555    }
556   
557    /// <summary>
558    /// Constructor
559    /// </summary>
560    /// <param name="partition">Partition where new link is to be created.</param>
561    /// <param name="roleAssignments">List of relationship role assignments.</param>
562    /// <param name="propertyAssignments">List of properties assignments to set on the new link.</param>
563    public ActivityReferencesTriggers(DslModeling::Partition partition, DslModeling::RoleAssignment[] roleAssignments, DslModeling::PropertyAssignment[] propertyAssignments)
564      : base(partition, roleAssignments, propertyAssignments)
565    {
566    }
567    #endregion
568    #region Activity domain role code
569   
570    /// <summary>
571    /// Activity domain role Id.
572    /// </summary>
573    public static readonly global::System.Guid ActivityDomainRoleId = new global::System.Guid(0x7796065f, 0x0003, 0x4aec, 0xbf, 0x7a, 0x6d, 0x22, 0xb9, 0x9f, 0x7c, 0x4b);
574   
575    /// <summary>
576    /// DomainRole Activity
577    /// Description for HeuristicLab.SimulationCore.ActivityReferencesTriggers.Activity
578    /// </summary>
579    [DslDesign::DisplayNameResource("HeuristicLab.SimulationCore.ActivityReferencesTriggers/Activity.DisplayName", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
580    [DslDesign::DescriptionResource("HeuristicLab.SimulationCore.ActivityReferencesTriggers/Activity.Description", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
581    [DslModeling::DomainRole(DslModeling::DomainRoleOrder.Source, PropertyName = "Triggers", PropertyDisplayNameKey="HeuristicLab.SimulationCore.ActivityReferencesTriggers/Activity.PropertyDisplayName",  PropagatesCopy = DslModeling::PropagatesCopyOption.DoNotPropagateCopy, Multiplicity = DslModeling::Multiplicity.ZeroMany)]
582    [DslModeling::DomainObjectId("7796065f-0003-4aec-bf7a-6d22b99f7c4b")]
583    public virtual Activity Activity
584    {
585      [global::System.Diagnostics.DebuggerStepThrough]
586      get
587      {
588        return (Activity)DslModeling::DomainRoleInfo.GetRolePlayer(this, ActivityDomainRoleId);
589      }
590      [global::System.Diagnostics.DebuggerStepThrough]
591      set
592      {
593        DslModeling::DomainRoleInfo.SetRolePlayer(this, ActivityDomainRoleId, value);
594      }
595    }
596       
597    #endregion
598    #region Static methods to access Activities of a Action
599    /// <summary>
600    /// Gets a list of Activities.
601    /// </summary>
602    [global::System.Diagnostics.DebuggerStepThrough]
603    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
604    public static DslModeling::LinkedElementCollection<Activity> GetActivities(Action element)
605    {
606      return GetRoleCollection<DslModeling::LinkedElementCollection<Activity>, Activity>(element, ActionDomainRoleId);
607    }
608    #endregion
609    #region Action domain role code
610   
611    /// <summary>
612    /// Action domain role Id.
613    /// </summary>
614    public static readonly global::System.Guid ActionDomainRoleId = new global::System.Guid(0x93b557c0, 0x5b55, 0x4e27, 0xaa, 0x06, 0x6e, 0xdf, 0xbe, 0x50, 0x85, 0x85);
615   
616    /// <summary>
617    /// DomainRole Action
618    /// Description for HeuristicLab.SimulationCore.ActivityReferencesTriggers.Action
619    /// </summary>
620    [DslDesign::DisplayNameResource("HeuristicLab.SimulationCore.ActivityReferencesTriggers/Action.DisplayName", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
621    [DslDesign::DescriptionResource("HeuristicLab.SimulationCore.ActivityReferencesTriggers/Action.Description", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
622    [DslModeling::DomainRole(DslModeling::DomainRoleOrder.Target, PropertyName = "Activities", PropertyDisplayNameKey="HeuristicLab.SimulationCore.ActivityReferencesTriggers/Action.PropertyDisplayName",  PropagatesCopy = DslModeling::PropagatesCopyOption.DoNotPropagateCopy, Multiplicity = DslModeling::Multiplicity.ZeroMany)]
623    [DslModeling::DomainObjectId("93b557c0-5b55-4e27-aa06-6edfbe508585")]
624    public virtual Action Action
625    {
626      [global::System.Diagnostics.DebuggerStepThrough]
627      get
628      {
629        return (Action)DslModeling::DomainRoleInfo.GetRolePlayer(this, ActionDomainRoleId);
630      }
631      [global::System.Diagnostics.DebuggerStepThrough]
632      set
633      {
634        DslModeling::DomainRoleInfo.SetRolePlayer(this, ActionDomainRoleId, value);
635      }
636    }
637       
638    #endregion
639    #region Static methods to access Triggers of a Activity
640    /// <summary>
641    /// Gets a list of Triggers.
642    /// </summary>
643    [global::System.Diagnostics.DebuggerStepThrough]
644    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
645    public static DslModeling::LinkedElementCollection<Action> GetTriggers(Activity element)
646    {
647      return GetRoleCollection<DslModeling::LinkedElementCollection<Action>, Action>(element, ActivityDomainRoleId);
648    }
649    #endregion
650    #region Activity link accessor
651    /// <summary>
652    /// Get the list of ActivityReferencesTriggers links to a Activity.
653    /// </summary>
654    [global::System.Diagnostics.DebuggerStepThrough]
655    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
656    public static global::System.Collections.ObjectModel.ReadOnlyCollection<global::HeuristicLab.SimulationCore.ActivityReferencesTriggers> GetLinksToTriggers ( global::HeuristicLab.SimulationCore.Activity activityInstance )
657    {
658      return DslModeling::DomainRoleInfo.GetElementLinks<global::HeuristicLab.SimulationCore.ActivityReferencesTriggers>(activityInstance, global::HeuristicLab.SimulationCore.ActivityReferencesTriggers.ActivityDomainRoleId);
659    }
660    #endregion
661    #region Action link accessor
662    /// <summary>
663    /// Get the list of ActivityReferencesTriggers links to a Action.
664    /// </summary>
665    [global::System.Diagnostics.DebuggerStepThrough]
666    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
667    public static global::System.Collections.ObjectModel.ReadOnlyCollection<global::HeuristicLab.SimulationCore.ActivityReferencesTriggers> GetLinksToActivities ( global::HeuristicLab.SimulationCore.Action actionInstance )
668    {
669      return DslModeling::DomainRoleInfo.GetElementLinks<global::HeuristicLab.SimulationCore.ActivityReferencesTriggers>(actionInstance, global::HeuristicLab.SimulationCore.ActivityReferencesTriggers.ActionDomainRoleId);
670    }
671    #endregion
672    #region ActivityReferencesTriggers instance accessors
673   
674    /// <summary>
675    /// Get any ActivityReferencesTriggers links between a given Activity and a Action.
676    /// </summary>
677    [global::System.Diagnostics.DebuggerStepThrough]
678    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
679    public static global::System.Collections.ObjectModel.ReadOnlyCollection<global::HeuristicLab.SimulationCore.ActivityReferencesTriggers> GetLinks( global::HeuristicLab.SimulationCore.Activity source, global::HeuristicLab.SimulationCore.Action target )
680    {
681      global::System.Collections.Generic.List<global::HeuristicLab.SimulationCore.ActivityReferencesTriggers> outLinks = new global::System.Collections.Generic.List<global::HeuristicLab.SimulationCore.ActivityReferencesTriggers>();
682      global::System.Collections.Generic.IList<global::HeuristicLab.SimulationCore.ActivityReferencesTriggers> links = DslModeling::DomainRoleInfo.GetElementLinks<global::HeuristicLab.SimulationCore.ActivityReferencesTriggers>(source, global::HeuristicLab.SimulationCore.ActivityReferencesTriggers.ActivityDomainRoleId);
683      foreach ( global::HeuristicLab.SimulationCore.ActivityReferencesTriggers link in links )
684      {
685        if ( target.Equals(link.Action) )
686        {
687          outLinks.Add(link);
688        }
689      }
690      return outLinks.AsReadOnly();
691    }
692    /// <summary>
693    /// Get the one ActivityReferencesTriggers link between a given Activityand a Action.
694    /// </summary>
695    [global::System.Diagnostics.DebuggerStepThrough]
696    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
697    public static global::HeuristicLab.SimulationCore.ActivityReferencesTriggers GetLink( global::HeuristicLab.SimulationCore.Activity source, global::HeuristicLab.SimulationCore.Action target )
698    {
699      global::System.Collections.Generic.IList<global::HeuristicLab.SimulationCore.ActivityReferencesTriggers> links = DslModeling::DomainRoleInfo.GetElementLinks<global::HeuristicLab.SimulationCore.ActivityReferencesTriggers>(source, global::HeuristicLab.SimulationCore.ActivityReferencesTriggers.ActivityDomainRoleId);
700      foreach ( global::HeuristicLab.SimulationCore.ActivityReferencesTriggers link in links )
701      {
702        if ( target.Equals(link.Action) )
703        {
704          return link;
705        }
706      }
707      return null;
708    }
709   
710    #endregion
711  }
712}
713namespace HeuristicLab.SimulationCore
714{
715  /// <summary>
716  /// DomainRelationship ActionReferencesListeners
717  /// Description for HeuristicLab.SimulationCore.ActionReferencesListeners
718  /// </summary>
719  [DslDesign::DisplayNameResource("HeuristicLab.SimulationCore.ActionReferencesListeners.DisplayName", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
720  [DslDesign::DescriptionResource("HeuristicLab.SimulationCore.ActionReferencesListeners.Description", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
721  [DslModeling::DomainModelOwner(typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel))]
722  [global::System.CLSCompliant(true)]
723  [DslModeling::DomainRelationship()]
724  [DslModeling::DomainObjectId("448eff77-5a72-420f-befa-d599574bb485")]
725  public partial class ActionReferencesListeners : DslModeling::ElementLink
726  {
727    #region Constructors, domain class Id
728   
729    /// <summary>
730    /// ActionReferencesListeners domain class Id.
731    /// </summary>
732    public static readonly new global::System.Guid DomainClassId = new global::System.Guid(0x448eff77, 0x5a72, 0x420f, 0xbe, 0xfa, 0xd5, 0x99, 0x57, 0x4b, 0xb4, 0x85);
733 
734       
735    /// <summary>
736    /// Constructor
737    /// Creates a ActionReferencesListeners link in the same Partition as the given Action
738    /// </summary>
739    /// <param name="source">Action to use as the source of the relationship.</param>
740    /// <param name="target">Activity to use as the target of the relationship.</param>
741    public ActionReferencesListeners(Action source, Activity target)
742      : base((source != null ? source.Partition : null), new DslModeling::RoleAssignment[]{new DslModeling::RoleAssignment(ActionReferencesListeners.ActionDomainRoleId, source), new DslModeling::RoleAssignment(ActionReferencesListeners.ActivityDomainRoleId, target)}, null)
743    {
744    }
745   
746    /// <summary>
747    /// Constructor
748    /// </summary>
749    /// <param name="store">Store where new link is to be created.</param>
750    /// <param name="roleAssignments">List of relationship role assignments.</param>
751    public ActionReferencesListeners(DslModeling::Store store, params DslModeling::RoleAssignment[] roleAssignments)
752      : base(store != null ? store.DefaultPartitionForClass(DomainClassId) : null, roleAssignments, null)
753    {
754    }
755   
756    /// <summary>
757    /// Constructor
758    /// </summary>
759    /// <param name="store">Store where new link is to be created.</param>
760    /// <param name="roleAssignments">List of relationship role assignments.</param>
761    /// <param name="propertyAssignments">List of properties assignments to set on the new link.</param>
762    public ActionReferencesListeners(DslModeling::Store store, DslModeling::RoleAssignment[] roleAssignments, DslModeling::PropertyAssignment[] propertyAssignments)
763      : base(store != null ? store.DefaultPartitionForClass(DomainClassId) : null, roleAssignments, propertyAssignments)
764    {
765    }
766   
767    /// <summary>
768    /// Constructor
769    /// </summary>
770    /// <param name="partition">Partition where new link is to be created.</param>
771    /// <param name="roleAssignments">List of relationship role assignments.</param>
772    public ActionReferencesListeners(DslModeling::Partition partition, params DslModeling::RoleAssignment[] roleAssignments)
773      : base(partition, roleAssignments, null)
774    {
775    }
776   
777    /// <summary>
778    /// Constructor
779    /// </summary>
780    /// <param name="partition">Partition where new link is to be created.</param>
781    /// <param name="roleAssignments">List of relationship role assignments.</param>
782    /// <param name="propertyAssignments">List of properties assignments to set on the new link.</param>
783    public ActionReferencesListeners(DslModeling::Partition partition, DslModeling::RoleAssignment[] roleAssignments, DslModeling::PropertyAssignment[] propertyAssignments)
784      : base(partition, roleAssignments, propertyAssignments)
785    {
786    }
787    #endregion
788    #region Action domain role code
789   
790    /// <summary>
791    /// Action domain role Id.
792    /// </summary>
793    public static readonly global::System.Guid ActionDomainRoleId = new global::System.Guid(0x0e8492e9, 0x920e, 0x4d6c, 0xb3, 0x98, 0x53, 0x84, 0x4a, 0x0b, 0x82, 0x94);
794   
795    /// <summary>
796    /// DomainRole Action
797    /// Description for HeuristicLab.SimulationCore.ActionReferencesListeners.Action
798    /// </summary>
799    [DslDesign::DisplayNameResource("HeuristicLab.SimulationCore.ActionReferencesListeners/Action.DisplayName", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
800    [DslDesign::DescriptionResource("HeuristicLab.SimulationCore.ActionReferencesListeners/Action.Description", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
801    [DslModeling::DomainRole(DslModeling::DomainRoleOrder.Source, PropertyName = "Listeners", PropertyDisplayNameKey="HeuristicLab.SimulationCore.ActionReferencesListeners/Action.PropertyDisplayName",  PropagatesCopy = DslModeling::PropagatesCopyOption.DoNotPropagateCopy, Multiplicity = DslModeling::Multiplicity.ZeroMany)]
802    [DslModeling::DomainObjectId("0e8492e9-920e-4d6c-b398-53844a0b8294")]
803    public virtual Action Action
804    {
805      [global::System.Diagnostics.DebuggerStepThrough]
806      get
807      {
808        return (Action)DslModeling::DomainRoleInfo.GetRolePlayer(this, ActionDomainRoleId);
809      }
810      [global::System.Diagnostics.DebuggerStepThrough]
811      set
812      {
813        DslModeling::DomainRoleInfo.SetRolePlayer(this, ActionDomainRoleId, value);
814      }
815    }
816       
817    #endregion
818    #region Static methods to access Actions of a Activity
819    /// <summary>
820    /// Gets a list of Actions.
821    /// </summary>
822    [global::System.Diagnostics.DebuggerStepThrough]
823    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
824    public static DslModeling::LinkedElementCollection<Action> GetActions(Activity element)
825    {
826      return GetRoleCollection<DslModeling::LinkedElementCollection<Action>, Action>(element, ActivityDomainRoleId);
827    }
828    #endregion
829    #region Activity domain role code
830   
831    /// <summary>
832    /// Activity domain role Id.
833    /// </summary>
834    public static readonly global::System.Guid ActivityDomainRoleId = new global::System.Guid(0xab4b8a78, 0xaa3e, 0x4315, 0x8b, 0xfd, 0xe4, 0x11, 0x26, 0xa5, 0xbc, 0x7a);
835   
836    /// <summary>
837    /// DomainRole Activity
838    /// Description for HeuristicLab.SimulationCore.ActionReferencesListeners.Activity
839    /// </summary>
840    [DslDesign::DisplayNameResource("HeuristicLab.SimulationCore.ActionReferencesListeners/Activity.DisplayName", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
841    [DslDesign::DescriptionResource("HeuristicLab.SimulationCore.ActionReferencesListeners/Activity.Description", typeof(global::HeuristicLab.SimulationCore.HLSimDomainModel), "HeuristicLab.SimulationCore.GeneratedCode.DomainModelResx")]
842    [DslModeling::DomainRole(DslModeling::DomainRoleOrder.Target, PropertyName = "Actions", PropertyDisplayNameKey="HeuristicLab.SimulationCore.ActionReferencesListeners/Activity.PropertyDisplayName",  PropagatesCopy = DslModeling::PropagatesCopyOption.DoNotPropagateCopy, Multiplicity = DslModeling::Multiplicity.ZeroMany)]
843    [DslModeling::DomainObjectId("ab4b8a78-aa3e-4315-8bfd-e41126a5bc7a")]
844    public virtual Activity Activity
845    {
846      [global::System.Diagnostics.DebuggerStepThrough]
847      get
848      {
849        return (Activity)DslModeling::DomainRoleInfo.GetRolePlayer(this, ActivityDomainRoleId);
850      }
851      [global::System.Diagnostics.DebuggerStepThrough]
852      set
853      {
854        DslModeling::DomainRoleInfo.SetRolePlayer(this, ActivityDomainRoleId, value);
855      }
856    }
857       
858    #endregion
859    #region Static methods to access Listeners of a Action
860    /// <summary>
861    /// Gets a list of Listeners.
862    /// </summary>
863    [global::System.Diagnostics.DebuggerStepThrough]
864    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
865    public static DslModeling::LinkedElementCollection<Activity> GetListeners(Action element)
866    {
867      return GetRoleCollection<DslModeling::LinkedElementCollection<Activity>, Activity>(element, ActionDomainRoleId);
868    }
869    #endregion
870    #region Action link accessor
871    /// <summary>
872    /// Get the list of ActionReferencesListeners links to a Action.
873    /// </summary>
874    [global::System.Diagnostics.DebuggerStepThrough]
875    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
876    public static global::System.Collections.ObjectModel.ReadOnlyCollection<global::HeuristicLab.SimulationCore.ActionReferencesListeners> GetLinksToListeners ( global::HeuristicLab.SimulationCore.Action actionInstance )
877    {
878      return DslModeling::DomainRoleInfo.GetElementLinks<global::HeuristicLab.SimulationCore.ActionReferencesListeners>(actionInstance, global::HeuristicLab.SimulationCore.ActionReferencesListeners.ActionDomainRoleId);
879    }
880    #endregion
881    #region Activity link accessor
882    /// <summary>
883    /// Get the list of ActionReferencesListeners links to a Activity.
884    /// </summary>
885    [global::System.Diagnostics.DebuggerStepThrough]
886    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
887    public static global::System.Collections.ObjectModel.ReadOnlyCollection<global::HeuristicLab.SimulationCore.ActionReferencesListeners> GetLinksToActions ( global::HeuristicLab.SimulationCore.Activity activityInstance )
888    {
889      return DslModeling::DomainRoleInfo.GetElementLinks<global::HeuristicLab.SimulationCore.ActionReferencesListeners>(activityInstance, global::HeuristicLab.SimulationCore.ActionReferencesListeners.ActivityDomainRoleId);
890    }
891    #endregion
892    #region ActionReferencesListeners instance accessors
893   
894    /// <summary>
895    /// Get any ActionReferencesListeners links between a given Action and a Activity.
896    /// </summary>
897    [global::System.Diagnostics.DebuggerStepThrough]
898    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
899    public static global::System.Collections.ObjectModel.ReadOnlyCollection<global::HeuristicLab.SimulationCore.ActionReferencesListeners> GetLinks( global::HeuristicLab.SimulationCore.Action source, global::HeuristicLab.SimulationCore.Activity target )
900    {
901      global::System.Collections.Generic.List<global::HeuristicLab.SimulationCore.ActionReferencesListeners> outLinks = new global::System.Collections.Generic.List<global::HeuristicLab.SimulationCore.ActionReferencesListeners>();
902      global::System.Collections.Generic.IList<global::HeuristicLab.SimulationCore.ActionReferencesListeners> links = DslModeling::DomainRoleInfo.GetElementLinks<global::HeuristicLab.SimulationCore.ActionReferencesListeners>(source, global::HeuristicLab.SimulationCore.ActionReferencesListeners.ActionDomainRoleId);
903      foreach ( global::HeuristicLab.SimulationCore.ActionReferencesListeners link in links )
904      {
905        if ( target.Equals(link.Activity) )
906        {
907          outLinks.Add(link);
908        }
909      }
910      return outLinks.AsReadOnly();
911    }
912    /// <summary>
913    /// Get the one ActionReferencesListeners link between a given Actionand a Activity.
914    /// </summary>
915    [global::System.Diagnostics.DebuggerStepThrough]
916    [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1011")]
917    public static global::HeuristicLab.SimulationCore.ActionReferencesListeners GetLink( global::HeuristicLab.SimulationCore.Action source, global::HeuristicLab.SimulationCore.Activity target )
918    {
919      global::System.Collections.Generic.IList<global::HeuristicLab.SimulationCore.ActionReferencesListeners> links = DslModeling::DomainRoleInfo.GetElementLinks<global::HeuristicLab.SimulationCore.ActionReferencesListeners>(source, global::HeuristicLab.SimulationCore.ActionReferencesListeners.ActionDomainRoleId);
920      foreach ( global::HeuristicLab.SimulationCore.ActionReferencesListeners link in links )
921      {
922        if ( target.Equals(link.Activity) )
923        {
924          return link;
925        }
926      }
927      return null;
928    }
929   
930    #endregion
931  }
932}
Note: See TracBrowser for help on using the repository browser.