1use thiserror::Error;
2
3#[derive(Debug, Error)]
4pub enum CopcError {
5 #[error("I/O error: {0}")]
6 Io(#[from] std::io::Error),
7
8 #[error("LAS error: {0}")]
9 Las(#[from] las::Error),
10
11 #[error("LAZ error: {0}")]
12 Laz(#[from] laz::LasZipError),
13
14 #[error("COPC info VLR not found")]
15 CopcInfoNotFound,
16
17 #[error("LAZ VLR not found")]
18 LazVlrNotFound,
19
20 #[error("hierarchy page at offset {offset} truncated")]
21 TruncatedHierarchyPage { offset: u64 },
22
23 #[error("byte source error: {0}")]
24 ByteSource(Box<dyn std::error::Error + Send + Sync>),
25}