[][src]Trait type_uuid::TypeUuid

pub trait TypeUuid {
    const UUID: Bytes;
}

Provides a statically defined UUID for a Rust type.

Examples

This crate provides a custom derive that allows you to specify a UUID as a human-readable string. This is the recommended way to implement TypeUuid for your types. You can use https://www.uuidgenerator.net to generate random UUIDs to use with the derive.

use type_uuid::TypeUuid;

#[derive(TypeUuid)]
#[uuid = "d4adfc76-f5f4-40b0-8e28-8a51a12f5e46"]
struct MyType;

Associated Constants

const UUID: Bytes

Loading content...

Implementations on Foreign Types

impl TypeUuid for bool[src]

impl TypeUuid for isize[src]

impl TypeUuid for i8[src]

impl TypeUuid for i16[src]

impl TypeUuid for i32[src]

impl TypeUuid for i64[src]

impl TypeUuid for usize[src]

impl TypeUuid for u8[src]

impl TypeUuid for u16[src]

impl TypeUuid for u32[src]

impl TypeUuid for u64[src]

impl TypeUuid for i128[src]

impl TypeUuid for u128[src]

impl TypeUuid for f32[src]

impl TypeUuid for f64[src]

impl TypeUuid for char[src]

impl TypeUuid for str[src]

impl TypeUuid for String[src]

impl TypeUuid for CStr[src]

impl TypeUuid for CString[src]

impl TypeUuid for OsStr[src]

impl TypeUuid for OsString[src]

impl TypeUuid for NonZeroU8[src]

impl TypeUuid for NonZeroU16[src]

impl TypeUuid for NonZeroU32[src]

impl TypeUuid for NonZeroU64[src]

impl TypeUuid for Duration[src]

impl TypeUuid for SystemTime[src]

impl TypeUuid for IpAddr[src]

impl TypeUuid for Ipv4Addr[src]

impl TypeUuid for Ipv6Addr[src]

impl TypeUuid for SocketAddr[src]

impl TypeUuid for SocketAddrV4[src]

impl TypeUuid for SocketAddrV6[src]

impl TypeUuid for Path[src]

impl TypeUuid for PathBuf[src]

impl TypeUuid for ()[src]

Loading content...

Implementors

Loading content...