@nhtio/encoder/exceptions
Exceptions thrown by the encoder/decoder
Classes
| Class | Description |
|---|---|
| E_CIRCULAR_REFERENCE | Exception thrown when a circular reference is detected during encoding. Circular references cannot be encoded and must be avoided. |
| E_ENCODING_FAILED | Exception thrown when encoding fails due to an underlying error. This wraps the original error as the cause for better error tracing. |
| E_INCOMPATIBLE_VERSION | Exception thrown when attempting to decode data encoded with an incompatible version. This typically occurs when the encoded data is from a newer version than the decoder supports. |
| E_INVALID_VERSION | Exception thrown when an invalid version string is encountered. |
| E_NOT_AN_ENCODED_VALUE | Exception thrown when attempting to decode a value that is not a valid encoded value. This indicates the input string is not in the expected encoded format. |
| E_UNDECODABLE_VALUE | Exception thrown when a value with an unknown or unsupported type cannot be decoded. |
| E_UNENCODABLE_VALUE | Exception thrown when a value cannot be encoded. This indicates that the value type is not supported by the encoder. |
Interfaces
| Interface | Description |
|---|---|
| BaseException | Base exception class that extends the native Error class. Provides a foundation for all custom exceptions with additional metadata like error codes, status codes, and help descriptions. |