]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
Add new method to get the list of rotated/translated entities of MultiRotation/MultiT...
authorArtem Zhidkov <Artem.Zhidkov@opencascade.com>
Sat, 5 Dec 2020 14:20:59 +0000 (17:20 +0300)
committerArtem Zhidkov <Artem.Zhidkov@opencascade.com>
Sat, 5 Dec 2020 14:20:59 +0000 (17:20 +0300)
Revert changes in unit tests. Use new methods in models tests.

18 files changed:
src/BuildPlugin/Test/Test19056.py
src/FeaturesPlugin/Test/Test2495.py
src/FeaturesPlugin/Test/Test2724.py
src/FiltersPlugin/Test/Test2946.py
src/FiltersPlugin/Test/Test3241.py
src/ModelAPI/Test/TestBlockRecalculation.py
src/SketchAPI/SketchAPI_Rotation.cpp
src/SketchAPI/SketchAPI_Rotation.h
src/SketchAPI/SketchAPI_Translation.cpp
src/SketchAPI/SketchAPI_Translation.h
src/SketchPlugin/Test/Test20274_1.py
src/SketchPlugin/Test/Test20274_2.py
src/SketchPlugin/Test/Test2393.py
src/SketchPlugin/Test/Test3240.py
test.compatibility/bobine_film_reel.py
test.compatibility/ecran.py
test.models/bobine_film_reel.py
test.models/ecran.py

index 868a08fe51c8e4eba17a30f59896a5b09699b815..6807f3bf31baad14c12e61e4de6fc3e4897a95c6 100644 (file)
@@ -50,7 +50,7 @@ SketchConstraintCoincidence_5 = Sketch_1.setCoincident(SketchArc_3.startPoint(),
 SketchConstraintCoincidence_6 = Sketch_1.setCoincident(SketchArc_1.startPoint(), SketchArc_3.startPoint())
 SketchMultiRotation_1_objects = [SketchArc_1.results()[1], SketchLine_2.result(), SketchLine_4.result(), SketchArc_2.results()[1]]
 SketchMultiRotation_1 = Sketch_1.addRotation(SketchMultiRotation_1_objects, SketchAPI_Line(SketchLine_1).startPoint(), 360, "nb", True)
-[SketchArc_4, SketchArc_5, SketchArc_6, SketchArc_7, SketchArc_8, SketchArc_9, SketchArc_10, SketchLine_5, SketchLine_6, SketchLine_7, SketchLine_8, SketchLine_9, SketchLine_10, SketchLine_11, SketchLine_12, SketchLine_13, SketchLine_14, SketchLine_15, SketchLine_16, SketchLine_17, SketchLine_18, SketchArc_11, SketchArc_12, SketchArc_13, SketchArc_14, SketchArc_15, SketchArc_16, SketchArc_17] = SketchMultiRotation_1.rotated()
+[SketchArc_4, SketchArc_5, SketchArc_6, SketchArc_7, SketchArc_8, SketchArc_9, SketchArc_10, SketchLine_5, SketchLine_6, SketchLine_7, SketchLine_8, SketchLine_9, SketchLine_10, SketchLine_11, SketchLine_4, SketchLine_12, SketchLine_13, SketchLine_14, SketchLine_15, SketchLine_16, SketchLine_17, SketchLine_18, SketchArc_2, SketchArc_11, SketchArc_12, SketchArc_13, SketchArc_14, SketchArc_15, SketchArc_16, SketchArc_17] = SketchMultiRotation_1.rotated()
 SketchArc_13.setName("SketchArc_9")
 SketchArc_13.result().setName("SketchArc_9")
 SketchArc_13.results()[1].setName("SketchArc_9_2")
index 0a401813ac5984e721821574ecb5a8d99eaab8bd..7e246a1b30cc3b380500b1232f0a514ed87d5b1d 100644 (file)
@@ -124,7 +124,7 @@ SketchConstraintCoincidence_17.setName("SketchConstraintCoincidence_20")
 SketchConstraintDistance_3 = Sketch_1.setDistance(SketchPoint_5.coordinates(), SketchLine_6.result(), 21, True)
 SketchMultiTranslation_2_objects = [SketchArc_1.results()[1], SketchLine_7.result(), SketchLine_8.result(), SketchArc_2.results()[1], SketchLine_10.result(), SketchArc_5.results()[1], SketchLine_12.result(), SketchArc_3.results()[1], SketchArc_4.results()[1], SketchLine_13.result(), SketchLine_11.result(), SketchArc_6.results()[1]]
 SketchMultiTranslation_2 = Sketch_1.addTranslation(SketchMultiTranslation_2_objects, SketchPoint_3.coordinates(), SketchPoint_5.coordinates(), 2)
-[SketchArc_7, SketchLine_14, SketchLine_15, SketchArc_8, SketchLine_16, SketchArc_9, SketchLine_17, SketchArc_10, SketchArc_11, SketchLine_18, SketchLine_19, SketchArc_12] = SketchMultiTranslation_2.translated()
+[SketchArc_7, SketchLine_14, SketchLine_15, SketchArc_8, SketchLine_10, SketchLine_16, SketchArc_5, SketchArc_9, SketchLine_12, SketchLine_17, SketchArc_3, SketchArc_10, SketchArc_4, SketchArc_11, SketchLine_13, SketchLine_18, SketchLine_11, SketchLine_19, SketchArc_6, SketchArc_12] = SketchMultiTranslation_2.translated()
 SketchLine_19.setName("SketchLine_20")
 SketchLine_19.result().setName("SketchLine_20")
 SketchLine_18.setName("SketchLine_19")
@@ -295,7 +295,7 @@ SketchConstraintCoincidence_35.setName("SketchConstraintCoincidence_46")
 SketchConstraintDistance_7 = Sketch_1.setDistance(SketchPoint_7.coordinates(), SketchLine_6.result(), 5.3, True)
 SketchMultiTranslation_4_objects = [SketchLine_20.result(), SketchArc_21.results()[1], SketchLine_22.result(), SketchArc_16.results()[1], SketchLine_41.result(), SketchLine_37.result(), SketchLine_38.result(), SketchArc_33.results()[1], SketchLine_43.result(), SketchLine_24.result(), SketchLine_42.result(), SketchArc_13.results()[1], SketchArc_31.results()[1], SketchLine_36.result(), SketchLine_28.result(), SketchArc_19.results()[1], SketchLine_21.result(), SketchArc_36.results()[1], SketchArc_14.results()[1], SketchArc_24.results()[1], SketchLine_31.result(), SketchArc_32.results()[1], SketchArc_20.results()[1], SketchLine_27.result(), SketchLine_34.result(), SketchArc_30.results()[1], SketchLine_39.result(), SketchArc_25.results()[1], SketchArc_34.results()[1], SketchArc_18.results()[1], SketchLine_40.result(), SketchLine_35.result(), SketchArc_35.results()[1], SketchArc_28.results()[1], SketchLine_32.result(), SketchArc_22.results()[1], SketchArc_26.results()[1], SketchLine_26.result(), SketchLine_30.result(), SketchArc_15.results()[1], SketchLine_33.result(), SketchLine_29.result(), SketchLine_23.result(), SketchLine_25.result(), SketchArc_29.results()[1], SketchArc_23.results()[1], SketchArc_27.results()[1], SketchArc_17.results()[1]]
 SketchMultiTranslation_4 = Sketch_1.addTranslation(SketchMultiTranslation_4_objects, SketchArc_15.center(), SketchPoint_7.coordinates(), 2)
-[SketchLine_44, SketchArc_37, SketchLine_45, SketchArc_38, SketchLine_46, SketchLine_47, SketchLine_48, SketchArc_39, SketchLine_49, SketchLine_50, SketchLine_51, SketchArc_40, SketchArc_41, SketchLine_52, SketchLine_53, SketchArc_42, SketchLine_54, SketchArc_43, SketchArc_44, SketchArc_45, SketchLine_55, SketchArc_46, SketchArc_47, SketchLine_56, SketchLine_57, SketchArc_48, SketchLine_58, SketchArc_49, SketchArc_50, SketchArc_51, SketchLine_59, SketchLine_60, SketchArc_52, SketchArc_53, SketchLine_61, SketchArc_54, SketchArc_55, SketchLine_62, SketchLine_63, SketchArc_56, SketchLine_64, SketchLine_65, SketchLine_66, SketchLine_67, SketchArc_57, SketchArc_58, SketchArc_59, SketchArc_60] = SketchMultiTranslation_4.translated()
+[SketchLine_44, SketchArc_21, SketchArc_37, SketchLine_45, SketchArc_38, SketchLine_41, SketchLine_46, SketchLine_37, SketchLine_47, SketchLine_38, SketchLine_48, SketchArc_33, SketchArc_39, SketchLine_43, SketchLine_49, SketchLine_24, SketchLine_50, SketchLine_42, SketchLine_51, SketchArc_40, SketchArc_31, SketchArc_41, SketchLine_36, SketchLine_52, SketchLine_28, SketchLine_53, SketchArc_19, SketchArc_42, SketchLine_54, SketchArc_36, SketchArc_43, SketchArc_44, SketchArc_24, SketchArc_45, SketchLine_31, SketchLine_55, SketchArc_32, SketchArc_46, SketchArc_20, SketchArc_47, SketchLine_27, SketchLine_56, SketchLine_34, SketchLine_57, SketchArc_30, SketchArc_48, SketchLine_39, SketchLine_58, SketchArc_25, SketchArc_49, SketchArc_34, SketchArc_50, SketchArc_18, SketchArc_51, SketchLine_40, SketchLine_59, SketchLine_35, SketchLine_60, SketchArc_35, SketchArc_52, SketchArc_28, SketchArc_53, SketchLine_32, SketchLine_61, SketchArc_22, SketchArc_54, SketchArc_26, SketchArc_55, SketchLine_26, SketchLine_62, SketchLine_30, SketchLine_63, SketchArc_56, SketchLine_33, SketchLine_64, SketchLine_29, SketchLine_65, SketchLine_66, SketchLine_25, SketchLine_67, SketchArc_29, SketchArc_57, SketchArc_23, SketchArc_58, SketchArc_27, SketchArc_59, SketchArc_17, SketchArc_60] = SketchMultiTranslation_4.translated()
 SketchLine_67.setName("SketchLine_68")
 SketchLine_67.result().setName("SketchLine_68")
 SketchLine_66.setName("SketchLine_67")
index ec0fb61edda16b01f0bb46feae8f6047a0e20af0..40a0dc7bf743c9a6bb8333f065254c64ff8a218b 100644 (file)
@@ -49,7 +49,7 @@ SketchConstraintMirror_1 = Sketch_1.addMirror(SketchLine_3.result(), SketchConst
 [SketchLine_5, SketchLine_6, SketchLine_7] = SketchConstraintMirror_1.mirrored()
 SketchMultiTranslation_1_objects = [SketchLine_1.result(), SketchLine_4.result(), SketchLine_3.result(), SketchLine_5.result(), SketchLine_6.result()]
 SketchMultiTranslation_1 = Sketch_1.addTranslation(SketchMultiTranslation_1_objects, SketchLine_2.endPoint(), SketchLine_4.startPoint(), 4)
-[SketchLine_8, SketchLine_9, SketchLine_10, SketchLine_11, SketchLine_12, SketchLine_13, SketchLine_14, SketchLine_15, SketchLine_16, SketchLine_17, SketchLine_18, SketchLine_19, SketchLine_20, SketchLine_21, SketchLine_22] = SketchMultiTranslation_1.translated()
+[SketchLine_8, SketchLine_9, SketchLine_10, SketchLine_11, SketchLine_12, SketchLine_13, SketchLine_14, SketchLine_15, SketchLine_16, SketchLine_5, SketchLine_17, SketchLine_18, SketchLine_19, SketchLine_6, SketchLine_20, SketchLine_21, SketchLine_22] = SketchMultiTranslation_1.translated()
 model.do()
 Part_1 = model.addPart(partSet)
 Part_1_doc = Part_1.document()
index 401e75ebfaa763b8dbf0a8beac3414f60990dd51..0cb89d013796b43fb57c7d4ec68aee521463ea85 100644 (file)
@@ -39,7 +39,7 @@ SketchConstraintAngle_1 = Sketch_1.setAngle(SketchLine_2.result(), SketchLine_1.
 SketchConstraintMirror_1 = Sketch_1.addMirror(SketchLine_2.result(), [SketchLine_1.result()])
 [SketchLine_3] = SketchConstraintMirror_1.mirrored()
 SketchMultiRotation_1 = Sketch_1.addRotation([SketchLine_1.result(), SketchLine_3.result()], SketchAPI_Line(SketchLine_2).startPoint(), 360, 4, True)
-[SketchLine_4, SketchLine_5, SketchLine_6, SketchLine_7, SketchLine_8, SketchLine_9] = SketchMultiRotation_1.rotated()
+[SketchLine_4, SketchLine_5, SketchLine_6, SketchLine_3, SketchLine_7, SketchLine_8, SketchLine_9] = SketchMultiRotation_1.rotated()
 SketchArc_1 = Sketch_1.addArc(0, 0, 10.35276180410083, 38.63703305156273, -10.35276180410083, 38.63703305156273, False)
 SketchConstraintCoincidence_3 = Sketch_1.setCoincident(SketchCircle_1.center(), SketchArc_1.center())
 SketchConstraintRadius_3 = Sketch_1.setRadius(SketchArc_1.results()[1], 40)
index ad6380c413c7fb18ca9b282840cf6f8a38ce46d9..ea375c2bbc89fa6e8c1eeaae8be59a2c003c6596 100644 (file)
@@ -57,7 +57,7 @@ SketchPoint_4 = SketchProjection_4.createdFeature()
 SketchProjection_5 = Sketch_4.addProjection(model.selection("EDGE", "PartSet/OX"), True)
 SketchLine_1 = SketchProjection_5.createdFeature()
 SketchMultiRotation_1 = Sketch_4.addRotation([SketchLine_1.result()], SketchAPI_Point(SketchPoint_4).coordinates(), 360, 12, True)
-[SketchLine_2, SketchLine_3, SketchLine_4, SketchLine_5, SketchLine_6, SketchLine_7, SketchLine_8, SketchLine_9, SketchLine_10, SketchLine_11, SketchLine_12] = SketchMultiRotation_1.rotated()
+[SketchLine_1, SketchLine_2, SketchLine_3, SketchLine_4, SketchLine_5, SketchLine_6, SketchLine_7, SketchLine_8, SketchLine_9, SketchLine_10, SketchLine_11, SketchLine_12] = SketchMultiRotation_1.rotated()
 model.do()
 Edge_1 = model.addEdge(Part_1_doc, [model.selection("COMPOUND", "Sketch_4")], False)
 Extrusion_1 = model.addExtrusion(Part_1_doc, [model.selection("COMPOUND", "all-in-Edge_1")], model.selection(), model.selection("FACE", "Plane_2"), 0, model.selection(), 0)
index fc808f1de2402edc895e47d560c8a4c6cee67d5e..a01f013281d422d0925ab9ef9d18d28a3886f27b 100644 (file)
@@ -65,7 +65,7 @@ SketchConstraintMirror_1 = Sketch_1.addMirror(SketchLine_6.result(), SketchConst
 [SketchLine_7, SketchArc_2, SketchLine_8, SketchLine_9, SketchLine_10] = SketchConstraintMirror_1.mirrored()
 SketchMultiRotation_1_objects = [SketchLine_10.result(), SketchLine_9.result(), SketchLine_8.result(), SketchArc_2.results()[1], SketchLine_7.result(), SketchLine_1.result(), SketchArc_1.results()[1], SketchLine_2.result(), SketchLine_3.result(), SketchLine_4.result()]
 SketchMultiRotation_1 = Sketch_1.addRotation(SketchMultiRotation_1_objects, SketchAPI_Line(SketchLine_6).startPoint(), 360, 4, True)
-[SketchLine_11, SketchLine_12, SketchLine_13, SketchLine_14, SketchLine_15, SketchLine_16, SketchLine_17, SketchLine_18, SketchLine_19, SketchArc_3, SketchArc_4, SketchArc_5, SketchLine_20, SketchLine_21, SketchLine_22, SketchLine_23, SketchLine_24, SketchLine_25, SketchArc_6, SketchArc_7, SketchArc_8, SketchLine_26, SketchLine_27, SketchLine_28, SketchLine_29, SketchLine_30, SketchLine_31, SketchLine_32, SketchLine_33, SketchLine_34] = SketchMultiRotation_1.rotated()
+[SketchLine_10, SketchLine_11, SketchLine_12, SketchLine_13, SketchLine_9, SketchLine_14, SketchLine_15, SketchLine_16, SketchLine_8, SketchLine_17, SketchLine_18, SketchLine_19, SketchArc_2, SketchArc_3, SketchArc_4, SketchArc_5, SketchLine_7, SketchLine_20, SketchLine_21, SketchLine_22, SketchLine_23, SketchLine_24, SketchLine_25, SketchArc_6, SketchArc_7, SketchArc_8, SketchLine_26, SketchLine_27, SketchLine_28, SketchLine_29, SketchLine_30, SketchLine_31, SketchLine_32, SketchLine_33, SketchLine_34] = SketchMultiRotation_1.rotated()
 model.do()
 Part_1 = model.addPart(partSet)
 Part_1_doc = Part_1.document()
index 7b5ec3831fd28d50250bfd64d3755f015d7845fb..4a83244cea932eb4336d14e7cb042193a2cd222d 100644 (file)
@@ -66,6 +66,21 @@ void SketchAPI_Rotation::setRotationList(
 }
 
 std::list<std::shared_ptr<SketchAPI_SketchEntity> > SketchAPI_Rotation::rotated() const
+{
+  std::list<ObjectPtr> aList = rotatedObjects()->list();
+  // remove all initial features
+  std::list<FeaturePtr> anIntermediate;
+  std::list<ObjectPtr>::const_iterator anIt = aList.begin();
+  for (; anIt != aList.end(); ++anIt) {
+    FeaturePtr aFeature = ModelAPI_Feature::feature(*anIt);
+    AttributeBooleanPtr isCopy = aFeature->boolean(SketchPlugin_SketchEntity::COPY_ID());
+    if (isCopy.get() && isCopy->value())
+      anIntermediate.push_back(aFeature);
+  }
+  return SketchAPI_SketchEntity::wrap(anIntermediate);
+}
+
+std::list<std::shared_ptr<SketchAPI_SketchEntity> > SketchAPI_Rotation::rotatedList() const
 {
   std::list<ObjectPtr> aList = rotationList()->list();
   std::set<ObjectPtr> anOriginalObjects;
@@ -137,7 +152,7 @@ void SketchAPI_Rotation::dump(ModelHighAPI_Dumper& theDumper) const
 
   // Dump variables for a list of rotated features
   theDumper << "[";
-  std::list<std::shared_ptr<SketchAPI_SketchEntity> > aList = rotated();
+  std::list<std::shared_ptr<SketchAPI_SketchEntity> > aList = rotatedList();
   std::list<std::shared_ptr<SketchAPI_SketchEntity> >::const_iterator anIt = aList.begin();
   for (size_t anIndex = 0; anIndex < aFirstNotDumped; ++anIndex)
     for (int i = 1; i < aNbCopies->value() && anIt != aList.end(); ++i, ++anIt) {
@@ -145,7 +160,7 @@ void SketchAPI_Rotation::dump(ModelHighAPI_Dumper& theDumper) const
         theDumper << ", ";
       theDumper << (*anIt)->feature();
     }
-  theDumper << "] = " << theDumper.name(aBase) << ".rotated()" << std::endl;
+  theDumper << "] = " << theDumper.name(aBase) << ".rotatedList()" << std::endl;
 
   if (theDumper.isDumped(aRotObjects)) {
     aNbDumpedArguments.erase(aBase);
index e9899d001021bbed51df3911152d8a63ed499983..beff1d64d8f073ffac1ec4d2c3137a48ee91ce18 100644 (file)
@@ -82,10 +82,15 @@ public:
   SKETCHAPI_EXPORT
   void setRotationList(const std::list<std::shared_ptr<ModelAPI_Object> >& theObjects);
 
-  /// List of rotated objects
+  /// List of rotated objects.
+  /// [DEPRECATED]: use rotatedList() instead.
   SKETCHAPI_EXPORT
   std::list<std::shared_ptr<SketchAPI_SketchEntity> > rotated() const;
 
+  /// List of rotated objects.
+  SKETCHAPI_EXPORT
+  std::list<std::shared_ptr<SketchAPI_SketchEntity> > rotatedList() const;
+
   /// Dump wrapped feature
   virtual void dump(ModelHighAPI_Dumper& theDumper) const;
 };
index ff32e3fa2e221500faec4e12d5995fe8c62a10ff..60b88fbf6d27f96bce42dc7ab6a12c0706deb78e 100644 (file)
@@ -63,6 +63,21 @@ void SketchAPI_Translation::setTranslationList(
 }
 
 std::list<std::shared_ptr<SketchAPI_SketchEntity> > SketchAPI_Translation::translated() const
+{
+  std::list<ObjectPtr> aList = translatedObjects()->list();
+  // remove all initial features
+  std::list<FeaturePtr> anIntermediate;
+  std::list<ObjectPtr>::const_iterator anIt = aList.begin();
+  for (; anIt != aList.end(); ++anIt) {
+    FeaturePtr aFeature = ModelAPI_Feature::feature(*anIt);
+    AttributeBooleanPtr isCopy = aFeature->boolean(SketchPlugin_SketchEntity::COPY_ID());
+    if (isCopy.get() && isCopy->value())
+      anIntermediate.push_back(aFeature);
+  }
+  return SketchAPI_SketchEntity::wrap(anIntermediate);
+}
+
+std::list<std::shared_ptr<SketchAPI_SketchEntity> > SketchAPI_Translation::translatedList() const
 {
   std::list<ObjectPtr> aList = translationList()->list();
   std::set<ObjectPtr> anOriginalObjects;
@@ -129,7 +144,7 @@ void SketchAPI_Translation::dump(ModelHighAPI_Dumper& theDumper) const
 
   // Dump variables for a list of translated features
   theDumper << "[";
-  std::list<std::shared_ptr<SketchAPI_SketchEntity> > aList = translated();
+  std::list<std::shared_ptr<SketchAPI_SketchEntity> > aList = translatedList();
   std::list<std::shared_ptr<SketchAPI_SketchEntity> >::const_iterator anIt = aList.begin();
   for (size_t anIndex = 0; anIndex < aFirstNotDumped; ++anIndex)
     for (int i = 1; i < aNbCopies->value() && anIt != aList.end(); ++i, ++anIt) {
@@ -137,7 +152,7 @@ void SketchAPI_Translation::dump(ModelHighAPI_Dumper& theDumper) const
         theDumper << ", ";
       theDumper << (*anIt)->feature();
     }
-  theDumper << "] = " << theDumper.name(aBase) << ".translated()" << std::endl;
+  theDumper << "] = " << theDumper.name(aBase) << ".translatedList()" << std::endl;
 
   if (theDumper.isDumped(aTransObjects)) {
     aNbDumpedArguments.erase(aBase);
index 32119218e7143095e97d402377dbb7a840df7d9f..d0ed7840f7de9dace8ab5b1475e430296be25230 100644 (file)
@@ -78,10 +78,15 @@ public:
   SKETCHAPI_EXPORT
   void setTranslationList(const std::list<std::shared_ptr<ModelAPI_Object> >& theObjects);
 
-  /// List of translated objects
+  /// List of translated objects.
+  /// [DEPRECATED]: use translatedList() instead.
   SKETCHAPI_EXPORT
   std::list<std::shared_ptr<SketchAPI_SketchEntity> > translated() const;
 
+  /// List of translated objects.
+  SKETCHAPI_EXPORT
+  std::list<std::shared_ptr<SketchAPI_SketchEntity> > translatedList() const;
+
   /// Dump wrapped feature
   virtual void dump(ModelHighAPI_Dumper& theDumper) const;
 };
index 353241aa7d9f8326ad074a80d4ea59f043c1bec3..e083254cddba91a3c39daa3c08bc661eecb09f11 100644 (file)
@@ -70,7 +70,7 @@ Sketch_1.setCoincident(SketchCircle_1.center(), SketchLine_5.result())
 ### Create SketchMultiRotation
 SketchMultiRotation_1_objects = [SketchLine_1.result(), SketchLine_3.result(), SketchLine_5.result()]
 SketchMultiRotation_1 = Sketch_1.addRotation(SketchMultiRotation_1_objects, SketchCircle_1.center(), 360, 4, True)
-[SketchLine_6, SketchLine_7, SketchLine_8, SketchLine_9, SketchLine_10, SketchLine_11, SketchLine_12, SketchLine_13, SketchLine_14] = SketchMultiRotation_1.rotated()
+[SketchLine_6, SketchLine_7, SketchLine_8, SketchLine_9, SketchLine_10, SketchLine_11, SketchLine_12, SketchLine_13, SketchLine_14] = SketchMultiRotation_1.rotatedList()
 model.do()
 
 ### Create Extrusion
index e239d3b7653bf2b1ebd5cf7766ed964e880eafeb..b6780939836118e3d87ddaf75c2e008589e3f81e 100644 (file)
@@ -70,7 +70,7 @@ Sketch_1.setCoincident(SketchCircle_1.center(), SketchLine_5.result())
 ### Create SketchMultiTranslation
 SketchMultiTranslation_1_objects = [SketchLine_1.result(), SketchLine_3.result(), SketchLine_5.result()]
 SketchMultiTranslation_1 = Sketch_1.addTranslation(SketchMultiTranslation_1_objects, SketchAPI_Line(SketchLine_4).startPoint(), SketchLine_5.endPoint(), 2)
-[SketchLine_7, SketchLine_8, SketchLine_9] = SketchMultiTranslation_1.translated()
+[SketchLine_7, SketchLine_8, SketchLine_9] = SketchMultiTranslation_1.translatedList()
 model.do()
 
 ### Create Extrusion
index df93682c8c02f6af033c10fb066a8b855f3bae6d..804c68428512696bf1c514ad925a20de98f8e72a 100644 (file)
@@ -40,7 +40,7 @@ SketchPoint_1 = SketchProjection_1.createdFeature()
 SketchProjection_2 = Sketch_1.addProjection(model.selection("EDGE", "[Box_1_1/Front][Box_1_1/Top]"), True)
 SketchLine_1 = SketchProjection_2.createdFeature()
 SketchMultiRotation_1 = Sketch_1.addRotation([SketchLine_1.result()], SketchAPI_Point(SketchPoint_1).coordinates(), 90, 3)
-[SketchLine_2, SketchLine_3] = SketchMultiRotation_1.rotated()
+[SketchLine_1, SketchLine_2, SketchLine_3] = SketchMultiRotation_1.rotated()
 model.do()
 
 model.checkSketch(Sketch_1, 0)
index 3380e5643547aff00dad791a0cf3838e855c97be..c6b0a2971b7d2863a9bccd5900ffa168e2c6124b 100644 (file)
@@ -32,7 +32,7 @@ Sketch_1 = model.addSketch(partSet, model.defaultPlane("XOY"))
 SketchProjection_1 = Sketch_1.addProjection(model.selection("EDGE", "OX"), True)
 SketchLine_1 = SketchProjection_1.createdFeature()
 SketchMultiRotation_1 = Sketch_1.addRotation([SketchLine_1.result()], SketchAPI_Line(SketchLine_1).startPoint(), 360, NB_COPIES, True)
-[SketchLine_2, SketchLine_3, SketchLine_4, SketchLine_5, SketchLine_6, SketchLine_7, SketchLine_8] = SketchMultiRotation_1.rotated()
+[SketchLine_1, SketchLine_2, SketchLine_3, SketchLine_4, SketchLine_5, SketchLine_6, SketchLine_7, SketchLine_8] = SketchMultiRotation_1.rotated()
 model.do()
 model.end()
 
index 78dd04332c5f5f00d751046062f3bea59dcb061f..2556838cfb7960b98fd14b8e403f0066d2605c88 100644 (file)
@@ -111,7 +111,7 @@ SketchConstraintDistance_2 = Sketch_8.setDistance(SketchLine_9.startPoint(), Ske
 SketchConstraintDistance_3 = Sketch_8.setDistance(SketchLine_8.endPoint(), SketchLine_9.startPoint(), 30)
 SketchMultiRotation_2_objects = [SketchLine_11.result(), SketchLine_10.result(), SketchLine_8.result(), SketchLine_7.result()]
 SketchMultiRotation_2 = Sketch_8.addRotation(SketchMultiRotation_2_objects, SketchLine_9.startPoint(), 120, 3)
-[SketchLine_12, SketchLine_13, SketchLine_14, SketchLine_15, SketchLine_16, SketchLine_17, SketchLine_18, SketchLine_19] = SketchMultiRotation_2.rotated()
+[SketchLine_11, SketchLine_12, SketchLine_13, SketchLine_10, SketchLine_14, SketchLine_15, SketchLine_16, SketchLine_17, SketchLine_18, SketchLine_19] = SketchMultiRotation_2.rotated()
 SketchLine_18.setName("SketchLine_15")
 SketchLine_18.result().setName("SketchLine_15")
 SketchLine_17.setName("SketchLine_18")
index a80f2f6378c8d925766d5f5ba20e63f77d68a699..94209ecb13481cda822ad4ea78cb7c42e87a568d 100644 (file)
@@ -721,7 +721,7 @@ SketchConstraintCoincidence_112.setName("SketchConstraintCoincidence_119")
 SketchConstraintDistance_16 = Sketch_6.setDistance(SketchPoint_9.coordinates(), SketchLine_81.result(), "10+5.3+5.7")
 SketchMultiTranslation_3_objects = [SketchArc_13.results()[1], SketchArc_34.results()[1], SketchArc_14.results()[1], SketchArc_33.results()[1], SketchArc_12.results()[1], SketchArc_11.results()[1], SketchArc_30.results()[1], SketchArc_29.results()[1], SketchArc_15.results()[1], SketchArc_16.results()[1], SketchArc_26.results()[1], SketchArc_25.results()[1], SketchArc_17.results()[1], SketchArc_18.results()[1], SketchArc_24.results()[1], SketchArc_23.results()[1], SketchArc_20.results()[1], SketchArc_22.results()[1], SketchArc_28.results()[1], SketchArc_27.results()[1], SketchArc_19.results()[1], SketchArc_21.results()[1], SketchArc_32.results()[1], SketchArc_31.results()[1], SketchLine_82.result(), SketchLine_77.result(), SketchLine_97.result(), SketchLine_94.result(), SketchLine_101.result(), SketchLine_99.result(), SketchLine_83.result(), SketchLine_88.result(), SketchLine_89.result(), SketchLine_86.result(), SketchLine_85.result(), SketchLine_100.result(), SketchLine_79.result(), SketchLine_92.result(), SketchLine_87.result(), SketchLine_91.result(), SketchLine_84.result(), SketchLine_96.result(), SketchLine_95.result(), SketchLine_93.result(), SketchLine_78.result(), SketchLine_98.result(), SketchLine_76.result(), SketchLine_90.result()]
 SketchMultiTranslation_3 = Sketch_6.addTranslation(SketchMultiTranslation_3_objects, SketchPoint_6.coordinates(), SketchPoint_9.coordinates(), 2)
-[SketchArc_35, SketchArc_36, SketchArc_37, SketchArc_38, SketchArc_39, SketchArc_40, SketchArc_41, SketchArc_42, SketchArc_43, SketchArc_44, SketchArc_45, SketchArc_46, SketchArc_47, SketchArc_48, SketchArc_49, SketchArc_50, SketchArc_51, SketchArc_52, SketchArc_53, SketchArc_54, SketchArc_55, SketchArc_56, SketchArc_57, SketchArc_58, SketchLine_102, SketchLine_103, SketchLine_104, SketchLine_105, SketchLine_106, SketchLine_107, SketchLine_108, SketchLine_109, SketchLine_110, SketchLine_111, SketchLine_112, SketchLine_113, SketchLine_114, SketchLine_115, SketchLine_116, SketchLine_117, SketchLine_118, SketchLine_119, SketchLine_120, SketchLine_121, SketchLine_122, SketchLine_123, SketchLine_124, SketchLine_125] = SketchMultiTranslation_3.translated()
+[SketchArc_35, SketchArc_34, SketchArc_36, SketchArc_37, SketchArc_33, SketchArc_38, SketchArc_39, SketchArc_40, SketchArc_30, SketchArc_41, SketchArc_29, SketchArc_42, SketchArc_15, SketchArc_43, SketchArc_16, SketchArc_44, SketchArc_26, SketchArc_45, SketchArc_25, SketchArc_46, SketchArc_17, SketchArc_47, SketchArc_18, SketchArc_48, SketchArc_24, SketchArc_49, SketchArc_23, SketchArc_50, SketchArc_20, SketchArc_51, SketchArc_22, SketchArc_52, SketchArc_28, SketchArc_53, SketchArc_27, SketchArc_54, SketchArc_19, SketchArc_55, SketchArc_21, SketchArc_56, SketchArc_32, SketchArc_57, SketchArc_31, SketchArc_58, SketchLine_82, SketchLine_102, SketchLine_103, SketchLine_97, SketchLine_104, SketchLine_94, SketchLine_105, SketchLine_101, SketchLine_106, SketchLine_99, SketchLine_107, SketchLine_83, SketchLine_108, SketchLine_88, SketchLine_109, SketchLine_89, SketchLine_110, SketchLine_86, SketchLine_111, SketchLine_85, SketchLine_112, SketchLine_100, SketchLine_113, SketchLine_114, SketchLine_92, SketchLine_115, SketchLine_87, SketchLine_116, SketchLine_91, SketchLine_117, SketchLine_84, SketchLine_118, SketchLine_96, SketchLine_119, SketchLine_95, SketchLine_120, SketchLine_93, SketchLine_121, SketchLine_122, SketchLine_98, SketchLine_123, SketchLine_124, SketchLine_90, SketchLine_125] = SketchMultiTranslation_3.translated()
 SketchLine_125.setName("SketchLine_130")
 SketchLine_125.result().setName("SketchLine_130")
 SketchLine_124.setName("SketchLine_129")
index 8d6a66010a4e1d314fdcf566b2edcc1a5bd1c75e..766cca10f208ec89897902d25c6e2d28fa4e65e3 100644 (file)
@@ -111,7 +111,7 @@ SketchConstraintDistance_2 = Sketch_8.setDistance(SketchLine_9.startPoint(), Ske
 SketchConstraintDistance_3 = Sketch_8.setDistance(SketchLine_8.endPoint(), SketchLine_9.startPoint(), 30)
 SketchMultiRotation_2_objects = [SketchLine_11.result(), SketchLine_10.result(), SketchLine_8.result(), SketchLine_7.result()]
 SketchMultiRotation_2 = Sketch_8.addRotation(SketchMultiRotation_2_objects, SketchLine_9.startPoint(), 120, 3)
-[SketchLine_12, SketchLine_13, SketchLine_14, SketchLine_15, SketchLine_16, SketchLine_17, SketchLine_18, SketchLine_19] = SketchMultiRotation_2.rotated()
+[SketchLine_12, SketchLine_13, SketchLine_14, SketchLine_15, SketchLine_16, SketchLine_17, SketchLine_18, SketchLine_19] = SketchMultiRotation_2.rotatedList()
 SketchLine_18.setName("SketchLine_15")
 SketchLine_18.result().setName("SketchLine_15")
 SketchLine_17.setName("SketchLine_18")
index 0166f9aeb00cd1b238230794a2252ea801085c2f..e97f7d7ec118b5451379f6293454e2c10f92ffe5 100644 (file)
@@ -721,7 +721,7 @@ SketchConstraintCoincidence_112.setName("SketchConstraintCoincidence_119")
 SketchConstraintDistance_16 = Sketch_6.setDistance(SketchPoint_9.coordinates(), SketchLine_81.result(), "10+5.3+5.7")
 SketchMultiTranslation_3_objects = [SketchArc_13.results()[1], SketchArc_34.results()[1], SketchArc_14.results()[1], SketchArc_33.results()[1], SketchArc_12.results()[1], SketchArc_11.results()[1], SketchArc_30.results()[1], SketchArc_29.results()[1], SketchArc_15.results()[1], SketchArc_16.results()[1], SketchArc_26.results()[1], SketchArc_25.results()[1], SketchArc_17.results()[1], SketchArc_18.results()[1], SketchArc_24.results()[1], SketchArc_23.results()[1], SketchArc_20.results()[1], SketchArc_22.results()[1], SketchArc_28.results()[1], SketchArc_27.results()[1], SketchArc_19.results()[1], SketchArc_21.results()[1], SketchArc_32.results()[1], SketchArc_31.results()[1], SketchLine_82.result(), SketchLine_77.result(), SketchLine_97.result(), SketchLine_94.result(), SketchLine_101.result(), SketchLine_99.result(), SketchLine_83.result(), SketchLine_88.result(), SketchLine_89.result(), SketchLine_86.result(), SketchLine_85.result(), SketchLine_100.result(), SketchLine_79.result(), SketchLine_92.result(), SketchLine_87.result(), SketchLine_91.result(), SketchLine_84.result(), SketchLine_96.result(), SketchLine_95.result(), SketchLine_93.result(), SketchLine_78.result(), SketchLine_98.result(), SketchLine_76.result(), SketchLine_90.result()]
 SketchMultiTranslation_3 = Sketch_6.addTranslation(SketchMultiTranslation_3_objects, SketchPoint_6.coordinates(), SketchPoint_9.coordinates(), 2)
-[SketchArc_35, SketchArc_36, SketchArc_37, SketchArc_38, SketchArc_39, SketchArc_40, SketchArc_41, SketchArc_42, SketchArc_43, SketchArc_44, SketchArc_45, SketchArc_46, SketchArc_47, SketchArc_48, SketchArc_49, SketchArc_50, SketchArc_51, SketchArc_52, SketchArc_53, SketchArc_54, SketchArc_55, SketchArc_56, SketchArc_57, SketchArc_58, SketchLine_102, SketchLine_103, SketchLine_104, SketchLine_105, SketchLine_106, SketchLine_107, SketchLine_108, SketchLine_109, SketchLine_110, SketchLine_111, SketchLine_112, SketchLine_113, SketchLine_114, SketchLine_115, SketchLine_116, SketchLine_117, SketchLine_118, SketchLine_119, SketchLine_120, SketchLine_121, SketchLine_122, SketchLine_123, SketchLine_124, SketchLine_125] = SketchMultiTranslation_3.translated()
+[SketchArc_35, SketchArc_36, SketchArc_37, SketchArc_38, SketchArc_39, SketchArc_40, SketchArc_41, SketchArc_42, SketchArc_43, SketchArc_44, SketchArc_45, SketchArc_46, SketchArc_47, SketchArc_48, SketchArc_49, SketchArc_50, SketchArc_51, SketchArc_52, SketchArc_53, SketchArc_54, SketchArc_55, SketchArc_56, SketchArc_57, SketchArc_58, SketchLine_102, SketchLine_103, SketchLine_104, SketchLine_105, SketchLine_106, SketchLine_107, SketchLine_108, SketchLine_109, SketchLine_110, SketchLine_111, SketchLine_112, SketchLine_113, SketchLine_114, SketchLine_115, SketchLine_116, SketchLine_117, SketchLine_118, SketchLine_119, SketchLine_120, SketchLine_121, SketchLine_122, SketchLine_123, SketchLine_124, SketchLine_125] = SketchMultiTranslation_3.translatedList()
 SketchLine_125.setName("SketchLine_130")
 SketchLine_125.result().setName("SketchLine_130")
 SketchLine_124.setName("SketchLine_129")