Struct melon::Program
[−]
[src]
pub struct Program { pub target_version: String, pub system_id: String, pub instructions: Vec<Instruction>, pub mem_pages: Option<Address>, }
The container for a program
Fields
target_version: String
The target version of the melon
API
system_id: String
The ID of the System the program is compiled against
instructions: Vec<Instruction>
The instuctions of the program
mem_pages: Option<Address>
(Optional) The number of allocated memory pages (1 page = 1024 Byte)
Methods
impl Program
[src]
pub fn from_file<P: AsRef<Path>>(path: P) -> Result<Program>
[src]
Loads a MsgPack encoded and gzipped melon image from the given file
pub fn save_as<P: AsRef<Path>>(&self, path: P) -> Result<()>
[src]
Saves the program as a MsgPack encoded and gzipped image to the given file
Trait Implementations
impl Clone for Program
[src]
fn clone(&self) -> Program
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more