pub struct EnterpriseConfig { /* private fields */ }
Expand description
Enterprise-grade configuration manager with caching and access control
Implementations§
Source§impl EnterpriseConfig
impl EnterpriseConfig
Sourcepub fn from_file<P: AsRef<Path>>(path: P) -> Result<Self>
pub fn from_file<P: AsRef<Path>>(path: P) -> Result<Self>
Load configuration from file with caching
Sourcepub fn from_string(content: &str, format: Option<&str>) -> Result<Self>
pub fn from_string(content: &str, format: Option<&str>) -> Result<Self>
Load configuration from string with caching
Sourcepub fn get(&self, key: &str) -> Option<&Value>
pub fn get(&self, key: &str) -> Option<&Value>
Get value with default fallback - enterprise API
Sourcepub fn get_or<T>(&self, key: &str, default: T) -> T
pub fn get_or<T>(&self, key: &str, default: T) -> T
Get a value or return a default (ZERO-COPY optimized)
Sourcepub fn get_or_default(&self, key: &str) -> Option<Value>
pub fn get_or_default(&self, key: &str) -> Option<Value>
Get with default value from defaults table
Sourcepub fn set_default(&mut self, key: &str, value: Value)
pub fn set_default(&mut self, key: &str, value: Value)
Set default value for key
Sourcepub fn make_read_only(&mut self)
pub fn make_read_only(&mut self)
Make config read-only for security
Sourcepub fn merge(&mut self, other: &EnterpriseConfig) -> Result<()>
pub fn merge(&mut self, other: &EnterpriseConfig) -> Result<()>
Merge another config into this one
Trait Implementations§
Auto Trait Implementations§
impl Freeze for EnterpriseConfig
impl RefUnwindSafe for EnterpriseConfig
impl Send for EnterpriseConfig
impl Sync for EnterpriseConfig
impl Unpin for EnterpriseConfig
impl UnwindSafe for EnterpriseConfig
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