XdmfUnstructuredGrid.hpp 1.69 KB
Newer Older
1 2
#ifndef XDMFUNSTRUCTUREDGRID_HPP_
#define XDMFUNSTRUCTUREDGRID_HPP_
3 4 5 6 7

// Includes
#include "XdmfGrid.hpp"

/**
8
 * @brief An unstructured grid consisting of elements, points, and fields attached to the mesh.
9
 *
10 11 12
 * After creating an unstructured grid, the XdmfGeometry and XdmfTopology must be set.  The XdmfTopology
 * describes the element types contained in the grid and their connectivity.  The XdmfGeometry describes the
 * location of nodes.
13
 */
14
class XdmfUnstructuredGrid : public XdmfGrid {
15 16 17 18 19 20 21 22

public:

	/**
	 * Create a new XdmfGridUnstructured.
	 *
	 * @return constructed XdmfGridUnstructured.
	 */
23
	static boost::shared_ptr<XdmfUnstructuredGrid> New();
24

25
	virtual ~XdmfUnstructuredGrid();
26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60

	static const std::string ItemTag;

	/**
	 * Get the geometry associated with this grid.
	 *
	 * @return the geometry associated with this grid.
	 */
	boost::shared_ptr<XdmfGeometry> getGeometry();

	virtual std::string getItemTag() const;

	/**
	 * Get the topology associated with this grid.
	 *
	 * @return the topology associated with this grid.
	 */
	boost::shared_ptr<XdmfTopology> getTopology();

	/**
	 * Set the geometry associated with this grid.
	 *
	 * @param geometry an XdmfGeometry to associate with this grid.
	 */
	void setGeometry(const boost::shared_ptr<XdmfGeometry> geometry);

	/**
	 * Set the topology associated with this grid.
	 *
	 * @param topology an XdmfTopology to associate with this grid.
	 */
	void setTopology(const boost::shared_ptr<XdmfTopology> topology);

protected:

61
	XdmfUnstructuredGrid();
62 63 64

private:

65 66
	XdmfUnstructuredGrid(const XdmfUnstructuredGrid & grid);  // Not implemented.
	void operator=(const XdmfUnstructuredGrid & grid);  // Not implemented.
67 68 69

};

70
#endif /* XDMFUNSTRUCTUREDGRID_HPP_ */