-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
抽象型FacilityAttributeの定義 #137
Conversation
Codecov ReportAttention:
Additional details and impacted files
📢 Thoughts on this report? Let us know! |
#[citygml_data(name = "uro:FishingPortFacilityAttribute")]//スキーマに存在しない | ||
pub struct FishingPortFacilityAttribute { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
uro:FishingPortCapacity と uro:FishingPortFacilityは下にあるので、この二つを削除しときますね。
@@ -1,65 +1,1454 @@ | |||
use nusamai_citygml::citygml_property; | |||
use nusamai_citygml::{citygml_property,citygml_data,CityGMLElement,Code,Measure,Date}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nits: ここってエディターで自動整形されないですかね... 🤔
VS Code
https://tech.uzabase.com/entry/2022/12/28/094600
JetBrains
https://zenn.dev/hkusu/articles/ce6d289fa6588e#clippy-%E3%81%AE%E9%81%A9%E7%94%A8
#[citygml(path = b"uro:portFacilityDetailsType")] | ||
pub port_facility_details_type: Code,//スキーマに存在しない | ||
|
||
#[citygml(path = b"uro:portName")] | ||
pub port_name: String, | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
内部の処理の都合上、[1..1]
のものも Option<T>
になっているのがよいです!
いずれ「required」であることを表現できるようにしたいです。
pub is_designated: Option<bool>, | ||
|
||
#[citygml(path = b"uro:degradationLevel")] | ||
pub degradation_level: Option<u64>, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
xs:integer 型は、負数の可能性もあるので i64 がよいです。おそらく facility.rs に登場するものはすべて i64 ではないかと。
#[citygml(path = b"uro:lefEndDistance")] | ||
pub lef_end_distance: Option<Measure>, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
memo: スキーマを信じるしかないですが、スキーマにこういうタイポありますよね。。。
#[citygml(path = b"uro:FishingPortFacility")] | ||
FishingPortFacilityAttribute(FishingPortFacility), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
こちらが要らなくなってそうです!
#[citygml(path = b"uro:RiverFacilityIdAttribute")] | ||
RiverFacilityIdAttribute(RiverFacilityIdAttribute), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
こちら FacilityIdAttribute の下位型なのでここには登場しないハズと思います。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
最新の plateau_schema.junk.gen_attrs_rust
を使ってコードを生成して、一部を修正いたしました!
こちら Approve してマージさせて頂きます。ありがとうございました。
relate #117
uro:PortAttribute
以外を実装TODO:テスト