PostGIS  2.5.1dev-r@@SVN_REVISION@@

◆ gserialized_datum_predicate_gidx_geom()

static int gserialized_datum_predicate_gidx_geom ( GIDX *  gidx1,
Datum  gs2,
gidx_predicate  predicate 
)
static

Definition at line 562 of file gserialized_gist_nd.c.

References LW_FALSE, LW_SUCCESS, and LW_TRUE.

Referenced by gserialized_gidx_geog_overlaps(), gserialized_gidx_geom_contains(), gserialized_gidx_geom_overlaps(), and gserialized_gidx_geom_same().

563 {
564  /* Put aside some stack memory and use it for GIDX pointers. */
565  char boxmem2[GIDX_MAX_SIZE];
566  GIDX *gidx2 = (GIDX*)boxmem2;
567 
568  POSTGIS_DEBUG(3, "entered function");
569 
570  /* Must be able to build box for gs2 arguement (ie, not empty geometry)
571  and predicate function to return true. */
572  if ( (gserialized_datum_get_gidx_p(gs2, gidx2) == LW_SUCCESS) &&
573  predicate(gidx1, gidx2) )
574  {
575  POSTGIS_DEBUGF(3, "got boxes %s and %s", gidx_to_string(gidx1), gidx_to_string(gidx2));
576  return LW_TRUE;
577  }
578  return LW_FALSE;
579 }
#define LW_SUCCESS
Definition: liblwgeom.h:79
#define LW_FALSE
Definition: liblwgeom.h:76
#define LW_TRUE
Return types for functions with status returns.
Definition: liblwgeom.h:75
Here is the caller graph for this function: