Branch data Line data Source code
1 : : /* *****************************************************************
2 : : MESQUITE -- The Mesh Quality Improvement Toolkit
3 : :
4 : : Copyright 2006 Lawrence Livermore National Laboratory. Under
5 : : the terms of Contract B545069 with the University of Wisconsin --
6 : : Madison, Lawrence Livermore National Laboratory retains certain
7 : : rights in this software.
8 : :
9 : : This library is free software; you can redistribute it and/or
10 : : modify it under the terms of the GNU Lesser General Public
11 : : License as published by the Free Software Foundation; either
12 : : version 2.1 of the License, or (at your option) any later version.
13 : :
14 : : This library is distributed in the hope that it will be useful,
15 : : but WITHOUT ANY WARRANTY; without even the implied warranty of
16 : : MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17 : : Lesser General Public License for more details.
18 : :
19 : : You should have received a copy of the GNU Lesser General Public License
20 : : (lgpl.txt) along with this library; if not, write to the Free Software
21 : : Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
22 : :
23 : : (2006) [email protected]
24 : :
25 : : ***************************************************************** */
26 : :
27 : : #ifndef MSQ_GLOBAL_PATCH_CPP
28 : : #define MSQ_GLOBAL_PATCH_CPP
29 : :
30 : : /** \file GlobalPatch.cpp
31 : : * \brief
32 : : * \author Jason Kraftcheck
33 : : */
34 : :
35 : : #include "GlobalPatch.hpp"
36 : : #include "MeshInterface.hpp"
37 : : #include "MsqError.hpp"
38 : : #include <assert.h>
39 : :
40 : : namespace MBMesquite
41 : : {
42 : :
43 : : const PatchSet::PatchHandle GLOBAL_PATCH_HANDLE = 0;
44 : :
45 [ - + ]: 442 : GlobalPatch::~GlobalPatch() {}
46 : :
47 : 166 : void GlobalPatch::get_patch_handles( std::vector< PatchHandle >& patch_handles_out, MsqError& )
48 : : {
49 : 166 : patch_handles_out.resize( 1 );
50 : 166 : patch_handles_out[0] = GLOBAL_PATCH_HANDLE;
51 : 166 : }
52 : :
53 : 192 : void GlobalPatch::get_patch( PatchHandle patch_handle, std::vector< Mesh::ElementHandle >& elem_handles_out,
54 : : std::vector< Mesh::VertexHandle >& free_vertices_out, MsqError& err )
55 : : {
56 : 192 : free_vertices_out.clear();
57 [ - + ]: 192 : assert( GLOBAL_PATCH_HANDLE == patch_handle );
58 [ - + ][ # # ]: 192 : get_mesh()->get_all_elements( elem_handles_out, err );MSQ_ERRRTN( err );
[ - + ]
59 : : // get_mesh()->get_all_vertices( free_vertices_out, err ); MSQ_ERRRTN(err);
60 : : }
61 : :
62 [ + - ][ + - ]: 120 : } // namespace MBMesquite
63 : :
64 : : #endif
|