Beispiel #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)
            {
                IGmlFeatureStyle gmlFeatureStylesCasted = item.As <IGmlFeatureStyle>();

                if ((gmlFeatureStylesCasted != null))
                {
                    this._parent.GmlFeatureStyles.Add(gmlFeatureStylesCasted);
                }
            }
Beispiel #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)
            {
                IGmlFeatureStyle gmlFeatureStyleItem = item.As <IGmlFeatureStyle>();

                if (((gmlFeatureStyleItem != null) &&
                     this._parent.GmlFeatureStyles.Remove(gmlFeatureStyleItem)))
                {
                    return(true);
                }
                return(false);
            }
Beispiel #3
0
            /// <summary>
            /// Adds the given element to the collection
            /// </summary>
            /// <param name="item">The item to add</param>
            public override void Add(IModelElement item)
            {
                IGmlFeatureStyle gmlFeatureStylesCasted = item.As <IGmlFeatureStyle>();

                if ((gmlFeatureStylesCasted != null))
                {
                    this._parent.GmlFeatureStyles.Add(gmlFeatureStylesCasted);
                }
                if ((this._parent.GmlBaseSymbol == null))
                {
                    IGmlBaseSymbol gmlBaseSymbolCasted = item.As <IGmlBaseSymbol>();
                    if ((gmlBaseSymbolCasted != null))
                    {
                        this._parent.GmlBaseSymbol = gmlBaseSymbolCasted;
                        return;
                    }
                }
            }
Beispiel #4
0
 /// <summary>
 /// Adds the given element to the collection
 /// </summary>
 /// <param name="item">The item to add</param>
 public override void Add(IModelElement item)
 {
     if ((this._parent.GmlLableStyle == null))
     {
         IGmlLabelStyle gmlLableStyleCasted = item.As <IGmlLabelStyle>();
         if ((gmlLableStyleCasted != null))
         {
             this._parent.GmlLableStyle = gmlLableStyleCasted;
             return;
         }
     }
     if ((this._parent.GmlFeatureStyle == null))
     {
         IGmlFeatureStyle gmlFeatureStyleCasted = item.As <IGmlFeatureStyle>();
         if ((gmlFeatureStyleCasted != null))
         {
             this._parent.GmlFeatureStyle = gmlFeatureStyleCasted;
             return;
         }
     }
 }
Beispiel #5
0
            /// <summary>
            /// Adds the given element to the collection
            /// </summary>
            /// <param name="item">The item to add</param>
            public override void Add(IModelElement item)
            {
                if ((this._parent.GmlFeatureStyle == null))
                {
                    IGmlFeatureStyle gmlFeatureStyleCasted = item.As <IGmlFeatureStyle>();
                    if ((gmlFeatureStyleCasted != null))
                    {
                        this._parent.GmlFeatureStyle = gmlFeatureStyleCasted;
                        return;
                    }
                }
                IGmlGeometryStyle gmlGeometryStylesCasted = item.As <IGmlGeometryStyle>();

                if ((gmlGeometryStylesCasted != null))
                {
                    this._parent.GmlGeometryStyles.Add(gmlGeometryStylesCasted);
                }
                IGmlTopologyStyle gmlTopologyStylesCasted = item.As <IGmlTopologyStyle>();

                if ((gmlTopologyStylesCasted != null))
                {
                    this._parent.GmlTopologyStyles.Add(gmlTopologyStylesCasted);
                }
            }