UNPKG

1.98 kBTypeScriptView Raw
1/** @module errors */
2/**
3 * Defines standard error categories to application exceptions
4 * supported by PipServices toolkit.
5 */
6export declare class ErrorCategory {
7 /**
8 * Unknown or unexpected errors.
9 */
10 static readonly Unknown: string;
11 /**
12 * Internal errors caused by programming mistakes.
13 */
14 static readonly Internal: string;
15 /**
16 * Errors related to mistakes in user-defined configurations.
17 */
18 static readonly Misconfiguration: string;
19 /**
20 * Errors caused by incorrect object state..
21 *
22 * For example: business calls when the component is not ready.
23 */
24 static readonly InvalidState: string;
25 /**
26 * Errors caused by remote calls timeouted and not returning results.
27 * It allows to clearly separate communication related problems
28 * from other application errors.
29 */
30 static readonly NoResponse: string;
31 /**
32 * Errors caused by remote calls failed due to unidenfied reasons.
33 */
34 static readonly FailedInvocation: string;
35 /**
36 * Errors in read/write local disk operations.
37 */
38 static readonly FileError: string;
39 /**
40 * Errors due to incorrectly specified invocation parameters.
41 *
42 * For example: missing or incorrect parameters.
43 */
44 static readonly BadRequest: string;
45 /**
46 * Access errors caused by missing user identity (authentication error)
47 * or incorrect security permissions (authorization error).
48 */
49 static readonly Unauthorized: string;
50 /**
51 * Errors caused by attempts to access missing objects.
52 */
53 static readonly NotFound: string;
54 /**
55 * Errors raised by conflicts between object versions that were
56 * posted by the user and those that are stored on the server.
57 */
58 static readonly Conflict: string;
59 /**
60 * Errors caused by calls to unsupported or not yet implemented functionality.
61 */
62 static readonly Unsupported: string;
63}