pub struct Sexp<T: RType> { /* private fields */ }Available on crate feature
public-all only.Expand description
ReadOnly SEXP, should not be changed.
This is the preferred way for accept ffi values
Since R marked the input values as readonly.
Implementations§
Source§impl<T: RType> Sexp<T>
impl<T: RType> Sexp<T>
Sourcepub const unsafe fn missing(self) -> bool
👎Deprecated: Sexp<T> cannot missing (while the item is registered), using OptionSexp<T> instead.
pub const unsafe fn missing(self) -> bool
Sexp means the item is not missing, using OptionSexp<T> if the sexp is optional
(The best practice is, never use this!)
Trait Implementations§
Source§impl<T: RType> SExt for Sexp<T>
impl<T: RType> SExt for Sexp<T>
Source§fn raw(len: usize) -> Owned<Self::Data>
fn raw(len: usize) -> Owned<Self::Data>
allocate a new SEXP object with length, and does not protect it. Read more
Source§fn from(
data: impl AsRef<[<Self::Data as RType>::Data]>,
) -> Protected<Self::Data>
fn from( data: impl AsRef<[<Self::Data as RType>::Data]>, ) -> Protected<Self::Data>
Create a protected R copy from rust object. Read more
Source§fn raw_from(
data: impl AsRef<[<Self::Data as RType>::Data]>,
) -> Owned<Self::Data>
fn raw_from( data: impl AsRef<[<Self::Data as RType>::Data]>, ) -> Owned<Self::Data>
Create a unprotected R copy from rust object. Read more
Source§fn is_correct_type(&self) -> bool
fn is_correct_type(&self) -> bool
check whether the data has the desired type
impl<T: Copy + RType> Copy for Sexp<T>
impl Send for Sexp<Rchar>
impl Sync for Sexp<Rchar>
Auto Trait Implementations§
impl<T> Freeze for Sexp<T>
impl<T> RefUnwindSafe for Sexp<T>where
T: RefUnwindSafe,
impl<T> !Send for Sexp<T>
impl<T> !Sync for Sexp<T>
impl<T> Unpin for Sexp<T>where
T: Unpin,
impl<T> UnwindSafe for Sexp<T>where
T: UnwindSafe,
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