1
// Copyright (C) 2006 Anders Logg.
2
// Licensed under the GNU LGPL Version 2.1.
4
// First added: 2006-05-08
5
// Last changed: 2006-06-22
7
#include <dolfin/MeshData.h>
9
using namespace dolfin;
11
//-----------------------------------------------------------------------------
12
MeshData::MeshData() : cell_type(0)
16
//-----------------------------------------------------------------------------
17
MeshData::MeshData(const MeshData& data) : cell_type(0)
21
//-----------------------------------------------------------------------------
26
//-----------------------------------------------------------------------------
27
const MeshData& MeshData::operator= (const MeshData& data)
29
// Clear old data if any
33
topology = data.topology;
34
geometry = data.geometry;
36
// Create new cell type
38
cell_type = CellType::create(data.cell_type->cellType());
44
//-----------------------------------------------------------------------------
45
void MeshData::clear()
47
// Clear mesh topology
50
// Clear mesh geometry
58
//-----------------------------------------------------------------------------
59
void MeshData::disp() const
61
cout << "Mesh data" << endl;
62
cout << "---------" << endl << endl;
67
// Display topology and geometry
72
cout << "Cell type" << endl;
73
cout << "---------" << endl << endl;
76
cout << cell_type->description() << endl;
78
cout << "undefined" << endl;
85
//-----------------------------------------------------------------------------