fedimint_empty_common/
config.rs

1use fedimint_core::core::ModuleKind;
2use fedimint_core::encoding::{Decodable, Encodable};
3use fedimint_core::plugin_types_trait_impl_config;
4use serde::{Deserialize, Serialize};
5
6use crate::EmptyCommonInit;
7
8/// Contains all the configuration for the server
9#[derive(Clone, Debug, Serialize, Deserialize)]
10pub struct EmptyConfig {
11    pub private: EmptyConfigPrivate,
12    pub consensus: EmptyConfigConsensus,
13}
14
15/// Contains all the configuration for the client
16#[derive(Clone, Debug, Eq, PartialEq, Serialize, Deserialize, Encodable, Decodable, Hash)]
17pub struct EmptyClientConfig {}
18
19/// Will be the same for every federation member
20#[derive(Clone, Debug, Serialize, Deserialize, Decodable, Encodable)]
21pub struct EmptyConfigConsensus {}
22
23/// Will be encrypted and not shared such as private key material
24#[derive(Clone, Debug, Serialize, Deserialize)]
25pub struct EmptyConfigPrivate;
26
27// Wire together the configs for this module
28plugin_types_trait_impl_config!(
29    EmptyCommonInit,
30    EmptyConfig,
31    EmptyConfigPrivate,
32    EmptyConfigConsensus,
33    EmptyClientConfig
34);