Exemplo n.º 1
0
        public TopoInfo(Area topo)
        {
            Name = topo.Name;
            KKS  = topo.KKS;
            Type = topo.Type;



            if (Type == AreaTypes.分组 || Type == AreaTypes.区域)
            {
                BoundInfo = null;
            }
            else
            {
                BoundInfo = new BoundInfo(topo.InitBound);
                BoundInfo.IsCreateAreaByData = topo.IsCreateAreaByData;
                BoundInfo.IsOnAlarmArea      = topo.IsOnAlarmArea;
                BoundInfo.IsOnLocationArea   = topo.IsOnLocationArea;
            }

            if (topo.Children != null)
            {
                foreach (Area child in topo.Children)
                {
                    AddChild(new TopoInfo(child));
                }
            }
        }
Exemplo n.º 2
0
        public TopoInfo(Area topo, bool containCAD = true)
        {
            Name = topo.Name;
            KKS  = topo.KKS;
            Type = topo.Type;



            if (Type == AreaTypes.分组 || Type == AreaTypes.区域)
            {
                BoundInfo = null;
            }
            else
            {
                BoundInfo = new BoundInfo(topo);
                BoundInfo.IsCreateAreaByData = topo.IsCreateAreaByData;
                BoundInfo.IsOnAlarmArea      = topo.IsOnAlarmArea;
                BoundInfo.IsOnLocationArea   = topo.IsOnLocationArea;
            }

            if (topo.Children != null)
            {
                foreach (Area child in topo.Children)
                {
                    if (containCAD == false && Type == AreaTypes.CAD)
                    {
                        continue;
                    }
                    else
                    {
                        AddChild(new TopoInfo(child));
                    }
                }
            }
        }
Exemplo n.º 3
0
        public TopoInfo(PhysicalTopology topo)
        {
            Name = topo.Name;
            KKS  = topo.Nodekks == null ? "" : topo.Nodekks.KKS;
            Type = topo.Type;
            if (Type == Types.分组 || Type == Types.区域)
            {
                BoundInfo = null;
            }
            else
            {
                BoundInfo = new BoundInfo(topo.InitBound);
            }

            if (topo.Children != null)
            {
                foreach (PhysicalTopology child in topo.Children)
                {
                    AddChild(new TopoInfo(child));
                }
            }
        }