completed basic functions

This commit is contained in:
2026-08-01 18:23:06 +00:00
commit 4baae18dd6
8 changed files with 611 additions and 0 deletions

27
src/properties.rs Normal file
View File

@@ -0,0 +1,27 @@
use std::collections::HashMap;
pub struct Properties {
pub(crate) properties: HashMap<String, Property>
}
impl Properties {
pub(crate) fn new() -> Self {
Self {
properties: HashMap::new()
}
}
}
pub enum Property {
Integer(i32),
Text(String),
}
impl std::fmt::Display for Property {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match self {
Self::Integer(i) => write!(f, "{}", i),
Self::Text(t) => write!(f, "{}", t),
}
}
}