1use thiserror::Error;
2
3pub type Result<T> = std::result::Result<T, OwlError>;
4
5#[derive(Debug, Error)]
6pub enum OwlError {
7 #[error("core error: {0}")]
8 Core(#[from] ontocore_core::OntoCoreError),
9
10 #[error("unsupported format for write-back: {0}")]
11 UnsupportedFormat(String),
12
13 #[error("patch validation failed: {0}")]
14 PatchInvalid(String),
15
16 #[error("entity not found: {0}")]
17 EntityNotFound(String),
18
19 #[error("entity already exists: {0}")]
20 EntityExists(String),
21
22 #[error("Horned-OWL load failed: {0}")]
23 LoadFailed(String),
24
25 #[error("IO error: {0}")]
26 Io(#[from] std::io::Error),
27
28 #[error("store error: {0}")]
29 Store(String),
30
31 #[error("invalid Manchester expression: {0}")]
32 ManchesterInvalid(String),
33}