21 #ifndef Tulip_PlanarConMap_H 22 #define Tulip_PlanarConMap_H 25 #include <tulip/tuliphash.h> 26 #include <tulip/Face.h> 27 #include <tulip/GraphDecorator.h> 46 class TLP_SCOPE PlanarConMap :
public GraphDecorator {
49 friend class FaceIteratorTest;
50 friend class PlanarConMapTest;
53 friend class FaceIterator;
54 friend class FaceAdjIterator;
55 friend class NodeFaceIterator;
56 friend class EdgeFaceIterator;
58 friend TLP_SCOPE PlanarConMap* computePlanarConMap(Graph* graph);
64 PlanarConMap(Graph* s);
92 edge addEdgeMap(
const node v,
const node w, Face f,
const edge e1,
const edge e2, Face new_face= Face());
100 Face splitFace(Face,
const node,
const node, node = node());
106 Face splitFace(Face,
const edge);
112 void mergeFaces(Face f, Face g);
132 edge succCycleEdge(
const edge,
const node)
const;
134 edge predCycleEdge(
const edge,
const node)
const;
136 node succCycleNode(
const node,
const node)
const;
138 node predCycleNode(
const node,
const node)
const;
141 unsigned int nbFaces();
143 unsigned int nbFacesNodes(
const Face);
145 unsigned int nbFacesEdges(
const Face);
148 bool containNode(
const Face,
const node) ;
150 bool containEdge(
const Face,
const edge);
155 Face getFaceContaining(
const node,
const node);
157 Face sameFace(
const node,
const node);
171 void delEdgeMap(edge, Face = Face());
173 typedef TLP_HASH_MAP<Face , std::vector<edge> > faceMap;
174 typedef faceMap::value_type faceMapEntry;
175 typedef TLP_HASH_MAP<edge, std::vector<Face> > edgeMap;
176 typedef edgeMap::value_type edgeMapEntry;
177 typedef TLP_HASH_MAP<node, std::vector<Face> > nodeMap;
178 typedef nodeMap::value_type nodeMapEntry;
184 mutable std::vector<Face > faces;
192 TLP_SCOPE PlanarConMap* computePlanarConMap(Graph* graph);
197 TLP_SCOPE std::ostream&
operator<< (std::ostream &, tlp::PlanarConMap *);
std::ostream & operator<<(std::ostream &os, const Array< Obj, SIZE > &array)
operator << stream operator to easily print an array, or save it to a file.
Interface for Tulip iterators. Allows basic iteration operations only.