juno 0.1.2

A helper rust library for the juno microservices framework
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use std::fmt::*;

#[derive(Debug)]
pub enum Error {
	Internal(String),
	FromJuno(u32),
}

impl Display for Error {
	fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
		match self {
			Error::Internal(string) => write!(f, "Module internal error: {}", string),
			Error::FromJuno(num) => write!(f, "Juno error code: {}", num),
		}
	}
}

pub type Result<T> = std::result::Result<T, Error>;