clr_assembler/formats/dll/
mod.rs1pub use self::{reader::DllReader, writer::DllWriter};
2use crate::program::ClrProgram;
3use gaia_types::{helpers::open_file, GaiaError};
4use std::{io::Cursor, path::Path};
5
6pub mod reader;
7pub mod writer;
8
9#[derive(Clone, Debug)]
18pub struct DllReadConfig {
19 pub assembly_ref_fallback_names: Vec<String>,
20}
21
22impl Default for DllReadConfig {
23 fn default() -> Self {
24 Self { assembly_ref_fallback_names: Vec::new() }
25 }
26}
27
28pub fn dll_from_file(file_path: &Path) -> Result<ClrProgram, GaiaError> {
30 Err(GaiaError::custom_error("DllReader is currently disabled"))
35}
36
37pub fn dll_from_bytes(_bytes: &[u8]) -> Result<ClrProgram, GaiaError> {
39 Err(GaiaError::custom_error("DllReader is currently disabled"))
43}
44
45pub fn is_dotnet_dll(_file_path: &Path) -> Result<bool, GaiaError> {
47 todo!()
49}
50
51pub fn read_dotnet_assembly(file_path: &Path, options: &DllReadConfig) -> Result<ClrProgram, GaiaError> {
53 Err(GaiaError::custom_error("DllReader is currently disabled"))
57}