ErrorClass is an error generating function. It accepts a message and optional key value pairs and produces errors that implement ServiceError. If the message is a string or a fmt.Stringer then the string value is used. If the message is an error then the string returned by Error() is used. Otherwise the string produced using fmt.Sprintf("%v") is used. The optional key value pairs are intended to provide additional contextual information and are returned to the client.

ErrorClass is referenced in 1 repository