forked from devit-tel/go.osrm
-
Notifications
You must be signed in to change notification settings - Fork 0
/
errors.go
26 lines (23 loc) · 924 Bytes
/
errors.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
package osrm
import "errors"
// Error codes that could be returned from OSRM
const (
ErrorCodeInvalidURL = "InvalidUrl"
ErrorCodeInvalidService = "InvalidService"
ErrorCodeInvalidVersion = "InvalidVersion"
ErrorCodeInvalidOptions = "InvalidOptions"
ErrorCodeInvalidQuery = "InvalidQuery"
ErrorCodeInvalidValue = "InvalidValue"
ErrorCodeNoSegment = "NoSegment"
ErrorCodeTooBig = "TooBig"
ErrorCodeNoRoute = "NoRoute"
ErrorCodeNoTable = "NoTable"
ErrorCodeNoMatch = "NoMatch"
errorCodeOK = "Ok" // "Ok" error code never returned to library client, thus not exported
)
// Invalid request errors
var (
ErrEmptyProfileName = errors.New("osrm5: the request should contain a profile name")
ErrNoCoordinates = errors.New("osrm5: the request should contain coordinates")
ErrEmptyServiceName = errors.New("osrm5: the request should contain a service name")
)