• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

DomCR / ACadSharp / 19747691062

27 Nov 2025 08:58PM UTC coverage: 77.833% (-0.2%) from 78.079%
19747691062

Pull #898

github

web-flow
Merge 7246c0e16 into b4f4477ec
Pull Request #898: DimensionStyle Overrides

7643 of 10693 branches covered (71.48%)

Branch coverage included in aggregate %.

481 of 674 new or added lines in 7 files covered. (71.36%)

54 existing lines in 7 files now uncovered.

28210 of 35371 relevant lines covered (79.75%)

134840.38 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

70.45
/src/ACadSharp/IO/DXF/DxfStreamReader/DxfEntitiesSectionReader.cs
1
using ACadSharp.Blocks;
2
using ACadSharp.IO.Templates;
3
using System;
4

5
namespace ACadSharp.IO.DXF
6
{
7
        internal class DxfEntitiesSectionReader : DxfSectionReaderBase
8
        {
9
                public DxfEntitiesSectionReader(IDxfStreamReader reader, DxfDocumentBuilder builder)
10
                        : base(reader, builder)
368✔
11
                {
368✔
12
                }
368✔
13

14
                public override void Read()
15
                {
368✔
16
                        //Advance to the first value in the section
17
                        this._reader.ReadNext();
368✔
18

19
                        //Loop until the section ends
20
                        while (this._reader.ValueAsString != DxfFileToken.EndSection)
49,762✔
21
                        {
49,394✔
22
                                CadEntityTemplate template = null;
49,394✔
23

24
                                try
25
                                {
49,394✔
26
                                        template = this.readEntity();
49,394✔
27
                                }
49,394✔
28
                                catch (Exception ex)
×
29
                                {
×
30
                                        if (!this._builder.Configuration.Failsafe)
×
UNCOV
31
                                                throw;
×
32

UNCOV
33
                                        this._builder.Notify($"Error while reading an entity at line {this._reader.Position}", NotificationType.Error, ex);
×
34

35
                                        while (this._reader.DxfCode != DxfCode.Start)
×
36
                                                this._reader.ReadNext();
×
UNCOV
37
                                }
×
38

39
                                if (template == null)
49,394✔
UNCOV
40
                                        continue;
×
41

42
                                //Add the object and the template to the builder
43
                                this._builder.AddTemplate(template);
49,394✔
44

45
                                if (template.OwnerHandle == null)
49,394✔
46
                                {
6,360✔
47
                                        this._builder.ModelSpaceEntities.Add(template.CadObject);
6,360✔
48
                                }
6,360✔
49
                                else if (this._builder.TryGetObjectTemplate(template.OwnerHandle, out ICadOwnerTemplate owner))
43,034✔
50
                                {
41,126✔
51
                                        owner.OwnedObjectsHandlers.Add(template.CadObject.Handle);
41,126✔
52
                                }
41,126✔
53
                        }
49,394✔
54
                }
368✔
55
        }
56
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc