/// <summary> /// Set symbol if not yet set or geometry type changed. /// </summary> private void _SetSymbol() { if (_geometryType == null || _geometryType != _barrier.Geometry.GetType()) { _geometryType = _barrier.Geometry.GetType(); if (_geometryType == typeof(ESRI.ArcLogistics.Geometry.Point)) { Symbol = new BarrierSymbol(); } else if (_geometryType == typeof(ESRI.ArcLogistics.Geometry.Polygon)) { Symbol = new BarrierPolygonSymbol(); } else if (_geometryType == typeof(ESRI.ArcLogistics.Geometry.Polyline)) { Symbol = new BarrierPolylineSymbol(); } else { Debug.Assert(false); } } }
public BarrierModel([NotNull] BarrierSymbol symbol) : base(symbol, ModelType.Barrier) { Timeout = TimeSpan.Parse(symbol.Timeout.Value); }