IntoCaveat

Trait IntoCaveat 

Source
pub trait IntoCaveat: Sized {
    // Required method
    fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>;
}
Expand description

Converts a value T into a Caveat.

Each module can use this to whitelist their types for conversion to Caveat<T>.

Required Methods§

Source

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Any type can be converted to Caveat<T> only a list of Warnings is required.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl IntoCaveat for Cow<'_, str>

Allow Cow<'a, str> to be converted into a Caveat.

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for Tz

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for bool

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for char

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for i8

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for i16

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for i32

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for i64

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for i128

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for u8

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for u16

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for u32

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for u64

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for u128

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for ()

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for DateTime<Utc>

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for NaiveDate

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for NaiveTime

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for TimeDelta

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl IntoCaveat for Decimal

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Source§

impl<T> IntoCaveat for Option<T>
where T: IntoCaveat,

Allow Option<T: IntoCaveat> to be converted into a Caveat.

Source§

fn into_caveat<K: Kind>(self, warnings: Set<K>) -> Caveat<Self, K>

Implementors§

Source§

impl IntoCaveat for ocpi_tariffs::country::Code

Source§

impl IntoCaveat for ocpi_tariffs::currency::Code

Source§

impl IntoCaveat for Source

Source§

impl IntoCaveat for Price