Skip to main content

RawExcelValue

Struct RawExcelValue 

Source
pub struct RawExcelValue<'call> { /* private fields */ }
Expand description

An XLOPER12 whose storage is owned by Excel for one callback invocation.

This wrapper is deliberately neither Clone, Copy, Send, nor Sync.

ⓘ
use excel_api::RawExcelValue;
fn require_sync<T: Sync>() {}
require_sync::<RawExcelValue<'static>>();
ⓘ
use excel_api::RawExcelValue;
fn require_clone<T: Clone>() {}
require_clone::<RawExcelValue<'static>>();

Implementations§

Source§

impl<'call> RawExcelValue<'call>

Source

pub unsafe fn from_callback(raw: &'call XLOPER12) -> Self

Establishes the single unsafe boundary for a callback argument.

§Safety

raw and every pointer-bearing member reachable from it must describe initialized, properly aligned SDK storage that remains readable and is not mutated for all of 'call. Counted strings must include their prefix and payload, null-terminated direct strings have separate constructors, multis must contain rows * columns initialized elements, and multi-references must contain count initialized areas.

Source

pub fn decode(&self) -> Result<ExcelValueRef<'call>, DecodeError>

Decodes the raw value after masking Excel’s ownership bits.

Trait Implementations§

Source§

impl<'call> Debug for RawExcelValue<'call>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl<'call> !Send for RawExcelValue<'call>

§

impl<'call> !Sync for RawExcelValue<'call>

§

impl<'call> Freeze for RawExcelValue<'call>

§

impl<'call> RefUnwindSafe for RawExcelValue<'call>

§

impl<'call> Unpin for RawExcelValue<'call>

§

impl<'call> UnsafeUnpin for RawExcelValue<'call>

§

impl<'call> UnwindSafe for RawExcelValue<'call>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.