X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FFeaturesAPI%2FFeaturesAPI_BooleanSmash.cpp;h=c23f639678f937da2fa8d0d135ea598798eb9c10;hb=2e0f664e66dc2b46796df2953f52871b10799173;hp=9c22e3bd34a632af326690dc06babf9138d26a9d;hpb=c4eab94a20a0d93100549a210582d46409fec1cc;p=modules%2Fshaper.git diff --git a/src/FeaturesAPI/FeaturesAPI_BooleanSmash.cpp b/src/FeaturesAPI/FeaturesAPI_BooleanSmash.cpp index 9c22e3bd3..c23f63967 100644 --- a/src/FeaturesAPI/FeaturesAPI_BooleanSmash.cpp +++ b/src/FeaturesAPI/FeaturesAPI_BooleanSmash.cpp @@ -35,10 +35,12 @@ FeaturesAPI_BooleanSmash::FeaturesAPI_BooleanSmash( FeaturesAPI_BooleanSmash::FeaturesAPI_BooleanSmash( const std::shared_ptr& theFeature, const std::list& theMainObjects, - const std::list& theToolObjects) + const std::list& theToolObjects, + const int theVersion) : ModelHighAPI_Interface(theFeature) { if(initialize()) { + fillAttribute(theVersion, theFeature->integer(FeaturesPlugin_Boolean::VERSION_ID())); fillAttribute(theMainObjects, mymainObjects); fillAttribute(theToolObjects, mytoolObjects); @@ -82,17 +84,26 @@ void FeaturesAPI_BooleanSmash::dump(ModelHighAPI_Dumper& theDumper) const aBase->selectionList(FeaturesPlugin_BooleanSmash::OBJECT_LIST_ID()); AttributeSelectionListPtr aTools = aBase->selectionList(FeaturesPlugin_BooleanSmash::TOOL_LIST_ID()); + AttributeIntegerPtr aVersion = + aBase->integer(FeaturesPlugin_BooleanSmash::VERSION_ID()); + + theDumper << "(" << aDocName << ", " << anObjects << ", " << aTools; + + if (aVersion && aVersion->isInitialized()) + theDumper << ", " << aVersion->value(); - theDumper << "(" << aDocName << ", " << anObjects << ", " << aTools << ")" << std::endl; + theDumper << ")" << std::endl; } //================================================================================================== BooleanSmashPtr addSmash(const std::shared_ptr& thePart, const std::list& theMainObjects, - const std::list& theToolObjects) + const std::list& theToolObjects, + const int theVersion) { std::shared_ptr aFeature = thePart->addFeature(FeaturesAPI_BooleanSmash::ID()); return BooleanSmashPtr(new FeaturesAPI_BooleanSmash(aFeature, theMainObjects, - theToolObjects)); + theToolObjects, + theVersion)); }