/// <summary>
        /// Create graphic object for data element.
        /// </summary>
        /// <param name="data">Data object to show on map.</param>
        /// <param name="typeOfData">Type of data.</param>
        /// <param name="graphicObjectType">Graphic, associated with data object.</param>
        /// <param name="layerContext">Layer context.</param>
        /// <returns>Created graphic object.</returns>
        public Graphic CreateGraphic(object data, Type typeOfData, Type graphicObjectType, object layerContext)
        {
            Graphic graphic = null;
            Type    type    = data.GetType();

            if (type == typeof(Location))
            {
                graphic = LocationGraphicObject.Create((Location)data);
            }
            else if (type == typeof(Order))
            {
                graphic = OrderGraphicObject.Create((Order)data);
            }
            else if (type == typeof(EditingMarker))
            {
                graphic = EditMarkerGraphicObject.Create((EditingMarker)data);
            }
            else if (type == typeof(AddressCandidate))
            {
                graphic = CandidateGraphicObject.Create((AddressCandidate)data);
            }
            else if (type == typeof(Route))
            {
                graphic = RouteGraphicObject.Create((Route)data);
            }
            else if (type == typeof(Stop))
            {
                graphic = StopGraphicObject.Create((Stop)data);
            }
            else if (type == typeof(Zone))
            {
                graphic = ZoneGraphicObject.Create((Zone)data);
            }
            else if (type == typeof(Barrier))
            {
                graphic = BarrierGraphicObject.Create((Barrier)data);
            }
            else
            {
                Debug.Assert(false);
            }

            DataGraphicObject dataGraphicObject = graphic as DataGraphicObject;

            if (dataGraphicObject != null)
            {
                dataGraphicObject.ParentLayer = this;
                _graphicDictionary.Add(data, dataGraphicObject);
            }

            return(graphic);
        }
        /// <summary>
        /// React on symbology settings changed.
        /// </summary>
        /// <param name="sender">Ignored.</param>
        /// <param name="e">Ignored.</param>
        private void _SymbologyManagerOnSettingsChanged(object sender, EventArgs e)
        {
            foreach (Graphic graphic in MapLayer)
            {
                StopGraphicObject stopGraphic = graphic as StopGraphicObject;
                if (stopGraphic != null)
                {
                    stopGraphic.InitSymbology();
                }

                OrderGraphicObject orderGraphic = graphic as OrderGraphicObject;
                if (orderGraphic != null)
                {
                    SymbologyManager.InitGraphic(orderGraphic);
                }
            }
        }