Esempio n. 1
0
        public static void read(geometry.Polygon data, Halodi.CDR.CDRDeserializer cdr)
        {
            int points_length = cdr.read_type_2();

            data.points = new System.Collections.Generic.List <geometry.Vector>(points_length);
            for (int i = 0; i < points_length; i++)
            {
                geometry.Vector new_points = geometry.VectorPubSubType.Create();
                geometry.VectorPubSubType.read(new_points, cdr);
                data.points.Add(new_points);
            }
        }
 public void Set(Polygon other)
 {
     if (other.points == null)
     {
         points = null;
     }
     else
     {
         points = new System.Collections.Generic.List <geometry.Vector>(other.points.Count);
         for (int i4 = 0; i4 < other.points.Count; i4++)
         {
             if (other.points[i4] == null)
             {
                 points.Add(null);
             }
             else
             {
                 geometry.Vector newElement = geometry.VectorPubSubType.Create();
                 geometry.VectorPubSubType.Copy(other.points[i4], newElement);
                 points.Add(newElement);
             }
         }
     }
 }