diff options
author | 2024-11-02 01:48:54 +0000 | |
---|---|---|
committer | 2024-11-02 01:48:54 +0000 | |
commit | 009b53c4a958fd751686ea185b006fa1a383b703 (patch) | |
tree | b873536fa86cc2d4859887c5e603a96332f60bcb /src/xml/mod.rs | |
parent | d0a8d25d256a72c18a1dde14fdb77b732f4f3ac7 (diff) | |
download | peanuts-009b53c4a958fd751686ea185b006fa1a383b703.tar.gz peanuts-009b53c4a958fd751686ea185b006fa1a383b703.tar.bz2 peanuts-009b53c4a958fd751686ea185b006fa1a383b703.zip |
implement XML composers
Diffstat (limited to 'src/xml/mod.rs')
-rw-r--r-- | src/xml/mod.rs | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/xml/mod.rs b/src/xml/mod.rs index 8df2f41..f072fde 100644 --- a/src/xml/mod.rs +++ b/src/xml/mod.rs @@ -345,6 +345,7 @@ pub struct Elementdecl<'s> { } // TODO: casings??? +// TODO: wtf does that todo mean? /// [46] contentspec ::= 'EMPTY' | 'ANY' | Mixed | children #[derive(Clone, Debug)] pub enum Contentspec<'s> { @@ -469,7 +470,8 @@ pub struct Enumeration<'s>(Vec<Nmtoken<'s>>); pub enum DefaultDecl<'s> { Required, Implied, - Fixed(AttValue<'s>), + /// if bool == true, attribute MUST always have default value + Fixed(bool, AttValue<'s>), } /// [61] conditionalSect ::= includeSect | ignoreSect @@ -544,7 +546,7 @@ pub enum EntityDef<'s> { EntityValue(EntityValue<'s>), ExternalID { external_id: ExternalID<'s>, - ndata_decl: Option<NDataDecl<'s>>, + n_data_decl: Option<NDataDecl<'s>>, }, } @@ -583,8 +585,9 @@ pub struct ExtParsedEnt<'s> { content: Content<'s>, } -/// [80] EncodingDecl ::= S 'encoding' Eq ('"' EncName '"' | "'" EncName +/// [80] EncodingDecl ::= S 'encoding' Eq ('"' EncName '"' | "'" EncName "'" ) #[derive(Debug)] +// TODO?: select quote version pub struct EncodingDecl<'s>(EncName<'s>); /// [81] EncName ::= [A-Za-z] ([A-Za-z0-9._] | '-')* |