![]() |
00001 // Copyright (C) 2003 Johan Hoffman and Anders Logg. 00002 // Licensed under the GNU GPL Version 2. 00003 00004 #ifndef __BOUNDARY_DATA_H 00005 #define __BOUNDARY_DATA_H 00006 00007 #include <dolfin/NodeIterator.h> 00008 #include <dolfin/List.h> 00009 00010 namespace dolfin { 00011 00012 class Node; 00013 class Edge; 00014 class Face; 00015 class Mesh; 00016 00017 class BoundaryData { 00018 public: 00019 00020 // Create an empty set of boundary data 00021 BoundaryData(Mesh& mesh); 00022 00024 ~BoundaryData(); 00025 00027 void clear(); 00028 00030 void add(Node& node); 00031 00033 void add(Edge& edge); 00034 00036 void add(Face& face); 00037 00039 bool empty(); 00040 00042 int noNodes() const; 00043 00045 int noEdges() const; 00046 00048 int noFaces() const; 00049 00051 friend class Mesh; 00052 friend class BoundaryInit; 00053 friend class NodeIterator::BoundaryNodeIterator; 00054 friend class EdgeIterator::BoundaryEdgeIterator; 00055 friend class FaceIterator::BoundaryFaceIterator; 00056 00057 private: 00058 00059 // Change the mesh pointer 00060 void setMesh(Mesh& mesh); 00061 00062 // The mesh 00063 Mesh* mesh; 00064 00065 // A list of all nodes on the boundary 00066 List<Node*> nodes; 00067 00068 // A list of all edges on the boundary 00069 List<Edge*> edges; 00070 00071 // A list of all faces on the boundary 00072 List<Face*> faces; 00073 00074 }; 00075 00076 } 00077 00078 #endif
Documentation automatically generated with Doxygen on 10 Sep 2004.