Exemplo n.º 1
0
            /// <summary>
            /// Adds the given element to the collection
            /// </summary>
            /// <param name="item">The item to add</param>
            public override void Add(IModelElement item)
            {
                IContinuousSample samplesCasted = item.As <IContinuousSample>();

                if ((samplesCasted != null))
                {
                    this._parent.Samples.Add(samplesCasted);
                }
            }
Exemplo n.º 2
0
            /// <summary>
            /// Removes the given item from the collection
            /// </summary>
            /// <returns>True, if the item was removed, otherwise False</returns>
            /// <param name="item">The item that should be removed</param>
            public override bool Remove(IModelElement item)
            {
                IContinuousSample continuousSampleItem = item.As <IContinuousSample>();

                if (((continuousSampleItem != null) &&
                     this._parent.Samples.Remove(continuousSampleItem)))
                {
                    return(true);
                }
                return(false);
            }
Exemplo n.º 3
0
 /// <summary>
 /// Creates a new observable property access proxy
 /// </summary>
 /// <param name="modelElement">The model instance element for which to create the property access proxy</param>
 public ProbabilityProxy(IContinuousSample modelElement) :
     base(modelElement, "probability")
 {
 }
Exemplo n.º 4
0
 /// <summary>
 /// Creates a new observable property access proxy
 /// </summary>
 /// <param name="modelElement">The model instance element for which to create the property access proxy</param>
 public ValueProxy(IContinuousSample modelElement) :
     base(modelElement, "value")
 {
 }