95
110
int msWCSException11(mapObj *map, const char *locator,
96
111
const char *exceptionCode, const char *version);
114
/* -------------------------------------------------------------------- */
115
/* Some WCS 2.0 specific functions and structs from mapwcs20.c */
116
/* -------------------------------------------------------------------- */
126
MS_WCS20_ERROR_VALUE = -1,
127
MS_WCS20_SCALAR_VALUE = 0,
128
MS_WCS20_TIME_VALUE = 1,
129
MS_WCS20_UNDEFINED_VALUE = 2
132
#define MS_WCS20_UNBOUNDED DBL_MAX
133
#define MS_WCS20_UNBOUNDED_TIME 0xFFFFFFFF
142
int unbounded; /* 0 if bounded, 1 if unbounded */
147
char *axis; /* the name of the subsetted axis */
148
int operation; /* Either TRIM or SLICE */
149
char *crs; /* optional CRS to use */
150
int timeOrScalar; /* 0 if scalar value, 1 if time value */
151
timeScalarUnion min; /* Minimum and Maximum of the subsetted axis;*/
154
typedef wcs20SubsetObj * wcs20SubsetObjPtr;
158
char *name; /* name of the axis */
159
int size; /* pixelsize of the axis */
160
double resolution; /* resolution of the axis */
161
char *resolutionUOM; /* resolution units of measure */
162
wcs20SubsetObjPtr subset;
164
typedef wcs20AxisObj * wcs20AxisObjPtr;
168
char *version; /* 2.0.0 */
169
char *request; /* GetCapabilities|DescribeCoverage|GetCoverage */
170
char *service; /* MUST be WCS */
171
char **accept_versions; /* NULL terminated list of Accepted versions */
172
char **sections; /* NULL terminated list of GetCapabilities sections */
173
char *updatesequence; /* GetCapabilities updatesequence */
174
char **ids; /* NULL terminated list of coverages (in the case of a GetCoverage there will only be 1) */
175
long width, height; /* image dimensions */
176
double resolutionX; /* image resolution in X axis */
177
double resolutionY; /* image resolution in Y axis */
178
char *resolutionUnits; /* Units of Measure for resolution */
179
char *format; /* requested output format */
180
int multipart; /* flag for multipart GML+image */
181
char *interpolation; /* requested interpolation method */
182
char *outputcrs; /* requested CRS for output */
183
char *subsetcrs; /* determined CRS of the subsets */
184
rectObj bbox; /* determined Bounding Box */
185
int numaxes; /* number of axes */
186
wcs20AxisObjPtr *axes; /* list of axes, NULL if none*/
188
char **invalid_get_parameters; /* NULL terminated list of invalid GET parameters */
190
typedef wcs20ParamsObj * wcs20ParamsObjPtr;
199
char *interpretation;
208
int significant_figures;
209
} wcs20rasterbandMetadataObj;
210
typedef wcs20rasterbandMetadataObj * wcs20rasterbandMetadataObjPtr;
214
char *native_format; /* mime type of the native format */
218
double geotransform[6];
226
char **nilvalues_reasons;
228
wcs20rasterbandMetadataObjPtr bands;
229
} wcs20coverageMetadataObj;
230
typedef wcs20coverageMetadataObj * wcs20coverageMetadataObjPtr;
232
#define MS_WCS_20_PROFILE_CORE "http://www.opengis.net/spec/WCS/2.0/conf/core"
233
#define MS_WCS_20_PROFILE_KVP "http://www.opengis.net/spec/WCS_protocol-binding_get-kvp/1.0"
234
#define MS_WCS_20_PROFILE_POST "http://www.opengis.net/spec/WCS_protocol-binding_post-xml/1.0"
235
#define MS_WCS_20_PROFILE_GEOTIFF "http://www.opengis.net/spec/WCS_coverage-encoding_geotiff/1.0/"
236
#define MS_WCS_20_PROFILE_GML_GEOTIFF "http://www.placeholder.com/GML_and_GeoTIFF"
237
#define MS_WCS_20_PROFILE_EPSG "http://www.placeholder.com/EPSG"
238
#define MS_WCS_20_PROFILE_IMAGECRS "http://www.placeholder.com/IMAGECRS"
239
#define MS_WCS_20_PROFILE_SCALING "http://www.placeholder.com/SCALING"
240
#define MS_WCS_20_PROFILE_INTERPOLATION "http://www.placeholder.com/INTERPOLATION"
241
#define MS_WCS_20_PROFILE_RANGESUBSET "http://www.placeholder.com/RANGESUBSET"
243
int msWCSDispatch20(mapObj *map, cgiRequestObj *request, owsRequestObj *ows_request);
245
int msWCSException20(mapObj *map, const char *locator,
246
const char *exceptionCode, const char *version);
248
#define XML_FOREACH_CHILD(parent_node, child_node) \
249
for(child_node = parent_node->children; child_node != NULL; child_node = child_node->next)
251
/* Makro to continue the iteration over an xml structure */
252
/* when the current node has the type 'text' or 'comment' */
253
#define XML_LOOP_IGNORE_COMMENT_OR_TEXT(node) \
254
if(xmlNodeIsText(node) || node->type == XML_COMMENT_NODE) \
259
/* Makro to set an XML error that an unknown node type */
261
#define XML_UNKNOWN_NODE_ERROR(node) \
262
msSetError(MS_WCSERR, "Unknown XML element '%s'.", \
263
__FUNCTION__, (char *)node->name); \
266
#define XML_ASSERT_NODE_NAME(node,nodename) \
267
if(EQUAL((char *)node->name, nodename) == MS_FALSE) \
269
XML_UNKNOWN_NODE_ERROR(node); \
272
#define MS_WCS_20_CAPABILITIES_INCLUDE_SECTION(params,section) \
273
(params->sections == NULL \
274
|| CSLFindString(params->sections, "All") != -1 \
275
|| CSLFindString(params->sections, section) != -1)
98
277
#endif /* nef MAPWCS_H */