SetOptionValue( "enforce_cad_edge_sizes", toEnforce ? "yes" : "no" );
NotifySubMeshesHypothesisModification();
}
+#else
+ (void)toEnforce; // maybe unused
#endif
}
//=============================================================================
}
//=============================================================================
-void BLSURFPlugin_Hypothesis::SetUseDeprecatedPatchMesher( bool useDeprecatedPatchMesher )
+void BLSURFPlugin_Hypothesis::SetUseDeprecatedPatchMesher( bool /*useDeprecatedPatchMesher*/ )
{
// if ( GetUseDeprecatedPatchMesher() != useDeprecatedPatchMesher )
// {
//=============================================================================
void BLSURFPlugin_Hypothesis::SetMaxNumberOfPointsPerPatch( int nb )
- throw (std::invalid_argument)
{
#if MESHGEMS_VERSION_HEX < 0x020A00
// Deprecated since MeshGems 2.10
SetOptionValue("max_number_of_points_per_patch", SMESH_Comment( nb ));
NotifySubMeshesHypothesisModification();
}
+#else
+ (void)nb; // maybe unused
#endif
}
//=============================================================================
//=============================================================================
void BLSURFPlugin_Hypothesis::SetMaxNumberOfThreads( int nb )
- throw (std::invalid_argument)
{
if ( nb < 0 )
throw std::invalid_argument( SMESH_Comment("Invalid number of threads: ") << nb );
//=============================================================================
void BLSURFPlugin_Hypothesis::SetPeriodicTolerance( CORBA::Double tol )
- throw (std::invalid_argument)
{
if ( tol <= 0 )
throw std::invalid_argument( SMESH_Comment("Invalid tolerance: ") << tol );
//=============================================================================
void BLSURFPlugin_Hypothesis::SetRequiredEntities( const std::string& howToTreat )
- throw (std::invalid_argument)
{
if ( howToTreat != "respect" && howToTreat != "ignore" && howToTreat != "clear" )
throw std::invalid_argument
//=============================================================================
void BLSURFPlugin_Hypothesis::SetSewingTolerance( CORBA::Double tol )
- throw (std::invalid_argument)
{
if ( tol <= 0 )
throw std::invalid_argument( SMESH_Comment("Invalid tolerance: ") << tol );
//=============================================================================
void BLSURFPlugin_Hypothesis::SetTags( const std::string& howToTreat )
- throw (std::invalid_argument)
{
if ( howToTreat != "respect" && howToTreat != "ignore" && howToTreat != "clear" )
throw std::invalid_argument
//=============================================================================
void BLSURFPlugin_Hypothesis::SetOptionValue(const std::string& optionName, const std::string& optionValue)
- throw (std::invalid_argument) {
-
+{
TOptionValues::iterator op_val = _option2value.find(optionName);
if (op_val == _option2value.end())
{
//=============================================================================
void BLSURFPlugin_Hypothesis::SetPreCADOptionValue(const std::string& optionName, const std::string& optionValue)
- throw (std::invalid_argument) {
-
+{
TOptionValues::iterator op_val = _preCADoption2value.find(optionName);
if (op_val == _preCADoption2value.end()) {
op_val = _option2value.find(optionName);
//=============================================================================
std::string BLSURFPlugin_Hypothesis::GetOptionValue(const std::string& optionName,
bool* isDefault) const
- throw (std::invalid_argument)
{
TOptionValues::const_iterator op_val = _option2value.find(optionName);
if (op_val == _option2value.end())
//=============================================================================
std::string BLSURFPlugin_Hypothesis::GetPreCADOptionValue(const std::string& optionName,
bool* isDefault) const
- throw (std::invalid_argument)
{
TOptionValues::const_iterator op_val = _preCADoption2value.find(optionName);
if (op_val == _preCADoption2value.end())
//=======================================================================
BLSURFPlugin_Hypothesis::TEnfVertexList BLSURFPlugin_Hypothesis::GetEnfVertexList(const TEntry& theFaceEntry)
- throw (std::invalid_argument) {
-
+{
if (_faceEntryEnfVertexListMap.count(theFaceEntry) > 0)
return _faceEntryEnfVertexListMap[theFaceEntry];
else
//function : GetEnfVertexCoordsList
//=======================================================================
-BLSURFPlugin_Hypothesis::TEnfVertexCoordsList BLSURFPlugin_Hypothesis::GetEnfVertexCoordsList(
- const TEntry& theFaceEntry) throw (std::invalid_argument) {
-
+BLSURFPlugin_Hypothesis::TEnfVertexCoordsList BLSURFPlugin_Hypothesis::GetEnfVertexCoordsList(const TEntry& theFaceEntry)
+{
if (_faceEntryCoordsListMap.count(theFaceEntry) > 0)
return _faceEntryCoordsListMap[theFaceEntry];
//=======================================================================
BLSURFPlugin_Hypothesis::TEntryList BLSURFPlugin_Hypothesis::GetEnfVertexEntryList(const TEntry& theFaceEntry)
- throw (std::invalid_argument) {
-
+{
if (_faceEntryEnfVertexEntryListMap.count(theFaceEntry) > 0)
return _faceEntryEnfVertexEntryListMap[theFaceEntry];
//=======================================================================
BLSURFPlugin_Hypothesis::TEnfVertex* BLSURFPlugin_Hypothesis::GetEnfVertex(TEnfVertexCoords coords)
- throw (std::invalid_argument) {
-
+{
if (_coordsEnfVertexMap.count(coords) > 0)
return _coordsEnfVertexMap[coords];
//=======================================================================
BLSURFPlugin_Hypothesis::TEnfVertex* BLSURFPlugin_Hypothesis::GetEnfVertex(const TEntry& theEnfVertexEntry)
- throw (std::invalid_argument) {
-
+{
if (_enfVertexEntryEnfVertexMap.count(theEnfVertexEntry) > 0)
return _enfVertexEntryEnfVertexMap[theEnfVertexEntry];
//=======================================================================
bool BLSURFPlugin_Hypothesis::ClearEnforcedVertex(const TEntry& theFaceEntry, double x, double y, double z,
- const TEntry& theVertexEntry) throw (std::invalid_argument) {
-
+ const TEntry& theVertexEntry)
+{
bool toNotify = false;
std::ostringstream msg;
TEnfVertex *oldEnfVertex;
//function : ClearEnforcedVertices
//=======================================================================
-bool BLSURFPlugin_Hypothesis::ClearEnforcedVertices(const TEntry& theFaceEntry) throw (std::invalid_argument) {
-
+bool BLSURFPlugin_Hypothesis::ClearEnforcedVertices(const TEntry& theFaceEntry)
+{
bool toNotify = false;
TEnfVertex *oldEnfVertex;
return hyp ? hyp->_GetAllEnforcedVerticesByEnfVertexEntry() : GetDefaultEnfVertexEntryEnfVertexMap();
}
-std::set<int> BLSURFPlugin_Hypothesis::GetEnfVertexNodeIDs(TEnfGroupName theGroupName) throw (std::invalid_argument)
+std::set<int> BLSURFPlugin_Hypothesis::GetEnfVertexNodeIDs(TEnfGroupName theGroupName)
{
TGroupNameNodeIDMap::const_iterator it = _groupNameNodeIDMap.find(theGroupName);
if (it != _groupNameNodeIDMap.end()) {
_groupNameNodeIDMap[theGroupName].insert(theNodeID);
}
-void BLSURFPlugin_Hypothesis::RemoveEnfVertexNodeID(TEnfGroupName theGroupName,int theNodeID) throw (std::invalid_argument)
+void BLSURFPlugin_Hypothesis::RemoveEnfVertexNodeID(TEnfGroupName theGroupName,int theNodeID)
{
TGroupNameNodeIDMap::iterator it = _groupNameNodeIDMap.find(theGroupName);
if (it != _groupNameNodeIDMap.end()) {
bool hasVerticesPeriodicity = false;
isOK = static_cast<bool>(load >> option_or_sm);
- if (isOK)
+ if (isOK) {
if ( (option_or_sm == "1")||(option_or_sm == "0") ) {
i = atoi(option_or_sm.c_str());
hasCADSurfOptions = true;
_phySizeRel = (bool) i;
}
- if (option_or_sm == "__OPTIONS_BEGIN__")
+ else if (option_or_sm == "__OPTIONS_BEGIN__")
hasOptions = true;
else if (option_or_sm == "__CUSTOM_OPTIONS_BEGIN__")
hasCustomOptions = true;
hasEdgesPeriodicity = true;
else if (option_or_sm == "__VERTICES_PERIODICITY_BEGIN__")
hasVerticesPeriodicity = true;
+ }
if (isOK && hasCADSurfOptions) {
isOK = static_cast<bool>(load >> i);
if (hasSizeMap) {
isOK = static_cast<bool>(load >> option_or_sm);
- if (isOK)
+ if (isOK) {
if (option_or_sm == "__ATTRACTORS_BEGIN__")
hasAttractor = true;
- if (option_or_sm == "__NEW_ATTRACTORS_BEGIN__")
+ else if (option_or_sm == "__NEW_ATTRACTORS_BEGIN__")
hasNewAttractor = true;
else if (option_or_sm == "__ENFORCED_VERTICES_BEGIN__")
hasEnforcedVertex = true;
hasEdgesPeriodicity = true;
else if (option_or_sm == "__VERTICES_PERIODICITY_BEGIN__")
hasVerticesPeriodicity = true;
+ }
}
std::string atEntry, atValue;
}
// New options in 2.9.6 (issue #17784)
- if ( static_cast<bool>( load >> _useSurfaceProximity ));
+ if ( static_cast<bool>( load >> _useSurfaceProximity ))
{
load >> _nbSurfaceProximityLayers;
load >> _surfaceProximityRatio;
*/
//================================================================================
-bool BLSURFPlugin_Hypothesis::SetParametersByMesh(const SMESH_Mesh* theMesh, const TopoDS_Shape& theShape) {
+bool BLSURFPlugin_Hypothesis::SetParametersByMesh(const SMESH_Mesh* /*theMesh*/, const TopoDS_Shape& /*theShape*/) {
return false;
}
//=============================================================================
bool BLSURFPlugin_Hypothesis::SetParametersByDefaults(const TDefaults& dflts,
- const SMESH_Mesh* theMesh)
+ const SMESH_Mesh* /*theMesh*/)
{
_phySize = GetDefaultPhySize(dflts._diagonal, _gen->GetBoundaryBoxSegmentation());
_minSize = GetDefaultMinSize(dflts._diagonal);
//================================================================================
bool BLSURFPlugin_Hypothesis::ToBool(const std::string& str, bool* isOk )
- throw (std::invalid_argument)
{
std::string s = str;
if ( isOk ) *isOk = true;
//================================================================================
double BLSURFPlugin_Hypothesis::ToDbl(const std::string& str, bool* isOk )
- throw (std::invalid_argument)
{
if ( str.empty() ) throw std::invalid_argument("Empty value provided");
//================================================================================
int BLSURFPlugin_Hypothesis::ToInt(const std::string& str, bool* isOk )
- throw (std::invalid_argument)
{
if ( str.empty() ) throw std::invalid_argument("Empty value provided");