network loads and saves NetShapes
This commit is contained in:
		@@ -68,6 +68,7 @@ namespace EduNetworkBuilder
 | 
			
		||||
        private List<Image> PacketImages = new List<Image>();
 | 
			
		||||
        private List<PingTestStatus> PingTestStats = new List<PingTestStatus>();
 | 
			
		||||
        private List<string> BrokenItems = new List<string>();
 | 
			
		||||
        private List<NetShape> Shapes = new List<NetShape>(); //For storing simple shapes which are drawn on the network
 | 
			
		||||
        public bool IsRandomNetwork = false;
 | 
			
		||||
 | 
			
		||||
        private List<AnimationClass> Animations = new List<AnimationClass>();
 | 
			
		||||
@@ -271,6 +272,10 @@ namespace EduNetworkBuilder
 | 
			
		||||
                           StartingHelpLevel = NB.ParseEnum<NetTestVerbosity>(Individual.InnerText);
 | 
			
		||||
                           HintsToDisplay = StartingHelpLevel;
 | 
			
		||||
                            break;
 | 
			
		||||
                        case "shape":
 | 
			
		||||
                            NetShape nShape = new NetShape(Individual);
 | 
			
		||||
                            Shapes.Add(nShape);
 | 
			
		||||
                            break;
 | 
			
		||||
                        case "vlanname":
 | 
			
		||||
                            if (Individual.Attributes != null && Individual.Attributes["ID"] != null)
 | 
			
		||||
                            {
 | 
			
		||||
@@ -418,6 +423,10 @@ namespace EduNetworkBuilder
 | 
			
		||||
            {
 | 
			
		||||
                writer.WriteElementString("tag",HT.ToString());
 | 
			
		||||
            }
 | 
			
		||||
            foreach(NetShape shape in Shapes)
 | 
			
		||||
            {
 | 
			
		||||
                shape.Save(writer);
 | 
			
		||||
            }
 | 
			
		||||
            foreach(VLANName VLAN in VlanNames)
 | 
			
		||||
            {
 | 
			
		||||
                writer.WriteStartElement("VLANName");
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user