pub struct EnvironmentalConfig {Show 13 fields
pub enable_carbon_tracking: bool,
pub enable_energy_monitoring: bool,
pub enable_efficiency_analysis: bool,
pub enable_sustainability_reporting: bool,
pub enable_environmental_alerts: bool,
pub region: String,
pub carbon_intensity_override: Option<f64>,
pub energy_price_per_kwh: f64,
pub monitoring_interval_secs: u64,
pub carbon_alert_threshold: f64,
pub energy_alert_threshold: f64,
pub include_scope2_emissions: bool,
pub include_scope3_emissions: bool,
}Expand description
Configuration for environmental monitoring
Fields§
§enable_carbon_tracking: boolEnable carbon footprint tracking
enable_energy_monitoring: boolEnable detailed energy monitoring
enable_efficiency_analysis: boolEnable efficiency optimization recommendations
enable_sustainability_reporting: boolEnable sustainability reporting
enable_environmental_alerts: boolEnable real-time environmental alerts
region: StringGeographic region for carbon intensity calculations
carbon_intensity_override: Option<f64>Carbon intensity override (gCO2/kWh) - use regional average if None
energy_price_per_kwh: f64Energy price per kWh (USD)
monitoring_interval_secs: u64Monitoring interval (seconds)
carbon_alert_threshold: f64Carbon footprint alert threshold (kg CO2)
energy_alert_threshold: f64Energy consumption alert threshold (kWh)
include_scope2_emissions: boolInclude scope 2 emissions (electricity)
include_scope3_emissions: boolInclude scope 3 emissions (infrastructure, manufacturing)
Implementations§
Source§impl EnvironmentalConfig
Regional configuration presets
impl EnvironmentalConfig
Regional configuration presets
Sourcepub fn asia_pacific() -> Self
pub fn asia_pacific() -> Self
Asia-Pacific configuration (high carbon intensity)
Sourcepub fn high_precision() -> Self
pub fn high_precision() -> Self
High-precision monitoring configuration
Sourcepub fn low_overhead() -> Self
pub fn low_overhead() -> Self
Low-overhead monitoring configuration
Sourcepub fn compliance_focused() -> Self
pub fn compliance_focused() -> Self
Compliance monitoring configuration (detailed tracking)
Sourcepub fn development() -> Self
pub fn development() -> Self
Development environment configuration (minimal monitoring)
Trait Implementations§
Source§impl Clone for EnvironmentalConfig
impl Clone for EnvironmentalConfig
Source§fn clone(&self) -> EnvironmentalConfig
fn clone(&self) -> EnvironmentalConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for EnvironmentalConfig
impl Debug for EnvironmentalConfig
Source§impl Default for EnvironmentalConfig
impl Default for EnvironmentalConfig
Source§impl<'de> Deserialize<'de> for EnvironmentalConfig
impl<'de> Deserialize<'de> for EnvironmentalConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Auto Trait Implementations§
impl Freeze for EnvironmentalConfig
impl RefUnwindSafe for EnvironmentalConfig
impl Send for EnvironmentalConfig
impl Sync for EnvironmentalConfig
impl Unpin for EnvironmentalConfig
impl UnsafeUnpin for EnvironmentalConfig
impl UnwindSafe for EnvironmentalConfig
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> ConfigSerializable for Twhere
T: Serialize + for<'de> Deserialize<'de>,
impl<T> ConfigSerializable for Twhere
T: Serialize + for<'de> Deserialize<'de>,
Source§fn save_to_file(&self, path: &Path) -> Result<(), TrustformersError>
fn save_to_file(&self, path: &Path) -> Result<(), TrustformersError>
Source§fn load_from_file(path: &Path) -> Result<Self, TrustformersError>where
Self: Sized,
fn load_from_file(path: &Path) -> Result<Self, TrustformersError>where
Self: Sized,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.