Ejemplo n.º 1
0
        public static Polyline ConvertToPolyline(this QuickTransaction tr, Entity id)
        {
            switch (id)
            {
            case Polyline poly:
                return(poly);

            case Line line:
                return(LineToPoly(tr, line));

            case Arc arc:
                return(ArcToPoly(tr, arc));

            case Circle c:
                return(CircleToPoly(tr, c));

            case Spline sp:
                return(SplineToPoly(tr, sp));

            case Polyline2d p2d:
                return(ConvertToPolyline(p2d, tr));

            default:
                tr.WriteLine("Unsupported to polyline conversion: " + id.GetType().FullName);
                return(null);
            }
        }