From 50bd2ad1cfc7647457f3708e8a4fc3f7afd7eea4 Mon Sep 17 00:00:00 2001 From: satoshi komatsu Date: Tue, 21 Jan 2025 19:28:28 +0900 Subject: [PATCH] core --- nusamai-plateau/src/models/core.rs | 21 +++++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) diff --git a/nusamai-plateau/src/models/core.rs b/nusamai-plateau/src/models/core.rs index dc6a3b277..8046dfe31 100644 --- a/nusamai-plateau/src/models/core.rs +++ b/nusamai-plateau/src/models/core.rs @@ -1,7 +1,24 @@ -use nusamai_citygml::citygml_data; +use nusamai_citygml::{citygml_data, CityGmlElement}; #[citygml_data(name = "core:Address")] #[citygml(allow_extra)] pub struct Address { - // TODO + #[citygml(path = b"core:xalAddress/xAL:AddressDetails")] + country: Vec, +} + +#[citygml_data(name = "xAL:AddressDetails")] +#[citygml(allow_extra)] +pub struct AddressDetail { + #[citygml(path = b"xAL:Country")] + country: Country, +} + +#[citygml_data(name = "xAL:Country")] +#[citygml(allow_extra)] +pub struct Country { + #[citygml(path = b"xAL:CountryName")] + name: Option, + #[citygml(path = b"xAL:Locality/xAL:LocalityName")] + locality_name: Option, }