rs::util

Trait CloneOwned

Source
pub trait CloneOwned {
    type Owned;

    // Required method
    fn clone_owned(&self) -> Self::Owned;
}
Expand description

Clones the underlying data structure, like ToOwned.

Required Associated Types§

Required Methods§

Source

fn clone_owned(&self) -> Self::Owned

Implementors§

Source§

impl<T: Clone> CloneOwned for ArcWrapped<T>

ToOwned won’t work here

Source§

type Owned = T

Source§

impl<T: Clone> CloneOwned for Wrapped<T>

ToOwned won’t work here because it’s really difficult to implement Borrow on Wrapped with the Rc<RefCell<>> chain on the way to the data

Source§

type Owned = T