33#ifndef __H__LIB_GRID__FILE_IO_UGX_IMPL__
34#define __H__LIB_GRID__FILE_IO_UGX_IMPL__
46template <
class TAPosition>
51 ugxWriter.
add_grid(grid,
"defGrid", aPos);
58template <
class TAPosition>
64 UG_LOG(
"ERROR in LoadGridFromUGX: File not found: " << filename << std::endl);
69 UG_LOG(
"ERROR in LoadGridFromUGX: File contains no grid.\n");
73 ugxReader.
grid(grid, 0, aPos);
78 for(
size_t i_name = 0; i_name < additionalSHNames.size(); ++i_name){
79 std::string shName = additionalSHNames[i_name];
95 for(
size_t i_name = 0; i_name < additionalSHNames.size(); ++i_name)
96 if(shName2==additionalSHNames[i_name])
98 try {ph->set_subset_handler(ash[i_name]);}
99 UG_CATCH_THROW(
"Additional subset handler '"<< shName2 <<
"' has not been added to the domain.\n"
100 "Do so by using Domain::create_additional_subset_handler(std::string name).");
108template <
class TAPosition>
114 UG_LOG(
"ERROR in LoadGridFromUGX: File not found: " << filename << std::endl);
119 UG_LOG(
"ERROR in LoadGridFromUGX: File contains no grid.\n");
123 ugxReader.
grid(grid, 0, aPos);
133template <
class TPositionAttachment>
136 TPositionAttachment& aPos)
138 using namespace rapidxml;
142 UG_LOG(
" position attachment missing in grid " <<
name << endl);
149 xml_node<>* gridNode =
m_doc.allocate_node(node_element,
"grid");
150 gridNode->append_attribute(
m_doc.allocate_attribute(
"name",
name));
156 m_doc.append_node(gridNode);
175 aaPos, aaIndEDGE, aaIndFACE));
180 process_global_attachments<Vertex>(grid, gridNode);
181 process_global_attachments<Edge>(grid, gridNode);
182 process_global_attachments<Face>(grid, gridNode);
183 process_global_attachments<Volume>(grid, gridNode);
195template <
class TElem>
199 static const char* attachmentNodeNames[4] = {
"vertex_attachment",
202 "volume_attachment"};
203 return attachmentNodeNames[TElem::BASE_OBJECT_ID];
207template <
class TElem,
class TAttachment>
213 using namespace rapidxml;
217 "Invalid refGridIndex: " << refGridIndex
218 <<
", but only " <<
m_vEntries.size() <<
" grids available.");
240 xml_node<>* node =
m_doc.allocate_node(
242 attachment_node_name<TElem>(),
243 m_doc.allocate_string(ss.str().c_str()));
246 node->append_attribute(
247 m_doc.allocate_attribute(
251 node->append_attribute(
252 m_doc.allocate_attribute(
254 m_doc.allocate_string(
258 node->append_attribute(
259 m_doc.allocate_attribute(
261 m_doc.allocate_string(
mkstr(
int(attachment.default_pass_on_behaviour())).c_str())));
263 m_vEntries[refGridIndex].node->append_node(node);
267template <
class TAAPos>
274 using namespace rapidxml;
277 const int numCoords = (int)TAAPos::ValueType::Size;
284 for(
int i = 0; i < numCoords; ++i)
285 ss << aaPos[*iter][i] <<
" ";
289 xml_node<>* node = NULL;
291 if(ss.str().size() > 0){
293 char* nodeData =
m_doc.allocate_string(ss.str().c_str(), ss.str().size());
294 nodeData[ss.str().size()-1] = 0;
296 node =
m_doc.allocate_node(node_element,
"vertices", nodeData);
300 node =
m_doc.allocate_node(node_element,
"vertices");
303 char* buff =
m_doc.allocate_string(NULL, 10);
304 snprintf(buff, 10,
"%d", numCoords);
305 node->append_attribute(
m_doc.allocate_attribute(
"coords", buff));
311template <
class TAAPos>
320 using namespace rapidxml;
323 const int numCoords = (int)TAAPos::ValueType::Size;
330 for(
int i = 0; i < numCoords; ++i)
331 ss << aaPos[*iter][i] <<
" ";
339 Edge* ce =
dynamic_cast<Edge*
>((*iter)->get_constraining_object());
340 Face* cf =
dynamic_cast<Face*
>((*iter)->get_constraining_object());
342 ss <<
"1 " << aaIndEDGE[ce] <<
" " << (*iter)->get_local_coordinate_1() <<
" ";
344 ss <<
"2 " << aaIndFACE[cf] <<
" " << (*iter)->get_local_coordinate_1()
345 <<
" " << (*iter)->get_local_coordinate_2() <<
" ";
351 xml_node<>* node = NULL;
353 if(ss.str().size() > 0){
355 char* nodeData =
m_doc.allocate_string(ss.str().c_str(), ss.str().size());
356 nodeData[ss.str().size()-1] = 0;
358 node =
m_doc.allocate_node(node_element,
"constrained_vertices", nodeData);
362 node =
m_doc.allocate_node(node_element,
"constrained_vertices");
365 char* buff =
m_doc.allocate_string(NULL, 10);
366 snprintf(buff, 10,
"%d", numCoords);
367 node->append_attribute(
m_doc.allocate_attribute(
"coords", buff));
374template <
class TElem>
379 using namespace rapidxml;
382 for(
size_t ia = 0; ia < attachmentNames.size(); ++ia){
383 const std::string&
name = attachmentNames[ia];
384 if(!GlobalAttachments::is_attached<TElem>(grid,
name))
388 GlobalAttachments::write_attachment_values<TElem>(ss, grid,
name);
391 xml_node<>* node =
m_doc.allocate_node(
393 attachment_node_name<TElem>(),
394 m_doc.allocate_string(ss.str().c_str()));
397 node->append_attribute(
398 m_doc.allocate_attribute(
402 node->append_attribute(
403 m_doc.allocate_attribute(
405 m_doc.allocate_string(
408 node->append_attribute(
409 m_doc.allocate_attribute(
414 node->append_attribute(
415 m_doc.allocate_attribute(
417 m_doc.allocate_string(
"1")));
419 gridNode->append_node(node);
427template <
class TPositionAttachment>
430 TPositionAttachment& aPos)
432 using namespace rapidxml;
437 UG_LOG(
" GridReaderUGX::read: bad grid index!\n");
450 if(!
grid.has_vertex_attachment(aPos)){
451 grid.attach_to_vertices(aPos);
460 xml_node<>* gridNode =
m_entries[index].node;
461 vector<Vertex*>& vertices =
m_entries[index].vertices;
462 vector<Edge*>& edges =
m_entries[index].edges;
463 vector<Face*>& faces =
m_entries[index].faces;
464 vector<Volume*>& volumes =
m_entries[index].volumes;
467 std::vector<std::pair<int, int> > constrainingObjsVRT;
468 std::vector<std::pair<int, int> > constrainingObjsEDGE;
469 std::vector<std::pair<int, int> > constrainingObjsTRI;
470 std::vector<std::pair<int, int> > constrainingObjsQUAD;
473 xml_node<>* curNode = gridNode->first_node();
474 for(;curNode; curNode = curNode->next_sibling()){
475 bool bSuccess =
true;
476 const char*
name = curNode->name();
477 if(strcmp(
name,
"vertices") == 0)
479 else if(strcmp(
name,
"constrained_vertices") == 0)
481 grid, curNode, aaPos);
482 else if(strcmp(
name,
"edges") == 0)
484 else if(strcmp(
name,
"constraining_edges") == 0)
486 else if(strcmp(
name,
"constrained_edges") == 0)
488 grid, curNode, vertices);
489 else if(strcmp(
name,
"triangles") == 0)
491 else if(strcmp(
name,
"constraining_triangles") == 0)
493 else if(strcmp(
name,
"constrained_triangles") == 0)
495 grid, curNode, vertices);
496 else if(strcmp(
name,
"quadrilaterals") == 0)
498 else if(strcmp(
name,
"constraining_quadrilaterals") == 0)
500 else if(strcmp(
name,
"constrained_quadrilaterals") == 0)
502 grid, curNode, vertices);
503 else if(strcmp(
name,
"tetrahedrons") == 0)
505 else if(strcmp(
name,
"hexahedrons") == 0)
507 else if(strcmp(
name,
"prisms") == 0)
509 else if(strcmp(
name,
"pyramids") == 0)
511 else if(strcmp(
name,
"octahedrons") == 0)
514 else if(strcmp(
name,
"vertex_attachment") == 0)
515 bSuccess = read_attachment<Vertex>(
grid, curNode);
516 else if(strcmp(
name,
"edge_attachment") == 0)
517 bSuccess = read_attachment<Edge>(
grid, curNode);
518 else if(strcmp(
name,
"face_attachment") == 0)
519 bSuccess = read_attachment<Face>(
grid, curNode);
520 else if(strcmp(
name,
"volume_attachment") == 0)
521 bSuccess = read_attachment<Volume>(
grid, curNode);
525 grid.set_options(gridopts);
531 if(!constrainingObjsVRT.empty()){
537 for(std::vector<std::pair<int, int> >::iterator iter = constrainingObjsVRT.begin();
538 iter != constrainingObjsVRT.end(); ++iter, ++hvIter)
546 if(iter->second >= 0 && iter->second < (
int)edges.size()){
554 UG_LOG(
"WARNING: Type-ID / type mismatch. Ignoring edge " << iter->second <<
".\n");
558 UG_LOG(
"ERROR in GridReaderUGX: Bad edge index in constrained vertex: " << iter->second <<
"\n");
565 if(iter->second >= 0 && iter->second < (
int)faces.size()){
573 UG_LOG(
"WARNING in GridReaderUGX: Type-ID / type mismatch. Ignoring face " << iter->second <<
".\n");
577 UG_LOG(
"ERROR in GridReaderUGX: Bad face index in constrained vertex: " << iter->second <<
"\n");
591 if(!constrainingObjsEDGE.empty()){
596 for(std::vector<std::pair<int, int> >::iterator iter = constrainingObjsEDGE.begin();
597 iter != constrainingObjsEDGE.end(); ++iter, ++ceIter)
605 if(iter->second >= 0 && iter->second < (
int)edges.size()){
613 UG_LOG(
"WARNING in GridReaderUGX: Type-ID / type mismatch. Ignoring edge " << iter->second <<
".\n");
617 UG_LOG(
"ERROR in GridReaderUGX: Bad edge index in constrained edge.\n");
623 if(iter->second >= 0 && iter->second < (
int)faces.size()){
631 UG_LOG(
"WARNING in GridReaderUGX: Type-ID / type mismatch. Ignoring face " << iter->second <<
".\n");
635 UG_LOG(
"ERROR in GridReaderUGX: Bad face index in constrained edge: " << iter->second <<
"\n");
649 if(!constrainingObjsTRI.empty()){
654 for(std::vector<std::pair<int, int> >::iterator iter = constrainingObjsTRI.begin();
655 iter != constrainingObjsTRI.end(); ++iter, ++cfIter)
663 if(iter->second >= 0 && iter->second < (
int)faces.size()){
671 UG_LOG(
"WARNING in GridReaderUGX: Type-ID / type mismatch. Ignoring face " << iter->second <<
".\n");
675 UG_LOG(
"ERROR in GridReaderUGX: Bad face index in constrained face: " << iter->second <<
"\n");
689 if(!constrainingObjsQUAD.empty()){
694 for(std::vector<std::pair<int, int> >::iterator iter = constrainingObjsQUAD.begin();
695 iter != constrainingObjsQUAD.end(); ++iter, ++cfIter)
703 if(iter->second >= 0 && iter->second < (
int)faces.size()){
711 UG_LOG(
"WARNING in GridReaderUGX: Type-ID / type mismatch. Ignoring face " << iter->second <<
".\n");
715 UG_LOG(
"ERROR in GridReaderUGX: Bad face index in constrained face: " << iter->second <<
"\n");
730 grid.set_options(gridopts);
735template <
class TAAPos>
738 rapidxml::xml_node<>* vrtNode, TAAPos aaPos)
740 using namespace rapidxml;
743 int numSrcCoords = -1;
744 xml_attribute<>* attrib = vrtNode->first_attribute(
"coords");
746 numSrcCoords = atoi(attrib->value());
748 int numDestCoords = (int)TAAPos::ValueType::Size;
750 assert(numDestCoords > 0 &&
"bad position attachment type");
752 if(numSrcCoords < 1 || numDestCoords < 1)
756 string str(vrtNode->value(), vrtNode->value_size());
757 stringstream ss(str, ios_base::in);
760 if(numSrcCoords == numDestCoords){
763 typename TAAPos::ValueType v;
765 for(
int i = 0; i < numSrcCoords; ++i)
774 vrtsOut.push_back(vrt);
784 int minNumCoords = min(numSrcCoords, numDestCoords);
785 typename TAAPos::ValueType::value_type dummy = 0;
789 typename TAAPos::ValueType v;
792 for(iMin = 0; iMin < minNumCoords; ++iMin)
796 for(
int i = iMin; i < numSrcCoords; ++i)
800 for(
int i = iMin; i < numDestCoords; ++i)
809 vrtsOut.push_back(vrt);
819template <
class TAAPos>
822 std::vector<std::pair<int, int> >& constrainingObjsOut,
823 Grid& grid, rapidxml::xml_node<>* vrtNode, TAAPos aaPos)
825 using namespace rapidxml;
828 int numSrcCoords = -1;
829 xml_attribute<>* attrib = vrtNode->first_attribute(
"coords");
831 numSrcCoords = atoi(attrib->value());
833 int numDestCoords = (int)TAAPos::ValueType::Size;
835 assert(numDestCoords > 0 &&
"bad position attachment type");
837 if(numSrcCoords < 1 || numDestCoords < 1)
841 string str(vrtNode->value(), vrtNode->value_size());
842 stringstream ss(str, ios_base::in);
847 int minNumCoords = min(numSrcCoords, numDestCoords);
848 typename TAAPos::ValueType::value_type dummy = 0;
853 typename TAAPos::ValueType v;
856 for(iMin = 0; iMin < minNumCoords; ++iMin)
860 for(
int i = iMin; i < numSrcCoords; ++i)
864 for(
int i = iMin; i < numDestCoords; ++i)
869 int conObjIndex = -1;
879 ss >> localCoords.x();
882 ss >> localCoords.x() >> localCoords.y();
894 vrtsOut.push_back(vrt);
903 constrainingObjsOut.push_back(std::make_pair(conObjType, conObjIndex));
910template <
class TElem>
914 using namespace rapidxml;
917 xml_attribute<>* attribName = node->first_attribute(
"name");
918 UG_COND_THROW(!attribName,
"Invalid attachment entry: No 'name' attribute was supplied!");
919 string name = attribName->value();
921 xml_attribute<>* attribType = node->first_attribute(
"type");
922 UG_COND_THROW(!attribType,
"Invalid attachment entry: No 'type' attribute was supplied!");
923 string type = attribType->value();
926 if (xml_attribute<>* attrib = node->first_attribute(
"global")){
927 global = bool(atoi(attrib->value()));
931 if (xml_attribute<>* attrib = node->first_attribute(
"passOn")){
932 passOn = bool(atoi(attrib->value()));
945 "Attachment type mismatch. Expecting type: " <<
947 <<
", but given type is: " << type);
949 string str(node->value(), node->value_size());
950 stringstream ss(str, ios_base::in);
951 GlobalAttachments::read_attachment_values<TElem>(ss,
grid,
name);
location name
Definition checkpoint_util.lua:128
Definition smart_pointer.h:108
This edge is a sub-edge of a.
Definition grid_objects_1d.h:146
void set_constraining_object(GridObject *pObj)
Definition grid_objects_1d.h:218
This class stores the constraining object.
Definition grid_objects_2d.h:383
void set_constraining_object(GridObject *pObj)
Definition grid_objects_2d.h:395
a quadrilateral constrained by another object.
Definition grid_objects_2d.h:501
a triangle constrained by another object.
Definition grid_objects_2d.h:440
A vertex appearing on edges or faces.
Definition grid_objects_0d.h:110
void set_constraining_object(GridObject *constrObj)
Definition grid_objects_0d.h:143
void set_local_coordinates(number x, number y)
Definition grid_objects_0d.h:167
contains elements of type
Definition grid_objects_1d.h:279
void add_constrained_object(Vertex *pObj)
Definition grid_objects_1d.h:353
This class is used to store constrained geometric objects.
Definition grid_objects_2d.h:562
void add_constrained_object(Vertex *pObj)
Definition grid_objects_2d.h:584
Base-class for edges.
Definition grid_base_objects.h:397
Faces are 2-dimensional objects.
Definition grid_base_objects.h:510
static const char * type_name(const std::string &name)
Definition global_attachments.h:213
static bool type_is_registered(const std::string &typeName)
Definition global_attachments.h:124
static bool attachment_pass_on_behaviour(const std::string &name)
Definition global_attachments.h:117
static void declare_attachment(const std::string &name, bool passOnBehaviour=false)
Definition global_attachments.h:47
static bool is_declared(const std::string &name)
Definition global_attachments.h:111
static const std::vector< std::string > & declared_attachment_names()
Definition global_attachments.h:105
the generic attachment-accessor for access to grids attachment pipes.
Definition grid.h:182
Manages the elements of a grid and their interconnection.
Definition grid.h:132
size_t num() const
Definition grid_impl.hpp:230
bool has_attachment(IAttachment &attachment)
Definition grid.h:796
geometry_traits< TGeomObj >::iterator begin()
Definition grid_impl.hpp:164
bool has_vertex_attachment(IAttachment &attachment)
Definition grid.h:798
geometry_traits< TGeomObj >::iterator end()
Definition grid_impl.hpp:175
uint get_options() const
Definition grid.cpp:706
Grants read access to ugx files.
Definition file_io_ugx.h:301
bool create_hexahedrons(std::vector< Volume * > &volsOut, Grid &grid, rapidxml::xml_node<> *node, std::vector< Vertex * > &vrts)
Definition file_io_ugx.cpp:1782
bool parse_file(const char *filename)
parses an xml file
Definition file_io_ugx.cpp:1304
bool projection_handler(ProjectionHandler &phOut, size_t phIndex, size_t refGridIndex)
fills the given projection-handler
Definition file_io_ugx.cpp:1266
size_t num_projection_handlers(size_t refGridIndex) const
returns the number of projection-handlers for the given grid
Definition file_io_ugx.cpp:1196
bool create_vertices(std::vector< Vertex * > &vrtsOut, Grid &grid, rapidxml::xml_node<> *vrtNode, TAAPos aaPos)
creates vertices from a vertex-node.
Definition file_io_ugx_impl.hpp:737
bool create_constrained_vertices(std::vector< Vertex * > &vrtsOut, std::vector< std::pair< int, int > > &constrainingObjsOut, Grid &grid, rapidxml::xml_node<> *vrtNode, TAAPos aaPos)
Definition file_io_ugx_impl.hpp:821
size_t num_grids() const
returns the number of grids
Definition file_io_ugx.h:310
bool create_constraining_edges(std::vector< Edge * > &edgesOut, Grid &grid, rapidxml::xml_node<> *node, std::vector< Vertex * > &vrts)
Definition file_io_ugx.cpp:1408
bool read_attachment(Grid &grid, rapidxml::xml_node<> *node)
Definition file_io_ugx_impl.hpp:912
bool create_constrained_edges(std::vector< Edge * > &edgesOut, std::vector< std::pair< int, int > > &constrainingObjsOut, Grid &grid, rapidxml::xml_node<> *node, std::vector< Vertex * > &vrts)
Definition file_io_ugx.cpp:1443
bool create_tetrahedrons(std::vector< Volume * > &volsOut, Grid &grid, rapidxml::xml_node<> *node, std::vector< Vertex * > &vrts)
Definition file_io_ugx.cpp:1743
bool create_constrained_quadrilaterals(std::vector< Face * > &facesOut, std::vector< std::pair< int, int > > &constrainingObjsOut, Grid &grid, rapidxml::xml_node<> *node, std::vector< Vertex * > &vrts)
Definition file_io_ugx.cpp:1691
bool create_octahedrons(std::vector< Volume * > &volsOut, Grid &grid, rapidxml::xml_node<> *node, std::vector< Vertex * > &vrts)
Definition file_io_ugx.cpp:1906
bool create_edges(std::vector< Edge * > &edgesOut, Grid &grid, rapidxml::xml_node<> *node, std::vector< Vertex * > &vrts)
Definition file_io_ugx.cpp:1372
bool create_constraining_triangles(std::vector< Face * > &facesOut, Grid &grid, rapidxml::xml_node<> *node, std::vector< Vertex * > &vrts)
Definition file_io_ugx.cpp:1527
size_t get_projection_handler_subset_handler_index(size_t phIndex, size_t refGridIndex)
returns the subset handler index for a projection handler
Definition file_io_ugx.cpp:1221
bool create_constrained_triangles(std::vector< Face * > &facesOut, std::vector< std::pair< int, int > > &constrainingObjsOut, Grid &grid, rapidxml::xml_node<> *node, std::vector< Vertex * > &vrts)
Definition file_io_ugx.cpp:1564
bool create_pyramids(std::vector< Volume * > &volsOut, Grid &grid, rapidxml::xml_node<> *node, std::vector< Vertex * > &vrts)
Definition file_io_ugx.cpp:1866
const char * get_subset_handler_name(size_t refGridIndex, size_t subsetHandlerIndex) const
returns the name of the given subset handler
Definition file_io_ugx.cpp:957
bool subset_handler(ISubsetHandler &shOut, size_t subsetHandlerIndex, size_t refGridIndex)
fills the given subset-handler
Definition file_io_ugx.cpp:970
bool create_constraining_quadrilaterals(std::vector< Face * > &facesOut, Grid &grid, rapidxml::xml_node<> *node, std::vector< Vertex * > &vrts)
Definition file_io_ugx.cpp:1651
bool create_prisms(std::vector< Volume * > &volsOut, Grid &grid, rapidxml::xml_node<> *node, std::vector< Vertex * > &vrts)
Definition file_io_ugx.cpp:1825
bool create_quadrilaterals(std::vector< Face * > &facesOut, Grid &grid, rapidxml::xml_node<> *node, std::vector< Vertex * > &vrts)
Definition file_io_ugx.cpp:1612
size_t num_subset_handlers(size_t refGridIndex) const
returns the number of subset handlers for the given grid
Definition file_io_ugx.cpp:945
bool grid(Grid &gridOut, size_t index, TPositionAttachment &aPos)
returns the i-th grid.
Definition file_io_ugx_impl.hpp:429
bool create_triangles(std::vector< Face * > &facesOut, Grid &grid, rapidxml::xml_node<> *node, std::vector< Vertex * > &vrts)
Definition file_io_ugx.cpp:1490
std::vector< GridEntry > m_entries
holds grids which already have been created
Definition file_io_ugx.h:493
Grants write access to ugx files.
Definition file_io_ugx.h:108
rapidxml::xml_document m_doc
the xml_document which stores the data
Definition file_io_ugx.h:283
void add_elements_to_node(rapidxml::xml_node<> *node, Grid &grid)
adds grid elements (edges, faces, volumes) to the given node.
Definition file_io_ugx.cpp:424
void add_attachment(TAttachment attachment, const char *name, size_t refGridIndex)
Definition file_io_ugx_impl.hpp:209
void process_global_attachments(Grid &grid, rapidxml::xml_node<> *gridNode)
Definition file_io_ugx_impl.hpp:376
std::vector< Entry > m_vEntries
List of accessible grids.
Definition file_io_ugx.h:286
rapidxml::xml_node * create_constrained_vertex_node(ConstrainedVertexIterator vrtsBegin, ConstrainedVertexIterator vrtsEnd, TAAPos &aaPos, AAEdgeIndex aaIndEDGE, AAFaceIndex aaIndFACE)
Definition file_io_ugx_impl.hpp:314
const char * attachment_node_name()
Definition file_io_ugx_impl.hpp:197
AInt m_aInt
attached to vertices of each grid during add_grid.
Definition file_io_ugx.h:289
rapidxml::xml_node * create_vertex_node(RegularVertexIterator vrtsBegin, RegularVertexIterator vrtsEnd, TAAPos &aaPos)
Definition file_io_ugx_impl.hpp:270
bool write_to_file(const char *filename)
Definition file_io_ugx.cpp:111
void init_grid_attachments(Grid &grid)
Definition file_io_ugx.cpp:376
bool add_grid(Grid &grid, const char *name, TPositionAttachment &aPos)
Definition file_io_ugx_impl.hpp:135
void add_subset_handler(ISubsetHandler &sh, const char *name, size_t refGridIndex)
Definition file_io_ugx.cpp:152
Definition subset_handler_interface.h:223
A basic vertex-type.
Definition grid_objects_0d.h:62
@ GRIDOPT_NONE
Definition grid_constants.h:91
#define UG_CATCH_THROW(msg)
Definition error.h:64
#define UG_LOG(msg)
Definition log.h:367
unsigned int uint
Definition types.h:114
#define UG_COND_THROW(cond, msg)
UG_COND_THROW(cond, msg) : performs a UG_THROW(msg) if cond == true.
Definition error.h:61
Definition smart_pointer.h:814
geometry_traits< ConstrainedTriangle >::iterator ConstrainedTriangleIterator
Definition grid_objects_2d.h:487
geometry_traits< ConstrainedQuadrilateral >::iterator ConstrainedQuadrilateralIterator
Definition grid_objects_2d.h:545
bool LoadGridFromUGX(Grid &grid, ISubsetHandler &sh, const char *filename)
Reads a grid to an ugx file.
Definition file_io_ugx.cpp:69
bool SaveGridToUGX(Grid &grid, ISubsetHandler &sh, const char *filename)
Writes a grid to a ugx file.
Definition file_io_ugx.cpp:55
geometry_traits< RegularVertex >::iterator RegularVertexIterator
Definition grid_objects_0d.h:94
geometry_traits< ConstrainedVertex >::iterator ConstrainedVertexIterator
Definition grid_objects_0d.h:196
geometry_traits< ConstrainedEdge >::iterator ConstrainedEdgeIterator
Definition grid_objects_1d.h:264
#define mkstr(s)
Comfortable (but not necessarily efficient) string building.
Definition stringify.h:100
geometry_traits< TElem >::iterator iterator
Definition grid.h:143
entries are stored for each grid.
Definition file_io_ugx.h:272
Definition attachment_info_traits.h:46
static void write_value(std::ostream &out, const_reference_type v)
Definition attachment_io_traits.h:45