Added System initializer method

This commit is contained in:
François Autin 2023-03-08 15:34:13 +01:00
parent 06be5c9796
commit de502973c7
No known key found for this signature in database
GPG Key ID: 343F5D382E1DD77C

View File

@ -28,6 +28,17 @@ pub struct System {
impl System { impl System {
/// System constructor
pub fn new(machine: Machine, scheduler: Scheduler) -> Self {
Self {
g_machine: machine,
g_current_thread: None,
g_thread_to_be_destroyed: None,
g_alive: List::new(),
g_scheduler: scheduler
}
}
// GETTERS // GETTERS
/// Returns the Machine /// Returns the Machine