Skip to content

Instantly share code, notes, and snippets.

@jcoglan
Created May 14, 2019 20:22
Show Gist options
  • Save jcoglan/045af8da7cb1530a201ffd9f6217a581 to your computer and use it in GitHub Desktop.
Save jcoglan/045af8da7cb1530a201ffd9f6217a581 to your computer and use it in GitHub Desktop.

Rust types reference

Prelude

  • std::borrow::ToOwned
  • std::boxed::Box
  • std::clone::Clone
  • std::cmp::{PartialEq, PartialOrd, Eq, Ord}
  • std::convert::{AsRef, AsMut, Into, From}
  • std::default::Default
  • std::iter::{Iterator, Extend, IntoIterator, DoubleEndedIterator, ExactSizeIterator}
  • std::marker::{Copy, Send, Sized, Sync, Unpin}
  • std::mem::drop
  • std::ops::{Drop, Fn, FnMut, FnOnce}
  • std::option::Option::{self, Some, None}
  • std::result::Result::{self, Ok, Err}
  • std::slice::SliceConcatExt
  • std::string::{String, ToString}
  • std::vec::Vec

std::any::Any

trait Any: 'static

Requires:

  • type_id(&self) -> TypeId

Provides:

  • downcast_ref<T>(&self) -> Option<&T> where T: Any

  • is<T>(&self) -> bool where T: Any

  • downcast_mut<T>(&mut self) -> Option<&mut T> where T: Any

Implements:

  • impl Debug for dyn Any + 'static + Send + Sync
  • impl Debug for dyn Any + 'static + Send
  • impl Debug for dyn Any + 'static

std::any::TypeId

Methods:

  • of<T>() -> TypeId where T: 'static + ?Sized

Implements:

  • impl Clone for TypeId
  • impl Copy for TypeId
  • impl Debug for TypeId
  • impl Eq for TypeId
  • impl Hash for TypeId
  • impl Ord for TypeId
  • impl PartialEq<TypeId> for TypeId
  • impl PartialOrd<TypeId> for TypeId
  • impl Send for TypeId
  • impl Sync for TypeId

std::borrow::Borrow

trait Borrow<Borrowed>
where
    Borrowed: ?Sized

Requires:

  • borrow(&self) -> &Borrowed

std::borrow::ToOwned (prelude)

trait ToOwned {
    type Owned: Borrow<Self>;
}

Requires:

  • to_owned(&self) -> Self::Owned

Provides:

  • clone_into(&self, target: &mut Self::Owned)

std::boxed::Box (prelude)

struct Box<T>(_)
where
    T: ?Sized

Methods:

  • from_raw(raw: *mut T) -> Box<T>

  • new(x: T) -> Box<T>

  • pin(x: T) -> Pin<Box<T>>

  • into_pin(boxed: Box<T>) -> Pin<Box<T>>

  • into_raw(b: Box<T>) -> *mut T

  • into_raw_non_null(b: Box<T>) -> NonNull<T>

  • leak<'a>(b: Box<T>) -> &'a mut T where T: 'a

  • downcast<T>(self) -> Result<Box<T>, Box<dyn Any + 'static + Send>> where T: Any

  • downcast<T>(self) -> Result<Box<T>, Box<dyn Any + 'static>> where T: Any

Implements:

  • impl Clone for Box<CStr>
  • impl Clone for Box<OsStr>
  • impl Clone for Box<Path>
  • impl Clone for Box<str>
  • impl Default for Box<CStr>
  • impl Default for Box<OsStr>
  • impl Default for Box<str>
  • impl From<Box<CStr>> for CString
  • impl From<Box<OsStr>> for OsString
  • impl From<Box<Path>> for PathBuf
  • impl From<Box<str>> for Box<[u8]>
  • impl From<Box<str>> for String
  • impl From<CString> for Box<CStr>
  • impl From<OsString> for Box<OsStr>
  • impl From<PathBuf> for Box<Path>
  • impl From<String> for Box<dyn Error + Send + Sync>
  • impl From<String> for Box<dyn Error>
  • impl From<String> for Box<str>
  • impl<'_, A, R> FnOnce<A> for Box<dyn FnBox<A, Output = R> + '_ + Send>
  • impl<'_, A, R> FnOnce<A> for Box<dyn FnBox<A, Output = R> + '_>
  • impl<'a, 'b> From<&'b str> for Box<dyn Error + Send + Sync + 'a>
  • impl<'a, 'b> From<Cow<'b, str>> for Box<dyn Error + Send + Sync + 'a>
  • impl<'a, E: Error + 'a> From<E> for Box<dyn Error + 'a>
  • impl<'a, E: Error + Send + Sync + 'a> From<E> for Box<dyn Error + Send + Sync + 'a>
  • impl<'a, T> From<&'a [T]> for Box<[T]> where T: Copy
  • impl<'a> From<&'a CStr> for Box<CStr>
  • impl<'a> From<&'a OsStr> for Box<OsStr>
  • impl<'a> From<&'a Path> for Box<Path>
  • impl<'a> From<&'a str> for Box<dyn Error>
  • impl<'a> From<&'a str> for Box<str>
  • impl<'a> From<Cow<'a, str>> for Box<dyn Error>
  • impl<A> FromIterator<A> for Box<[A]>
  • impl<B: BufRead + ?Sized> BufRead for Box<B>
  • impl<F> Future for Box<F> where F: Unpin + Future + ?Sized
  • impl<G> Generator for Box<G> where G: Unpin + Generator + ?Sized
  • impl<I> DoubleEndedIterator for Box<I> where I: DoubleEndedIterator + ?Sized
  • impl<I> ExactSizeIterator for Box<I> where I: ExactSizeIterator + ?Sized
  • impl<I> FusedIterator for Box<I> where I: FusedIterator + ?Sized
  • impl<I> Iterator for Box<I> where I: Iterator + ?Sized
  • impl<R: Read + ?Sized> Read for Box<R>
  • impl<S: Seek + ?Sized> Seek for Box<S>
  • impl<T, U> CoerceUnsized<Box<U>> for Box<T> where T: Unsize<U> + ?Sized, U: ?Sized
  • impl<T, U> DispatchFromDyn<Box<U>> for Box<T> where T: Unsize<U> + ?Sized, U: ?Sized
  • impl<T: ?Sized> Send for Box<T> where T: Send
  • impl<T: ?Sized> Sync for Box<T> where T: Sync
  • impl<T: Error> Error for Box<T>
  • impl<T> AsMut<T> for Box<T> where T: ?Sized
  • impl<T> AsRef<T> for Box<T> where T: ?Sized
  • impl<T> Borrow<T> for Box<T> where T: ?Sized
  • impl<T> BorrowMut<T> for Box<T> where T: ?Sized
  • impl<T> Clone for Box<T> where T: Clone
  • impl<T> Clone for Box<[T]> where T: Clone
  • impl<T> Debug for Box<T> where T: Debug + ?Sized
  • impl<T> Default for Box<T> where T: Default
  • impl<T> Default for Box<[T]>
  • impl<T> Deref for Box<T> where T: ?Sized
  • impl<T> DerefMut for Box<T> where T: ?Sized
  • impl<T> Display for Box<T> where T: Display + ?Sized
  • impl<T> Drop for Box<T> where T: ?Sized
  • impl<T> Eq for Box<T> where T: Eq + ?Sized
  • impl<T> From<Box<T>> for Arc<T> where T: ?Sized
  • impl<T> From<Box<T>> for Pin<Box<T>> where T: ?Sized
  • impl<T> From<Box<T>> for Rc<T> where T: ?Sized
  • impl<T> From<Box<[T]>> for Vec<T>
  • impl<T> From<T> for Box<T>
  • impl<T> From<Vec<T>> for Box<[T]>
  • impl<T> Hash for Box<T> where T: Hash + ?Sized
  • impl<T> Hasher for Box<T> where T: Hasher + ?Sized
  • impl<T> Ord for Box<T> where T: Ord + ?Sized
  • impl<T> PartialEq<Box<T>> for Box<T> where T: PartialEq<T> + ?Sized
  • impl<T> PartialOrd<Box<T>> for Box<T> where T: PartialOrd<T> + ?Sized
  • impl<T> Pointer for Box<T> where T: ?Sized
  • impl<T> Unpin for Box<T> where T: ?Sized
  • impl<W: Write + ?Sized> Write for Box<W>

std::cell::RefCell

struct RefCell<T>
where
    T: ?Sized

Methods:

  • new(value: T) -> RefCell<T>

  • as_ptr(&self) -> *mut T

  • borrow(&self) -> Ref<T>

  • borrow_mut(&self) -> RefMut<T>

  • replace(&self, t: T) -> T

  • replace_with<F>(&self, f: F) -> T where F: FnOnce(&mut T) -> T

  • swap(&self, other: &RefCell<T>)

  • try_borrow(&self) -> Result<Ref<T>, BorrowError>

  • try_borrow_mut(&self) -> Result<RefMut<T>, BorrowMutError>

  • get_mut(&mut self) -> &mut T

  • into_inner(self) -> T

Implements:

  • impl<T, U> CoerceUnsized<RefCell<U>> for RefCell<T> where T: CoerceUnsized<U>
  • impl<T> !Sync for RefCell<T> where T: ?Sized
  • impl<T> Clone for RefCell<T> where T: Clone
  • impl<T> Debug for RefCell<T> where T: Debug + ?Sized
  • impl<T> Default for RefCell<T> where T: Default
  • impl<T> Eq for RefCell<T> where T: Eq + ?Sized
  • impl<T> From<T> for RefCell<T>
  • impl<T> Ord for RefCell<T> where T: Ord + ?Sized
  • impl<T> PartialEq<RefCell<T>> for RefCell<T> where T: PartialEq<T> + ?Sized
  • impl<T> PartialOrd<RefCell<T>> for RefCell<T> where T: PartialOrd<T> + ?Sized
  • impl<T> RefCell<T> where T: ?Sized
  • impl<T> RefCell<T>
  • impl<T> Send for RefCell<T> where T: Send + ?Sized

std::cell::Ref

struct Ref<'b, T>
where
    T: 'b + 'b + ?Sized

Methods:

  • clone(orig: &Ref<'b, T>) -> Ref<'b, T>
  • map<U, F>(orig: Ref<'b, T>, f: F) -> Ref<'b, U> where F: FnOnce(&T) -> &U, U: ?Sized
  • map_split<U, V, F>(orig: Ref<'b, T>, f: F) -> (Ref<'b, U>, Ref<'b, V>) where F: FnOnce(&T) -> (&U, &V), U: ?Sized, V: ?Sized

Implements:

  • impl<'_, T> Debug for Ref<'_, T> where T: Debug + ?Sized
  • impl<'_, T> Deref for Ref<'_, T> where T: ?Sized
  • impl<'_, T> Display for Ref<'_, T> where T: Display + ?Sized
  • impl<'b, T, U> CoerceUnsized<Ref<'b, U>> for Ref<'b, T> where T: Unsize<U> + ?Sized, U: ?Sized
  • impl<'b, T> !Send for Ref<'b, T>
  • impl<'b, T> !Sync for Ref<'b, T>
  • impl<'b, T> Ref<'b, T> where T: ?Sized

std::cell::RefMut

struct RefMut<'b, T>
where
    T: 'b + 'b + ?Sized

Methods:

  • map<U, F>(orig: RefMut<'b, T>, f: F) -> RefMut<'b, U> where F: FnOnce(&mut T) -> &mut U, U: ?Sized
  • map_split<U, V, F>( orig: RefMut<'b, T>, f: F ) -> (RefMut<'b, U>, RefMut<'b, V>) where F: FnOnce(&mut T) -> (&mut U, &mut V), U: ?Sized, V: ?Sized

Implements:

  • impl<'_, T> Debug for RefMut<'_, T> where T: Debug + ?Sized
  • impl<'_, T> Deref for RefMut<'_, T> where T: ?Sized
  • impl<'_, T> DerefMut for RefMut<'_, T> where T: ?Sized
  • impl<'_, T> Display for RefMut<'_, T> where T: Display + ?Sized
  • impl<'b, T, U> CoerceUnsized<RefMut<'b, U>> for RefMut<'b, T> where T: Unsize<U> + ?Sized, U: ?Sized
  • impl<'b, T> !Send for RefMut<'b, T>
  • impl<'b, T> !Sync for RefMut<'b, T>
  • impl<'b, T> RefMut<'b, T> where T: ?Sized

std::clone::Clone (prelude)

trait Clone

Requires:

  • clone(&self) -> Self

Provides:

  • clone_from(&mut self, source: &Self)

std::cmp::Eq (prelude)

trait Eq: PartialEq<Self>

std::cmp::Ord (prelude)

trait Ord: Eq + PartialOrd<Self>

Requires:

  • cmp(&self, other: &Self) -> Ordering

Provides:

  • max(self, other: Self) -> Self
  • min(self, other: Self) -> Self

std::cmp::Ordering

enum Ordering {
    Less,
    Equal,
    Greater,
}

Methods:

  • reverse(self) -> Ordering
  • then(self, other: Ordering) -> Ordering
  • then_with<F>(self, f: F) -> Ordering where F: FnOnce() -> Ordering

Implements:

  • impl Clone for Ordering
  • impl Copy for Ordering
  • impl Debug for Ordering
  • impl Eq for Ordering
  • impl Hash for Ordering
  • impl Ord for Ordering
  • impl Ordering
  • impl PartialEq<Ordering> for Ordering
  • impl PartialOrd<Ordering> for Ordering
  • impl Send for Ordering
  • impl Sync for Ordering

std::cmp::PartialEq (prelude)

trait PartialEq<Rhs = Self>
where
    Rhs: ?Sized

Requires:

  • eq(&self, other: &Rhs) -> bool

Provides:

  • ne(&self, other: &Rhs) -> bool

std::cmp::PartialOrd (prelude)

trait PartialOrd<Rhs = Self>: PartialEq<Rhs>
where
    Rhs: ?Sized

Requires:

  • partial_cmp(&self, other: &Rhs) -> Option<Ordering>

Provides:

  • ge(&self, other: &Rhs) -> bool
  • gt(&self, other: &Rhs) -> bool
  • le(&self, other: &Rhs) -> bool
  • lt(&self, other: &Rhs) -> bool

std::convert::AsMut (prelude)

trait AsMut<T>
where
    T: ?Sized

Requires:

  • as_mut(&mut self) -> &mut T

std::convert::AsRef (prelude)

trait AsRef<T>
where
    T: ?Sized

Requires:

  • as_ref(&self) -> &T

std::convert::From (prelude)

trait From<T>

Requires:

  • from(T) -> Self

std::convert::Into (prelude)

trait Into<T>

Requires:

  • into(self) -> T

std::default::Default (prelude)

trait Default

Requires:

  • default() -> Self

std::iter::DoubleEndedIterator (prelude)

trait DoubleEndedIterator: Iterator

Requires:

  • next_back(&mut self) -> Option<Self::Item>

Provides:

  • nth_back(&mut self, n: usize) -> Option<Self::Item>

  • rfind<P>(&mut self, predicate: P) -> Option<Self::Item> where P: FnMut(&Self::Item) -> bool

  • try_rfold<B, F, R>(&mut self, init: B, f: F) -> R where F: FnMut(B, Self::Item) -> R, R: Try<Ok = B>

  • rfold<B, F>(self, accum: B, f: F) -> B where F: FnMut(B, Self::Item) -> B

std::iter::ExactSizeIterator (prelude)

trait ExactSizeIterator: Iterator

Provides:

  • is_empty(&self) -> bool
  • len(&self) -> usize

std::iter::Extend (prelude)

trait Extend<A>

Requires:

  • extend<T>(&mut self, iter: T) where T: IntoIterator<Item = A>

std::iter::IntoIterator (prelude)

trait IntoIterator
where
    <Self::IntoIter as Iterator>::Item == Self::Item
{
    type Item;
    type IntoIter: Iterator;
}

Requires:

  • into_iter(self) -> Self::IntoIter

std::iter::Iterator (prelude)

trait Iterator {
    type Item;
}

Requires:

  • next(&mut self) -> Option<Self::Item>

Provides:

  • size_hint(&self) -> (usize, Option<usize>)

  • all<F>(&mut self, f: F) -> bool where F: FnMut(Self::Item) -> bool

  • any<F>(&mut self, f: F) -> bool where F: FnMut(Self::Item) -> bool

  • by_ref(&mut self) -> &mut Self

  • find<P>(&mut self, predicate: P) -> Option<Self::Item> where P: FnMut(&Self::Item) -> bool

  • find_map<B, F>(&mut self, f: F) -> Option<B> where F: FnMut(Self::Item) -> Option<B>

  • nth(&mut self, n: usize) -> Option<Self::Item>

  • position<P>(&mut self, predicate: P) -> Option<usize> where P: FnMut(Self::Item) -> bool

  • rposition<P>(&mut self, predicate: P) -> Option<usize> where P: FnMut(Self::Item) -> bool, Self: ExactSizeIterator + DoubleEndedIterator

  • try_fold<B, F, R>(&mut self, init: B, f: F) -> R where F: FnMut(B, Self::Item) -> R, R: Try<Ok = B>

  • try_for_each<F, R>(&mut self, f: F) -> R where F: FnMut(Self::Item) -> R, R: Try<Ok = ()>

  • chain<U>(self, other: U) -> Chain<Self, <U as IntoIterator>::IntoIter> where U: IntoIterator<Item = Self::Item>

  • cloned<'a, T>(self) -> Cloned<Self> where Self: Iterator<Item = &'a T>, T: 'a + Clone

  • cmp<I>(self, other: I) -> Ordering where I: IntoIterator<Item = Self::Item>, Self::Item: Ord

  • collect<B>(self) -> B where B: FromIterator<Self::Item>

  • copied<'a, T>(self) -> Copied<Self> where Self: Iterator<Item = &'a T>, T: 'a + Copy

  • count(self) -> usize

  • cycle(self) -> Cycle<Self> where Self: Clone

  • enumerate(self) -> Enumerate<Self>

  • eq<I>(self, other: I) -> bool where I: IntoIterator, Self::Item: PartialEq<<I as IntoIterator>::Item>

  • filter<P>(self, predicate: P) -> Filter<Self, P> where P: FnMut(&Self::Item) -> bool

  • filter_map<B, F>(self, f: F) -> FilterMap<Self, F> where F: FnMut(Self::Item) -> Option<B>

  • flat_map<U, F>(self, f: F) -> FlatMap<Self, U, F> where F: FnMut(Self::Item) -> U, U: IntoIterator

  • flatten(self) -> Flatten<Self> where Self::Item: IntoIterator

  • fold<B, F>(self, init: B, f: F) -> B where F: FnMut(B, Self::Item) -> B

  • for_each<F>(self, f: F) where F: FnMut(Self::Item)

  • fuse(self) -> Fuse<Self>

  • ge<I>(self, other: I) -> bool where I: IntoIterator, Self::Item: PartialOrd<<I as IntoIterator>::Item>

  • gt<I>(self, other: I) -> bool where I: IntoIterator, Self::Item: PartialOrd<<I as IntoIterator>::Item>

  • inspect<F>(self, f: F) -> Inspect<Self, F> where F: FnMut(&Self::Item)

  • is_sorted(self) -> bool where Self::Item: PartialOrd<Self::Item>

  • is_sorted_by<F>(self, compare: F) -> bool where F: FnMut(&Self::Item, &Self::Item) -> Option<Ordering>

  • is_sorted_by_key<F, K>(self, f: F) -> bool where F: FnMut(&Self::Item) -> K, K: PartialOrd<K>

  • last(self) -> Option<Self::Item>

  • le<I>(self, other: I) -> bool where I: IntoIterator, Self::Item: PartialOrd<<I as IntoIterator>::Item>

  • lt<I>(self, other: I) -> bool where I: IntoIterator, Self::Item: PartialOrd<<I as IntoIterator>::Item>

  • map<B, F>(self, f: F) -> Map<Self, F> where F: FnMut(Self::Item) -> B

  • max(self) -> Option<Self::Item> where Self::Item: Ord

  • max_by<F>(self, compare: F) -> Option<Self::Item> where F: FnMut(&Self::Item, &Self::Item) -> Ordering

  • max_by_key<B, F>(self, f: F) -> Option<Self::Item> where B: Ord, F: FnMut(&Self::Item) -> B

  • min(self) -> Option<Self::Item> where Self::Item: Ord

  • min_by<F>(self, compare: F) -> Option<Self::Item> where F: FnMut(&Self::Item, &Self::Item) -> Ordering

  • min_by_key<B, F>(self, f: F) -> Option<Self::Item> where B: Ord, F: FnMut(&Self::Item) -> B

  • ne<I>(self, other: I) -> bool where I: IntoIterator, Self::Item: PartialEq<<I as IntoIterator>::Item>

  • partial_cmp<I>(self, other: I) -> Option<Ordering> where I: IntoIterator, Self::Item: PartialOrd<<I as IntoIterator>::Item>

  • partition<B, F>(self, f: F) -> (B, B) where B: Default + Extend<Self::Item>, F: FnMut(&Self::Item) -> bool

  • peekable(self) -> Peekable<Self>

  • product<P>(self) -> P where P: Product<Self::Item>

  • rev(self) -> Rev<Self> where Self: DoubleEndedIterator

  • scan<St, B, F>(self, initial_state: St, f: F) -> Scan<Self, St, F> where F: FnMut(&mut St, Self::Item) -> Option<B>

  • skip(self, n: usize) -> Skip<Self>

  • skip_while<P>(self, predicate: P) -> SkipWhile<Self, P> where P: FnMut(&Self::Item) -> bool

  • step_by(self, step: usize) -> StepBy<Self>

  • sum<S>(self) -> S where S: Sum<Self::Item>

  • take(self, n: usize) -> Take<Self>

  • take_while<P>(self, predicate: P) -> TakeWhile<Self, P> where P: FnMut(&Self::Item) -> bool

  • unzip<A, B, FromA, FromB>(self) -> (FromA, FromB) where FromA: Default + Extend<A>, FromB: Default + Extend<B>, Self: Iterator<Item = (A, B)>

  • zip<U>(self, other: U) -> Zip<Self, <U as IntoIterator>::IntoIter> where U: IntoIterator

std::option::Option (prelude)

enum Option<T> {
    Some(T),
    None,
}

Methods:

  • as_ref(&self) -> Option<&T>

  • deref(&self) -> Option<&<T as Deref>::Target>

  • is_none(&self) -> bool

  • is_some(&self) -> bool

  • iter(&self) -> Iter<T>

  • as_mut(&mut self) -> Option<&mut T>

  • get_or_insert(&mut self, v: T) -> &mut T

  • get_or_insert_with<F>(&mut self, f: F) -> &mut T where F: FnOnce() -> T

  • iter_mut(&mut self) -> IterMut<T>

  • replace(&mut self, value: T) -> Option<T>

  • take(&mut self) -> Option<T>

  • and<U>(self, optb: Option<U>) -> Option<U>

  • and_then<U, F>(self, f: F) -> Option<U> where F: FnOnce(T) -> Option<U>

  • as_pin_mut(self: Pin<&'a mut Option<T>>) -> Option<Pin<&'a mut T>>

  • as_pin_ref(self: Pin<&'a Option<T>>) -> Option<Pin<&'a T>>

  • cloned(self) -> Option<T>

  • copied(self) -> Option<T>

  • expect(self, msg: &str) -> T

  • filter<P>(self, predicate: P) -> Option<T> where P: FnOnce(&T) -> bool

  • map<U, F>(self, f: F) -> Option<U> where F: FnOnce(T) -> U

  • map_or<U, F>(self, default: U, f: F) -> U where F: FnOnce(T) -> U

  • map_or_else<U, D, F>(self, default: D, f: F) -> U where D: FnOnce() -> U, F: FnOnce(T) -> U

  • ok_or<E>(self, err: E) -> Result<T, E>

  • ok_or_else<E, F>(self, err: F) -> Result<T, E> where F: FnOnce() -> E

  • or(self, optb: Option<T>) -> Option<T>

  • or_else<F>(self, f: F) -> Option<T> where F: FnOnce() -> Option<T>

  • transpose(self) -> Result<Option<T>, E>

  • unwrap(self) -> T

  • unwrap_or(self, def: T) -> T

  • unwrap_or_default(self) -> T

  • unwrap_or_else<F>(self, f: F) -> T where F: FnOnce() -> T

  • xor(self, optb: Option<T>) -> Option<T>

Implements:

  • impl<'_, T> Option<&'_ T> where T: Clone
  • impl<'_, T> Option<&'_ T> where T: Copy
  • impl<'_, T> Option<&'_ mut T> where T: Clone
  • impl<'_, T> Option<&'_ mut T> where T: Copy
  • impl<'a, T> From<&'a Option<T>> for Option<&'a T>
  • impl<'a, T> From<&'a mut Option<T>> for Option<&'a mut T>
  • impl<'a, T> IntoIterator for &'a Option<T>
  • impl<'a, T> IntoIterator for &'a mut Option<T>
  • impl<A, V> FromIterator<Option<A>> for Option<V> where V: FromIterator<A>
  • impl<T, E> Option<Result<T, E>>
  • impl<T> Clone for Option<T> where T: Clone
  • impl<T> Copy for Option<T> where T: Copy
  • impl<T> Debug for Option<T> where T: Debug
  • impl<T> Default for Option<T>
  • impl<T> Eq for Option<T> where T: Eq
  • impl<T> From<T> for Option<T>
  • impl<T> Hash for Option<T> where T: Hash
  • impl<T> IntoIterator for Option<T>
  • impl<T> Option<T> where T: Default
  • impl<T> Option<T> where T: Deref
  • impl<T> Option<T>
  • impl<T> Ord for Option<T> where T: Ord
  • impl<T> PartialEq<Option<T>> for Option<T> where T: PartialEq<T>
  • impl<T> PartialOrd<Option<T>> for Option<T> where T: PartialOrd<T>
  • impl<T> Send for Option<T> where T: Send
  • impl<T> Sync for Option<T> where T: Sync
  • impl<T> Try for Option<T>

std::result::Result (prelude)

enum Result<T, E> {
    Ok(T),
    Err(E),
}

Methods:

  • as_ref(&self) -> Result<&T, &E>

  • deref(&self) -> Result<&<T as Deref>::Target, &<E as Deref>::Target>

  • deref_err(&self) -> Result<&T, &<E as Deref>::Target>

  • deref_ok(&self) -> Result<&<T as Deref>::Target, &E>

  • is_err(&self) -> bool

  • is_ok(&self) -> bool

  • iter(&self) -> Iter<T>

  • as_mut(&mut self) -> Result<&mut T, &mut E>

  • iter_mut(&mut self) -> IterMut<T>

  • and<U>(self, res: Result<U, E>) -> Result<U, E>

  • and_then<U, F>(self, op: F) -> Result<U, E> where F: FnOnce(T) -> Result<U, E>

  • err(self) -> Option<E>

  • expect(self, msg: &str) -> T

  • expect_err(self, msg: &str) -> E

  • map<U, F>(self, op: F) -> Result<U, E> where F: FnOnce(T) -> U

  • map_err<F, O>(self, op: O) -> Result<T, F> where O: FnOnce(E) -> F

  • map_or_else<U, M, F>(self, fallback: F, map: M) -> U where F: FnOnce(E) -> U, M: FnOnce(T) -> U

  • ok(self) -> Option<T>

  • or<F>(self, res: Result<T, F>) -> Result<T, F>

  • or_else<F, O>(self, op: O) -> Result<T, F> where O: FnOnce(E) -> Result<T, F>

  • transpose(self) -> Option<Result<T, E>>

  • unwrap(self) -> T

  • unwrap_err(self) -> E

  • unwrap_or(self, optb: T) -> T

  • unwrap_or_default(self) -> T

  • unwrap_or_else<F>(self, op: F) -> T where F: FnOnce(E) -> T

Implements:

  • impl<'a, T, E> IntoIterator for &'a Result<T, E>
  • impl<'a, T, E> IntoIterator for &'a mut Result<T, E>
  • impl<A, E, V> FromIterator<Result<A, E>> for Result<V, E> where V: FromIterator<A>
  • impl<E: Debug> Termination for Result<!, E>
  • impl<E: Debug> Termination for Result<(), E>
  • impl<T, E> Clone for Result<T, E> where E: Clone, T: Clone
  • impl<T, E> Copy for Result<T, E> where E: Copy, T: Copy
  • impl<T, E> Debug for Result<T, E> where E: Debug, T: Debug
  • impl<T, E> Eq for Result<T, E> where E: Eq, T: Eq
  • impl<T, E> Hash for Result<T, E> where E: Hash, T: Hash
  • impl<T, E> IntoIterator for Result<T, E>
  • impl<T, E> Ord for Result<T, E> where E: Ord, T: Ord
  • impl<T, E> PartialEq<Result<T, E>> for Result<T, E> where E: PartialEq<E>, T: PartialEq<T>
  • impl<T, E> PartialOrd<Result<T, E>> for Result<T, E> where E: PartialOrd<E>, T: PartialOrd<T>
  • impl<T, E> Result<Option<T>, E>
  • impl<T, E> Result<T, E> where E: Debug
  • impl<T, E> Result<T, E> where E: Deref, T: Deref
  • impl<T, E> Result<T, E> where E: Deref
  • impl<T, E> Result<T, E> where T: Debug
  • impl<T, E> Result<T, E> where T: Default
  • impl<T, E> Result<T, E> where T: Deref
  • impl<T, E> Result<T, E>
  • impl<T, E> Send for Result<T, E> where E: Send, T: Send
  • impl<T, E> Sync for Result<T, E> where E: Sync, T: Sync
  • impl<T, E> Try for Result<T, E>
  • impl<T, U, E> Product<Result<U, E>> for Result<T, E> where T: Product<U>
  • impl<T, U, E> Sum<Result<U, E>> for Result<T, E> where T: Sum<U>

std::ops::Deref

trait Deref {
    type Target: ?Sized;
}

Requires:

  • deref(&self) -> &Self::Target

std::ops::Drop (prelude)

trait Drop

Requires:

  • drop(&mut self)

std::ops::Fn (prelude)

trait Fn<Args>: FnMut<Args>

Requires:

  • call(&self, args: Args) -> Self::Output

std::ops::FnMut (prelude)

trait FnMut<Args>: FnOnce<Args>

Requires:

  • call_mut(&mut self, args: Args) -> Self::Output

std::ops::FnOnce (prelude)

trait FnOnce<Args> {
    type Output;
}

Requires:

  • call_once(self, args: Args) -> Self::Output

std::pin::Pin

struct Pin<P> { /* ... */ }

Methods:

  • new(pointer: P) -> Pin<P>

  • new_unchecked(pointer: P) -> Pin<P>

  • as_ref(&self) -> Pin<&<P as Deref>::Target>

  • as_mut(&mut self) -> Pin<&mut <P as Deref>::Target>

  • set(&mut self, value: <P as Deref>::Target) where <P as Deref>::Target: Sized

  • get_mut(self) -> &'a mut T where T: Unpin

  • get_ref(self) -> &'a T

  • into_ref(self) -> Pin<&'a T>

  • get_unchecked_mut(self) -> &'a mut T

  • map_unchecked<U, F>(self, func: F) -> Pin<&'a U> where F: FnOnce(&T) -> &U

  • map_unchecked_mut<U, F>(self, func: F) -> Pin<&'a mut U> where F: FnOnce(&mut T) -> &mut U

Implements:

  • impl<'_, G> Generator for Pin<&'_ mut G> where G: Generator + ?Sized
  • impl<'a, P, U> DispatchFromDyn<Pin<U>> for Pin<P> where P: DispatchFromDyn<U>
  • impl<G> Generator for Pin<Box<G>> where G: Generator + ?Sized
  • impl<P, Q> PartialEq<Pin<Q>> for Pin<P> where P: PartialEq<Q>
  • impl<P, Q> PartialOrd<Pin<Q>> for Pin<P> where P: PartialOrd<Q>
  • impl<P, U> CoerceUnsized<Pin<U>> for Pin<P> where P: CoerceUnsized<U>
  • impl<P> Clone for Pin<P> where P: Clone
  • impl<P> Copy for Pin<P> where P: Copy
  • impl<P> Debug for Pin<P> where P: Debug
  • impl<P> Deref for Pin<P> where P: Deref
  • impl<P> DerefMut for Pin<P> where P: DerefMut, <P as Deref>::Target: Unpin
  • impl<P> Display for Pin<P> where P: Display
  • impl<P> Eq for Pin<P> where P: Eq
  • impl<P> Future for Pin<P> where P: Unpin + DerefMut, <P as Deref>::Target: Future
  • impl<P> Hash for Pin<P> where P: Hash
  • impl<P> Ord for Pin<P> where P: Ord
  • impl<P> Pointer for Pin<P> where P: Pointer
  • impl<P> Send for Pin<P> where P: Send
  • impl<P> Sync for Pin<P> where P: Sync
  • impl<T> From<Box<T>> for Pin<Box<T>> where T: ?Sized

std::ptr::NonNull

struct NonNull<T>
where
    T: ?Sized

Methods:

  • new_unchecked(ptr: *mut T) -> NonNull<T>

  • dangling() -> NonNull<T>

  • new(ptr: *mut T) -> Option<NonNull<T>>

  • as_ref(&self) -> &T

  • as_mut(&mut self) -> &mut T

  • as_ptr(self) -> *mut T

  • cast<U>(self) -> NonNull<U>

Implements:

  • impl<'a, T> From<&'a T> for NonNull<T> where T: ?Sized
  • impl<'a, T> From<&'a mut T> for NonNull<T> where T: ?Sized
  • impl<T, U> CoerceUnsized<NonNull<U>> for NonNull<T> where T: Unsize<U> + ?Sized, U: ?Sized
  • impl<T, U> DispatchFromDyn<NonNull<U>> for NonNull<T> where T: Unsize<U> + ?Sized, U: ?Sized
  • impl<T: RefUnwindSafe + ?Sized> UnwindSafe for NonNull<T>
  • impl<T> !Send for NonNull<T> where T: ?Sized
  • impl<T> !Sync for NonNull<T> where T: ?Sized
  • impl<T> Clone for NonNull<T> where T: ?Sized
  • impl<T> Copy for NonNull<T> where T: ?Sized
  • impl<T> Debug for NonNull<T> where T: ?Sized
  • impl<T> Eq for NonNull<T> where T: ?Sized
  • impl<T> From<Unique<T>> for NonNull<T> where T: ?Sized
  • impl<T> Hash for NonNull<T> where T: ?Sized
  • impl<T> Ord for NonNull<T> where T: ?Sized
  • impl<T> PartialEq<NonNull<T>> for NonNull<T> where T: ?Sized
  • impl<T> PartialOrd<NonNull<T>> for NonNull<T> where T: ?Sized
  • impl<T> Pointer for NonNull<T> where T: ?Sized

std::string::String (prelude)

struct String

Methods:

  • from_raw_parts( buf: *mut u8, length: usize, capacity: usize ) -> String

  • from_utf16(v: &[u16]) -> Result<String, FromUtf16Error>

  • from_utf16_lossy(v: &[u16]) -> String

  • from_utf8(vec: Vec<u8>) -> Result<String, FromUtf8Error>

  • from_utf8_lossy(v: &'a [u8]) -> Cow<'a, str>

  • from_utf8_unchecked(bytes: Vec<u8>) -> String

  • new() -> String

  • with_capacity(capacity: usize) -> String

  • as_bytes(&self) -> &[u8]

  • as_ptr(&self) -> *const u8

  • as_str(&self) -> &str

  • bytes(&self) -> Bytes

  • capacity(&self) -> usize

  • char_indices(&self) -> CharIndices

  • chars(&self) -> Chars

  • contains<'a, P>(&'a self, pat: P) -> bool where P: Pattern<'a>

  • encode_utf16(&self) -> EncodeUtf16

  • ends_with<'a, P>(&'a self, pat: P) -> bool where P: Pattern<'a>, <P as Pattern<'a>>::Searcher: ReverseSearcher<'a>

  • eq_ignore_ascii_case(&self, other: &str) -> bool

  • escape_debug(&self) -> EscapeDebug

  • escape_default(&self) -> EscapeDefault

  • escape_unicode(&self) -> EscapeUnicode

  • find<'a, P>(&'a self, pat: P) -> Option<usize> where P: Pattern<'a>

  • get<I>(&self, i: I) -> Option<&<I as SliceIndex<str>>::Output> where I: SliceIndex<str>

  • get_unchecked<I>(&self, i: I) -> &<I as SliceIndex<str>>::Output where I: SliceIndex<str>

  • is_ascii(&self) -> bool

  • is_char_boundary(&self, index: usize) -> bool

  • is_empty(&self) -> bool

  • len(&self) -> usize

  • lines(&self) -> Lines

  • lines_any(&self) -> LinesAny

  • match_indices<'a, P>(&'a self, pat: P) -> MatchIndices<'a, P> where P: Pattern<'a>

  • matches<'a, P>(&'a self, pat: P) -> Matches<'a, P> where P: Pattern<'a>

  • parse<F>(&self) -> Result<F, <F as FromStr>::Err> where F: FromStr

  • repeat(&self, n: usize) -> String

  • replace<'a, P>(&'a self, from: P, to: &str) -> String where P: Pattern<'a>

  • replacen<'a, P>(&'a self, pat: P, to: &str, count: usize) -> String where P: Pattern<'a>

  • rfind<'a, P>(&'a self, pat: P) -> Option<usize> where P: Pattern<'a>, <P as Pattern<'a>>::Searcher: ReverseSearcher<'a>

  • rmatch_indices<'a, P>(&'a self, pat: P) -> RMatchIndices<'a, P> where P: Pattern<'a>, <P as Pattern<'a>>::Searcher: ReverseSearcher<'a>

  • rmatches<'a, P>(&'a self, pat: P) -> RMatches<'a, P> where P: Pattern<'a>, <P as Pattern<'a>>::Searcher: ReverseSearcher<'a>

  • rsplit<'a, P>(&'a self, pat: P) -> RSplit<'a, P> where P: Pattern<'a>, <P as Pattern<'a>>::Searcher: ReverseSearcher<'a>

  • rsplit_terminator<'a, P>(&'a self, pat: P) -> RSplitTerminator<'a, P> where P: Pattern<'a>, <P as Pattern<'a>>::Searcher: ReverseSearcher<'a>

  • rsplitn<'a, P>(&'a self, n: usize, pat: P) -> RSplitN<'a, P> where P: Pattern<'a>, <P as Pattern<'a>>::Searcher: ReverseSearcher<'a>

  • slice_unchecked(&self, begin: usize, end: usize) -> &str

  • split<'a, P>(&'a self, pat: P) -> Split<'a, P> where P: Pattern<'a>

  • split_ascii_whitespace(&self) -> SplitAsciiWhitespace

  • split_at(&self, mid: usize) -> (&str, &str)

  • split_terminator<'a, P>(&'a self, pat: P) -> SplitTerminator<'a, P> where P: Pattern<'a>

  • split_whitespace(&self) -> SplitWhitespace

  • splitn<'a, P>(&'a self, n: usize, pat: P) -> SplitN<'a, P> where P: Pattern<'a>

  • starts_with<'a, P>(&'a self, pat: P) -> bool where P: Pattern<'a>

  • to_ascii_lowercase(&self) -> String

  • to_ascii_uppercase(&self) -> String

  • to_lowercase(&self) -> String

  • to_uppercase(&self) -> String

  • trim(&self) -> &str

  • trim_end(&self) -> &str

  • trim_end_matches<'a, P>(&'a self, pat: P) -> &'a str where P: Pattern<'a>, <P as Pattern<'a>>::Searcher: ReverseSearcher<'a>

  • trim_left(&self) -> &str

  • trim_left_matches<'a, P>(&'a self, pat: P) -> &'a str where P: Pattern<'a>

  • trim_matches<'a, P>(&'a self, pat: P) -> &'a str where P: Pattern<'a>, <P as Pattern<'a>>::Searcher: DoubleEndedSearcher<'a>

  • trim_right(&self) -> &str

  • trim_right_matches<'a, P>(&'a self, pat: P) -> &'a str where P: Pattern<'a>, <P as Pattern<'a>>::Searcher: ReverseSearcher<'a>

  • trim_start(&self) -> &str

  • trim_start_matches<'a, P>(&'a self, pat: P) -> &'a str where P: Pattern<'a>

  • as_bytes_mut(&mut self) -> &mut [u8]

  • as_mut_ptr(&mut self) -> *mut u8

  • as_mut_str(&mut self) -> &mut str

  • as_mut_vec(&mut self) -> &mut Vec<u8>

  • clear(&mut self)

  • drain<R>(&mut self, range: R) -> Drain where R: RangeBounds<usize>

  • get_mut<I>( &mut self, i: I ) -> Option<&mut <I as SliceIndex<str>>::Output> where I: SliceIndex<str>

  • get_unchecked_mut<I>( &mut self, i: I ) -> &mut <I as SliceIndex<str>>::Output where I: SliceIndex<str>

  • insert(&mut self, idx: usize, ch: char)

  • insert_str(&mut self, idx: usize, string: &str)

  • make_ascii_lowercase(&mut self)

  • make_ascii_uppercase(&mut self)

  • pop(&mut self) -> Option<char>

  • push(&mut self, ch: char)

  • push_str(&mut self, string: &str)

  • remove(&mut self, idx: usize) -> char

  • replace_range<R>(&mut self, range: R, replace_with: &str) where R: RangeBounds<usize>

  • reserve(&mut self, additional: usize)

  • reserve_exact(&mut self, additional: usize)

  • retain<F>(&mut self, f: F) where F: FnMut(char) -> bool

  • shrink_to(&mut self, min_capacity: usize)

  • shrink_to_fit(&mut self)

  • slice_mut_unchecked( &mut self, begin: usize, end: usize ) -> &mut str

  • split_at_mut(&mut self, mid: usize) -> (&mut str, &mut str)

  • split_off(&mut self, at: usize) -> String

  • truncate(&mut self, new_len: usize)

  • try_reserve( &mut self, additional: usize ) -> Result<(), CollectionAllocErr>

  • try_reserve_exact( &mut self, additional: usize ) -> Result<(), CollectionAllocErr>

  • into_boxed_str(self) -> Box<str>

  • into_bytes(self) -> Vec<u8>

Implements:

  • impl AsRef<OsStr> for String
  • impl AsRef<Path> for String
  • impl AsRef<[u8]> for String
  • impl AsRef<str> for String
  • impl Borrow<str> for String
  • impl Clone for String
  • impl Debug for String
  • impl Default for String
  • impl Deref for String
  • impl DerefMut for String
  • impl Display for String
  • impl Eq for String
  • impl Extend<String> for String
  • impl Extend<char> for String
  • impl From<Box<str>> for String
  • impl From<String> for Arc<str>
  • impl From<String> for Box<dyn Error + Send + Sync>
  • impl From<String> for Box<dyn Error>
  • impl From<String> for Box<str>
  • impl From<String> for OsString
  • impl From<String> for PathBuf
  • impl From<String> for Rc<str>
  • impl From<String> for Vec<u8>
  • impl FromIterator<String> for String
  • impl FromIterator<char> for String
  • impl FromStr for String
  • impl Hash for String
  • impl Index<Range<usize>> for String
  • impl Index<RangeFrom<usize>> for String
  • impl Index<RangeFull> for String
  • impl Index<RangeInclusive<usize>> for String
  • impl Index<RangeTo<usize>> for String
  • impl Index<RangeToInclusive<usize>> for String
  • impl IndexMut<Range<usize>> for String
  • impl IndexMut<RangeFrom<usize>> for String
  • impl IndexMut<RangeFull> for String
  • impl IndexMut<RangeInclusive<usize>> for String
  • impl IndexMut<RangeTo<usize>> for String
  • impl IndexMut<RangeToInclusive<usize>> for String
  • impl Ord for String
  • impl PartialEq<String> for String
  • impl PartialOrd<String> for String
  • impl Send for String
  • impl String
  • impl Sync for String
  • impl ToSocketAddrs for String
  • impl ToString for String
  • impl Write for String
  • impl<'_> Add<&'_ str> for String
  • impl<'_> AddAssign<&'_ str> for String
  • impl<'a, 'b> PartialEq<&'a str> for String
  • impl<'a, 'b> PartialEq<Cow<'a, str>> for String
  • impl<'a, 'b> PartialEq<String> for &'a str
  • impl<'a, 'b> PartialEq<String> for Cow<'a, str>
  • impl<'a, 'b> PartialEq<String> for str
  • impl<'a, 'b> PartialEq<str> for String
  • impl<'a, 'b> Pattern<'a> for &'b String
  • impl<'a> Extend<&'a char> for String
  • impl<'a> Extend<&'a str> for String
  • impl<'a> Extend<Cow<'a, str>> for String
  • impl<'a> From<&'a String> for Cow<'a, str>
  • impl<'a> From<&'a str> for String
  • impl<'a> From<Cow<'a, str>> for String
  • impl<'a> From<String> for Cow<'a, str>
  • impl<'a> FromIterator<&'a char> for String
  • impl<'a> FromIterator<&'a str> for String
  • impl<'a> FromIterator<Cow<'a, str>> for String
  • impl<'a> FromIterator<String> for Cow<'a, str>

std::string::ToString (prelude)

trait ToString

Requires:

  • to_string(&self) -> String

std::vec::Vec (prelude)

struct Vec<T>

Methods:

  • from_raw_parts( ptr: *mut T, length: usize, capacity: usize ) -> Vec<T>

  • new() -> Vec<T>

  • with_capacity(capacity: usize) -> Vec<T>

  • as_ptr(&self) -> *const T

  • as_slice(&self) -> &[T]

  • binary_search(&self, x: &T) -> Result<usize, usize> where T: Ord

  • binary_search_by<'a, F>(&'a self, f: F) -> Result<usize, usize> where F: FnMut(&'a T) -> Ordering

  • binary_search_by_key<'a, B, F>( &'a self, b: &B, f: F ) -> Result<usize, usize> where B: Ord, F: FnMut(&'a T) -> B

  • capacity(&self) -> usize

  • chunks(&self, chunk_size: usize) -> Chunks<T>

  • chunks_exact(&self, chunk_size: usize) -> ChunksExact<T>

  • contains(&self, x: &T) -> bool where T: PartialEq<T>

  • ends_with(&self, needle: &[T]) -> bool where T: PartialEq<T>

  • eq_ignore_ascii_case(&self, other: &[u8]) -> bool

  • first(&self) -> Option<&T>

  • get<I>(&self, index: I) -> Option<&<I as SliceIndex<[T]>>::Output> where I: SliceIndex<[T]>

  • is_ascii(&self) -> bool

  • is_empty(&self) -> bool

  • is_sorted(&self) -> bool where T: PartialOrd<T>

  • is_sorted_by<F>(&self, compare: F) -> bool where F: FnMut(&T, &T) -> Option<Ordering>

  • is_sorted_by_key<F, K>(&self, f: F) -> bool where F: FnMut(&T) -> K, K: PartialOrd<K>

  • iter(&self) -> Iter<T>

  • last(&self) -> Option<&T>

  • len(&self) -> usize

  • align_to<U>(&self) -> (&[T], &[U], &[T])

  • get_unchecked<I>( &self, index: I ) -> &<I as SliceIndex<[T]>>::Output where I: SliceIndex<[T]>

  • rchunks(&self, chunk_size: usize) -> RChunks<T>

  • rchunks_exact(&self, chunk_size: usize) -> RChunksExact<T>

  • repeat(&self, n: usize) -> Vec<T> where T: Copy

  • rsplit<F>(&self, pred: F) -> RSplit<T, F> where F: FnMut(&T) -> bool

  • rsplitn<F>(&self, n: usize, pred: F) -> RSplitN<T, F> where F: FnMut(&T) -> bool

  • split<F>(&self, pred: F) -> Split<T, F> where F: FnMut(&T) -> bool

  • split_at(&self, mid: usize) -> (&[T], &[T])

  • split_first(&self) -> Option<(&T, &[T])>

  • split_last(&self) -> Option<(&T, &[T])>

  • splitn<F>(&self, n: usize, pred: F) -> SplitN<T, F> where F: FnMut(&T) -> bool

  • starts_with(&self, needle: &[T]) -> bool where T: PartialEq<T>

  • to_ascii_lowercase(&self) -> Vec<u8>

  • to_ascii_uppercase(&self) -> Vec<u8>

  • to_vec(&self) -> Vec<T> where T: Clone

  • windows(&self, size: usize) -> Windows<T>

  • align_to_mut<U>(&mut self) -> (&mut [T], &mut [U], &mut [T])

  • append(&mut self, other: &mut Vec<T>)

  • as_mut_ptr(&mut self) -> *mut T

  • as_mut_slice(&mut self) -> &mut [T]

  • chunks_exact_mut(&mut self, chunk_size: usize) -> ChunksExactMut<T>

  • chunks_mut(&mut self, chunk_size: usize) -> ChunksMut<T>

  • clear(&mut self)

  • clone_from_slice(&mut self, src: &[T]) where T: Clone

  • copy_from_slice(&mut self, src: &[T]) where T: Copy

  • copy_within<R>(&mut self, src: R, dest: usize) where R: RangeBounds<usize>, T: Copy

  • dedup(&mut self)

  • dedup_by<F>(&mut self, same_bucket: F) where F: FnMut(&mut T, &mut T) -> bool

  • dedup_by_key<F, K>(&mut self, key: F) where F: FnMut(&mut T) -> K, K: PartialEq<K>

  • drain<R>(&mut self, range: R) -> Drain<T> where R: RangeBounds<usize>

  • drain_filter<F>(&mut self, filter: F) -> DrainFilter<T, F> where F: FnMut(&mut T) -> bool

  • extend_from_slice(&mut self, other: &[T])

  • first_mut(&mut self) -> Option<&mut T>

  • get_mut<I>( &mut self, index: I ) -> Option<&mut <I as SliceIndex<[T]>>::Output> where I: SliceIndex<[T]>

  • get_unchecked_mut<I>( &mut self, index: I ) -> &mut <I as SliceIndex<[T]>>::Output where I: SliceIndex<[T]>

  • insert(&mut self, index: usize, element: T)

  • iter_mut(&mut self) -> IterMut<T>

  • last_mut(&mut self) -> Option<&mut T>

  • make_ascii_lowercase(&mut self)

  • make_ascii_uppercase(&mut self)

  • partition_dedup(&mut self) -> (&mut [T], &mut [T]) where T: PartialEq<T>

  • partition_dedup_by<F>(&mut self, same_bucket: F) -> (&mut [T], &mut [T]) where F: FnMut(&mut T, &mut T) -> bool

  • partition_dedup_by_key<K, F>(&mut self, key: F) -> (&mut [T], &mut [T]) where F: FnMut(&mut T) -> K, K: PartialEq<K>

  • pop(&mut self) -> Option<T>

  • push(&mut self, value: T)

  • rchunks_exact_mut(&mut self, chunk_size: usize) -> RChunksExactMut<T>

  • rchunks_mut(&mut self, chunk_size: usize) -> RChunksMut<T>

  • remove(&mut self, index: usize) -> T

  • remove_item(&mut self, item: &T) -> Option<T>

  • reserve(&mut self, additional: usize)

  • reserve_exact(&mut self, additional: usize)

  • resize(&mut self, new_len: usize, value: T)

  • resize_default(&mut self, new_len: usize)

  • resize_with<F>(&mut self, new_len: usize, f: F) where F: FnMut() -> T

  • retain<F>(&mut self, f: F) where F: FnMut(&T) -> bool

  • reverse(&mut self)

  • rotate_left(&mut self, mid: usize)

  • rotate_right(&mut self, k: usize)

  • rsplit_mut<F>(&mut self, pred: F) -> RSplitMut<T, F> where F: FnMut(&T) -> bool

  • rsplitn_mut<F>(&mut self, n: usize, pred: F) -> RSplitNMut<T, F> where F: FnMut(&T) -> bool

  • set_len(&mut self, new_len: usize)

  • shrink_to(&mut self, min_capacity: usize)

  • shrink_to_fit(&mut self)

  • sort(&mut self) where T: Ord

  • sort_by<F>(&mut self, compare: F) where F: FnMut(&T, &T) -> Ordering

  • sort_by_cached_key<K, F>(&mut self, f: F) where F: FnMut(&T) -> K, K: Ord

  • sort_by_key<K, F>(&mut self, f: F) where F: FnMut(&T) -> K, K: Ord

  • sort_unstable(&mut self) where T: Ord

  • sort_unstable_by<F>(&mut self, compare: F) where F: FnMut(&T, &T) -> Ordering

  • sort_unstable_by_key<K, F>(&mut self, f: F) where F: FnMut(&T) -> K, K: Ord

  • splice<R, I>( &mut self, range: R, replace_with: I ) -> Splice<<I as IntoIterator>::IntoIter> where I: IntoIterator<Item = T>, R: RangeBounds<usize>

  • split_at_mut(&mut self, mid: usize) -> (&mut [T], &mut [T])

  • split_first_mut(&mut self) -> Option<(&mut T, &mut [T])>

  • split_last_mut(&mut self) -> Option<(&mut T, &mut [T])>

  • split_mut<F>(&mut self, pred: F) -> SplitMut<T, F> where F: FnMut(&T) -> bool

  • split_off(&mut self, at: usize) -> Vec<T>

  • splitn_mut<F>(&mut self, n: usize, pred: F) -> SplitNMut<T, F> where F: FnMut(&T) -> bool

  • swap(&mut self, a: usize, b: usize)

  • swap_remove(&mut self, index: usize) -> T

  • swap_with_slice(&mut self, other: &mut [T])

  • truncate(&mut self, len: usize)

  • try_reserve( &mut self, additional: usize ) -> Result<(), CollectionAllocErr>

  • try_reserve_exact( &mut self, additional: usize ) -> Result<(), CollectionAllocErr>

  • into_boxed_slice(self) -> Box<[T]>

Implements:

  • impl From<CString> for Vec<u8>
  • impl From<String> for Vec<u8>
  • impl Write for Vec<u8>
  • impl<'a, 'b, A, B> PartialEq<&'b [B]> for Vec<A> where A: PartialEq<B>
  • impl<'a, 'b, A, B> PartialEq<&'b mut [B]> for Vec<A> where A: PartialEq<B>
  • impl<'a, 'b, A, B> PartialEq<Vec<B>> for Cow<'a, [A]> where A: Clone + PartialEq<B>
  • impl<'a, 'b, A, B> PartialEq<Vec<B>> for Vec<A> where A: PartialEq<B>
  • impl<'a, T> Extend<&'a T> for Vec<T> where T: 'a + Copy
  • impl<'a, T> From<&'a Vec<T>> for Cow<'a, [T]> where T: Clone
  • impl<'a, T> From<&'a [T]> for Vec<T> where T: Clone
  • impl<'a, T> From<&'a mut [T]> for Vec<T> where T: Clone
  • impl<'a, T> From<Cow<'a, [T]>> for Vec<T> where [T]: ToOwned, <[T] as ToOwned>::Owned == Vec<T>
  • impl<'a, T> From<Vec<T>> for Cow<'a, [T]> where T: Clone
  • impl<'a, T> IntoIterator for &'a Vec<T>
  • impl<'a, T> IntoIterator for &'a mut Vec<T>
  • impl<'a> From<&'a str> for Vec<u8>
  • impl<A, B> PartialEq<Vec<B>> for VecDeque<A> where A: PartialEq<B>
  • impl<T, I> Index<I> for Vec<T> where I: SliceIndex<[T]>
  • impl<T, I> IndexMut<I> for Vec<T> where I: SliceIndex<[T]>
  • impl<T> AsMut<Vec<T>> for Vec<T>
  • impl<T> AsMut<[T]> for Vec<T>
  • impl<T> AsRef<Vec<T>> for Vec<T>
  • impl<T> AsRef<[T]> for Vec<T>
  • impl<T> Borrow<[T]> for Vec<T>
  • impl<T> BorrowMut<[T]> for Vec<T>
  • impl<T> Clone for Vec<T> where T: Clone
  • impl<T> Debug for Vec<T> where T: Debug
  • impl<T> Default for Vec<T>
  • impl<T> Deref for Vec<T>
  • impl<T> DerefMut for Vec<T>
  • impl<T> Drop for Vec<T>
  • impl<T> Eq for Vec<T> where T: Eq
  • impl<T> Extend<T> for Vec<T>
  • impl<T> From<BinaryHeap<T>> for Vec<T>
  • impl<T> From<Box<[T]>> for Vec<T>
  • impl<T> From<Vec<T>> for Arc<[T]>
  • impl<T> From<Vec<T>> for BinaryHeap<T> where T: Ord
  • impl<T> From<Vec<T>> for Box<[T]>
  • impl<T> From<Vec<T>> for Rc<[T]>
  • impl<T> From<Vec<T>> for VecDeque<T>
  • impl<T> From<VecDeque<T>> for Vec<T>
  • impl<T> FromIterator<T> for Vec<T>
  • impl<T> Hash for Vec<T> where T: Hash
  • impl<T> IntoIterator for Vec<T>
  • impl<T> Ord for Vec<T> where T: Ord
  • impl<T> PartialOrd<Vec<T>> for Vec<T> where T: PartialOrd<T>
  • impl<T> Send for Vec<T> where T: Send
  • impl<T> Sync for Vec<T> where T: Sync
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment