hit-data 0.0.5

Hierarchical Indexed Typed data structure
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
use std::{collections::HashMap, rc::Rc};

use crate::{HitError, Model};

pub fn kernel_init(models: HashMap<String, Rc<Model>>) -> Result<(), HitError> {
    for model in models.values() {
        for (_, field) in model.get_fields().iter() {
            let mut field = field.borrow_mut();
            field.on_kernel_init(model.get_name())?;
        }
    }
    Ok(())
}