prefixmap/
prefixmap_error.rs

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use crate::PrefixMap;
use iri_s::IriSError;
use thiserror::Error;

#[derive(Debug, Error, Clone)]
pub enum PrefixMapError {
    #[error(transparent)]
    IriSError(#[from] IriSError),

    #[error("Prefix '{prefix}' not found in PrefixMap '{prefixmap}'")]
    PrefixNotFound {
        prefix: String,
        prefixmap: PrefixMap,
    },

    #[error("Format error: {error}")]
    FormatError { error: String },
}