/// <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) { IDPL dPLItem = item.As<IDPL>(); if (((dPLItem != null) && this._parent.DPL.Remove(dPLItem))) { return true; } ILPL lPLItem = item.As<ILPL>(); if (((lPLItem != null) && this._parent.LPL.Remove(lPLItem))) { return true; } ICSD cSDItem = item.As<ICSD>(); if (((cSDItem != null) && this._parent.CSD.Remove(cSDItem))) { return true; } IC_PrimitiveCDC c_PrimitiveCDCItem = item.As<IC_PrimitiveCDC>(); if (((c_PrimitiveCDCItem != null) && this._parent.C_PrimitiveCDC.Remove(c_PrimitiveCDCItem))) { return true; } return false; }
/// <summary> /// Adds the given element to the collection /// </summary> /// <param name="item">The item to add</param> public override void Add(IModelElement item) { IDPL dPLCasted = item.As<IDPL>(); if ((dPLCasted != null)) { this._parent.DPL.Add(dPLCasted); } ILPL lPLCasted = item.As<ILPL>(); if ((lPLCasted != null)) { this._parent.LPL.Add(lPLCasted); } ICSD cSDCasted = item.As<ICSD>(); if ((cSDCasted != null)) { this._parent.CSD.Add(cSDCasted); } IC_PrimitiveCDC c_PrimitiveCDCCasted = item.As<IC_PrimitiveCDC>(); if ((c_PrimitiveCDCCasted != null)) { this._parent.C_PrimitiveCDC.Add(c_PrimitiveCDCCasted); } }
/// <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 NumPtsProxy(ICSD modelElement) : base(modelElement, "numPts") { }