Inheritance: ENTITIE
Example #1
0
        protected override Property ReadSonClass(Property prop)
        {
            if (prop.Code == 0 && prop.Value != "ENDBLK")
            {
                switch (prop.Value)
                {
                //case "C3DFACE":
                //case "C3DSOLID":
                //case "ACAD_PROXY_ENTITY":
                case "ARC":
                    var arc = new ARC(DXFData, prop);
                    ARCList.Add(arc);
                    return(arc.ReadProperties());

                //case "ATTDEF":
                //case "ATTRIB":
                //case "BODY":
                case "CIRCLE":
                    var circle = new CIRCLE(DXFData, prop);
                    CIRCLEList.Add(circle);
                    return(circle.ReadProperties());

                //case "DIMENSION":
                case "ELLIPSE":
                    var ellipes = new ELLIPSE(DXFData, prop);
                    ELLIPSEList.Add(ellipes);
                    return(ellipes.ReadProperties());

                //case "HATCH":
                //case "HELIX":
                //case "IMAGE":
                case "INSERT":
                    var insert = new INSERT(DXFData, prop);
                    INSERTList.Add(insert);
                    return(insert.ReadProperties());

                //case "LEADER":
                //case "LIGHT":
                case "LINE":
                    var line = new LINE(DXFData, prop);
                    LINEList.Add(line);
                    return(line.ReadProperties());

                case "LWPOLYLINE":
                    var lwpolyline = new LWPOLYLINE(DXFData, prop);
                    LWPOLYLINEList.Add(lwpolyline);
                    return(lwpolyline.ReadProperties());

                //case "MESH":
                //case "MLINE":
                //case "MLEADERSTYLE":
                //case "MLEADER":
                //case "MTEXT":
                //case "OLEFRAME":
                //case "OLE2FRAME":
                //case "POINT":
                //case "POLYLINE":
                //case "RAY":
                //case "REGION":
                //case "SECTION":
                //case "SEQEND":
                //case "SHAPE":
                //case "SOLID":
                //case "SPLINE":
                //case "SUN":
                //case "SURFACE":
                //case "TABLE":
                case "TEXT":
                    var text = new TEXT(DXFData, prop);
                    TEXTList.Add(text);
                    return(text.ReadProperties());

                //case "TOLERANCE":
                //case "TRACE":
                //case "UNDERLAY":
                //case "VERTEX":
                //case "VIEWPORT":
                //case "WIPEOUT":
                //case "XLINE":

                default:
                    return(CreateSonClass(new ENTITIE(DXFData, prop)));
                }
            }
            else
            {
                return(base.ReadSonClass(prop));
            }
        }
Example #2
0
 protected override Property ReadSonClass(Property prop)
 {
     if (prop.Code == 0 && prop.Value != "ENDSEC")
     {
         switch (prop.Value)
         {
             //case "C3DFACE":
             //case "C3DSOLID":
             //case "ACAD_PROXY_ENTITY":
             case "ARC":
                 var arc = new ARC(DXFData, prop);
                 ARCList.Add(arc);
                 return arc.ReadProperties();
             //case "ATTDEF":
             //case "ATTRIB":
             //case "BODY":
             case "CIRCLE":
                 var circle = new CIRCLE(DXFData, prop);
                 CIRCLEList.Add(circle);
                 return circle.ReadProperties();
             //case "DIMENSION":
             case "ELLIPSE":
                 var ellipes = new ELLIPSE(DXFData, prop);
                 ELLIPSEList.Add(ellipes);
                 return ellipes.ReadProperties();
             //case "HATCH":
             //case "HELIX":
             //case "IMAGE":
             case "INSERT":
                 var insert = new INSERT(DXFData, prop);
                  INSERTList.Add(insert);
                  return insert.ReadProperties();
             //case "LEADER":
             //case "LIGHT":
             case "LINE":
                 var line = new LINE(DXFData, prop);
                 LINEList.Add(line);
                 return line.ReadProperties();
             case "LWPOLYLINE":
                 var lwpolyline = new LWPOLYLINE(DXFData, prop);
                 LWPOLYLINEList.Add(lwpolyline);
                 return lwpolyline.ReadProperties();
             //case "MESH":
             //case "MLINE":
             //case "MLEADERSTYLE":
             //case "MLEADER":
             //case "MTEXT":
             //case "OLEFRAME":
             //case "OLE2FRAME":
             //case "POINT":
             //case "POLYLINE":
             //case "RAY":
             //case "REGION":
             //case "SECTION":
             //case "SEQEND":
             //case "SHAPE":
             //case "SOLID":
             //case "SPLINE":
             //case "SUN":
             //case "SURFACE":
             //case "TABLE":
             case "TEXT":
                 var text = new TEXT(DXFData, prop);
                 TEXTList.Add(text);
                 return text.ReadProperties();
             //case "TOLERANCE":
             //case "TRACE":
             //case "UNDERLAY":
             //case "VERTEX":
             //case "VIEWPORT":
             //case "WIPEOUT":
             //case "XLINE":
             default:
                 return CreateSonClass(new ENTITIE(DXFData, prop));
         }
     }
     else
     {
         return base.ReadSonClass(prop);
     }
 }