pub trait ShaderLabel:
Send
+ Sync
+ Debug
+ DynEq
+ DynHash {
// Required method
fn dyn_clone(&self) -> Box<dyn ShaderLabel>;
// Provided method
fn intern(&self) -> Interned<dyn ShaderLabel>
where Self: Sized { ... }
}Expand description
Labels used to uniquely identify types of material shaders
Required Methods§
Sourcefn dyn_clone(&self) -> Box<dyn ShaderLabel>
fn dyn_clone(&self) -> Box<dyn ShaderLabel>
Clones this ShaderLabel.
Provided Methods§
Trait Implementations§
impl Eq for dyn ShaderLabel
Source§impl Hash for dyn ShaderLabel
impl Hash for dyn ShaderLabel
Source§impl Internable for dyn ShaderLabel
impl Internable for dyn ShaderLabel
Source§fn leak(&self) -> &'static dyn ShaderLabel
fn leak(&self) -> &'static dyn ShaderLabel
Creates a static reference to
self, possibly leaking memory.Source§fn ref_eq(&self, other: &(dyn ShaderLabel + 'static)) -> bool
fn ref_eq(&self, other: &(dyn ShaderLabel + 'static)) -> bool
Returns
true if the two references point to the same value.Source§impl PartialEq for dyn ShaderLabel
impl PartialEq for dyn ShaderLabel
Source§fn eq(&self, other: &(dyn ShaderLabel + 'static)) -> bool
fn eq(&self, other: &(dyn ShaderLabel + 'static)) -> bool
Tests for
self and other values to be equal, and is used by ==.Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".