X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FSMESHFiltersSelection%2FSMESH_LogicalFilter.hxx;h=3069fa89025284ecaf45c08d100dd9ae129a4139;hb=986cacacdb49caea7239a784db3a64278d7e65bb;hp=ec10f865b062eb2781fb3cefdd6962ed25e862d6;hpb=e4737e85f0da6d3f90fd08f6be1c2825195fe16f;p=modules%2Fsmesh.git diff --git a/src/SMESHFiltersSelection/SMESH_LogicalFilter.hxx b/src/SMESHFiltersSelection/SMESH_LogicalFilter.hxx index ec10f865b..3069fa890 100644 --- a/src/SMESHFiltersSelection/SMESH_LogicalFilter.hxx +++ b/src/SMESHFiltersSelection/SMESH_LogicalFilter.hxx @@ -1,102 +1,60 @@ -// SALOME SALOMEGUI : implementation of desktop and GUI kernel +// Copyright (C) 2007-2012 CEA/DEN, EDF R&D, OPEN CASCADE // -// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, -// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS -// -// This library is free software; you can redistribute it and/or -// modify it under the terms of the GNU Lesser General Public -// License as published by the Free Software Foundation; either -// version 2.1 of the License. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// 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 +// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, +// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS // +// This library is free software; you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public +// License as published by the Free Software Foundation; either +// version 2.1 of the License. // +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. // +// You should have received a copy of the GNU Lesser General Public +// 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.salome-platform.org/ or email : webmaster.salome@opencascade.com +// + // File : SMESH_LogicalFilter.hxx -// Author : Sergey LITONIN // Module : SMESH - +// #ifndef _SMESH_LogicalFilter_HeaderFile #define _SMESH_LogicalFilter_HeaderFile -#include "SALOME_Filter.hxx" +#include "SMESH_Type.h" -#include -#include -#include +#include -DEFINE_STANDARD_HANDLE( SMESH_LogicalFilter, SALOME_Filter ) +#include -DEFINE_BASECOLLECTION( SMESH_FilterColl, Handle(SALOME_Filter) ) -DEFINE_LIST( SMESH_ListOfFilter, SMESH_FilterColl, Handle(SALOME_Filter) ) - - -/* - Class : SMESH_LogicalFilter - Description : Filter for combaining several filters with logical operation (OR or AND) -*/ - -class SMESH_LogicalFilter : public SALOME_Filter +class SMESHFILTERSSELECTION_EXPORT SMESH_LogicalFilter : public SUIT_SelectionFilter { -public: - - enum { LO_OR, LO_AND, LO_UNDEFINED }; - -public: + public: + enum { LO_OR, LO_AND, LO_NOT, LO_UNDEFINED }; - SMESH_LogicalFilter( const SMESH_ListOfFilter&, const int ); + public: + SMESH_LogicalFilter( const QList&, const int, bool takeOwnership=false ); + virtual ~SMESH_LogicalFilter(); + virtual bool isOk (const SUIT_DataOwner*) const; - virtual ~SMESH_LogicalFilter(); - virtual Standard_Boolean IsOk( const Handle(SALOME_InteractiveObject)& ) const; - - void SetFilters( const SMESH_ListOfFilter& ); - void SetLogOp( const int ); - const SMESH_ListOfFilter& GetFilters() const; - int GetLogOp() const; + void setFilters (const QList&); + void setOperation (const int); + const QList getFilters() const; + int getOperation() const; private: + void deleteFilters(); - SMESH_ListOfFilter myFilters; - int myLogOp; - -public: - DEFINE_STANDARD_RTTI( SMESH_LogicalFilter ) +private: + QList myFilters; + int myOperation; + bool myOwnership; }; #endif - - - - - - - - - - - - - - - - - - - - - - - - - -