pub struct CloudWatchState {
pub account_id: String,
pub metrics: BTreeMap<String, BTreeMap<String, Vec<MetricDatum>>>,
pub alarms: BTreeMap<String, BTreeMap<String, MetricAlarm>>,
pub dashboards: BTreeMap<String, Dashboard>,
}Fields§
§account_id: String§metrics: BTreeMap<String, BTreeMap<String, Vec<MetricDatum>>>region -> namespace -> Vec
alarms: BTreeMap<String, BTreeMap<String, MetricAlarm>>region -> alarm_name -> MetricAlarm
dashboards: BTreeMap<String, Dashboard>Dashboards keyed by name (CloudWatch dashboards are global per account, not regional).
Implementations§
Source§impl CloudWatchState
impl CloudWatchState
pub fn new(account_id: &str) -> Self
pub fn metrics_in( &self, region: &str, ) -> Option<&BTreeMap<String, Vec<MetricDatum>>>
pub fn metrics_in_mut( &mut self, region: &str, ) -> &mut BTreeMap<String, Vec<MetricDatum>>
pub fn alarms_in(&self, region: &str) -> Option<&BTreeMap<String, MetricAlarm>>
pub fn alarms_in_mut( &mut self, region: &str, ) -> &mut BTreeMap<String, MetricAlarm>
Trait Implementations§
Source§impl Debug for CloudWatchState
impl Debug for CloudWatchState
Source§impl Default for CloudWatchState
impl Default for CloudWatchState
Source§fn default() -> CloudWatchState
fn default() -> CloudWatchState
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for CloudWatchState
impl<'de> Deserialize<'de> for CloudWatchState
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>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for CloudWatchState
impl RefUnwindSafe for CloudWatchState
impl Send for CloudWatchState
impl Sync for CloudWatchState
impl Unpin for CloudWatchState
impl UnsafeUnpin for CloudWatchState
impl UnwindSafe for CloudWatchState
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