use std::collections::HashMap; /// The Maven variant to parse poms /// These structs is directly modelled after the XML because that is what strong-xml plugin requires #[derive(PartialEq, Debug)] pub struct Pom { pub parent: Option, pub group_id: Option, pub artifact_id: String, pub version: Option, pub name: Option, pub packaging: Option, pub url: Option, pub dependencies: Vec, pub dependency_management: Vec, pub properties: HashMap, pub modules: Vec, } #[derive(PartialEq, Debug)] pub struct License { pub name: String, pub url: String, pub distribution: Option, } #[derive(PartialEq, Debug)] pub struct Parent { pub group_id: String, pub artifact_id: String, pub version: String, } #[derive(PartialEq, Debug)] pub struct Developer { pub id: Option, pub name: String, } #[derive(PartialEq, Debug, Clone)] pub struct Dependency { pub group_id: String, pub artifact_id: String, pub version: Option, } #[cfg(test)] mod test { use crate::maven::pom::Pom; #[test] fn parse_should_not_fail() {} }