pub enum ComponentError {
Show 44 variants
ArtifactNotFound {
component_id: String,
target: String,
},
ComponentsNotLocked {
component_id: String,
},
BundledComponentNotLoadable {
component: String,
},
ContractNotProvided {
component_id: String,
contract: String,
},
InvalidDigest(String),
DigestMismatch {
expected: String,
actual: String,
},
SizeMismatch {
expected: u64,
actual: u64,
},
SignatureRequired,
InvalidSignatureEncoding,
SignatureVerification,
NonCanonicalManifest,
ManifestDigestMismatch,
ManifestIdentityMismatch,
UnsupportedManifest,
UnsupportedSignatureAlgorithm(String),
UnknownSignatureKey(String),
SignatureKeyMismatch,
UnsafeArchiveEntry(String),
TooManyArchiveEntries {
max: usize,
actual: usize,
},
ExtractedSizeExceeded {
limit: u64,
actual: u64,
},
UnsafeLibraryPath(String),
MissingLibrary(PathBuf),
Download {
url: String,
message: String,
},
Offline {
component: String,
url: String,
},
LibraryLoad {
path: PathBuf,
message: String,
},
MissingEntrypoint(String),
EntrypointFailed(i32),
InvalidDescriptor(&'static str),
IncompatibleAbi {
expected_major: u32,
expected_minor: u32,
actual_major: u32,
actual_minor: u32,
},
IdentityMismatch {
expected: String,
actual: String,
},
ContractHashMismatch,
FeatureSetHashMismatch,
DuplicateLockEntry {
component_id: String,
target: String,
},
UnsupportedLockSchema(u32),
InvalidPublicKey,
InvalidContractTable,
MissingInstanceFactory,
MissingInstanceDestructor,
InstanceCreation {
status: i32,
message: String,
},
NullInstance,
InvalidUtf8,
StringTooLong,
Json(Error),
Io(Error),
}Variants§
ArtifactNotFound
ComponentsNotLocked
BundledComponentNotLoadable
ContractNotProvided
InvalidDigest(String)
DigestMismatch
SizeMismatch
SignatureRequired
InvalidSignatureEncoding
SignatureVerification
NonCanonicalManifest
ManifestDigestMismatch
ManifestIdentityMismatch
UnsupportedManifest
UnsupportedSignatureAlgorithm(String)
UnknownSignatureKey(String)
SignatureKeyMismatch
UnsafeArchiveEntry(String)
TooManyArchiveEntries
ExtractedSizeExceeded
UnsafeLibraryPath(String)
MissingLibrary(PathBuf)
Download
Offline
LibraryLoad
MissingEntrypoint(String)
EntrypointFailed(i32)
InvalidDescriptor(&'static str)
IncompatibleAbi
IdentityMismatch
ContractHashMismatch
FeatureSetHashMismatch
DuplicateLockEntry
UnsupportedLockSchema(u32)
InvalidPublicKey
InvalidContractTable
MissingInstanceFactory
MissingInstanceDestructor
InstanceCreation
NullInstance
InvalidUtf8
StringTooLong
Json(Error)
Io(Error)
Implementations§
Source§impl ComponentError
impl ComponentError
Sourcepub fn code(&self) -> &'static str
pub fn code(&self) -> &'static str
A stable, language-agnostic identifier for this error’s kind, independent of its
human-readable message and never changing across releases for the same variant.
Generated bindings prefix the message with this (see
alef::backends::native_components) so callers in any host language can distinguish,
for example, an offline failure from an invalid signature from an unsupported host
without parsing free-form text.
Trait Implementations§
Source§impl Debug for ComponentError
impl Debug for ComponentError
Source§impl Display for ComponentError
impl Display for ComponentError
Source§impl Error for ComponentError
impl Error for ComponentError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl From<Error> for ComponentError
impl From<Error> for ComponentError
Auto Trait Implementations§
impl !RefUnwindSafe for ComponentError
impl !UnwindSafe for ComponentError
impl Freeze for ComponentError
impl Send for ComponentError
impl Sync for ComponentError
impl Unpin for ComponentError
impl UnsafeUnpin for ComponentError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more