Struct gimli::write::EndianVec [−][src]
A Vec<u8>
with endianity metadata.
This implements the Writer
trait, which is used for all writing of DWARF sections.
Implementations
impl<Endian> EndianVec<Endian> where
Endian: Endianity,
[src]
Endian: Endianity,
pub fn new(endian: Endian) -> EndianVec<Endian>
[src]
Construct an empty EndianVec
with the given endianity.
pub fn slice(&self) -> &[u8]
[src]
Return a reference to the raw slice.
pub fn into_vec(self) -> Vec<u8>
[src]
Convert into a Vec<u8>
.
pub fn take(&mut self) -> Vec<u8>
[src]
Take any written data out of the EndianVec
, leaving an empty Vec
in its place.
Trait Implementations
impl<Endian: Clone> Clone for EndianVec<Endian> where
Endian: Endianity,
[src]
Endian: Endianity,
impl<Endian: Debug> Debug for EndianVec<Endian> where
Endian: Endianity,
[src]
Endian: Endianity,
impl<Endian> Writer for EndianVec<Endian> where
Endian: Endianity,
[src]
Endian: Endianity,
type Endian = Endian
The endianity of bytes that are written.
fn endian(&self) -> Self::Endian
[src]
fn len(&self) -> usize
[src]
fn write(&mut self, bytes: &[u8]) -> Result<()>
[src]
fn write_at(&mut self, offset: usize, bytes: &[u8]) -> Result<()>
[src]
fn write_address(&mut self, address: Address, size: u8) -> Result<()>
[src]
fn write_eh_pointer(
&mut self,
address: Address,
eh_pe: DwEhPe,
size: u8
) -> Result<()>
[src]
&mut self,
address: Address,
eh_pe: DwEhPe,
size: u8
) -> Result<()>
fn write_eh_pointer_data(
&mut self,
val: u64,
format: DwEhPe,
size: u8
) -> Result<()>
[src]
&mut self,
val: u64,
format: DwEhPe,
size: u8
) -> Result<()>
fn write_offset(
&mut self,
val: usize,
_section: SectionId,
size: u8
) -> Result<()>
[src]
&mut self,
val: usize,
_section: SectionId,
size: u8
) -> Result<()>
fn write_offset_at(
&mut self,
offset: usize,
val: usize,
_section: SectionId,
size: u8
) -> Result<()>
[src]
&mut self,
offset: usize,
val: usize,
_section: SectionId,
size: u8
) -> Result<()>
fn write_reference(&mut self, _symbol: usize, _size: u8) -> Result<()>
[src]
fn write_u8(&mut self, val: u8) -> Result<()>
[src]
fn write_u16(&mut self, val: u16) -> Result<()>
[src]
fn write_u32(&mut self, val: u32) -> Result<()>
[src]
fn write_u64(&mut self, val: u64) -> Result<()>
[src]
fn write_u8_at(&mut self, offset: usize, val: u8) -> Result<()>
[src]
fn write_u16_at(&mut self, offset: usize, val: u16) -> Result<()>
[src]
fn write_u32_at(&mut self, offset: usize, val: u32) -> Result<()>
[src]
fn write_u64_at(&mut self, offset: usize, val: u64) -> Result<()>
[src]
fn write_udata(&mut self, val: u64, size: u8) -> Result<()>
[src]
fn write_sdata(&mut self, val: i64, size: u8) -> Result<()>
[src]
fn write_udata_at(&mut self, offset: usize, val: u64, size: u8) -> Result<()>
[src]
fn write_uleb128(&mut self, val: u64) -> Result<()>
[src]
fn write_sleb128(&mut self, val: i64) -> Result<()>
[src]
fn write_initial_length(
&mut self,
format: Format
) -> Result<InitialLengthOffset>
[src]
&mut self,
format: Format
) -> Result<InitialLengthOffset>
fn write_initial_length_at(
&mut self,
offset: InitialLengthOffset,
length: u64,
format: Format
) -> Result<()>
[src]
&mut self,
offset: InitialLengthOffset,
length: u64,
format: Format
) -> Result<()>
Auto Trait Implementations
impl<Endian> RefUnwindSafe for EndianVec<Endian> where
Endian: RefUnwindSafe,
Endian: RefUnwindSafe,
impl<Endian> Send for EndianVec<Endian> where
Endian: Send,
Endian: Send,
impl<Endian> Sync for EndianVec<Endian> where
Endian: Sync,
Endian: Sync,
impl<Endian> Unpin for EndianVec<Endian> where
Endian: Unpin,
Endian: Unpin,
impl<Endian> UnwindSafe for EndianVec<Endian> where
Endian: UnwindSafe,
Endian: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,