-
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
地下街モデルのuro:BuildingDataQualityAttributeの対応 #694
Conversation
Walkthroughこの変更は、CityGMLデータモデルにおける建物データ品質属性の表現を拡張するものです。 Changes
Possibly related PRs
Suggested reviewers
Poem
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
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.
Actionable comments posted: 1
🧹 Nitpick comments (2)
nusamai-plateau/src/models/iur/uro/common.rs (2)
66-81
: ドキュメンテーションの追加を推奨新しく追加された
BuildingDataQualityAttribute
構造体とそのフィールドの目的や使用方法について、ドキュメントコメントの追加を推奨します。特に:
- 構造体の目的
- 各フィールドの期待される値
DataQualityAttribute
との関係性+/// 建物データの品質属性を表す構造体 +/// CityGML URO拡張の BuildingDataQualityAttribute 要素に対応 #[citygml_data(name = "uro:BuildingDataQualityAttribute")] pub struct BuildingDataQualityAttribute { + /// データの縮尺を示すコード #[citygml(path = b"uro:srcScale")] pub src_scale: Vec<Code>,
61-64
: PLATEAUバージョン互換性の明記を推奨他のフィールドと同様に、PLATEAUバージョンとの互換性に関するコメントの追加を推奨します。
+ // PLATEAU 3.x compatibility #[citygml(path = b"uro:BuildingDataQualityAttribute")] pub building_data_quality_attribute: Option<BuildingDataQualityAttribute>,
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (1)
nusamai/src/transformer/transform/shp_field_dict.json
is excluded by!**/*.json
📒 Files selected for processing (2)
nusamai-plateau/src/models/iur/uro/common.rs
(1 hunks)nusamai-plateau/src/models/iur/uro/underground_building.rs
(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (1)
- GitHub Check: build
🔇 Additional comments (1)
nusamai-plateau/src/models/iur/uro/common.rs (1)
77-78
:⚠️ Potential issuelod1_height_typeの型の不一致について
DataQualityAttribute
構造体ではlod1_height_type
がOption<Code>
として定義されているのに対し、BuildingDataQualityAttribute
構造体ではVec<Code>
として定義されています。この不一致は意図的なものでしょうか?- pub lod1_height_type: Vec<Code>, + pub lod1_height_type: Option<Code>,✅ Verification successful
lod1_height_typeの型の修正について
レビューコメントは正しいです。
BuildingDataQualityAttribute
構造体のlod1_height_type
フィールドはVec<Code>
ではなくOption<Code>
として定義するべきです。これは以下の理由によります:
- PLATEAUの仕様では、このフィールドは単一の値として使用されることが想定されています
- 実装例のXMLデータでも、常に単一の値として使用されています
🏁 Scripts executed
The following scripts were executed for the analysis:
Error: No shell scripts found
Script:
#!/bin/bash # Search for struct definitions echo "=== Struct Definitions ===" ast-grep --pattern 'struct DataQualityAttribute { $$$ }' ast-grep --pattern 'struct BuildingDataQualityAttribute { $$$ }' echo -e "\n=== Usage Patterns ===" # Search for usage patterns rg "DataQualityAttribute|BuildingDataQualityAttribute" -A 5 -B 5 echo -e "\n=== Documentation ===" # Look for documentation rg -l "height.*type" . | xargs rg "///|//!" || trueLength of output: 128077
@satoshi7190 コンフリクト解消とテストの修正お願いします! |
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.
Actionable comments posted: 2
🧹 Nitpick comments (1)
nusamai-plateau/src/models/iur/uro/common.rs (1)
86-101
: ドキュメンテーションコメントを追加してください新しい構造体とそのフィールドの目的や使用方法を説明するドキュメンテーションコメントが不足しています。将来のメンテナンス性を向上させるため、以下の情報を含むコメントの追加を推奨します:
- 構造体の目的
- 各フィールドの役割
- 想定される値や制約
例えば:
/// 建物データの品質属性を表現する構造体 /// PLATEAU 4.xの仕様に準拠 #[citygml_data(name = "uro:BuildingDataQualityAttribute")] pub struct BuildingDataQualityAttribute { /// データの縮尺を示すコード #[citygml(path = b"uro:srcScale")] pub src_scale: Vec<Code>, // ... 他のフィールドも同様に }
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (1)
nusamai/src/transformer/transform/shp_field_dict.json
is excluded by!**/*.json
📒 Files selected for processing (1)
nusamai-plateau/src/models/iur/uro/common.rs
(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (2)
- GitHub Check: build
- GitHub Check: test
Codecov ReportAttention: Patch coverage is
Additional details and impacted files
📢 Thoughts on this report? Let us know! |
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.
Actionable comments posted: 0
🧹 Nitpick comments (1)
nusamai-plateau/src/models/iur/uro/common.rs (1)
86-101
: 構造体の実装は適切ですが、ドキュメントの追加を推奨します構造体の実装は適切で、フィールドの型も正しく定義されています。ただし、以下の改善を推奨します:
- 構造体の目的と使用方法を説明するドキュメントコメントの追加
- 各フィールドの役割を説明するドキュメントコメントの追加
/// 建物データの品質属性を表現する構造体 /// PLATEAU の建物データに関する品質情報を格納します #[citygml_data(name = "uro:BuildingDataQualityAttribute")] pub struct BuildingDataQualityAttribute { /// データの縮尺を示すコード #[citygml(path = b"uro:srcScale")] pub src_scale: Vec<Code>, // ... 他のフィールドも同様に
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
nusamai-plateau/src/models/iur/uro/common.rs
(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (2)
- GitHub Check: test
- GitHub Check: build
🔇 Additional comments (1)
nusamai-plateau/src/models/iur/uro/common.rs (1)
81-84
: パス属性の形式を修正してくださいパス属性の形式が他のフィールドと一貫性がありません。他のフィールドでは2段階のパスを使用していますが、このフィールドでは単一のパスになっています。
- #[citygml(path = b"uro:BuildingDataQualityAttribute")] + #[citygml(path = b"uro:buildingDataQualityAttribute/uro:BuildingDataQualityAttribute")]
@nokonoko1203 |
@satoshi7190 ありがとうございます!! |
<!-- Close or Related Issues --> Close #108 ### What I did(変更内容) <!-- Please describe the motivation behind this PR and the changes it introduces. --> <!-- どのような変更をしますか? 目的は? --> - 竹芝、新宿、中央区、世田谷区のデータで動作確認済み - 竹芝のxal:Addressを含むulodの変換エラーは #694 で対応 ### Notes(連絡事項) <!-- If manual testing is required, please describe the procedure. --> <!-- 手動での動作確認が必要なら手順を簡単に伝えてください。そのほか連絡事項など。 --> None / なし
Close #0
What I did(変更内容)
対象のファイル
Notes(連絡事項)
None / なし