From ea596975b6fc33f4a0f9efa7140b6f03eb1caec7 Mon Sep 17 00:00:00 2001 From: Nicolas RECHATIN Date: Wed, 16 Jun 2021 14:43:17 +0200 Subject: [PATCH] =?utf8?q?Int=C3=A9gration=20:=20=20=20=20=20+=20Lint=20an?= =?utf8?q?d=20code=20norm?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- src/FiltersAPI/FiltersAPI_Argument.cpp | 4 ++-- src/FiltersAPI/FiltersAPI_Feature.cpp | 4 ++-- src/FiltersPlugin/FiltersPlugin_FaceSize.cpp | 6 +++--- src/FiltersPlugin/FiltersPlugin_FeatureEdges.cpp | 2 +- src/FiltersPlugin/FiltersPlugin_VolumeSize.cpp | 8 ++++---- src/GeomValidators/GeomValidators_Positive.cpp | 4 ++-- 6 files changed, 14 insertions(+), 14 deletions(-) diff --git a/src/FiltersAPI/FiltersAPI_Argument.cpp b/src/FiltersAPI/FiltersAPI_Argument.cpp index 8cc6880bd..182251e19 100644 --- a/src/FiltersAPI/FiltersAPI_Argument.cpp +++ b/src/FiltersAPI/FiltersAPI_Argument.cpp @@ -64,10 +64,10 @@ void FiltersAPI_Argument::dump(ModelHighAPI_Dumper& theDumper) const theDumper << "model.selection()"; // mySelectionAttr; } else if (mySelection.variantType() == ModelHighAPI_Selection::VT_Empty) { - if (myDouble.value() > -100000000000 ){ + if (myDouble.value() > -100000000000 ) { theDumper << myDouble.value(); } - else if (myValue.empty()){ + else if (myValue.empty()) { theDumper << myBoolean; } else{ diff --git a/src/FiltersAPI/FiltersAPI_Feature.cpp b/src/FiltersAPI/FiltersAPI_Feature.cpp index 9a24140f4..095f45775 100644 --- a/src/FiltersAPI/FiltersAPI_Feature.cpp +++ b/src/FiltersAPI/FiltersAPI_Feature.cpp @@ -51,7 +51,7 @@ static void separateArguments(const std::list& theArguments else if (anIt->dble().value() > -100000000000) { theDoubleArgs.push_back(anIt->dble()); } - else if (anIt->string().empty()){ + else if (anIt->string().empty()) { theBoolArgs.push_back(anIt->boolean()); } else @@ -108,7 +108,7 @@ void FiltersAPI_Feature::setFilters(const std::list& theFilters) if (aBoolean) { if (aBools.size() == 1) fillAttribute(aBools.front(), aBoolean); - }else { + } else { AttributeDoublePtr aDouble = std::dynamic_pointer_cast(*aFIt); if (aDouble) { diff --git a/src/FiltersPlugin/FiltersPlugin_FaceSize.cpp b/src/FiltersPlugin/FiltersPlugin_FaceSize.cpp index 52633b834..17923ffba 100644 --- a/src/FiltersPlugin/FiltersPlugin_FaceSize.cpp +++ b/src/FiltersPlugin/FiltersPlugin_FaceSize.cpp @@ -56,7 +56,7 @@ bool FiltersPlugin_FaceSize::isOk(const GeomShapePtr& theShape, const ResultPtr& return false; double aValMax = aValue->value(); - if (aVal < 0.0) + if (aVal < 0.0) return false; double aTolerance = 0.0001; @@ -64,12 +64,12 @@ bool FiltersPlugin_FaceSize::isOk(const GeomShapePtr& theShape, const ResultPtr& double aSurfArea; double aVolume; std::string aError; - if( !GetBasicProperties(theShape, + if (!GetBasicProperties(theShape, aTolerance, aLength, aSurfArea, aVolume, - aError) ) + aError)) return false; anAttr = theArgs.argument("comparatorType"); diff --git a/src/FiltersPlugin/FiltersPlugin_FeatureEdges.cpp b/src/FiltersPlugin/FiltersPlugin_FeatureEdges.cpp index 79dd0aa65..4b6ad58cc 100644 --- a/src/FiltersPlugin/FiltersPlugin_FeatureEdges.cpp +++ b/src/FiltersPlugin/FiltersPlugin_FeatureEdges.cpp @@ -77,7 +77,7 @@ static void cacheFeatureEdge(const GeomShapePtr theTopLevelShape, anEdge->middlePoint(), theAngle, anError)) { - if( anError.empty()) + if (anError.empty()) theCache.insert(anEdge); } } diff --git a/src/FiltersPlugin/FiltersPlugin_VolumeSize.cpp b/src/FiltersPlugin/FiltersPlugin_VolumeSize.cpp index c50b58d91..32f04d30f 100644 --- a/src/FiltersPlugin/FiltersPlugin_VolumeSize.cpp +++ b/src/FiltersPlugin/FiltersPlugin_VolumeSize.cpp @@ -46,13 +46,13 @@ bool FiltersPlugin_VolumeSize::isOk(const GeomShapePtr& theShape, const ResultPt { AttributePtr anAttr = theArgs.argument("value"); AttributeDoublePtr aValue = std::dynamic_pointer_cast(anAttr); - if (!aValue.get()|| !anAttr->isInitialized() ) + if (!aValue.get()|| !anAttr->isInitialized()) return false; double aVal = aValue->value(); anAttr = theArgs.argument("valueMax"); aValue = std::dynamic_pointer_cast(anAttr); - if (!aValue.get()|| !anAttr->isInitialized() ) + if (!aValue.get()|| !anAttr->isInitialized()) return false; double aValMax = aValue->value(); @@ -64,12 +64,12 @@ bool FiltersPlugin_VolumeSize::isOk(const GeomShapePtr& theShape, const ResultPt double aSurfArea; double aVolume; std::string aError; - if( !GetBasicProperties(theShape, + if (!GetBasicProperties(theShape, aTolerance, aLength, aSurfArea, aVolume, - aError) ) + aError)) return false; anAttr = theArgs.argument("comparatorType"); diff --git a/src/GeomValidators/GeomValidators_Positive.cpp b/src/GeomValidators/GeomValidators_Positive.cpp index bc352836a..cfb033f31 100644 --- a/src/GeomValidators/GeomValidators_Positive.cpp +++ b/src/GeomValidators/GeomValidators_Positive.cpp @@ -45,10 +45,10 @@ bool GeomValidators_Positive::isValid(const AttributePtr& theAttribute, Events_InfoMessage& theError) const { double aMinValue = 1.e-12; - if(theArguments.size() == 1) { + if (theArguments.size() == 1) { std::list::const_iterator anIt = theArguments.begin(); double aValue = Config_PropManager::stringToDouble((*anIt).c_str()); - if(aValue != 0) { + if (aValue != 0) { // very probably ok aMinValue = aValue; } -- 2.39.2