<!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::geom::prep::PreparedPolygonContains 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_1geom.html">geom</a> </li> <li><b>prep</b> </li> <li><a class="el" href="classgeos_1_1geom_1_1prep_1_1PreparedPolygonContains.html">geos::geom::prep::PreparedPolygonContains</a> </li> </ul> </div> </div> <div class="header"> <div class="summary"> <a href="#pub-methods">Public Member Functions</a> | <a href="#pub-static-methods">Static Public Member Functions</a> | <a href="#pro-methods">Protected Member Functions</a> </div> <div class="headertitle"> <h1>geos::geom::prep::PreparedPolygonContains Class Reference</h1> </div> </div> <div class="contents"> <!-- doxytag: class="geos::geom::prep::PreparedPolygonContains" --><!-- doxytag: inherits="geos::geom::prep::AbstractPreparedPolygonContains" --> <p>Computes the <code>contains</code> spatial relationship predicate for a <a class="el" href="classgeos_1_1geom_1_1prep_1_1PreparedPolygon.html">PreparedPolygon</a> relative to all other <a class="el" href="classgeos_1_1geom_1_1Geometry.html">Geometry</a> classes. <a href="#_details">More...</a></p> <p><code>#include <<a class="el" href="PreparedPolygonContains_8h_source.html">PreparedPolygonContains.h</a>></code></p> <div class="dynheader"> Inheritance diagram for geos::geom::prep::PreparedPolygonContains:</div> <div class="dyncontent"> <div class="center"> <img src="classgeos_1_1geom_1_1prep_1_1PreparedPolygonContains.png" usemap="#geos::geom::prep::PreparedPolygonContains_map" alt=""/> <map id="geos::geom::prep::PreparedPolygonContains_map" name="geos::geom::prep::PreparedPolygonContains_map"> <area href="classgeos_1_1geom_1_1prep_1_1AbstractPreparedPolygonContains.html" alt="geos::geom::prep::AbstractPreparedPolygonContains" shape="rect" coords="0,56,308,80"/> <area href="classgeos_1_1geom_1_1prep_1_1PreparedPolygonPredicate.html" alt="geos::geom::prep::PreparedPolygonPredicate" shape="rect" coords="0,0,308,24"/> </map> </div> <p><a href="classgeos_1_1geom_1_1prep_1_1PreparedPolygonContains-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_1geom_1_1prep_1_1PreparedPolygonContains.html#a332f4153af211bb9db9ca7bf4d2f73ca">PreparedPolygonContains</a> (const <a class="el" href="classgeos_1_1geom_1_1prep_1_1PreparedPolygon.html">PreparedPolygon</a> *const prepPoly)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classgeos_1_1geom_1_1prep_1_1PreparedPolygonContains.html#a517a41317f9c2994a60aef07ba32af2a">contains</a> (const <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> *geom)</td></tr> <tr><td colspan="2"><h2><a name="pub-static-methods"></a> Static Public Member Functions</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top">static bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classgeos_1_1geom_1_1prep_1_1PreparedPolygonContains.html#ad5103efd7f545208b3bddd7fdcaf1586">contains</a> (const <a class="el" href="classgeos_1_1geom_1_1prep_1_1PreparedPolygon.html">PreparedPolygon</a> *const prep, const <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> *geom)</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">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classgeos_1_1geom_1_1prep_1_1PreparedPolygonContains.html#a9ba1d345023ac1b0489e44884586e100">fullTopologicalPredicate</a> (const <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> *geom)</td></tr> </table> <hr/><a name="_details"></a><h2>Detailed Description</h2> <p>Computes the <code>contains</code> spatial relationship predicate for a <a class="el" href="classgeos_1_1geom_1_1prep_1_1PreparedPolygon.html">PreparedPolygon</a> relative to all other <a class="el" href="classgeos_1_1geom_1_1Geometry.html">Geometry</a> classes. </p> <p>Uses short-circuit tests and indexing to improve performance.</p> <p>It is not possible to short-circuit in all cases, in particular in the case where the test geometry touches the polygon linework. In this case full topology must be computed.</p> <dl class="author"><dt><b>Author:</b></dt><dd>Martin Davis </dd></dl> <hr/><h2>Constructor & Destructor Documentation</h2> <a class="anchor" id="a332f4153af211bb9db9ca7bf4d2f73ca"></a><!-- doxytag: member="geos::geom::prep::PreparedPolygonContains::PreparedPolygonContains" ref="a332f4153af211bb9db9ca7bf4d2f73ca" args="(const PreparedPolygon *const prepPoly)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">geos::geom::prep::PreparedPolygonContains::PreparedPolygonContains </td> <td>(</td> <td class="paramtype">const <a class="el" href="classgeos_1_1geom_1_1prep_1_1PreparedPolygon.html">PreparedPolygon</a> *const </td> <td class="paramname"> <em>prepPoly</em></td> <td> ) </td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Creates an instance of this operation.</p> <dl><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>prepPoly</em> </td><td>the <a class="el" href="classgeos_1_1geom_1_1prep_1_1PreparedPolygon.html" title="A prepared version of Polygon or MultiPolygon geometries.">PreparedPolygon</a> to evaluate </td></tr> </table> </dd> </dl> </div> </div> <hr/><h2>Member Function Documentation</h2> <a class="anchor" id="a517a41317f9c2994a60aef07ba32af2a"></a><!-- doxytag: member="geos::geom::prep::PreparedPolygonContains::contains" ref="a517a41317f9c2994a60aef07ba32af2a" args="(const geom::Geometry *geom)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">bool geos::geom::prep::PreparedPolygonContains::contains </td> <td>(</td> <td class="paramtype">const <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> * </td> <td class="paramname"> <em>geom</em></td> <td> ) </td> <td><code> [inline]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Tests whether this <a class="el" href="classgeos_1_1geom_1_1prep_1_1PreparedPolygon.html" title="A prepared version of Polygon or MultiPolygon geometries.">PreparedPolygon</a> <code>contains</code> a given geometry.</p> <dl><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>geom</em> </td><td>the test geometry </td></tr> </table> </dd> </dl> <dl class="return"><dt><b>Returns:</b></dt><dd>true if the test geometry is contained </dd></dl> <p>References <a class="el" href="classgeos_1_1geom_1_1prep_1_1AbstractPreparedPolygonContains.html#a40a340530e4d7ebf07a731258497a357">geos::geom::prep::AbstractPreparedPolygonContains::eval()</a>.</p> <p>Referenced by <a class="el" href="classgeos_1_1geom_1_1prep_1_1PreparedPolygonContains.html#ad5103efd7f545208b3bddd7fdcaf1586">contains()</a>.</p> </div> </div> <a class="anchor" id="ad5103efd7f545208b3bddd7fdcaf1586"></a><!-- doxytag: member="geos::geom::prep::PreparedPolygonContains::contains" ref="ad5103efd7f545208b3bddd7fdcaf1586" args="(const PreparedPolygon *const prep, const geom::Geometry *geom)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">static bool geos::geom::prep::PreparedPolygonContains::contains </td> <td>(</td> <td class="paramtype">const <a class="el" href="classgeos_1_1geom_1_1prep_1_1PreparedPolygon.html">PreparedPolygon</a> *const </td> <td class="paramname"> <em>prep</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">const <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> * </td> <td class="paramname"> <em>geom</em></td><td> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td><td><code> [inline, static]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Computes the contains predicate between a <a class="el" href="classgeos_1_1geom_1_1prep_1_1PreparedPolygon.html">PreparedPolygon</a> and a <a class="el" href="classgeos_1_1geom_1_1Geometry.html">Geometry</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>prep</em> </td><td>the prepared polygon </td></tr> <tr><td valign="top"></td><td valign="top"><em>geom</em> </td><td>a test geometry </td></tr> </table> </dd> </dl> <dl class="return"><dt><b>Returns:</b></dt><dd>true if the polygon contains the geometry </dd></dl> <p>References <a class="el" href="classgeos_1_1geom_1_1prep_1_1PreparedPolygonContains.html#a517a41317f9c2994a60aef07ba32af2a">contains()</a>.</p> </div> </div> <a class="anchor" id="a9ba1d345023ac1b0489e44884586e100"></a><!-- doxytag: member="geos::geom::prep::PreparedPolygonContains::fullTopologicalPredicate" ref="a9ba1d345023ac1b0489e44884586e100" args="(const geom::Geometry *geom)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">bool geos::geom::prep::PreparedPolygonContains::fullTopologicalPredicate </td> <td>(</td> <td class="paramtype">const <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> * </td> <td class="paramname"> <em>geom</em></td> <td> ) </td> <td><code> [protected, virtual]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Computes the full topological <code>contains</code> predicate. Used when short-circuit tests are not conclusive.</p> <dl><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>geom</em> </td><td>the test geometry </td></tr> </table> </dd> </dl> <dl class="return"><dt><b>Returns:</b></dt><dd>true if this prepared polygon contains the test geometry </dd></dl> <p>Implements <a class="el" href="classgeos_1_1geom_1_1prep_1_1AbstractPreparedPolygonContains.html#ae0fba49106f225fd7399605437560823">geos::geom::prep::AbstractPreparedPolygonContains</a>.</p> </div> </div> <hr/>The documentation for this class was generated from the following file:<ul> <li><a class="el" href="PreparedPolygonContains_8h_source.html">PreparedPolygonContains.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>