pub trait IntoValueDefault<T> {
// Required method
fn into_value_default(self) -> T;
}Expand description
Required Methods§
Sourcefn into_value_default(self) -> T
fn into_value_default(self) -> T
Converts this argument into the default value.
§Returns
The owned default value expected by the read API.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".
Implementations on Foreign Types§
Source§impl IntoValueDefault<String> for &String
impl IntoValueDefault<String> for &String
Source§fn into_value_default(self) -> String
fn into_value_default(self) -> String
Clones the borrowed string into an owned default string.
§Returns
An owned string with the same contents as the input.
Source§impl IntoValueDefault<String> for &str
impl IntoValueDefault<String> for &str
Source§fn into_value_default(self) -> String
fn into_value_default(self) -> String
Copies the borrowed string into an owned default string.
§Returns
An owned string with the same contents as the input.
Source§impl<T, const N: usize> IntoValueDefault<Vec<T>> for &[T; N]where
T: Clone,
impl<T, const N: usize> IntoValueDefault<Vec<T>> for &[T; N]where
T: Clone,
Source§fn into_value_default(self) -> Vec<T>
fn into_value_default(self) -> Vec<T>
Clones the borrowed array elements into an owned default vector.
§Returns
An owned vector preserving the input element order.
Source§impl<T, const N: usize> IntoValueDefault<Vec<T>> for [T; N]
impl<T, const N: usize> IntoValueDefault<Vec<T>> for [T; N]
Source§fn into_value_default(self) -> Vec<T>
fn into_value_default(self) -> Vec<T>
Moves the array elements into an owned default vector.
§Returns
An owned vector preserving the input element order.
Source§impl<T> IntoValueDefault<Vec<T>> for &Vec<T>where
T: Clone,
impl<T> IntoValueDefault<Vec<T>> for &Vec<T>where
T: Clone,
Source§fn into_value_default(self) -> Vec<T>
fn into_value_default(self) -> Vec<T>
Clones the borrowed vector elements into an owned default vector.
§Returns
An owned vector preserving the input element order.
Source§impl<T> IntoValueDefault<Vec<T>> for &[T]where
T: Clone,
impl<T> IntoValueDefault<Vec<T>> for &[T]where
T: Clone,
Source§fn into_value_default(self) -> Vec<T>
fn into_value_default(self) -> Vec<T>
Clones the borrowed slice elements into an owned default vector.
§Returns
An owned vector preserving the input element order.