1 // Copyright (C) 2007-2013 CEA/DEN, EDF R&D, OPEN CASCADE
3 // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
6 // This library is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU Lesser General Public
8 // License as published by the Free Software Foundation; either
9 // version 2.1 of the License.
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 // Lesser General Public License for more details.
16 // You should have received a copy of the GNU Lesser General Public
17 // License along with this library; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
23 // SMESH SMESH_I : idl implementation based on 'SMESH' unit's calsses
24 // File : SMESH_Filter_i.hxx
25 // Author : Alexey Petrov, OCC
28 #ifndef _SMESH_FILTER_I_HXX_
29 #define _SMESH_FILTER_I_HXX_
33 #include <SALOMEconfig.h>
34 #include CORBA_SERVER_HEADER(SMESH_Filter)
36 #include <LDOM_Document.hxx>
37 #include <TopoDS_Shape.hxx>
39 #include "SALOME_GenericObj_i.hh"
40 #include "SMESH_ControlsDef.hxx"
49 // ================================================================================
55 Description : Predicate for verifying whether entiy belong to
56 specified geometrical support
58 class SMESH_I_EXPORT BelongToGeom: public virtual Predicate
63 virtual void SetMesh( const SMDS_Mesh* theMesh );
64 virtual void SetGeom( const TopoDS_Shape& theShape );
66 virtual bool IsSatisfy( long theElementId );
68 virtual void SetType( SMDSAbs_ElementType theType );
69 virtual SMDSAbs_ElementType GetType() const;
71 TopoDS_Shape GetShape();
72 const SMESHDS_Mesh* GetMeshDS() const;
74 void SetTolerance( double );
75 double GetTolerance();
81 const SMESHDS_Mesh* myMeshDS;
82 SMDSAbs_ElementType myType;
84 double myTolerance; // only if myIsSubshape == false
85 Controls::ElementsOnShapePtr myElementsOnShapePtr; // only if myIsSubshape == false
87 typedef boost::shared_ptr<BelongToGeom> BelongToGeomPtr;
91 Description : Predicate for verifying whether entiy lying or partially lying on
92 specified geometrical support
94 class SMESH_I_EXPORT LyingOnGeom: public virtual Predicate
99 virtual void SetMesh( const SMDS_Mesh* theMesh );
100 virtual void SetGeom( const TopoDS_Shape& theShape );
102 virtual bool IsSatisfy( long theElementId );
104 virtual void SetType( SMDSAbs_ElementType theType );
105 virtual SMDSAbs_ElementType GetType() const;
107 TopoDS_Shape GetShape();
108 const SMESHDS_Mesh* GetMeshDS() const;
110 void SetTolerance( double );
111 double GetTolerance();
113 virtual bool Contains( const SMESHDS_Mesh* theMeshDS,
114 const TopoDS_Shape& theShape,
115 const SMDS_MeshElement* theElem,
116 TopAbs_ShapeEnum theFindShapeEnum,
117 TopAbs_ShapeEnum theAvoidShapeEnum = TopAbs_SHAPE );
121 TopoDS_Shape myShape;
122 const SMESHDS_Mesh* myMeshDS;
123 SMDSAbs_ElementType myType;
125 double myTolerance; // only if myIsSubshape == false
126 Controls::ElementsOnShapePtr myElementsOnShapePtr; // only if myIsSubshape == false
128 typedef boost::shared_ptr<LyingOnGeom> LyingOnGeomPtr;
130 } // namespace Controls
132 // ================================================================================
139 Description : An abstact class for all functors
141 class SMESH_I_EXPORT Functor_i: public virtual POA_SMESH::Functor,
142 public virtual SALOME::GenericObj_i
145 virtual void SetMesh( SMESH_Mesh_ptr theMesh );
146 Controls::FunctorPtr GetFunctor() { return myFunctorPtr; }
147 ElementType GetElementType();
153 Controls::FunctorPtr myFunctorPtr;
157 Class : NumericalFunctor_i
158 Description : Base class for numerical functors
160 class SMESH_I_EXPORT NumericalFunctor_i: public virtual POA_SMESH::NumericalFunctor,
161 public virtual Functor_i
164 CORBA::Double GetValue( CORBA::Long theElementId );
165 SMESH::Histogram* GetHistogram(CORBA::Short nbIntervals,
166 CORBA::Boolean isLogarithmic);
167 SMESH::Histogram* GetLocalHistogram(CORBA::Short nbIntervals,
168 CORBA::Boolean isLogarithmic,
169 SMESH::SMESH_IDSource_ptr object);
170 void SetPrecision( CORBA::Long thePrecision );
171 CORBA::Long GetPrecision();
172 Controls::NumericalFunctorPtr GetNumericalFunctor();
175 Controls::NumericalFunctorPtr myNumericalFunctorPtr;
180 Class : SMESH_MinimumAngleFunct
181 Description : Functor for calculation of minimum angle
183 class SMESH_I_EXPORT MinimumAngle_i: public virtual POA_SMESH::MinimumAngle,
184 public virtual NumericalFunctor_i
188 FunctorType GetFunctorType();
193 Class : AspectRatio_i
194 Description : Functor for calculating aspect ratio
196 class SMESH_I_EXPORT AspectRatio_i: public virtual POA_SMESH::AspectRatio,
197 public virtual NumericalFunctor_i
201 FunctorType GetFunctorType();
206 Class : AspectRatio3D_i
207 Description : Functor for calculating aspect ratio for 3D
209 class SMESH_I_EXPORT AspectRatio3D_i: public virtual POA_SMESH::AspectRatio3D,
210 public virtual NumericalFunctor_i
214 FunctorType GetFunctorType();
220 Description : Functor for calculating warping
222 class SMESH_I_EXPORT Warping_i: public virtual POA_SMESH::Warping,
223 public virtual NumericalFunctor_i
227 FunctorType GetFunctorType();
233 Description : Functor for calculating taper
235 class SMESH_I_EXPORT Taper_i: public virtual POA_SMESH::Taper,
236 public virtual NumericalFunctor_i
240 FunctorType GetFunctorType();
246 Description : Functor for calculating skew in degrees
248 class SMESH_I_EXPORT Skew_i: public virtual POA_SMESH::Skew,
249 public virtual NumericalFunctor_i
253 FunctorType GetFunctorType();
259 Description : Functor for calculating area
261 class SMESH_I_EXPORT Area_i: public virtual POA_SMESH::Area,
262 public virtual NumericalFunctor_i
266 FunctorType GetFunctorType();
272 Description : Functor for calculating volume of 3D element
274 class SMESH_I_EXPORT Volume3D_i: public virtual POA_SMESH::Volume3D,
275 public virtual NumericalFunctor_i
279 FunctorType GetFunctorType();
284 Class : MaxElementLength2D_i
285 Description : Functor for calculating maximum length of 2D element
287 class SMESH_I_EXPORT MaxElementLength2D_i: public virtual POA_SMESH::MaxElementLength2D,
288 public virtual NumericalFunctor_i
291 MaxElementLength2D_i();
292 FunctorType GetFunctorType();
297 Class : MaxElementLength3D_i
298 Description : Functor for calculating maximum length of 3D element
300 class SMESH_I_EXPORT MaxElementLength3D_i: public virtual POA_SMESH::MaxElementLength3D,
301 public virtual NumericalFunctor_i
304 MaxElementLength3D_i();
305 FunctorType GetFunctorType();
311 Description : Functor for calculating length of edge
313 class SMESH_I_EXPORT Length_i: public virtual POA_SMESH::Length,
314 public virtual NumericalFunctor_i
318 FunctorType GetFunctorType();
323 Description : Functor for calculating length of edge
325 class SMESH_I_EXPORT Length2D_i: public virtual POA_SMESH::Length2D,
326 public virtual NumericalFunctor_i
330 SMESH::Length2D::Values* GetValues();
331 FunctorType GetFunctorType();
334 Controls::Length2DPtr myLength2DPtr;
338 Class : MultiConnection_i
339 Description : Functor for calculating number of faces conneted to the edge
341 class SMESH_I_EXPORT MultiConnection_i: public virtual POA_SMESH::MultiConnection,
342 public virtual NumericalFunctor_i
346 FunctorType GetFunctorType();
350 Class : MultiConnection2D_i
351 Description : Functor for calculating number of faces conneted to the edge
353 class SMESH_I_EXPORT MultiConnection2D_i: public virtual POA_SMESH::MultiConnection2D,
354 public virtual NumericalFunctor_i
357 MultiConnection2D_i();
358 SMESH::MultiConnection2D::Values* GetValues();
359 FunctorType GetFunctorType();
362 Controls::MultiConnection2DPtr myMulticonnection2DPtr;
366 Class : BallDiameter_i
367 Description : Functor returning diameter of a ball element
369 class SMESH_I_EXPORT BallDiameter_i: public virtual POA_SMESH::BallDiameter,
370 public virtual NumericalFunctor_i
374 FunctorType GetFunctorType();
383 Description : Base class for all predicates
385 class SMESH_I_EXPORT Predicate_i: public virtual POA_SMESH::Predicate,
386 public virtual Functor_i
389 CORBA::Boolean IsSatisfy( CORBA::Long theElementId );
390 CORBA::Long NbSatisfying( SMESH::SMESH_IDSource_ptr obj );
391 Controls::PredicatePtr GetPredicate();
394 Controls::PredicatePtr myPredicatePtr;
399 Class : BadOrientedVolume_i
400 Description : Verify whether a mesh volume is incorrectly oriented from
401 the point of view of MED convention
403 class SMESH_I_EXPORT BadOrientedVolume_i: public virtual POA_SMESH::BadOrientedVolume,
404 public virtual Predicate_i
407 BadOrientedVolume_i();
408 FunctorType GetFunctorType();
412 Class : BareBorderVolume_i
413 Description : Verify whether a mesh volume has a free facet without a face on it
415 class SMESH_I_EXPORT BareBorderVolume_i: public virtual POA_SMESH::BareBorderVolume,
416 public virtual Predicate_i
419 BareBorderVolume_i();
420 FunctorType GetFunctorType();
424 Class : BareBorderFace_i
425 Description : Verify whether a mesh face has a free border without an edge on it
427 class SMESH_I_EXPORT BareBorderFace_i: public virtual POA_SMESH::BareBorderFace,
428 public virtual Predicate_i
432 FunctorType GetFunctorType();
436 Class : OverConstrainedVolume_i
437 Description : Verify whether a mesh volume has only one facet shared with other volumes
439 class SMESH_I_EXPORT OverConstrainedVolume_i: public virtual POA_SMESH::OverConstrainedVolume,
440 public virtual Predicate_i
443 OverConstrainedVolume_i();
444 FunctorType GetFunctorType();
448 Class : OverConstrainedFace_i
449 Description : Verify whether a mesh face has only one border shared with other faces
451 class SMESH_I_EXPORT OverConstrainedFace_i: public virtual POA_SMESH::OverConstrainedFace,
452 public virtual Predicate_i
455 OverConstrainedFace_i();
456 FunctorType GetFunctorType();
460 Class : BelongToGeom_i
461 Description : Predicate for selection on geometrical support
463 class SMESH_I_EXPORT BelongToGeom_i: public virtual POA_SMESH::BelongToGeom,
464 public virtual Predicate_i
468 virtual ~BelongToGeom_i();
470 void SetGeom( GEOM::GEOM_Object_ptr theGeom );
471 void SetElementType( ElementType theType );
472 FunctorType GetFunctorType();
474 void SetGeom( const TopoDS_Shape& theShape );
476 void SetShapeName( const char* theName );
477 void SetShape( const char* theID, const char* theName );
478 char* GetShapeName();
481 void SetTolerance( CORBA::Double );
482 CORBA::Double GetTolerance();
485 Controls::BelongToGeomPtr myBelongToGeomPtr;
491 Class : BelongToSurface_i
492 Description : Verify whether mesh element lie in pointed Geom planar object
494 class SMESH_I_EXPORT BelongToSurface_i: public virtual POA_SMESH::BelongToSurface,
495 public virtual Predicate_i
498 BelongToSurface_i( const Handle(Standard_Type)& );
499 virtual ~BelongToSurface_i();
501 void SetSurface( GEOM::GEOM_Object_ptr theGeom, ElementType theType );
503 void SetShapeName( const char* theName, ElementType theType );
504 void SetShape( const char* theID, const char* theName, ElementType theType );
505 char* GetShapeName();
508 void SetTolerance( CORBA::Double );
509 CORBA::Double GetTolerance();
511 void SetUseBoundaries( CORBA::Boolean theUseBndRestrictions );
512 CORBA::Boolean GetUseBoundaries();
515 Controls::ElementsOnSurfacePtr myElementsOnSurfacePtr;
518 Handle(Standard_Type) mySurfaceType;
522 Class : BelongToPlane_i
523 Description : Verify whether mesh element lie in pointed Geom planar object
525 class SMESH_I_EXPORT BelongToPlane_i: public virtual POA_SMESH::BelongToPlane,
526 public virtual BelongToSurface_i
530 void SetPlane( GEOM::GEOM_Object_ptr theGeom, ElementType theType );
531 FunctorType GetFunctorType();
535 Class : BelongToCylinder_i
536 Description : Verify whether mesh element lie in pointed Geom cylindrical object
538 class SMESH_I_EXPORT BelongToCylinder_i: public virtual POA_SMESH::BelongToCylinder,
539 public virtual BelongToSurface_i
542 BelongToCylinder_i();
543 void SetCylinder( GEOM::GEOM_Object_ptr theGeom, ElementType theType );
544 FunctorType GetFunctorType();
548 Class : BelongToGenSurface_i
549 Description : Verify whether mesh element lie on pointed Geom surfasic object
551 class BelongToGenSurface_i: public virtual POA_SMESH::BelongToGenSurface,
552 public virtual BelongToSurface_i
555 BelongToGenSurface_i();
556 void SetSurface( GEOM::GEOM_Object_ptr theGeom, ElementType theType );
557 FunctorType GetFunctorType();
561 Class : LyingOnGeom_i
562 Description : Predicate for selection on geometrical support(lying or partially lying)
564 class SMESH_I_EXPORT LyingOnGeom_i: public virtual POA_SMESH::LyingOnGeom,
565 public virtual Predicate_i
569 virtual ~LyingOnGeom_i();
571 void SetGeom( GEOM::GEOM_Object_ptr theGeom );
572 void SetElementType( ElementType theType );
573 FunctorType GetFunctorType();
575 void SetGeom( const TopoDS_Shape& theShape );
577 void SetShapeName( const char* theName );
578 void SetShape( const char* theID, const char* theName );
579 char* GetShapeName();
582 void SetTolerance( CORBA::Double );
583 CORBA::Double GetTolerance();
586 Controls::LyingOnGeomPtr myLyingOnGeomPtr;
592 Class : FreeBorders_i
593 Description : Predicate for free borders
595 class SMESH_I_EXPORT FreeBorders_i: public virtual POA_SMESH::FreeBorders,
596 public virtual Predicate_i
600 FunctorType GetFunctorType();
606 Description : Predicate for free edges
608 class SMESH_I_EXPORT FreeEdges_i: public virtual POA_SMESH::FreeEdges,
609 public virtual Predicate_i
613 SMESH::FreeEdges::Borders* GetBorders();
614 FunctorType GetFunctorType();
617 Controls::FreeEdgesPtr myFreeEdgesPtr;
623 Description : Predicate for free faces
625 class SMESH_I_EXPORT FreeFaces_i: public virtual POA_SMESH::FreeFaces,
626 public virtual Predicate_i
630 FunctorType GetFunctorType();
636 Description : Predicate for free nodes
638 class SMESH_I_EXPORT FreeNodes_i: public virtual POA_SMESH::FreeNodes,
639 public virtual Predicate_i
643 FunctorType GetFunctorType();
649 Description : Predicate for equal nodes
651 class SMESH_I_EXPORT EqualNodes_i: public virtual POA_SMESH::EqualNodes,
652 public virtual Predicate_i
656 FunctorType GetFunctorType();
657 void SetTolerance( double );
658 double GetTolerance();
661 Controls::CoincidentNodesPtr myCoincidentNodesPtr;
665 Description : Predicate for equal edges
667 class SMESH_I_EXPORT EqualEdges_i: public virtual POA_SMESH::EqualEdges,
668 public virtual Predicate_i
672 FunctorType GetFunctorType();
676 Description : Predicate for equal Faces
678 class SMESH_I_EXPORT EqualFaces_i: public virtual POA_SMESH::EqualFaces,
679 public virtual Predicate_i
683 FunctorType GetFunctorType();
686 Class : EqualVolumes_i
687 Description : Predicate for equal Volumes
689 class SMESH_I_EXPORT EqualVolumes_i: public virtual POA_SMESH::EqualVolumes,
690 public virtual Predicate_i
694 FunctorType GetFunctorType();
700 Description : Predicate for Range of Ids
702 class SMESH_I_EXPORT RangeOfIds_i: public virtual POA_SMESH::RangeOfIds,
703 public virtual Predicate_i
707 void SetRange( const SMESH::long_array& theIds );
708 CORBA::Boolean SetRangeStr( const char* theRange );
711 void SetElementType( ElementType theType );
712 FunctorType GetFunctorType();
715 Controls::RangeOfIdsPtr myRangeOfIdsPtr;
719 Class : LinearOrQuadratic_i
720 Description : Verify whether a mesh element is linear
722 class SMESH_I_EXPORT LinearOrQuadratic_i: public virtual POA_SMESH::LinearOrQuadratic,
723 public virtual Predicate_i
726 LinearOrQuadratic_i();
727 FunctorType GetFunctorType();
728 void SetElementType( ElementType theType );
731 Controls::LinearOrQuadraticPtr myLinearOrQuadraticPtr;
736 Description : Functor for check color of group to whic mesh element belongs to
738 class SMESH_I_EXPORT GroupColor_i: public virtual POA_SMESH::GroupColor,
739 public virtual Predicate_i
743 FunctorType GetFunctorType();
745 void SetElementType( ElementType theType );
746 void SetColorStr( const char* theColor );
750 Controls::GroupColorPtr myGroupColorPtr;
754 Class : ElemGeomType_i
755 Description : Functor for check element geometry type
757 class SMESH_I_EXPORT ElemGeomType_i: public virtual POA_SMESH::ElemGeomType,
758 public virtual Predicate_i
762 FunctorType GetFunctorType();
764 void SetElementType ( ElementType theType );
765 void SetGeometryType( GeometryType theType );
766 GeometryType GetGeometryType() const;
769 Controls::ElemGeomTypePtr myElemGeomTypePtr;
773 Class : ElemEntityType_i
774 Description : Functor for check element entity type
776 class SMESH_I_EXPORT ElemEntityType_i: public virtual POA_SMESH::ElemEntityType,
777 public virtual Predicate_i
781 FunctorType GetFunctorType();
783 void SetElementType ( ElementType theType );
784 void SetEntityType( EntityType theEntityType );
785 EntityType GetEntityType() const;
788 Controls::ElemEntityTypePtr myElemEntityTypePtr;
792 Class : CoplanarFaces_i
793 Description : Returns true if a mesh face is a coplanar neighbour to a given one
795 class SMESH_I_EXPORT CoplanarFaces_i: public virtual POA_SMESH::CoplanarFaces,
796 public virtual Predicate_i
800 FunctorType GetFunctorType();
802 void SetFace ( CORBA::Long theFaceID );
803 void SetTolerance( CORBA::Double theToler );
804 char* GetFaceAsString () const;
805 CORBA::Long GetFace () const;
806 CORBA::Double GetTolerance () const;
808 Controls::CoplanarFacesPtr myCoplanarFacesPtr;
812 * Class : ConnectedElements_i
813 * Description : Returns true if an element is connected via other elements to the element
814 * located at a given point.
816 class SMESH_I_EXPORT ConnectedElements_i: public virtual POA_SMESH::ConnectedElements,
817 public virtual Predicate_i
820 ConnectedElements_i();
821 FunctorType GetFunctorType();
823 void SetElementType( ElementType theType );
824 void SetPoint( CORBA::Double x, CORBA::Double y, CORBA::Double z );
825 void SetVertex( GEOM::GEOM_Object_ptr vertex )
826 throw (SALOME::SALOME_Exception);
827 void SetNode ( CORBA::Long nodeID )
828 throw (SALOME::SALOME_Exception);
829 void SetThreshold ( const char* threshold,
830 SMESH::ConnectedElements::ThresholdType type )
831 throw (SALOME::SALOME_Exception);
832 char* GetThreshold ( SMESH::ConnectedElements::ThresholdType& type );
835 Controls::ConnectedElementsPtr myConnectedElementsPtr;
836 std::string myVertexID;
841 Description : Base class for comparators
843 class SMESH_I_EXPORT Comparator_i: public virtual POA_SMESH::Comparator,
844 public virtual Predicate_i
847 virtual ~Comparator_i();
849 virtual void SetMargin( CORBA::Double );
850 virtual void SetNumFunctor( NumericalFunctor_ptr );
852 Controls::ComparatorPtr GetComparator();
853 NumericalFunctor_i* GetNumFunctor_i();
854 CORBA::Double GetMargin();
859 Controls::ComparatorPtr myComparatorPtr;
860 NumericalFunctor_i* myNumericalFunctor;
866 Description : Comparator "<"
868 class SMESH_I_EXPORT LessThan_i: public virtual POA_SMESH::LessThan,
869 public virtual Comparator_i
873 FunctorType GetFunctorType();
879 Description : Comparator ">"
881 class SMESH_I_EXPORT MoreThan_i: public virtual POA_SMESH::MoreThan,
882 public virtual Comparator_i
886 FunctorType GetFunctorType();
892 Description : Comparator "="
894 class SMESH_I_EXPORT EqualTo_i: public virtual POA_SMESH::EqualTo,
895 public virtual Comparator_i
899 virtual void SetTolerance( CORBA::Double );
900 CORBA::Double GetTolerance();
901 FunctorType GetFunctorType();
904 Controls::EqualToPtr myEqualToPtr;
910 Description : Logical NOT predicate
912 class SMESH_I_EXPORT LogicalNOT_i: public virtual POA_SMESH::LogicalNOT,
913 public virtual Predicate_i
917 virtual ~LogicalNOT_i();
919 virtual void SetPredicate( Predicate_ptr );
920 Predicate_i* GetPredicate_i();
921 FunctorType GetFunctorType();
924 Controls::LogicalNOTPtr myLogicalNOTPtr;
925 Predicate_i* myPredicate;
930 Class : LogicalBinary_i
931 Description : Base class for binary logical predicate
933 class SMESH_I_EXPORT LogicalBinary_i: public virtual POA_SMESH::LogicalBinary,
934 public virtual Predicate_i
937 virtual ~LogicalBinary_i();
938 virtual void SetMesh( SMESH_Mesh_ptr theMesh );
939 virtual void SetPredicate1( Predicate_ptr );
940 virtual void SetPredicate2( Predicate_ptr );
942 Controls::LogicalBinaryPtr GetLogicalBinary();
943 Predicate_i* GetPredicate1_i();
944 Predicate_i* GetPredicate2_i();
949 Controls::LogicalBinaryPtr myLogicalBinaryPtr;
950 Predicate_i* myPredicate1;
951 Predicate_i* myPredicate2;
957 Description : Logical AND
959 class SMESH_I_EXPORT LogicalAND_i: public virtual POA_SMESH::LogicalAND,
960 public virtual LogicalBinary_i
964 FunctorType GetFunctorType();
970 Description : Logical OR
972 class SMESH_I_EXPORT LogicalOR_i: public virtual POA_SMESH::LogicalOR,
973 public virtual LogicalBinary_i
977 FunctorType GetFunctorType();
984 class SMESH_I_EXPORT Filter_i: public virtual POA_SMESH::Filter,
985 public virtual SALOME::GenericObj_i
993 SetPredicate( Predicate_ptr );
997 SetMesh( SMESH_Mesh_ptr );
1001 GetElementsId( Predicate_i*,
1003 Controls::Filter::TIdSequence& );
1006 GetElementsId( Predicate_i*,
1008 Controls::Filter::TIdSequence& );
1012 GetElementsId( SMESH_Mesh_ptr );
1020 GetCriteria( SMESH::Filter::Criteria_out theCriteria );
1024 SetCriteria( const SMESH::Filter::Criteria& theCriteria );
1030 Predicate_i* GetPredicate_i();
1032 // =========================
1033 // SMESH_IDSource interface
1034 // =========================
1035 virtual SMESH::long_array* GetIDs();
1036 virtual SMESH::long_array* GetMeshInfo();
1037 virtual SMESH::long_array* GetNbElementsByType();
1038 virtual SMESH::array_of_ElementType* GetTypes();
1039 virtual SMESH::SMESH_Mesh_ptr GetMesh();
1040 virtual bool IsMeshInfoCorrect() { return true; }
1043 * \brief Object notified on change of predicate
1045 struct TPredicateChangeWaiter
1047 virtual void PredicateChanged() = 0;
1049 void AddWaiter( TPredicateChangeWaiter* waiter );
1050 void RemoveWaiter( TPredicateChangeWaiter* waiter );
1053 Controls::Filter myFilter;
1054 Predicate_i* myPredicate;
1055 SMESH_Mesh_var myMesh;
1057 std::list<TPredicateChangeWaiter*> myWaiters;
1064 class SMESH_I_EXPORT FilterLibrary_i: public virtual POA_SMESH::FilterLibrary,
1065 public virtual SALOME::GenericObj_i
1068 FilterLibrary_i( const char* theFileName );
1072 Filter_ptr Copy( const char* theFilterName );
1074 CORBA::Boolean Add ( const char* theFilterName, Filter_ptr theFilter );
1075 CORBA::Boolean AddEmpty( const char* theFilterName, ElementType theType );
1076 CORBA::Boolean Delete ( const char* theFilterName );
1077 CORBA::Boolean Replace ( const char* theFilterName,
1078 const char* theNewName,
1079 Filter_ptr theFilter );
1081 CORBA::Boolean Save();
1082 CORBA::Boolean SaveAs( const char* aFileName );
1084 CORBA::Boolean IsPresent( const char* aFilterName );
1085 CORBA::Long NbFilters( ElementType );
1086 string_array* GetNames( ElementType );
1087 string_array* GetAllNames();
1088 void SetFileName( const char* theFileName );
1089 char* GetFileName();
1093 LDOM_Document myDoc;
1094 FilterManager_var myFilterMgr;
1102 class SMESH_I_EXPORT FilterManager_i: public virtual POA_SMESH::FilterManager,
1103 public virtual SALOME::GenericObj_i
1109 MinimumAngle_ptr CreateMinimumAngle();
1110 AspectRatio_ptr CreateAspectRatio();
1111 AspectRatio3D_ptr CreateAspectRatio3D();
1112 Warping_ptr CreateWarping();
1113 Taper_ptr CreateTaper();
1114 Skew_ptr CreateSkew();
1115 Area_ptr CreateArea();
1116 Volume3D_ptr CreateVolume3D();
1117 MaxElementLength2D_ptr CreateMaxElementLength2D();
1118 MaxElementLength3D_ptr CreateMaxElementLength3D();
1119 Length_ptr CreateLength();
1120 Length2D_ptr CreateLength2D();
1121 MultiConnection_ptr CreateMultiConnection();
1122 MultiConnection2D_ptr CreateMultiConnection2D();
1123 BallDiameter_ptr CreateBallDiameter();
1125 BelongToGeom_ptr CreateBelongToGeom();
1126 BelongToPlane_ptr CreateBelongToPlane();
1127 BelongToCylinder_ptr CreateBelongToCylinder();
1128 BelongToGenSurface_ptr CreateBelongToGenSurface();
1130 LyingOnGeom_ptr CreateLyingOnGeom();
1132 FreeBorders_ptr CreateFreeBorders();
1133 FreeEdges_ptr CreateFreeEdges();
1134 FreeNodes_ptr CreateFreeNodes();
1135 FreeFaces_ptr CreateFreeFaces();
1137 EqualNodes_ptr CreateEqualNodes();
1138 EqualEdges_ptr CreateEqualEdges();
1139 EqualFaces_ptr CreateEqualFaces();
1140 EqualVolumes_ptr CreateEqualVolumes();
1142 RangeOfIds_ptr CreateRangeOfIds();
1143 BadOrientedVolume_ptr CreateBadOrientedVolume();
1144 BareBorderFace_ptr CreateBareBorderFace();
1145 BareBorderVolume_ptr CreateBareBorderVolume();
1146 OverConstrainedFace_ptr CreateOverConstrainedFace();
1147 OverConstrainedVolume_ptr CreateOverConstrainedVolume();
1148 LinearOrQuadratic_ptr CreateLinearOrQuadratic();
1149 GroupColor_ptr CreateGroupColor();
1150 ElemGeomType_ptr CreateElemGeomType();
1151 ElemEntityType_ptr CreateElemEntityType();
1152 CoplanarFaces_ptr CreateCoplanarFaces();
1153 ConnectedElements_ptr CreateConnectedElements();
1155 LessThan_ptr CreateLessThan();
1156 MoreThan_ptr CreateMoreThan();
1157 EqualTo_ptr CreateEqualTo();
1159 LogicalNOT_ptr CreateLogicalNOT();
1160 LogicalAND_ptr CreateLogicalAND();
1161 LogicalOR_ptr CreateLogicalOR();
1163 Filter_ptr CreateFilter();
1165 FilterLibrary_ptr LoadLibrary( const char* aFileName );
1166 FilterLibrary_ptr CreateLibrary();
1167 CORBA::Boolean DeleteLibrary( const char* aFileName );
1172 GetPredicate( SMESH::Predicate_ptr thePredicate );
1174 const char* FunctorTypeToString(SMESH::FunctorType ft);
1175 SMESH::FunctorType StringToFunctorType(const char* str);