Documentation
¶
Index ¶
- Constants
- func InternalErrorFrom(err error, msg string, args ...interface{}) error
- func IsCannotReadTenant(err error) bool
- func IsCannotUpdateObjectInManyBundlesError(err error) bool
- func IsInvalidStatusCondition(err error) bool
- func IsKeyDoesNotExist(err error) bool
- func IsNewCheckViolationError(err error) bool
- func IsNewInvalidOperationError(err error) bool
- func IsNewNotNullViolationError(err error) bool
- func IsNotFoundError(err error) bool
- func IsNotUniqueError(err error) bool
- func IsTenantNotFoundError(err error) bool
- func IsTenantRequired(err error) bool
- func IsValueNotFoundInConfiguration(err error) bool
- func NewCannotReadClientUserError() error
- func NewCannotReadTenantError() error
- func NewCannotUpdateObjectInManyBundles() error
- func NewCheckViolationError(resourceType resource.Type) error
- func NewConcurrentOperationInProgressError(msg string) error
- func NewForeignKeyInvalidOperationError(sqlOperation resource.SQLOperation, resourceType resource.Type) error
- func NewInsufficientScopesError(requiredScopes, actualScopes []string) error
- func NewInternalError(msg string, args ...interface{}) error
- func NewInvalidDataError(msg string, args ...interface{}) error
- func NewInvalidDataErrorWithFields(fields map[string]error, objType string) error
- func NewInvalidOperationError(reason string) error
- func NewInvalidStatusCondition(resourceType resource.Type) error
- func NewKeyDoesNotExistError(key string) error
- func NewNoScopesInContextError() error
- func NewNotFoundError(resourceType resource.Type, objectID string) error
- func NewNotFoundErrorWithMessage(resourceType resource.Type, objectID string, message string) error
- func NewNotFoundErrorWithType(resourceType resource.Type) error
- func NewNotNullViolationError(resourceType resource.Type) error
- func NewNotUniqueError(resourceType resource.Type) error
- func NewNotUniqueNameError(resourceType resource.Type) error
- func NewOperationTimeoutError() error
- func NewRequiredScopesNotDefinedError() error
- func NewTenantNotFoundError(externalTenant string) error
- func NewTenantRequiredError() error
- func NewUnauthorizedError(msg string) error
- func NewValueNotFoundInConfigurationError() error
- func WriteAppError(ctx context.Context, w http.ResponseWriter, appErr error, statusCode int)
- type Error
- type ErrorType
Constants ¶
const ( // NotFoundMsg missing godoc NotFoundMsg = "Object not found" // NotFoundMsgF missing godoc NotFoundMsgF = "Object not found: %s" // InvalidDataMsg missing godoc InvalidDataMsg = "Invalid data" // InternalServerErrMsgF missing godoc InternalServerErrMsgF = "Internal Server Error: %s" // NotUniqueMsg missing godoc NotUniqueMsg = "Object is not unique" // TenantRequiredMsg missing godoc TenantRequiredMsg = "Tenant is required" // TenantNotFoundMsg missing godoc TenantNotFoundMsg = "Tenant not found" // InsufficientScopesMsg missing godoc InsufficientScopesMsg = "insufficient scopes provided" // NoScopesInContextMsg missing godoc NoScopesInContextMsg = "cannot read scopes from context" // NoRequiredScopesInContextMsg missing godoc NoRequiredScopesInContextMsg = "required scopes are not defined" // KeyDoesNotExistMsg missing godoc KeyDoesNotExistMsg = "the key does not exist in the source object" // CannotReadTenantMsg missing godoc CannotReadTenantMsg = "cannot read tenant from context" // CannotReadClientUserMsg missing godoc CannotReadClientUserMsg = "cannot read client_user from context" // InvalidOperationMsg missing godoc InvalidOperationMsg = "The operation is not allowed" UnauthorizedMsg = "Unauthorized" // OperationTimeoutMsg missing godoc OperationTimeoutMsg = "operation has timed out" // EmptyDataMsg missing godoc EmptyDataMsg = "Some required data was left out" // InconsistentDataMsg missing godoc InconsistentDataMsg = "Inconsistent or out-of-range data" // NotUniqueNameMsg missing godoc NotUniqueNameMsg = "Object name is not unique" // ConcurrentOperationMsg missing godoc ConcurrentOperationMsg = "Concurrent operation" // InvalidStatusConditionMsg missing godoc InvalidStatusConditionMsg = "Invalid status condition" // CannotUpdateObjectInManyBundlesMsg missing godoc CannotUpdateObjectInManyBundlesMsg = "Can not update object that is part of more than one bundle" )
Variables ¶
This section is empty.
Functions ¶
func InternalErrorFrom ¶
InternalErrorFrom missing godoc
func IsCannotUpdateObjectInManyBundlesError ¶
IsCannotUpdateObjectInManyBundlesError missing godoc
func IsInvalidStatusCondition ¶
IsInvalidStatusCondition missing godoc
func IsNewCheckViolationError ¶
IsNewCheckViolationError missing godoc
func IsNewInvalidOperationError ¶
IsNewInvalidOperationError missing godoc
func IsNewNotNullViolationError ¶
IsNewNotNullViolationError missing godoc
func IsTenantNotFoundError ¶
IsTenantNotFoundError missing godoc
func IsValueNotFoundInConfiguration ¶
IsValueNotFoundInConfiguration missing godoc
func NewCannotReadClientUserError ¶
func NewCannotReadClientUserError() error
NewCannotReadClientUserError missing godoc
func NewCannotReadTenantError ¶
func NewCannotReadTenantError() error
NewCannotReadTenantError missing godoc
func NewCannotUpdateObjectInManyBundles ¶
func NewCannotUpdateObjectInManyBundles() error
NewCannotUpdateObjectInManyBundles missing godoc
func NewCheckViolationError ¶
NewCheckViolationError missing godoc
func NewConcurrentOperationInProgressError ¶
NewConcurrentOperationInProgressError missing godoc
func NewForeignKeyInvalidOperationError ¶
func NewForeignKeyInvalidOperationError(sqlOperation resource.SQLOperation, resourceType resource.Type) error
NewForeignKeyInvalidOperationError missing godoc
func NewInsufficientScopesError ¶
NewInsufficientScopesError missing godoc
func NewInternalError ¶
NewInternalError missing godoc
func NewInvalidDataError ¶
NewInvalidDataError missing godoc
func NewInvalidDataErrorWithFields ¶
NewInvalidDataErrorWithFields missing godoc
func NewInvalidOperationError ¶
NewInvalidOperationError missing godoc
func NewInvalidStatusCondition ¶
NewInvalidStatusCondition missing godoc
func NewKeyDoesNotExistError ¶
NewKeyDoesNotExistError missing godoc
func NewNoScopesInContextError ¶
func NewNoScopesInContextError() error
NewNoScopesInContextError missing godoc
func NewNotFoundError ¶
NewNotFoundError missing godoc
func NewNotFoundErrorWithMessage ¶
NewNotFoundErrorWithMessage missing godoc
func NewNotFoundErrorWithType ¶
NewNotFoundErrorWithType missing godoc
func NewNotNullViolationError ¶
NewNotNullViolationError missing godoc
func NewNotUniqueError ¶
NewNotUniqueError missing godoc
func NewNotUniqueNameError ¶
NewNotUniqueNameError missing godoc
func NewOperationTimeoutError ¶
func NewOperationTimeoutError() error
NewOperationTimeoutError missing godoc
func NewRequiredScopesNotDefinedError ¶
func NewRequiredScopesNotDefinedError() error
NewRequiredScopesNotDefinedError missing godoc
func NewTenantNotFoundError ¶
NewTenantNotFoundError missing godoc
func NewTenantRequiredError ¶
func NewTenantRequiredError() error
NewTenantRequiredError missing godoc
func NewUnauthorizedError ¶
NewUnauthorizedError missing godoc
func NewValueNotFoundInConfigurationError ¶
func NewValueNotFoundInConfigurationError() error
NewValueNotFoundInConfigurationError missing godoc
func WriteAppError ¶
WriteAppError missing godoc
Types ¶
type Error ¶
type Error struct { Message string // contains filtered or unexported fields }
Error missing godoc
type ErrorType ¶
type ErrorType int
ErrorType missing godoc
const ( // InternalError missing godoc InternalError ErrorType = 10 // UnknownError missing godoc UnknownError ErrorType = 11 // NotFound missing godoc NotFound ErrorType = 20 // NotUnique missing godoc NotUnique ErrorType = 21 // InvalidData missing godoc InvalidData ErrorType = 22 // InsufficientScopes missing godoc InsufficientScopes ErrorType = 23 // TenantRequired missing godoc TenantRequired ErrorType = 24 // TenantNotFound missing godoc TenantNotFound ErrorType = 25 Unauthorized ErrorType = 26 // InvalidOperation missing godoc InvalidOperation ErrorType = 27 // OperationTimeout missing godoc OperationTimeout ErrorType = 28 // EmptyData missing godoc EmptyData ErrorType = 29 // InconsistentData missing godoc InconsistentData ErrorType = 30 // NotUniqueName missing godoc NotUniqueName ErrorType = 31 // ConcurrentOperation missing godoc ConcurrentOperation ErrorType = 32 // InvalidStatusCondition missing godoc InvalidStatusCondition ErrorType = 33 // CannotUpdateObjectInManyBundles missing godoc CannotUpdateObjectInManyBundles ErrorType = 34 )