/// <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) { ILandProperty landPropertyItem = item.As <ILandProperty>(); if (((landPropertyItem != null) && this._parent.LandProperties.Remove(landPropertyItem))) { return(true); } IAsset assetItem = item.As <IAsset>(); if (((assetItem != null) && this._parent.Assets.Remove(assetItem))) { return(true); } ISeal sealItem = item.As <ISeal>(); if (((sealItem != null) && this._parent.Seals.Remove(sealItem))) { 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) { ILandProperty landPropertiesCasted = item.As <ILandProperty>(); if ((landPropertiesCasted != null)) { this._parent.LandProperties.Add(landPropertiesCasted); } IAsset assetsCasted = item.As <IAsset>(); if ((assetsCasted != null)) { this._parent.Assets.Add(assetsCasted); } ISeal sealsCasted = item.As <ISeal>(); if ((sealsCasted != null)) { this._parent.Seals.Add(sealsCasted); } }
public void SetSeal(ISeal seal) { Seal = seal; }
/// <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 KindProxy(ISeal modelElement) : base(modelElement, "kind") { }
/// <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 ConditionProxy(ISeal modelElement) : base(modelElement, "condition") { }
public SealController() { Seal = new Seal(); }