pub struct ObjectWriter<W: Write> { /* private fields */ }Expand description
Mach-O 目标文件写入器
Implementations§
Source§impl<W: Write> ObjectWriter<W>
impl<W: Write> ObjectWriter<W>
Sourcepub fn new(writer: BinaryWriter<W, Fixed<LittleEndian>>) -> Self
pub fn new(writer: BinaryWriter<W, Fixed<LittleEndian>>) -> Self
创建一个新的目标文件写入器
Sourcepub fn write_header(&mut self, header: &MachoHeader) -> Result<(), GaiaError>
pub fn write_header(&mut self, header: &MachoHeader) -> Result<(), GaiaError>
写入目标文件头
Sourcepub fn write_load_commands(
&mut self,
load_commands: &[LoadCommand],
) -> Result<(), GaiaError>
pub fn write_load_commands( &mut self, load_commands: &[LoadCommand], ) -> Result<(), GaiaError>
写入加载命令
Trait Implementations§
Source§impl<W: Write> MachoWriter<W> for ObjectWriter<W>
impl<W: Write> MachoWriter<W> for ObjectWriter<W>
Source§fn write_program(&mut self, program: &MachoProgram) -> Result<(), GaiaError>
fn write_program(&mut self, program: &MachoProgram) -> Result<(), GaiaError>
写入 Mach-O 程序
Source§fn writer(&mut self) -> &mut BinaryWriter<W, Fixed<LittleEndian>>
fn writer(&mut self) -> &mut BinaryWriter<W, Fixed<LittleEndian>>
获取内部写入器的引用
Auto Trait Implementations§
impl<W> Freeze for ObjectWriter<W>where
W: Freeze,
impl<W> !RefUnwindSafe for ObjectWriter<W>
impl<W> Send for ObjectWriter<W>where
W: Send,
impl<W> Sync for ObjectWriter<W>where
W: Sync,
impl<W> Unpin for ObjectWriter<W>where
W: Unpin,
impl<W> UnsafeUnpin for ObjectWriter<W>where
W: UnsafeUnpin,
impl<W> !UnwindSafe for ObjectWriter<W>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more