Ejemplo n.º 1
0
        /// <summary>
        /// Constructor
        /// </summary>
        /// <param name="wayID">Identification about Way</param>
        /// <param name="segment">Segment containing this Way</param>
        /// <param name="lanes">Lanes this Way contains</param>
        public Way(WayID wayID, Segment segment, ICollection <Lane> lanes)
        {
            this.wayID   = wayID;
            this.segment = segment;

            // Create Dictionary
            this.lanes = new Dictionary <LaneID, Lane>();
            foreach (Lane lane in lanes)
            {
                this.lanes.Add(lane.LaneID, lane);
            }
        }
Ejemplo n.º 2
0
 public override bool Equals(object obj)
 {
     if (obj is WayID)
     {
         WayID wid = (WayID)obj;
         return(wid.wayNumber == wayNumber && wid.segmentID.Equals(segmentID));
     }
     else
     {
         return(false);
     }
 }
Ejemplo n.º 3
0
        /// <summary>
        /// Constructor
        /// </summary>
        /// <param name="wayID">Identification about Way</param>
        /// <param name="segment">Segment containing this Way</param>
        /// <param name="lanes">Lanes this Way contains</param>
        public Way(WayID wayID, Segment segment, ICollection<Lane> lanes)
        {
            this.wayID = wayID;
            this.segment = segment;

            // Create Dictionary
            this.lanes = new Dictionary<LaneID, Lane>();
            foreach (Lane lane in lanes)
            {
                this.lanes.Add(lane.LaneID, lane);
            }
        }
Ejemplo n.º 4
0
 /// <summary>
 /// Constructor
 /// </summary>
 /// <param name="wayID">Identification about Way</param>
 /// <param name="segment">Segment containing this Way</param>
 public Way(WayID wayID, Segment segment)
 {
     this.wayID   = wayID;
     this.segment = segment;
     lanes        = new Dictionary <LaneID, Lane>();
 }
Ejemplo n.º 5
0
 /// <summary>
 /// Constructor
 /// </summary>
 /// <param name="wayID">Identification about Way</param>
 /// <param name="segment">Segment containing this Way</param>
 public Way(WayID wayID, Segment segment)
 {
     this.wayID = wayID;
     this.segment = segment;
     lanes = new Dictionary<LaneID, Lane>();
 }
Ejemplo n.º 6
0
 /// <summary>
 /// Constructor
 /// </summary>
 /// <param name="wayID">Way identification information</param>
 /// <param name="laneNumber">Number of Lane in the Way</param>
 public LaneID(WayID wayID, int laneNumber)
 {
     this.wayID      = wayID;
     this.laneNumber = laneNumber;
 }
Ejemplo n.º 7
0
 /// <summary>
 /// Constructor
 /// </summary>
 /// <param name="wayID">Way identification information</param>
 /// <param name="laneNumber">Number of Lane in the Way</param>
 public LaneID(WayID wayID, int laneNumber)
 {
     this.wayID = wayID;
     this.laneNumber = laneNumber;
 }