예제 #1
0
 public FlowOrderMap(FlowOrderCollection orders)
 {
     foreach (FlowOrder o in orders)
     {
         this.AddOrder(o);
     }
 }
예제 #2
0
        private void AddOrder(FlowOrder order)
        {
            FlowOrderCollection l = this.m_Map.GetItemExact(order.Iteration, order.Timestep);

            if (l == null)
            {
                l = new FlowOrderCollection();
                this.m_Map.AddItem(order.Iteration, order.Timestep, l);
            }

            l.Add(order);
            this.m_HasItems = true;
        }
예제 #3
0
        public FlowOrderCollection GetOrders(int iteration, int timestep)
        {
            if (!this.m_HasItems)
            {
                return(null);
            }

            FlowOrderCollection l = this.m_Map.GetItem(iteration, timestep);

            if (l == null)
            {
                return(null);
            }

            Debug.Assert(l.Count > 0);
            return(l);
        }