mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-09 13:22:24 +03:00
0026715: Problems in reading STEP short names in complex entities
Add function to find next part of complex entity by name or short name. Add missing short names. Test cases for issue CR26715
This commit is contained in:
@@ -42,7 +42,7 @@ void RWStepRepr_RWCompGroupShAspAndCompShAspAndDatumFeatAndShAsp::ReadStep
|
||||
const Handle(StepRepr_CompGroupShAspAndCompShAspAndDatumFeatAndShAsp)& ent) const
|
||||
{
|
||||
Standard_Integer num = 0;
|
||||
data->NamedForComplex("SHAPE_ASPECT", num0, num, ach);
|
||||
data->NamedForComplex("SHAPE_ASPECT","SHPASP", num0, num, ach);
|
||||
if (!data->CheckNbParams(num, 4, ach, "shape_aspect")) return;
|
||||
|
||||
Handle(TCollection_HAsciiString) aName;
|
||||
|
@@ -42,7 +42,7 @@ void RWStepRepr_RWCompShAspAndDatumFeatAndShAsp::ReadStep
|
||||
const Handle(StepRepr_CompShAspAndDatumFeatAndShAsp)& ent) const
|
||||
{
|
||||
Standard_Integer num = 0;
|
||||
data->NamedForComplex("SHAPE_ASPECT", num0, num, ach);
|
||||
data->NamedForComplex("SHAPE_ASPECT","SHPASP", num0, num, ach);
|
||||
if (!data->CheckNbParams(num, 4, ach, "shape_aspect")) return;
|
||||
|
||||
Handle(TCollection_HAsciiString) aName;
|
||||
|
@@ -40,7 +40,7 @@ void RWStepRepr_RWReprItemAndLengthMeasureWithUnit::ReadStep
|
||||
const Handle(StepRepr_ReprItemAndLengthMeasureWithUnit)& ent) const
|
||||
{
|
||||
Standard_Integer num = 0;//num0;
|
||||
data->NamedForComplex("MEASURE_WITH_UNIT",num0,num,ach);
|
||||
data->NamedForComplex("MEASURE_WITH_UNIT","MSWTUN",num0,num,ach);
|
||||
if (!data->CheckNbParams(num,2,ach,"measure_with_unit")) return;
|
||||
// --- own field : valueComponent ---
|
||||
Handle(StepBasic_MeasureValueMember) mvc = new StepBasic_MeasureValueMember;
|
||||
@@ -51,7 +51,7 @@ void RWStepRepr_RWReprItemAndLengthMeasureWithUnit::ReadStep
|
||||
Handle(StepBasic_MeasureWithUnit) aMeasureWithUnit = new StepBasic_MeasureWithUnit;
|
||||
aMeasureWithUnit->Init(mvc, aUnitComponent);
|
||||
|
||||
data->NamedForComplex("REPRESENTATION_ITEM",num0,num,ach);
|
||||
data->NamedForComplex("REPRESENTATION_ITEM","RPRITM",num0,num,ach);
|
||||
if (!data->CheckNbParams(num,1,ach,"representation_item")) return;
|
||||
// --- own field : name ---
|
||||
Handle(TCollection_HAsciiString) aName;
|
||||
|
@@ -44,7 +44,7 @@ void RWStepRepr_RWReprItemAndLengthMeasureWithUnitAndQRI::ReadStep
|
||||
const Handle(StepRepr_ReprItemAndLengthMeasureWithUnitAndQRI)& ent) const
|
||||
{
|
||||
Standard_Integer num = 0;//num0;
|
||||
data->NamedForComplex("MEASURE_WITH_UNIT",num0,num,ach);
|
||||
data->NamedForComplex("MEASURE_WITH_UNIT","MSWTUN",num0,num,ach);
|
||||
if (!data->CheckNbParams(num,2,ach,"measure_with_unit")) return;
|
||||
// --- own field : valueComponent ---
|
||||
Handle(StepBasic_MeasureValueMember) mvc = new StepBasic_MeasureValueMember;
|
||||
@@ -55,7 +55,7 @@ void RWStepRepr_RWReprItemAndLengthMeasureWithUnitAndQRI::ReadStep
|
||||
Handle(StepBasic_MeasureWithUnit) aMeasureWithUnit = new StepBasic_MeasureWithUnit;
|
||||
aMeasureWithUnit->Init(mvc, aUnitComponent);
|
||||
|
||||
data->NamedForComplex("QUALIFIED_REPRESENTATION_ITEM",num0,num,ach);
|
||||
data->NamedForComplex("QUALIFIED_REPRESENTATION_ITEM","QLRPIT",num0,num,ach);
|
||||
if (!data->CheckNbParams(num,1,ach,"qualified_representation_item")) return;
|
||||
// --- own field : qualifiers ---
|
||||
Handle(StepShape_HArray1OfValueQualifier) quals;
|
||||
@@ -73,7 +73,7 @@ void RWStepRepr_RWReprItemAndLengthMeasureWithUnitAndQRI::ReadStep
|
||||
Handle(StepShape_QualifiedRepresentationItem) aQRI = new StepShape_QualifiedRepresentationItem();
|
||||
aQRI->SetQualifiers(quals);
|
||||
|
||||
data->NamedForComplex("REPRESENTATION_ITEM",num0,num,ach);
|
||||
data->NamedForComplex("REPRESENTATION_ITEM","RPRITM",num0,num,ach);
|
||||
if (!data->CheckNbParams(num,1,ach,"representation_item")) return;
|
||||
// --- own field : name ---
|
||||
Handle(TCollection_HAsciiString) aName;
|
||||
|
@@ -41,7 +41,7 @@ void RWStepRepr_RWReprItemAndPlaneAngleMeasureWithUnit::ReadStep
|
||||
const Handle(StepRepr_ReprItemAndPlaneAngleMeasureWithUnit)& ent) const
|
||||
{
|
||||
Standard_Integer num = 0;//num0;
|
||||
data->NamedForComplex("MEASURE_WITH_UNIT",num0,num,ach);
|
||||
data->NamedForComplex("MEASURE_WITH_UNIT","MSWTUN",num0,num,ach);
|
||||
if (!data->CheckNbParams(num,2,ach,"measure_with_unit")) return;
|
||||
// --- own field : valueComponent ---
|
||||
Handle(StepBasic_MeasureValueMember) mvc = new StepBasic_MeasureValueMember;
|
||||
@@ -52,7 +52,7 @@ void RWStepRepr_RWReprItemAndPlaneAngleMeasureWithUnit::ReadStep
|
||||
Handle(StepBasic_MeasureWithUnit) aMeasureWithUnit = new StepBasic_MeasureWithUnit;
|
||||
aMeasureWithUnit->Init(mvc, aUnitComponent);
|
||||
|
||||
data->NamedForComplex("REPRESENTATION_ITEM",num0,num,ach);
|
||||
data->NamedForComplex("REPRESENTATION_ITEM","RPRITM",num0,num,ach);
|
||||
if (!data->CheckNbParams(num,1,ach,"representation_item")) return;
|
||||
// --- own field : name ---
|
||||
Handle(TCollection_HAsciiString) aName;
|
||||
|
@@ -44,7 +44,7 @@ void RWStepRepr_RWReprItemAndPlaneAngleMeasureWithUnitAndQRI::ReadStep
|
||||
const Handle(StepRepr_ReprItemAndPlaneAngleMeasureWithUnitAndQRI)& ent) const
|
||||
{
|
||||
Standard_Integer num = 0;//num0;
|
||||
data->NamedForComplex("MEASURE_WITH_UNIT",num0,num,ach);
|
||||
data->NamedForComplex("MEASURE_WITH_UNIT","MSWTUN",num0,num,ach);
|
||||
if (!data->CheckNbParams(num,2,ach,"measure_with_unit")) return;
|
||||
// --- own field : valueComponent ---
|
||||
Handle(StepBasic_MeasureValueMember) mvc = new StepBasic_MeasureValueMember;
|
||||
@@ -55,7 +55,7 @@ void RWStepRepr_RWReprItemAndPlaneAngleMeasureWithUnitAndQRI::ReadStep
|
||||
Handle(StepBasic_MeasureWithUnit) aMeasureWithUnit = new StepBasic_MeasureWithUnit;
|
||||
aMeasureWithUnit->Init(mvc, aUnitComponent);
|
||||
|
||||
data->NamedForComplex("QUALIFIED_REPRESENTATION_ITEM",num0,num,ach);
|
||||
data->NamedForComplex("QUALIFIED_REPRESENTATION_ITEM","QLRPIT",num0,num,ach);
|
||||
if (!data->CheckNbParams(num,1,ach,"qualified_representation_item")) return;
|
||||
// --- own field : qualifiers ---
|
||||
Handle(StepShape_HArray1OfValueQualifier) quals;
|
||||
@@ -72,7 +72,7 @@ void RWStepRepr_RWReprItemAndPlaneAngleMeasureWithUnitAndQRI::ReadStep
|
||||
Handle(StepShape_QualifiedRepresentationItem) aQRI = new StepShape_QualifiedRepresentationItem();
|
||||
aQRI->SetQualifiers(quals);
|
||||
|
||||
data->NamedForComplex("REPRESENTATION_ITEM",num0,num,ach);
|
||||
data->NamedForComplex("REPRESENTATION_ITEM","RPRITM",num0,num,ach);
|
||||
if (!data->CheckNbParams(num,1,ach,"representation_item")) return;
|
||||
// --- own field : name ---
|
||||
Handle(TCollection_HAsciiString) aName;
|
||||
|
@@ -37,7 +37,7 @@ void RWStepRepr_RWShapeRepresentationRelationshipWithTransformation::ReadStep
|
||||
// --- Instance of plex componant RepresentationRelationship ---
|
||||
|
||||
Standard_Integer num = 0; // num0;
|
||||
data->NamedForComplex("REPRESENTATION_RELATIONSHIP RPRRLT",num0,num,ach);
|
||||
data->NamedForComplex("REPRESENTATION_RELATIONSHIP", "RPRRLT",num0,num,ach);
|
||||
|
||||
// --- Number of Parameter Control ---
|
||||
|
||||
@@ -70,7 +70,7 @@ void RWStepRepr_RWShapeRepresentationRelationshipWithTransformation::ReadStep
|
||||
|
||||
// --- Instance of plex componant RepresentationRelationshipWithTransformation ---
|
||||
|
||||
data->NamedForComplex("REPRESENTATION_RELATIONSHIP_WITH_TRANSFORMATION RRWT",num0,num,ach);
|
||||
data->NamedForComplex("REPRESENTATION_RELATIONSHIP_WITH_TRANSFORMATION", "RRWT",num0,num,ach);
|
||||
if (!data->CheckNbParams(num,1,ach,"representation_relationship_with_transformation")) return;
|
||||
|
||||
// --- own field : transformation_operator
|
||||
@@ -81,7 +81,7 @@ void RWStepRepr_RWShapeRepresentationRelationshipWithTransformation::ReadStep
|
||||
|
||||
// --- Instance of plex componant ShapeRepresentationRelationship ---
|
||||
|
||||
data->NamedForComplex("SHAPE_REPRESENTATION_RELATIONSHIP SHRPRL",num0,num,ach);
|
||||
data->NamedForComplex("SHAPE_REPRESENTATION_RELATIONSHIP", "SHRPRL",num0,num,ach);
|
||||
if (!data->CheckNbParams(num,0,ach,"shape_representation_relationship")) return;
|
||||
|
||||
//--- Initialisation of the read entity ---
|
||||
|
Reference in New Issue
Block a user