1 // Copyright (C) 2007-2019 CEA/DEN, EDF R&D
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License, or (at your option) any later version.
8 // This library is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 // Lesser General Public License for more details.
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
19 // Author : Anthony Geay (CEA/DEN)
21 #ifndef __TARGETINTERSECTOR__HXX__
22 #define __TARGETINTERSECTOR__HXX__
24 #include "INTERPKERNELDefines.hxx"
28 namespace INTERP_KERNEL
31 * \brief Abstract base class of Intersector classes.
32 * These classes represent a target element and calculate its intersection
33 * with the source elements.
35 template<class MyMeshType, class MyMatrix>
36 class TargetIntersector
39 typedef typename MyMeshType::MyConnType ConnType;
42 * Tool for cell intersection, result is always positive.
43 * @param icellT id of cell in target mesh in \b C \b mode.
44 * @param icellsS ids of cells in source mesh in \b C \b mode.
45 * @param res is an IN/OUT parameter that represents the icellTth row in final matrix, fed with at most icellsS elements.
47 virtual void intersectCells(ConnType targetCell, const std::vector<ConnType>& srcCells, MyMatrix& res) = 0;
49 virtual int getNumberOfRowsOfResMatrix() const = 0;
50 virtual int getNumberOfColsOfResMatrix() const = 0;
51 virtual ~TargetIntersector() { }