-static enum ctables_domain_type
-ctables_function_domain (enum ctables_summary_function function)
-{
- switch (function)
- {
- case CTSF_COUNT:
- case CTSF_ECOUNT:
- case CTSF_MISSING:
- case CSTF_TOTALN:
- case CTSF_ETOTALN:
- case CTSF_VALIDN:
- case CTSF_EVALIDN:
- case CTSF_MAXIMUM:
- case CTSF_MINIMUM:
- case CTSF_RANGE:
- case CTSF_MEAN:
- case CTSF_SEMEAN:
- case CTSF_STDDEV:
- case CTSF_SUM:
- case CTSF_VARIANCE:
- case CTSF_MEDIAN:
- case CTSF_PTILE:
- case CTSF_MODE:
- case CTSF_UCOUNT:
- case CTSF_UMISSING:
- case CSTF_UTOTALN:
- case CTSF_UVALIDN:
- case CTSF_UMEAN:
- case CTSF_USEMEAN:
- case CTSF_USTDDEV:
- case CTSF_USUM:
- case CTSF_UVARIANCE:
- case CTSF_UMEDIAN:
- case CTSF_UPTILE:
- case CTSF_UMODE:
- NOT_REACHED ();
-
- case CTSF_COLPCT_COUNT:
- case CTSF_COLPCT_SUM:
- case CTSF_COLPCT_TOTALN:
- case CTSF_COLPCT_VALIDN:
- case CTSF_UCOLPCT_COUNT:
- case CTSF_UCOLPCT_SUM:
- case CTSF_UCOLPCT_TOTALN:
- case CTSF_UCOLPCT_VALIDN:
- case CTSF_COL_ID:
- return CTDT_COL;
-
- case CTSF_LAYERCOLPCT_COUNT:
- case CTSF_LAYERCOLPCT_SUM:
- case CTSF_LAYERCOLPCT_TOTALN:
- case CTSF_LAYERCOLPCT_VALIDN:
- case CTSF_ULAYERCOLPCT_COUNT:
- case CTSF_ULAYERCOLPCT_SUM:
- case CTSF_ULAYERCOLPCT_TOTALN:
- case CTSF_ULAYERCOLPCT_VALIDN:
- case CTSF_LAYERCOL_ID:
- return CTDT_LAYERCOL;
-
- case CTSF_LAYERPCT_COUNT:
- case CTSF_LAYERPCT_SUM:
- case CTSF_LAYERPCT_TOTALN:
- case CTSF_LAYERPCT_VALIDN:
- case CTSF_ULAYERPCT_COUNT:
- case CTSF_ULAYERPCT_SUM:
- case CTSF_ULAYERPCT_TOTALN:
- case CTSF_ULAYERPCT_VALIDN:
- case CTSF_LAYER_ID:
- return CTDT_LAYER;
-
- case CTSF_LAYERROWPCT_COUNT:
- case CTSF_LAYERROWPCT_SUM:
- case CTSF_LAYERROWPCT_TOTALN:
- case CTSF_LAYERROWPCT_VALIDN:
- case CTSF_ULAYERROWPCT_COUNT:
- case CTSF_ULAYERROWPCT_SUM:
- case CTSF_ULAYERROWPCT_TOTALN:
- case CTSF_ULAYERROWPCT_VALIDN:
- case CTSF_LAYERROW_ID:
- return CTDT_LAYERROW;
-
- case CTSF_ROWPCT_COUNT:
- case CTSF_ROWPCT_SUM:
- case CTSF_ROWPCT_TOTALN:
- case CTSF_ROWPCT_VALIDN:
- case CTSF_UROWPCT_COUNT:
- case CTSF_UROWPCT_SUM:
- case CTSF_UROWPCT_TOTALN:
- case CTSF_UROWPCT_VALIDN:
- case CTSF_ROW_ID:
- return CTDT_ROW;
-
- case CTSF_SUBTABLEPCT_COUNT:
- case CTSF_SUBTABLEPCT_SUM:
- case CTSF_SUBTABLEPCT_TOTALN:
- case CTSF_SUBTABLEPCT_VALIDN:
- case CTSF_USUBTABLEPCT_COUNT:
- case CTSF_USUBTABLEPCT_SUM:
- case CTSF_USUBTABLEPCT_TOTALN:
- case CTSF_USUBTABLEPCT_VALIDN:
- case CTSF_SUBTABLE_ID:
- return CTDT_SUBTABLE;
-
- case CTSF_TABLEPCT_COUNT:
- case CTSF_TABLEPCT_SUM:
- case CTSF_TABLEPCT_TOTALN:
- case CTSF_TABLEPCT_VALIDN:
- case CTSF_UTABLEPCT_COUNT:
- case CTSF_UTABLEPCT_SUM:
- case CTSF_UTABLEPCT_TOTALN:
- case CTSF_UTABLEPCT_VALIDN:
- case CTSF_TABLE_ID:
- return CTDT_TABLE;
- }
-
- NOT_REACHED ();
-}
-
-static enum ctables_domain_type
-ctables_function_is_pctsum (enum ctables_summary_function function)
-{
- switch (function)
- {
- case CTSF_COUNT:
- case CTSF_ECOUNT:
- case CTSF_MISSING:
- case CSTF_TOTALN:
- case CTSF_ETOTALN:
- case CTSF_VALIDN:
- case CTSF_EVALIDN:
- case CTSF_MAXIMUM:
- case CTSF_MINIMUM:
- case CTSF_RANGE:
- case CTSF_MEAN:
- case CTSF_SEMEAN:
- case CTSF_STDDEV:
- case CTSF_SUM:
- case CTSF_VARIANCE:
- case CTSF_MEDIAN:
- case CTSF_PTILE:
- case CTSF_MODE:
- case CTSF_UCOUNT:
- case CTSF_UMISSING:
- case CSTF_UTOTALN:
- case CTSF_UVALIDN:
- case CTSF_UMEAN:
- case CTSF_USEMEAN:
- case CTSF_USTDDEV:
- case CTSF_USUM:
- case CTSF_UVARIANCE:
- case CTSF_UMEDIAN:
- case CTSF_UPTILE:
- case CTSF_UMODE:
- case CTSF_COLPCT_COUNT:
- case CTSF_COLPCT_TOTALN:
- case CTSF_COLPCT_VALIDN:
- case CTSF_UCOLPCT_COUNT:
- case CTSF_UCOLPCT_TOTALN:
- case CTSF_UCOLPCT_VALIDN:
- case CTSF_LAYERCOLPCT_COUNT:
- case CTSF_LAYERCOLPCT_TOTALN:
- case CTSF_LAYERCOLPCT_VALIDN:
- case CTSF_ULAYERCOLPCT_COUNT:
- case CTSF_ULAYERCOLPCT_TOTALN:
- case CTSF_ULAYERCOLPCT_VALIDN:
- case CTSF_LAYERPCT_COUNT:
- case CTSF_LAYERPCT_TOTALN:
- case CTSF_LAYERPCT_VALIDN:
- case CTSF_ULAYERPCT_COUNT:
- case CTSF_ULAYERPCT_TOTALN:
- case CTSF_ULAYERPCT_VALIDN:
- case CTSF_LAYERROWPCT_COUNT:
- case CTSF_LAYERROWPCT_TOTALN:
- case CTSF_LAYERROWPCT_VALIDN:
- case CTSF_ULAYERROWPCT_COUNT:
- case CTSF_ULAYERROWPCT_TOTALN:
- case CTSF_ULAYERROWPCT_VALIDN:
- case CTSF_ROWPCT_COUNT:
- case CTSF_ROWPCT_TOTALN:
- case CTSF_ROWPCT_VALIDN:
- case CTSF_UROWPCT_COUNT:
- case CTSF_UROWPCT_TOTALN:
- case CTSF_UROWPCT_VALIDN:
- case CTSF_SUBTABLEPCT_COUNT:
- case CTSF_SUBTABLEPCT_TOTALN:
- case CTSF_SUBTABLEPCT_VALIDN:
- case CTSF_USUBTABLEPCT_COUNT:
- case CTSF_USUBTABLEPCT_TOTALN:
- case CTSF_USUBTABLEPCT_VALIDN:
- case CTSF_TABLEPCT_COUNT:
- case CTSF_TABLEPCT_TOTALN:
- case CTSF_TABLEPCT_VALIDN:
- case CTSF_UTABLEPCT_COUNT:
- case CTSF_UTABLEPCT_TOTALN:
- case CTSF_UTABLEPCT_VALIDN:
- case CTSF_ROW_ID:
- case CTSF_COL_ID:
- case CTSF_TABLE_ID:
- case CTSF_SUBTABLE_ID:
- case CTSF_LAYER_ID:
- case CTSF_LAYERROW_ID:
- case CTSF_LAYERCOL_ID:
- return false;
-
- case CTSF_COLPCT_SUM:
- case CTSF_UCOLPCT_SUM:
- case CTSF_LAYERCOLPCT_SUM:
- case CTSF_ULAYERCOLPCT_SUM:
- case CTSF_LAYERPCT_SUM:
- case CTSF_ULAYERPCT_SUM:
- case CTSF_LAYERROWPCT_SUM:
- case CTSF_ULAYERROWPCT_SUM:
- case CTSF_ROWPCT_SUM:
- case CTSF_UROWPCT_SUM:
- case CTSF_SUBTABLEPCT_SUM:
- case CTSF_USUBTABLEPCT_SUM:
- case CTSF_TABLEPCT_SUM:
- case CTSF_UTABLEPCT_SUM:
- return true;
- }
-
- NOT_REACHED ();
-}
-