PostGIS  2.2.8dev-r@@SVN_REVISION@@

◆ rtpg_uniontype_index_from_name()

static rtpg_union_type rtpg_uniontype_index_from_name ( const char *  cutype)
static

Definition at line 1671 of file rtpg_mapalgebra.c.

References UT_COUNT, UT_FIRST, UT_LAST, UT_MAX, UT_MEAN, UT_MIN, UT_RANGE, and UT_SUM.

Referenced by RASTER_union_transfn(), and rtpg_union_unionarg_process().

1671  {
1672  assert(cutype && strlen(cutype) > 0);
1673 
1674  if (strcmp(cutype, "LAST") == 0)
1675  return UT_LAST;
1676  else if (strcmp(cutype, "FIRST") == 0)
1677  return UT_FIRST;
1678  else if (strcmp(cutype, "MIN") == 0)
1679  return UT_MIN;
1680  else if (strcmp(cutype, "MAX") == 0)
1681  return UT_MAX;
1682  else if (strcmp(cutype, "COUNT") == 0)
1683  return UT_COUNT;
1684  else if (strcmp(cutype, "SUM") == 0)
1685  return UT_SUM;
1686  else if (strcmp(cutype, "MEAN") == 0)
1687  return UT_MEAN;
1688  else if (strcmp(cutype, "RANGE") == 0)
1689  return UT_RANGE;
1690 
1691  return UT_LAST;
1692 }
Here is the caller graph for this function: