use std::collections::HashMap;
use subplotlib::prelude::*;

#[derive(Debug, Default)]
pub struct Context {
    pub(crate) counter: usize,
    pub(crate) files: HashMap<String, SubplotDataFile>,
    pub(crate) this_file: Option<SubplotDataFile>,
}

impl Context {
    pub fn remember_file(&mut self, name: &str, content: SubplotDataFile) {
        self.files.insert(name.to_string(), content);
    }
}

impl ContextElement for Context {
    // An empty implementation is sufficient for now
}
