1 |
mod operations;
|
2 |
|
3 |
use std::{any::Any, sync::Arc};
|
4 |
|
5 |
pub use operations::*;
|
6 |
use serde::{de::DeserializeOwned, Serialize};
|
7 |
|
8 |
pub trait Setting: Serialize + DeserializeOwned + Send + Sync {
|
9 |
fn name() -> &'static str;
|
10 |
}
|
11 |
|
12 |
#[derive(Clone, Copy, Hash, PartialEq, Eq, Debug)]
|
13 |
pub struct ObjectSettingPair<'s> {
|
14 |
pub object_kind: &'s str,
|
15 |
pub setting_name: &'s str,
|
16 |
}
|
17 |
|
18 |
impl<'s> ObjectSettingPair<'s> {
|
19 |
pub fn new(object_kind: &'s str, setting_name: &'s str) -> Self {
|
20 |
Self {
|
21 |
object_kind,
|
22 |
setting_name,
|
23 |
}
|
24 |
}
|
25 |
}
|
26 |
|