pub struct Region {
pub meta: Bo4eMeta,
pub region_code: Option<String>,
pub name: Option<String>,
pub description: Option<String>,
pub region_type: Option<RegionType>,
pub criteria: Vec<RegionCriterion>,
pub parent_region: Option<Box<Region>>,
pub sub_regions: Vec<Box<Region>>,
}Expand description
A geographical region in the energy market.
German: Region
§Example
use bo4e_core::bo::Region;
use bo4e_core::enums::RegionType;
let region = Region {
region_code: Some("DE-BY".to_string()),
name: Some("Bavaria".to_string()),
region_type: Some(RegionType::SupplyArea),
..Default::default()
};Fields§
§meta: Bo4eMetaBO4E metadata
region_code: Option<String>Region code (Regionscode)
name: Option<String>Region name (Name)
description: Option<String>Description (Beschreibung)
region_type: Option<RegionType>Type of region (Gebietstyp)
criteria: Vec<RegionCriterion>Criteria that define this region (Regionskriterien)
parent_region: Option<Box<Region>>Parent region (Uebergeordnete Region)
sub_regions: Vec<Box<Region>>Sub-regions (Unterregionen)
Trait Implementations§
Source§impl Bo4eObject for Region
impl Bo4eObject for Region
Source§fn type_name_german() -> &'static str
fn type_name_german() -> &'static str
Returns the German type name as used in the
_typ field. Read moreSource§fn type_name_english() -> &'static str
fn type_name_english() -> &'static str
Returns the English type name. Read more
Source§impl<'de> Deserialize<'de> for Region
impl<'de> Deserialize<'de> for Region
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
impl StructuralPartialEq for Region
Auto Trait Implementations§
impl Freeze for Region
impl RefUnwindSafe for Region
impl Send for Region
impl Sync for Region
impl Unpin for Region
impl UnwindSafe for Region
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