dynamic_waas_sdk_mpc/
error.rs1use thiserror::Error;
4
5#[derive(Debug, Error)]
6#[non_exhaustive]
7pub enum MpcError {
8 #[error("MPC operation failed: {0}")]
9 Operation(String),
10
11 #[error("invalid argument: {0}")]
12 InvalidArgument(String),
13
14 #[error("operation not yet implemented in this build of dynamic-waas-sdk-mpc")]
15 NotImplemented,
16
17 #[error("unexpected MPC error")]
18 Unknown,
19}
20
21pub(crate) mod codes {
24 pub const OK: i32 = 0;
25 pub const NOT_IMPLEMENTED: i32 = -1;
26 pub const INVALID_ARGUMENT: i32 = -2;
27 pub const MPC_FAILED: i32 = -3;
28}