<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <title>GEOS: geos::planargraph::Subgraph Class Reference</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <link href="doxygen.css" rel="stylesheet" type="text/css"/> </head> <body> <!-- Generated by Doxygen 1.7.1 --> <div class="navigation" id="top"> <div class="tabs"> <ul class="tablist"> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> <li><a href="namespaces.html"><span>Namespaces</span></a></li> <li class="current"><a href="annotated.html"><span>Classes</span></a></li> <li><a href="files.html"><span>Files</span></a></li> </ul> </div> <div class="tabs2"> <ul class="tablist"> <li><a href="annotated.html"><span>Class List</span></a></li> <li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li> <li><a href="functions.html"><span>Class Members</span></a></li> </ul> </div> <div class="navpath"> <ul> <li><a class="el" href="namespacegeos.html">geos</a> </li> <li><a class="el" href="namespacegeos_1_1planargraph.html">planargraph</a> </li> <li><a class="el" href="classgeos_1_1planargraph_1_1Subgraph.html">geos::planargraph::Subgraph</a> </li> </ul> </div> </div> <div class="header"> <div class="summary"> <a href="#pub-methods">Public Member Functions</a> | <a href="#pro-methods">Protected Member Functions</a> | <a href="#pro-attribs">Protected Attributes</a> </div> <div class="headertitle"> <h1>geos::planargraph::Subgraph Class Reference</h1> </div> </div> <div class="contents"> <!-- doxytag: class="geos::planargraph::Subgraph" --> <p>A subgraph of a <a class="el" href="classgeos_1_1planargraph_1_1PlanarGraph.html" title="Represents a directed graph which is embeddable in a planar surface.">PlanarGraph</a>. <a href="#_details">More...</a></p> <p><code>#include <<a class="el" href="Subgraph_8h_source.html">Subgraph.h</a>></code></p> <p><a href="classgeos_1_1planargraph_1_1Subgraph-members.html">List of all members.</a></p> <table class="memberdecls"> <tr><td colspan="2"><h2><a name="pub-methods"></a> Public Member Functions</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classgeos_1_1planargraph_1_1Subgraph.html#a8630d3ccec1933d4f80f46d74891f70f">Subgraph</a> (<a class="el" href="classgeos_1_1planargraph_1_1PlanarGraph.html">PlanarGraph</a> &parent)</td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classgeos_1_1planargraph_1_1PlanarGraph.html">PlanarGraph</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="classgeos_1_1planargraph_1_1Subgraph.html#a2df790a8b39e5624b132a966ce28b1a9">getParent</a> () const </td></tr> <tr><td class="memItemLeft" align="right" valign="top">std::pair< std::set< <a class="el" href="classgeos_1_1planargraph_1_1Edge.html">Edge</a> * ><br class="typebreak"/> ::iterator, bool > </td><td class="memItemRight" valign="bottom"><a class="el" href="classgeos_1_1planargraph_1_1Subgraph.html#aa2463e015559901fc7c53353689ce942">add</a> (<a class="el" href="classgeos_1_1planargraph_1_1Edge.html">Edge</a> *e)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">std::vector< const <br class="typebreak"/> <a class="el" href="classgeos_1_1planargraph_1_1DirectedEdge.html">DirectedEdge</a> * >::iterator </td><td class="memItemRight" valign="bottom"><a class="el" href="classgeos_1_1planargraph_1_1Subgraph.html#a9e05f70a3d04d371d53ddd7682cd5215">getDirEdgeBegin</a> ()</td></tr> <tr><td class="memItemLeft" align="right" valign="top">std::set< <a class="el" href="classgeos_1_1planargraph_1_1Edge.html">Edge</a> * >::iterator </td><td class="memItemRight" valign="bottom"><a class="el" href="classgeos_1_1planargraph_1_1Subgraph.html#a41c2167709f02478311b784031318e9d">edgeBegin</a> ()</td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a5b90d2be057c969c48a616a23dcfdfae"></a><!-- doxytag: member="geos::planargraph::Subgraph::edgeEnd" ref="a5b90d2be057c969c48a616a23dcfdfae" args="()" --> std::set< <a class="el" href="classgeos_1_1planargraph_1_1Edge.html">Edge</a> * >::iterator </td><td class="memItemRight" valign="bottom"><b>edgeEnd</b> ()</td></tr> <tr><td class="memItemLeft" align="right" valign="top">NodeMap::container::iterator </td><td class="memItemRight" valign="bottom"><a class="el" href="classgeos_1_1planargraph_1_1Subgraph.html#a6b6f87cfeb8de147d7f0197294e3b90b">nodeBegin</a> ()</td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a3073d60ec46d1317df16104b798a560f"></a><!-- doxytag: member="geos::planargraph::Subgraph::nodeEnd" ref="a3073d60ec46d1317df16104b798a560f" args="() const " --> NodeMap::container::const_iterator </td><td class="memItemRight" valign="bottom"><b>nodeEnd</b> () const </td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a9dd0a53b701637a1de6d5ae0d69b83e6"></a><!-- doxytag: member="geos::planargraph::Subgraph::nodeEnd" ref="a9dd0a53b701637a1de6d5ae0d69b83e6" args="()" --> NodeMap::container::iterator </td><td class="memItemRight" valign="bottom"><b>nodeEnd</b> ()</td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a8788aadec535bcabccb72d9d30b95b6e"></a><!-- doxytag: member="geos::planargraph::Subgraph::nodeBegin" ref="a8788aadec535bcabccb72d9d30b95b6e" args="() const " --> NodeMap::container::const_iterator </td><td class="memItemRight" valign="bottom"><b>nodeBegin</b> () const </td></tr> <tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classgeos_1_1planargraph_1_1Subgraph.html#a210b99e0f607b610a08df16ea83523a0">contains</a> (<a class="el" href="classgeos_1_1planargraph_1_1Edge.html">Edge</a> *e)</td></tr> <tr><td colspan="2"><h2><a name="pro-methods"></a> Protected Member Functions</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ac61b04ac3398ba0246b8e5ba038c69e0"></a><!-- doxytag: member="geos::planargraph::Subgraph::Subgraph" ref="ac61b04ac3398ba0246b8e5ba038c69e0" args="(const Subgraph &other)" --> </td><td class="memItemRight" valign="bottom"><b>Subgraph</b> (const <a class="el" href="classgeos_1_1planargraph_1_1Subgraph.html">Subgraph</a> &other)</td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a003bde7b44d3a63bdda1d4e5d1d39268"></a><!-- doxytag: member="geos::planargraph::Subgraph::operator=" ref="a003bde7b44d3a63bdda1d4e5d1d39268" args="(const Subgraph &rhs)" --> <a class="el" href="classgeos_1_1planargraph_1_1Subgraph.html">Subgraph</a> & </td><td class="memItemRight" valign="bottom"><b>operator=</b> (const <a class="el" href="classgeos_1_1planargraph_1_1Subgraph.html">Subgraph</a> &rhs)</td></tr> <tr><td colspan="2"><h2><a name="pro-attribs"></a> Protected Attributes</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a777972a95f270d3a8fff79f422a229e6"></a><!-- doxytag: member="geos::planargraph::Subgraph::parentGraph" ref="a777972a95f270d3a8fff79f422a229e6" args="" --> <a class="el" href="classgeos_1_1planargraph_1_1PlanarGraph.html">PlanarGraph</a> & </td><td class="memItemRight" valign="bottom"><b>parentGraph</b></td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a3e6bbb90c7519cc5b9aae8dab7e5fdd6"></a><!-- doxytag: member="geos::planargraph::Subgraph::edges" ref="a3e6bbb90c7519cc5b9aae8dab7e5fdd6" args="" --> std::set< <a class="el" href="classgeos_1_1planargraph_1_1Edge.html">Edge</a> * > </td><td class="memItemRight" valign="bottom"><b>edges</b></td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ae811468e8c1b6984a05762129bcf649c"></a><!-- doxytag: member="geos::planargraph::Subgraph::dirEdges" ref="ae811468e8c1b6984a05762129bcf649c" args="" --> std::vector< const <a class="el" href="classgeos_1_1planargraph_1_1DirectedEdge.html">DirectedEdge</a> * > </td><td class="memItemRight" valign="bottom"><b>dirEdges</b></td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ab623d1a1f693836a9c6cfc2d6f529086"></a><!-- doxytag: member="geos::planargraph::Subgraph::nodeMap" ref="ab623d1a1f693836a9c6cfc2d6f529086" args="" --> <a class="el" href="classgeos_1_1planargraph_1_1NodeMap.html">NodeMap</a> </td><td class="memItemRight" valign="bottom"><b>nodeMap</b></td></tr> </table> <hr/><a name="_details"></a><h2>Detailed Description</h2> <p>A subgraph of a <a class="el" href="classgeos_1_1planargraph_1_1PlanarGraph.html" title="Represents a directed graph which is embeddable in a planar surface.">PlanarGraph</a>. </p> <p>A subgraph may contain any subset of geomgraph::Edges from the parent graph. It will also automatically contain all <a class="el" href="classgeos_1_1geomgraph_1_1DirectedEdge.html" title="A directed EdgeEnd.">geomgraph::DirectedEdge</a> and geomgraph::Node associated with those edges. No new objects are created when edges are added - all associated components must already exist in the parent graph.</p> <p>@ Actually we'll be copying Coordinates in <a class="el" href="classgeos_1_1planargraph_1_1NodeMap.html" title="A map of Node, indexed by the coordinate of the node.">NodeMap</a>. I guess that'll need to be changed soon. </p> <hr/><h2>Constructor & Destructor Documentation</h2> <a class="anchor" id="a8630d3ccec1933d4f80f46d74891f70f"></a><!-- doxytag: member="geos::planargraph::Subgraph::Subgraph" ref="a8630d3ccec1933d4f80f46d74891f70f" args="(PlanarGraph &parent)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">geos::planargraph::Subgraph::Subgraph </td> <td>(</td> <td class="paramtype"><a class="el" href="classgeos_1_1planargraph_1_1PlanarGraph.html">PlanarGraph</a> & </td> <td class="paramname"> <em>parent</em></td> <td> ) </td> <td><code> [inline]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Creates a new subgraph of the given <a class="el" href="classgeos_1_1planargraph_1_1PlanarGraph.html" title="Represents a directed graph which is embeddable in a planar surface.">PlanarGraph</a></p> <dl><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>parent</em> </td><td>the parent graph </td></tr> </table> </dd> </dl> </div> </div> <hr/><h2>Member Function Documentation</h2> <a class="anchor" id="aa2463e015559901fc7c53353689ce942"></a><!-- doxytag: member="geos::planargraph::Subgraph::add" ref="aa2463e015559901fc7c53353689ce942" args="(Edge *e)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">std::pair<std::set<<a class="el" href="classgeos_1_1planargraph_1_1Edge.html">Edge</a>*>::iterator, bool> geos::planargraph::Subgraph::add </td> <td>(</td> <td class="paramtype"><a class="el" href="classgeos_1_1planargraph_1_1Edge.html">Edge</a> * </td> <td class="paramname"> <em>e</em></td> <td> ) </td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Adds an <a class="el" href="classgeos_1_1planargraph_1_1Edge.html">Edge</a> to the subgraph. The associated <a class="el" href="classgeos_1_1planargraph_1_1DirectedEdge.html">DirectedEdge</a>s and <a class="el" href="">planarNode</a>s are also added.</p> <dl><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>e</em> </td><td>the edge to add</td></tr> </table> </dd> </dl> <dl class="return"><dt><b>Returns:</b></dt><dd>a pair with first element being an iterator to the <a class="el" href="classgeos_1_1planargraph_1_1Edge.html" title="Represents an undirected edge of a PlanarGraph.">Edge</a> in set and second element being a boolean value indicating wheter the <a class="el" href="classgeos_1_1planargraph_1_1Edge.html" title="Represents an undirected edge of a PlanarGraph.">Edge</a> has been inserted now or was already in the set. </dd></dl> </div> </div> <a class="anchor" id="a210b99e0f607b610a08df16ea83523a0"></a><!-- doxytag: member="geos::planargraph::Subgraph::contains" ref="a210b99e0f607b610a08df16ea83523a0" args="(Edge *e)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">bool geos::planargraph::Subgraph::contains </td> <td>(</td> <td class="paramtype"><a class="el" href="classgeos_1_1planargraph_1_1Edge.html">Edge</a> * </td> <td class="paramname"> <em>e</em></td> <td> ) </td> <td><code> [inline]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Tests whether an <a class="el" href="classgeos_1_1planargraph_1_1Edge.html">Edge</a> is contained in this subgraph </p> <dl><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>e</em> </td><td>the edge to test </td></tr> </table> </dd> </dl> <dl class="return"><dt><b>Returns:</b></dt><dd><code>true</code> if the edge is contained in this subgraph </dd></dl> </div> </div> <a class="anchor" id="a41c2167709f02478311b784031318e9d"></a><!-- doxytag: member="geos::planargraph::Subgraph::edgeBegin" ref="a41c2167709f02478311b784031318e9d" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">std::set<<a class="el" href="classgeos_1_1planargraph_1_1Edge.html">Edge</a>*>::iterator geos::planargraph::Subgraph::edgeBegin </td> <td>(</td> <td class="paramname"></td> <td> ) </td> <td><code> [inline]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Returns an <a class="el" href="">Iterator</a> over the <a class="el" href="classgeos_1_1planargraph_1_1Edge.html">Edge</a>s in this graph, in the order in which they were added.</p> <dl class="return"><dt><b>Returns:</b></dt><dd>an iterator over the edges</dd></dl> <dl class="see"><dt><b>See also:</b></dt><dd>add(Edge) </dd></dl> </div> </div> <a class="anchor" id="a9e05f70a3d04d371d53ddd7682cd5215"></a><!-- doxytag: member="geos::planargraph::Subgraph::getDirEdgeBegin" ref="a9e05f70a3d04d371d53ddd7682cd5215" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">std::vector<const <a class="el" href="classgeos_1_1planargraph_1_1DirectedEdge.html">DirectedEdge</a>*>::iterator geos::planargraph::Subgraph::getDirEdgeBegin </td> <td>(</td> <td class="paramname"></td> <td> ) </td> <td><code> [inline]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Returns an iterator over the <a class="el" href="classgeos_1_1planargraph_1_1DirectedEdge.html" title="Represents a directed edge in a PlanarGraph.">DirectedEdge</a> in this graph, in the order in which they were added.</p> <dl class="return"><dt><b>Returns:</b></dt><dd>an iterator over the directed edges</dd></dl> <dl class="see"><dt><b>See also:</b></dt><dd>add(Edge) </dd></dl> </div> </div> <a class="anchor" id="a2df790a8b39e5624b132a966ce28b1a9"></a><!-- doxytag: member="geos::planargraph::Subgraph::getParent" ref="a2df790a8b39e5624b132a966ce28b1a9" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="classgeos_1_1planargraph_1_1PlanarGraph.html">PlanarGraph</a>& geos::planargraph::Subgraph::getParent </td> <td>(</td> <td class="paramname"></td> <td> ) </td> <td> const<code> [inline]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Gets the <a class="el" href="classgeos_1_1planargraph_1_1PlanarGraph.html">PlanarGraph</a> which this subgraph is part of.</p> <dl class="return"><dt><b>Returns:</b></dt><dd>the parent <a class="el" href="classgeos_1_1planargraph_1_1PlanarGraph.html" title="Represents a directed graph which is embeddable in a planar surface.">PlanarGraph</a> </dd></dl> </div> </div> <a class="anchor" id="a6b6f87cfeb8de147d7f0197294e3b90b"></a><!-- doxytag: member="geos::planargraph::Subgraph::nodeBegin" ref="a6b6f87cfeb8de147d7f0197294e3b90b" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">NodeMap::container::iterator geos::planargraph::Subgraph::nodeBegin </td> <td>(</td> <td class="paramname"></td> <td> ) </td> <td><code> [inline]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Returns a iterators over the planarNodesMap::container in this graph. </p> </div> </div> <hr/>The documentation for this class was generated from the following file:<ul> <li><a class="el" href="Subgraph_8h_source.html">Subgraph.h</a></li> </ul> </div> <hr class="footer"/><address class="footer"><small>Generated on Thu Jul 22 2010 for GEOS by <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.1 </small></address> </body> </html>