![]() |
00001 // Copyright (C) 2002 Johan Hoffman and Anders Logg. 00002 // Licensed under the GNU GPL Version 2. 00003 00004 #ifndef __MESH_HIERARCHY 00005 #define __MESH_HIERARCHY 00006 00007 #include <dolfin/Array.h> 00008 00009 namespace dolfin { 00010 00011 class Mesh; 00012 00013 class MeshHierarchy { 00014 public: 00015 00017 MeshHierarchy(); 00018 00020 MeshHierarchy(Mesh& mesh); 00021 00023 ~MeshHierarchy(); 00024 00026 void init(Mesh& mesh); 00027 00029 void clear(); 00030 00032 void add(Mesh& mesh); 00033 00035 Mesh& operator() (int level) const; 00036 00038 Mesh& coarse() const; 00039 00041 Mesh& fine() const; 00042 00044 int size() const; 00045 00047 bool empty() const; 00048 00050 friend class MeshIterator; 00051 00052 private: 00053 00054 // An array of mesh pointers 00055 Array<Mesh*> meshes; 00056 00057 }; 00058 00059 } 00060 00061 #endif
Documentation automatically generated with Doxygen on 10 Sep 2004.