Skip to main content

Resource

Trait Resource 

Source
pub trait Resource:
    IsSubject
    + IsPredicate
    + IsObject
    + IsGraph { }
Expand description

Marker trait for opaque resource handles (e.g. interpretation indices).

Implement via impl_resource!, which also emits the four position-trait impls so the type is usable in every position. The supertraits make R: Resource propagate position-trait bounds automatically — concrete Resource impls must also satisfy IsSubject, IsPredicate, IsObject, and IsGraph, which impl_resource! handles.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl Resource for String

Source§

impl Resource for i32

Source§

impl Resource for i64

Source§

impl Resource for str

Source§

impl Resource for u32

Source§

impl Resource for u64

Source§

impl Resource for usize

Source§

impl<T: Resource + ?Sized> Resource for &T

Implementors§

Source§

impl<T: Resource, M> Resource for Meta<T, M>