#[repr(C)]pub struct StyleBackgroundContentVecSlice {
pub ptr: *const StyleBackgroundContent,
pub len: usize,
}Expand description
C-compatible slice type for $struct_name. This is a non-owning view into a Vec’s data.
Fields§
§ptr: *const StyleBackgroundContent§len: usizeImplementations§
Source§impl StyleBackgroundContentVecSlice
impl StyleBackgroundContentVecSlice
Sourcepub const fn as_ptr(&self) -> *const StyleBackgroundContent
pub const fn as_ptr(&self) -> *const StyleBackgroundContent
Returns a pointer to the slice’s data.
Sourcepub fn as_slice(&self) -> &[StyleBackgroundContent]
pub fn as_slice(&self) -> &[StyleBackgroundContent]
Converts the C-slice to a Rust slice.
Sourcepub fn get(&self, index: usize) -> Option<&StyleBackgroundContent>
pub fn get(&self, index: usize) -> Option<&StyleBackgroundContent>
Returns a reference to the element at the given index, or None if out of bounds.
Sourcepub fn iter(&self) -> Iter<'_, StyleBackgroundContent>
pub fn iter(&self) -> Iter<'_, StyleBackgroundContent>
Returns an iterator over the elements.
Trait Implementations§
Source§impl Clone for StyleBackgroundContentVecSlice
impl Clone for StyleBackgroundContentVecSlice
Source§fn clone(&self) -> StyleBackgroundContentVecSlice
fn clone(&self) -> StyleBackgroundContentVecSlice
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for StyleBackgroundContentVecSlice
impl Send for StyleBackgroundContentVecSlice
impl Sync for StyleBackgroundContentVecSlice
Auto Trait Implementations§
impl Freeze for StyleBackgroundContentVecSlice
impl RefUnwindSafe for StyleBackgroundContentVecSlice
impl Unpin for StyleBackgroundContentVecSlice
impl UnsafeUnpin for StyleBackgroundContentVecSlice
impl UnwindSafe for StyleBackgroundContentVecSlice
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