pub struct FeaturesConfig {
pub enable_trading: bool,
pub enable_bridging: bool,
pub enable_social_monitoring: bool,
pub enable_graph_memory: bool,
pub enable_streaming: bool,
pub enable_webhooks: bool,
pub enable_analytics: bool,
pub debug_mode: bool,
pub experimental: bool,
pub custom: HashMap<String, bool>,
}Expand description
Feature flags configuration
Fields§
§enable_trading: boolEnable trading functionality
enable_bridging: boolEnable cross-chain bridging
Enable social media monitoring
enable_graph_memory: boolEnable graph-based memory
enable_streaming: boolEnable real-time streaming
enable_webhooks: boolEnable webhook notifications
enable_analytics: boolEnable analytics collection
debug_mode: boolEnable debug mode
experimental: boolEnable experimental features
custom: HashMap<String, bool>Custom feature flags
Implementations§
Source§impl FeaturesConfig
impl FeaturesConfig
Sourcepub fn is_enabled(&self, feature: Feature) -> bool
pub fn is_enabled(&self, feature: Feature) -> bool
Check if a feature is enabled
Sourcepub fn is_custom_enabled(&self, name: &str) -> bool
pub fn is_custom_enabled(&self, name: &str) -> bool
Check if a custom feature is enabled
Sourcepub fn validate_config(&self) -> Result<(), ConfigError>
pub fn validate_config(&self) -> Result<(), ConfigError>
Validate the features configuration for consistency and warnings
Trait Implementations§
Source§impl Clone for FeaturesConfig
impl Clone for FeaturesConfig
Source§fn clone(&self) -> FeaturesConfig
fn clone(&self) -> FeaturesConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FeaturesConfig
impl Debug for FeaturesConfig
Source§impl Default for FeaturesConfig
impl Default for FeaturesConfig
Source§fn default() -> FeaturesConfig
fn default() -> FeaturesConfig
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for FeaturesConfig
impl<'de> Deserialize<'de> for FeaturesConfig
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<FeaturesConfig, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<FeaturesConfig, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for FeaturesConfig
impl Serialize for FeaturesConfig
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl Freeze for FeaturesConfig
impl RefUnwindSafe for FeaturesConfig
impl Send for FeaturesConfig
impl Sync for FeaturesConfig
impl Unpin for FeaturesConfig
impl UnwindSafe for FeaturesConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more