Update parse_affiliated_keywords for handling optional pairs.

This commit is contained in:
Tom Alexander
2023-10-16 11:42:20 -04:00
parent f5a6a26c43
commit e352deb989
2 changed files with 123 additions and 68 deletions

View File

@@ -6,7 +6,11 @@ use super::Object;
pub enum AffiliatedKeywordValue<'s> {
SingleString(&'s str),
ListOfStrings(Vec<&'s str>),
ListOfListsOfObjects(Vec<(Option<Vec<Object<'s>>>, Vec<Object<'s>>)>),
OptionalPair {
optval: Option<&'s str>,
val: &'s str,
},
ObjectTree(Vec<(Option<Vec<Object<'s>>>, Vec<Object<'s>>)>),
}
#[derive(Debug)]