Skip to content

Commit

Permalink
flags
Browse files Browse the repository at this point in the history
  • Loading branch information
DomCR committed Jun 21, 2023
1 parent 5ed73b4 commit 7979ad2
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions ACadSharp/IO/DXF/DxfStreamReader/DxfSectionReaderBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -450,21 +450,21 @@ protected void readMapped<T>(CadObject cadObject, CadTemplate template)
continue;
}

if (dxfProperty.ReferenceType == DxfReferenceType.Handle)
if (dxfProperty.ReferenceType.HasFlag(DxfReferenceType.Handle))
{
if (!template.AddHandle(this._reader.Code, this._reader.ValueAsHandle))
this._builder.Notify($"Dxf referenced code {this._reader.Code} not implemented in the {template.GetType().Name} for {typeof(T)} | value : {this._reader.ValueAsHandle}");
}
else if (dxfProperty.ReferenceType == DxfReferenceType.Name)
else if (dxfProperty.ReferenceType.HasFlag(DxfReferenceType.Name))
{
if (!template.AddName(this._reader.Code, this._reader.ValueAsString))
this._builder.Notify($"Dxf named referenced code {this._reader.Code} not implemented in the {template.GetType().Name} for {typeof(T)} | value : {this._reader.ValueAsString}");
}
else if (dxfProperty.ReferenceType == DxfReferenceType.Count)
else if (dxfProperty.ReferenceType.HasFlag(DxfReferenceType.Count))
{
//Do nothing just marks the amount
}
else if (dxfProperty.ReferenceType == DxfReferenceType.Unprocess)
else if (dxfProperty.ReferenceType.HasFlag(DxfReferenceType.Unprocess) || dxfProperty.ReferenceType.HasFlag(DxfReferenceType.Ignored))
{
this._reader.ReadNext();
continue;
Expand Down

0 comments on commit 7979ad2

Please sign in to comment.