diff options
Diffstat (limited to 'src/declaration.rs')
| -rw-r--r-- | src/declaration.rs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/declaration.rs b/src/declaration.rs index 2c0855f..fe3aac8 100644 --- a/src/declaration.rs +++ b/src/declaration.rs @@ -1,9 +1,15 @@ +// SPDX-FileCopyrightText: 2025 cel <cel@bunny.garden> +// +// SPDX-License-Identifier: AGPL-3.0-or-later + +/// An XML declaration. pub struct Declaration { pub version_info: VersionInfo, pub encoding_decl: Option<String>, pub sd_decl: Option<bool>, } +/// An XML version. #[derive(Clone, Copy)] pub enum VersionInfo { One, @@ -11,6 +17,7 @@ pub enum VersionInfo { } impl Declaration { + /// Create an XML declaration from a version. pub fn version(version: VersionInfo) -> Self { Self { version_info: version, |
