04.02.2013 Views

MapInfo Spatial Server Map Tiling Service - Product Documentation ...

MapInfo Spatial Server Map Tiling Service - Product Documentation ...

MapInfo Spatial Server Map Tiling Service - Product Documentation ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Handling Errors<br />

Handling Errors<br />

When making requests to the Envinsa REST Interfaces, errors may occur for a variety of reasons. When<br />

they do occur, the interfaces return an Error object.<br />

Before processing the response from an interface, your client application must first check whether the<br />

returned JSON object is an Error object. If it is, your application can examine the contents of the object<br />

to determine what type of error occurred, and then call the appropriate error handling code.<br />

Error Object<br />

An Error object can be identified by its type field, which is set to the String value Error. It has an error<br />

field that contains the error details as an object. The object has the following fields:<br />

Field Name<br />

code<br />

message<br />

Type<br />

String<br />

String<br />

Description<br />

The error code.<br />

The error message.<br />

The following example illustrates the general form of an Error object:<br />

{<br />

}<br />

"EnvinsaResponse":<br />

{<br />

"type": "Error",<br />

"error":<br />

{<br />

"code": "8001",<br />

"message": "Missing input parameter : point"<br />

}<br />

}<br />

In the above example, the Error object contains an error code of 8001 and an error message of Missing<br />

input parameter : point.<br />

Error Codes<br />

50<br />

The following table lists the codes and messages for errors that may be generated by the Envinsa REST<br />

Interfaces.<br />

Note:<br />

Errors that are generated by the Envinsa Web <strong>Service</strong>s do not have an error number.<br />

<strong><strong>Map</strong>Info</strong> <strong>Spatial</strong> <strong>Server</strong> 1.0

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!