X-Git-Url: http://git.salome-platform.org/gitweb/?p=modules%2Fsmesh.git;a=blobdiff_plain;f=src%2FSMESH%2FSMESH_HypoFilter.cxx;h=fe0bcd46684dd9267311df7bfe260f4e3a95f714;hp=ff14016d8dae8ae62af359d12b7862aaf5b3db77;hb=0aa84210cf7da3868cc8eb26b17a2da8e046b3ae;hpb=860d831343f1f1a42c4ff04fc3592c01150b03db diff --git a/src/SMESH/SMESH_HypoFilter.cxx b/src/SMESH/SMESH_HypoFilter.cxx index ff14016d8..fe0bcd466 100644 --- a/src/SMESH/SMESH_HypoFilter.cxx +++ b/src/SMESH/SMESH_HypoFilter.cxx @@ -17,7 +17,7 @@ // License along with this library; if not, write to the Free Software // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA // -// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org +// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com // // // @@ -75,6 +75,17 @@ bool SMESH_HypoFilter::ApplicablePredicate::IsOk(const SMESH_Hypothesis* aHyp, return SMESH_subMesh::IsApplicableHypotesis( aHyp, (TopAbs_ShapeEnum)_shapeType ); }; +//======================================================================= +//function : IsAuxiliaryPredicate::IsOk +//purpose : +//======================================================================= + +bool SMESH_HypoFilter::IsAuxiliaryPredicate::IsOk(const SMESH_Hypothesis* aHyp, + const TopoDS_Shape& /*aShape*/) const +{ + return aHyp->IsAuxiliary(); +}; + //======================================================================= //function : ApplicablePredicate::ApplicablePredicate //purpose : @@ -190,6 +201,17 @@ SMESH_HypoPredicate* SMESH_HypoFilter::IsAlgo() return new TypePredicate( MORE, SMESHDS_Hypothesis::PARAM_ALGO ); } +//======================================================================= +//function : IsAuxiliary +//purpose : +//======================================================================= + +SMESH_HypoPredicate* SMESH_HypoFilter::IsAuxiliary() +{ + return new IsAuxiliaryPredicate(); +} + + //======================================================================= //function : IsGlobal //purpose : @@ -287,6 +309,7 @@ SMESH_HypoFilter & SMESH_HypoFilter::Init ( SMESH_HypoPredicate* aPredicate, bo list::const_iterator pred = myPredicates.begin(); for ( ; pred != myPredicates.end(); ++pred ) delete *pred; + myPredicates.clear(); add( notNagate ? AND : AND_NOT, aPredicate ); return *this;